exp_ch9.adb (Expand_N_Timed_Entry_Call): Do not attempt expansion in Ravenscar mode.

2009-07-27  Ed Schonberg  <schonberg@adacore.com>

	* exp_ch9.adb (Expand_N_Timed_Entry_Call): Do not attempt expansion in
	Ravenscar mode. Error has already been posted on specification.

	* sem.adb: Further code clean ups.

From-SVN: r150116
This commit is contained in:
Ed Schonberg 2009-07-27 13:41:57 +00:00 committed by Arnaud Charlet
parent 0e47ff5cdd
commit df7c3f6275
3 changed files with 23 additions and 1 deletions

View File

@ -1,3 +1,10 @@
2009-07-27 Ed Schonberg <schonberg@adacore.com>
* exp_ch9.adb (Expand_N_Timed_Entry_Call): Do not attempt expansion in
Ravenscar mode. Error has already been posted on specification.
* sem.adb: Further code clean ups.
2009-07-27 Robert Dewar <dewar@adacore.com>
* g-sse.ads: Minor reformatting

View File

@ -10324,6 +10324,13 @@ package body Exp_Ch9 is
S : Entity_Id; -- Primitive operation slot
begin
-- Under the Ravenscar profile, timed entry calls are excluded. An error
-- was already reported on spec, so do not attempt to expand the call.
if Restriction_Active (No_Select_Statements) then
return;
end if;
-- The arguments in the call may require dynamic allocation, and the
-- call statement may have been transformed into a block. The block
-- may contain additional declarations for internal entities, and the

View File

@ -1680,8 +1680,16 @@ package body Sem is
--------------------
procedure Do_Withed_Unit (Withed_Unit : Node_Id) is
Save_Do_Main : constant Boolean := Do_Main;
begin
-- Do not process the main unit if coming from a with_clause,
-- as would happen with a parent body that has a child spec
-- in its context.
Do_Main := False;
Do_Unit_And_Dependents (Withed_Unit, Unit (Withed_Unit));
Do_Main := Save_Do_Main;
end Do_Withed_Unit;
procedure Do_Withed_Units is new Walk_Withs (Do_Withed_Unit);
@ -1875,7 +1883,7 @@ package body Sem is
and then Present (Library_Unit (Main_CU))
then
Do_Unit_And_Dependents
(Library_Unit (Main_CU), Unit (Library_Unit (Main_CU)));
(Library_Unit (Main_CU), Unit (Library_Unit (Main_CU)));
else
Do_Unit_And_Dependents (Main_CU, Unit (Main_CU));
end if;