From: Ed Schonberg Date: Thu, 31 Jul 2008 10:27:42 +0000 (+0200) Subject: exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration): Use Insert_Actions... X-Git-Tag: releases/gcc-4.4.0~3581 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4f6e2c24220fdf6db9992288f40d22bd21ffa2f6;p=thirdparty%2Fgcc.git exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration): Use Insert_Actions to place the pointer declaration in the code... 2008-07-31 Ed Schonberg * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration): Use Insert_Actions to place the pointer declaration in the code, rather than Insert_Before_And_Analyze, so that insertions of temporaries are kept in the proper order when transient scopes are present. From-SVN: r138386 --- diff --git a/gcc/ada/exp_ch6.adb b/gcc/ada/exp_ch6.adb index cddc02102413..3e3c10db2b5c 100644 --- a/gcc/ada/exp_ch6.adb +++ b/gcc/ada/exp_ch6.adb @@ -5496,7 +5496,7 @@ package body Exp_Ch6 is if Is_Constrained (Underlying_Type (Result_Subt)) then Insert_After_And_Analyze (Object_Decl, Ptr_Typ_Decl); else - Insert_Before_And_Analyze (Object_Decl, Ptr_Typ_Decl); + Insert_Action (Object_Decl, Ptr_Typ_Decl); end if; -- Finally, create an access object initialized to a reference to the