[multiple changes]
2009-10-27 Thomas Quinot <quinot@adacore.com> * sem_ch12.adb (Install_Formal_Packages): Do not omit installation of visible entities when the formal package doesn't have a box. * checks.adb: Minor reformatting. 2009-10-27 Vincent Celier <celier@adacore.com> * prj-part.adb (Parse): Catch exception Types.Unrecoverable_Error and set Project to Empty_Node. 2009-10-27 Robert Dewar <dewar@adacore.com> * gnatbind.adb: Minor reformatting From-SVN: r153593
This commit is contained in:
parent
fdfcc66302
commit
0c0c6f49d5
@ -1,3 +1,19 @@
|
|||||||
|
2009-10-27 Thomas Quinot <quinot@adacore.com>
|
||||||
|
|
||||||
|
* sem_ch12.adb (Install_Formal_Packages): Do not omit installation of
|
||||||
|
visible entities when the formal package doesn't have a box.
|
||||||
|
|
||||||
|
* checks.adb: Minor reformatting.
|
||||||
|
|
||||||
|
2009-10-27 Vincent Celier <celier@adacore.com>
|
||||||
|
|
||||||
|
* prj-part.adb (Parse): Catch exception Types.Unrecoverable_Error and
|
||||||
|
set Project to Empty_Node.
|
||||||
|
|
||||||
|
2009-10-27 Robert Dewar <dewar@adacore.com>
|
||||||
|
|
||||||
|
* gnatbind.adb: Minor reformatting
|
||||||
|
|
||||||
2009-10-27 Arnaud Charlet <charlet@adacore.com>
|
2009-10-27 Arnaud Charlet <charlet@adacore.com>
|
||||||
|
|
||||||
* exp_aggr.adb: Fix comment.
|
* exp_aggr.adb: Fix comment.
|
||||||
|
@ -848,7 +848,7 @@ package body Checks is
|
|||||||
-- is not set anyway, or we are not doing code expansion, or the
|
-- is not set anyway, or we are not doing code expansion, or the
|
||||||
-- parent node is a type conversion whose operand is an arithmetic
|
-- parent node is a type conversion whose operand is an arithmetic
|
||||||
-- operation on signed integers on which the expander can promote
|
-- operation on signed integers on which the expander can promote
|
||||||
-- later the operands to type integer (see Expand_N_Type_Conversion).
|
-- later the operands to type Integer (see Expand_N_Type_Conversion).
|
||||||
|
|
||||||
-- Special case CLI target, where arithmetic overflow checks can be
|
-- Special case CLI target, where arithmetic overflow checks can be
|
||||||
-- performed for integer and long_integer
|
-- performed for integer and long_integer
|
||||||
|
@ -838,12 +838,14 @@ begin
|
|||||||
end if;
|
end if;
|
||||||
end loop;
|
end loop;
|
||||||
|
|
||||||
-- Subunits do not appear in the elaboration table because
|
-- Subunits do not appear in the elaboration table because they
|
||||||
-- they are subsumed by their parent units, but we need to
|
-- are subsumed by their parent units, but we need to list them
|
||||||
-- list them for other tools. For now they are listed after
|
-- for other tools. For now they are listed after other files,
|
||||||
-- other files, rather than following immediately their parent,
|
-- rather than right after their parent, since there is no easy
|
||||||
-- because there is no cheap link between the elaboration table
|
-- link between the elaboration table and the ALIs table ???
|
||||||
-- and the ALIs table.
|
-- Note also that subunits may appear repeatedly in the list,
|
||||||
|
-- if the parent unit appears in the context of several units
|
||||||
|
-- in the closure.
|
||||||
|
|
||||||
for J in Sdep.First .. Sdep.Last loop
|
for J in Sdep.First .. Sdep.Last loop
|
||||||
if Sdep.Table (J).Subunit_Name /= No_Name
|
if Sdep.Table (J).Subunit_Name /= No_Name
|
||||||
@ -853,8 +855,7 @@ begin
|
|||||||
Write_Str (" ");
|
Write_Str (" ");
|
||||||
end if;
|
end if;
|
||||||
|
|
||||||
Write_Str
|
Write_Str (Get_Name_String (Sdep.Table (J).Sfile));
|
||||||
(Get_Name_String (Sdep.Table (J).Sfile));
|
|
||||||
Write_Eol;
|
Write_Eol;
|
||||||
end if;
|
end if;
|
||||||
end loop;
|
end loop;
|
||||||
|
@ -485,19 +485,27 @@ package body Prj.Part is
|
|||||||
return;
|
return;
|
||||||
end if;
|
end if;
|
||||||
|
|
||||||
Parse_Single_Project
|
begin
|
||||||
(In_Tree => In_Tree,
|
Parse_Single_Project
|
||||||
Project => Project,
|
(In_Tree => In_Tree,
|
||||||
Extends_All => Dummy,
|
Project => Project,
|
||||||
Path_Name => Path_Name,
|
Extends_All => Dummy,
|
||||||
Extended => False,
|
Path_Name => Path_Name,
|
||||||
From_Extended => None,
|
Extended => False,
|
||||||
In_Limited => False,
|
From_Extended => None,
|
||||||
Packages_To_Check => Packages_To_Check,
|
In_Limited => False,
|
||||||
Depth => 0,
|
Packages_To_Check => Packages_To_Check,
|
||||||
Current_Dir => Current_Directory,
|
Depth => 0,
|
||||||
Is_Config_File => Is_Config_File,
|
Current_Dir => Current_Directory,
|
||||||
Flags => Flags);
|
Is_Config_File => Is_Config_File,
|
||||||
|
Flags => Flags);
|
||||||
|
|
||||||
|
exception
|
||||||
|
when Types.Unrecoverable_Error =>
|
||||||
|
-- Unrecoverable_Error is raised when a line is too long.
|
||||||
|
-- A meaningful error message will be displayed later.
|
||||||
|
Project := Empty_Node;
|
||||||
|
end;
|
||||||
|
|
||||||
-- If Project is an extending-all project, create the eventual
|
-- If Project is an extending-all project, create the eventual
|
||||||
-- virtual extending projects and check that there are no illegally
|
-- virtual extending projects and check that there are no illegally
|
||||||
|
@ -540,12 +540,9 @@ package body Sem_Ch12 is
|
|||||||
-- initialized before call to Check_Generic_Child_Unit.
|
-- initialized before call to Check_Generic_Child_Unit.
|
||||||
|
|
||||||
procedure Install_Formal_Packages (Par : Entity_Id);
|
procedure Install_Formal_Packages (Par : Entity_Id);
|
||||||
-- If any of the formals of the parent are formal packages with box,
|
-- Install the visible part of any formal of the parent that is a formal
|
||||||
-- their formal parts are visible in the parent and thus in the child
|
-- package. Note that for the case of a formal package with a box, this
|
||||||
-- unit as well. Analogous to what is done in Check_Generic_Actuals
|
-- includes the formal part of the formal package (12.7(10/2)).
|
||||||
-- for the unit itself. This procedure is also used in an instance, to
|
|
||||||
-- make visible the proper entities of the actual for a formal package
|
|
||||||
-- declared with a box.
|
|
||||||
|
|
||||||
procedure Install_Parent (P : Entity_Id; In_Body : Boolean := False);
|
procedure Install_Parent (P : Entity_Id; In_Body : Boolean := False);
|
||||||
-- When compiling an instance of a child unit the parent (which is
|
-- When compiling an instance of a child unit the parent (which is
|
||||||
@ -5217,11 +5214,10 @@ package body Sem_Ch12 is
|
|||||||
|
|
||||||
elsif In_Open_Scopes (Inst_Par) then
|
elsif In_Open_Scopes (Inst_Par) then
|
||||||
|
|
||||||
-- If the parent is already installed verify that the
|
-- If the parent is already installed, install the actuals
|
||||||
-- actuals for its formal packages declared with a box
|
-- for its formal packages. This is necessary when the
|
||||||
-- are already installed. This is necessary when the
|
-- child instance is a child of the parent instance:
|
||||||
-- child instance is a child of the parent instance.
|
-- in this case, the parent is placed on the scope stack
|
||||||
-- In this case the parent is placed on the scope stack
|
|
||||||
-- but the formal packages are not made visible.
|
-- but the formal packages are not made visible.
|
||||||
|
|
||||||
Install_Formal_Packages (Inst_Par);
|
Install_Formal_Packages (Inst_Par);
|
||||||
@ -7191,24 +7187,20 @@ package body Sem_Ch12 is
|
|||||||
if Renamed_Object (E) = Par then
|
if Renamed_Object (E) = Par then
|
||||||
exit;
|
exit;
|
||||||
|
|
||||||
-- The visibility of a formal of an enclosing generic is
|
-- The visibility of a formal of an enclosing generic is already
|
||||||
-- already correct.
|
-- correct.
|
||||||
|
|
||||||
elsif Denotes_Formal_Package (E) then
|
elsif Denotes_Formal_Package (E) then
|
||||||
null;
|
null;
|
||||||
|
|
||||||
elsif Present (Associated_Formal_Package (E))
|
elsif Present (Associated_Formal_Package (E)) then
|
||||||
and then Box_Present (Parent (Associated_Formal_Package (E)))
|
|
||||||
then
|
|
||||||
Check_Generic_Actuals (Renamed_Object (E), True);
|
Check_Generic_Actuals (Renamed_Object (E), True);
|
||||||
Set_Is_Hidden (E, False);
|
Set_Is_Hidden (E, False);
|
||||||
|
|
||||||
-- Find formal package in generic unit that corresponds to
|
-- Find formal package in generic unit that corresponds to
|
||||||
-- (instance of) formal package in instance.
|
-- (instance of) formal package in instance.
|
||||||
|
|
||||||
while Present (Gen_E)
|
while Present (Gen_E) and then Chars (Gen_E) /= Chars (E) loop
|
||||||
and then Chars (Gen_E) /= Chars (E)
|
|
||||||
loop
|
|
||||||
Next_Entity (Gen_E);
|
Next_Entity (Gen_E);
|
||||||
end loop;
|
end loop;
|
||||||
|
|
||||||
@ -8365,7 +8357,7 @@ package body Sem_Ch12 is
|
|||||||
"with volatile actual", Actual);
|
"with volatile actual", Actual);
|
||||||
end if;
|
end if;
|
||||||
|
|
||||||
-- formal in-parameter
|
-- Formal in-parameter
|
||||||
|
|
||||||
else
|
else
|
||||||
-- The instantiation of a generic formal in-parameter is constant
|
-- The instantiation of a generic formal in-parameter is constant
|
||||||
|
Loading…
x
Reference in New Issue
Block a user