This patch does not change the functionality of the compiler. It removes one argument that can be evaluated by the called routine.
No test required. Tested on x86_64-pc-linux-gnu, committed on trunk 2011-08-02 Javier Miranda <mira...@adacore.com> * exp_atag.ads, exp_atag.adb (Build_Common_Dispatching_Select_Statements): Remove argument Loc since its value is implicitly passed in argument Typ. * exp_disp.adb (Make_Disp_Conditional_Select_Body, Make_Disp_Timed_Select_Body): Remove Loc in calls to routine Build_Common_Dispatching_Select_Statements.
Index: exp_atag.adb =================================================================== --- exp_atag.adb (revision 177168) +++ exp_atag.adb (working copy) @@ -71,10 +71,10 @@ ------------------------------------------------ procedure Build_Common_Dispatching_Select_Statements - (Loc : Source_Ptr; - Typ : Entity_Id; + (Typ : Entity_Id; Stmts : List_Id) is + Loc : constant Source_Ptr := Sloc (Typ); Tag_Node : Node_Id; begin Index: exp_atag.ads =================================================================== --- exp_atag.ads (revision 177169) +++ exp_atag.ads (working copy) @@ -35,12 +35,11 @@ -- location used in constructing the corresponding nodes. procedure Build_Common_Dispatching_Select_Statements - (Loc : Source_Ptr; - Typ : Entity_Id; + (Typ : Entity_Id; Stmts : List_Id); - -- Ada 2005 (AI-345): Generate statements that are common between timed, - -- asynchronous, and conditional select expansion. - -- Comments required saying what parameters mean ??? + -- Ada 2005 (AI-345): Build statements that are common to the expansion of + -- timed, asynchronous, and conditional select and append them to Stmts. + -- Typ is the tagged type used for dispatching calls. procedure Build_CW_Membership (Loc : Source_Ptr; Index: exp_disp.adb =================================================================== --- exp_disp.adb (revision 177169) +++ exp_disp.adb (working copy) @@ -2623,7 +2623,7 @@ -- return; -- end if; - Build_Common_Dispatching_Select_Statements (Loc, Typ, Stmts); + Build_Common_Dispatching_Select_Statements (Typ, Stmts); -- Generate: -- Bnn : Communication_Block; @@ -3470,7 +3470,7 @@ -- return; -- end if; - Build_Common_Dispatching_Select_Statements (Loc, Typ, Stmts); + Build_Common_Dispatching_Select_Statements (Typ, Stmts); -- Generate: -- I := Get_Entry_Index (tag! (<type>VP), S);