diff options
author | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-10-11 10:07:06 +0000 |
---|---|---|
committer | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-10-11 10:07:06 +0000 |
commit | 51c733e0f6b4311d6dedf8a494d6fb79a2dd8198 (patch) | |
tree | ea3db1ae3135a8af79bd7e6657e739ecfc21ef62 /gcc/ada/exp_ch6.adb | |
parent | f422e2c4eaca1f04cbb42400da57ff223b0091ab (diff) | |
download | gcc-51c733e0f6b4311d6dedf8a494d6fb79a2dd8198.tar.gz |
2010-10-11 Arnaud Charlet <charlet@adacore.com>
* sem_ch3.adb, exp_ch6.adb
(Make_Build_In_Place_Call_In_Anonymous_Context,
Make_Build_In_Place_Call_In_Assignment,
Make_Build_In_Place_Call_In_Object_Declaration): Fix calls to
Add_Task_Actuals_To_Build_In_Place_Call in case of No_Task_Hierarchy
restriction.
(Access_Definition): Add missing handling of No_Task_Hierarchy.
2010-10-11 Javier Miranda <miranda@adacore.com>
* exp_util.adb (Remove_Side_Effects): No action needed for renamings of
class-wide expressions.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@165293 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/exp_ch6.adb')
-rw-r--r-- | gcc/ada/exp_ch6.adb | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/gcc/ada/exp_ch6.adb b/gcc/ada/exp_ch6.adb index 37df0d549fc..bd365801fda 100644 --- a/gcc/ada/exp_ch6.adb +++ b/gcc/ada/exp_ch6.adb @@ -475,8 +475,8 @@ package body Exp_Ch6 is Master_Actual : Node_Id) -- Note: Master_Actual can be Empty, but only if there are no tasks is - Loc : constant Source_Ptr := Sloc (Function_Call); - + Loc : constant Source_Ptr := Sloc (Function_Call); + Actual : Node_Id := Master_Actual; begin -- No such extra parameters are needed if there are no tasks @@ -484,6 +484,12 @@ package body Exp_Ch6 is return; end if; + -- Use a dummy _master actual in case of No_Task_Hierarchy + + if Restriction_Active (No_Task_Hierarchy) then + Actual := New_Occurrence_Of (RTE (RE_Library_Task_Level), Loc); + end if; + -- The master declare @@ -493,13 +499,13 @@ package body Exp_Ch6 is Master_Formal := Build_In_Place_Formal (Function_Id, BIP_Master); - Analyze_And_Resolve (Master_Actual, Etype (Master_Formal)); + Analyze_And_Resolve (Actual, Etype (Master_Formal)); -- Build the parameter association for the new actual and add it to -- the end of the function's actuals. Add_Extra_Actual_To_Call - (Function_Call, Master_Formal, Master_Actual); + (Function_Call, Master_Formal, Actual); end; -- The activation chain |