Commit ab027d28 by Robert Dewar Committed by Arnaud Charlet

exp_ch7.adb [...]: Minor reformatting

2011-08-02  Robert Dewar  <dewar@adacore.com>

	* exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting

From-SVN: r177165
parent b3b28b0c
2011-08-02 Robert Dewar <dewar@adacore.com>
* exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
2011-08-02 Javier Miranda <miranda@adacore.com>
* exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
......
......@@ -6,7 +6,7 @@
-- --
-- B o d y --
-- --
-- Copyright (C) 1992-2010, Free Software Foundation, Inc. --
-- Copyright (C) 1992-2011, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
......@@ -5121,9 +5121,9 @@ package body Exp_Ch6 is
-- Start of processing for Expand_N_Subprogram_Body
begin
-- If this is the main compilation unit and we are generating code for
-- VM targets we generate now the Type Specific Data record of all the
-- enclosing tagged type declarations
-- If this is the main compilation unit, and we are generating code for
-- VM targets, we now generate the Type Specific Data record of all the
-- enclosing tagged type declarations.
-- Temporarily restrict this support to the .NET compiler???
......
......@@ -6,7 +6,7 @@
-- --
-- B o d y --
-- --
-- Copyright (C) 1992-2010, Free Software Foundation, Inc. --
-- Copyright (C) 1992-2011, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
......@@ -1557,7 +1557,7 @@ package body Exp_Ch7 is
Build_Static_Dispatch_Tables (N);
-- In VM targets there is no need to build dispatch tables but
-- we must generate the corresponding Type Specific Data record
-- we must generate the corresponding Type Specific Data record.
-- Temporarily restrict this support to the .NET compiler???
......@@ -1664,23 +1664,22 @@ package body Exp_Ch7 is
if Is_Compilation_Unit (Id)
or else (Is_Generic_Instance (Id)
and then Is_Library_Level_Entity (Id))
and then Is_Library_Level_Entity (Id))
then
if Tagged_Type_Expansion then
Build_Static_Dispatch_Tables (N);
-- In VM targets there is no need to build dispatch tables but
-- we must generate the corresponding Type Specific Data record
-- In VM targets there is no need to build dispatch tables, but we
-- must generate the corresponding Type Specific Data record.
-- Temporarily restrict this support to the .NET compiler???
elsif Unit (Cunit (Main_Unit)) = N
and then VM_Target = CLI_Target
then
-- Enter the scope of the package because the new declarations
-- are appended at the end of the package and must be analyzed
-- in that context.
-- Enter the scope of the package because the new declarations are
-- appended at the end of the package and must be analyzed in that
-- context.
Push_Scope (Id);
......@@ -1721,7 +1720,7 @@ package body Exp_Ch7 is
R : Node_Id;
begin
-- If the restriction No_Finalization applies, then there's not any
-- If the restriction No_Finalization applies, then there isn't a
-- finalization list available to return, so return Empty.
if Restriction_Active (No_Finalization) then
......
......@@ -6,7 +6,7 @@
-- --
-- B o d y --
-- --
-- Copyright (C) 1992-2010, Free Software Foundation, Inc. --
-- Copyright (C) 1992-2011, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
......@@ -478,7 +478,7 @@ package body Exp_Disp is
procedure Build_TSDs (List : List_Id);
-- Build the static dispatch table of tagged types found in the list of
-- declarations. The generated nodes are added at the end of Target_List
-- declarations. Add the generated nodes to the end of Target_List.
procedure Build_Package_TSDs (N : Node_Id);
-- Build static dispatch tables associated with package declaration N
......@@ -6255,9 +6255,9 @@ package body Exp_Disp is
Loc : constant Source_Ptr := Sloc (Typ);
Result : constant List_Id := New_List;
AI : Elmt_Id;
I_Depth : Nat := 0;
I_Depth : Nat := 0; -- why initialized here ???
Iface_Table_Node : Node_Id;
Num_Ifaces : Nat := 0;
Num_Ifaces : Nat := 0; -- why initialized here ???
TSD_Aggr_List : List_Id;
Typ_Ifaces : Elist_Id;
TSD_Tags_List : List_Id;
......@@ -6341,11 +6341,9 @@ package body Exp_Disp is
declare
Type_Is_Library_Level : Entity_Id;
begin
Type_Is_Library_Level :=
Boolean_Literals (Is_Library_Level_Entity (Typ));
Append_To (TSD_Aggr_List,
New_Occurrence_Of (Type_Is_Library_Level, Loc));
end;
......@@ -6382,8 +6380,7 @@ package body Exp_Disp is
Expressions => New_List (
Make_Attribute_Reference (Loc,
Prefix => New_Reference_To (Node (AI), Loc),
Attribute_Name => Name_Tag)
)));
Attribute_Name => Name_Tag))));
Next_Elmt (AI);
end loop;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment