diff options
Diffstat (limited to 'gcc/ada/exp_ch7.adb')
-rw-r--r-- | gcc/ada/exp_ch7.adb | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/gcc/ada/exp_ch7.adb b/gcc/ada/exp_ch7.adb index 96742e5..4209785 100644 --- a/gcc/ada/exp_ch7.adb +++ b/gcc/ada/exp_ch7.adb @@ -379,10 +379,6 @@ package body Exp_Ch7 is -- references within these nested subprograms (typically generated -- subprograms to handle finalization actions). - function Contains_Subprogram (Blk : Entity_Id) return Boolean; - -- Check recursively whether a loop or block contains a subprogram that - -- may need an activation record. - procedure Check_Visibly_Controlled (Prim : Final_Primitives; Typ : Entity_Id; @@ -400,6 +396,10 @@ package body Exp_Ch7 is -- and use it instead. This is one case that might be solved more cleanly -- once Overriding pragmas or declarations are in place. + function Contains_Subprogram (Blk : Entity_Id) return Boolean; + -- Check recursively whether a loop or block contains a subprogram that + -- may need an activation record. + function Convert_View (Proc : Entity_Id; Arg : Node_Id; @@ -5187,6 +5187,7 @@ package body Exp_Ch7 is Set_Finalizer (Id, Fin_Id); end if; + Check_Unnesting_In_Declarations (Visible_Declarations (Spec)); Check_Unnesting_In_Declarations (Private_Declarations (Spec)); end Expand_N_Package_Declaration; |