diff options
Diffstat (limited to 'gcc/ada/sem_ch12.adb')
-rw-r--r-- | gcc/ada/sem_ch12.adb | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/gcc/ada/sem_ch12.adb b/gcc/ada/sem_ch12.adb index c7d1669..0874a03 100644 --- a/gcc/ada/sem_ch12.adb +++ b/gcc/ada/sem_ch12.adb @@ -8207,9 +8207,9 @@ package body Sem_Ch12 is while Scop /= Standard_Standard loop if Scop = Subp then return True; + else + Scop := Scope (Scop); end if; - - Scop := Scope (Scop); end loop; return False; @@ -8257,10 +8257,10 @@ package body Sem_Ch12 is -- the generic body appears textually later, and the generic body is -- also in the main unit. - -- If instance is nested within a subprogram, and the generic body is - -- not, the instance is delayed because the enclosing body is. If - -- instance and body are within the same scope, or the same sub- - -- program body, indicate explicitly that the instance is delayed. + -- If instance is nested within a subprogram, and the generic body + -- is not, the instance is delayed because the enclosing body is. If + -- instance and body are within the same scope, or the same subprogram + -- body, indicate explicitly that the instance is delayed. Must_Delay := (Gen_Unit = Act_Unit @@ -8308,14 +8308,14 @@ package body Sem_Ch12 is -- package Inst is new ... -- In this particular scenario, the freeze node for Inst must - -- be inserted in the same manner as that of Parent_Inst - + -- be inserted in the same manner as that of Parent_Inst, -- before the next source body or at the end of the declarative -- list (body not available). If body P did not exist and -- Parent_Inst was frozen after Inst, either by a body - -- following Inst or at the end of the declarative region, the - -- freeze node for Inst must be inserted after that of - -- Parent_Inst. This relation is established by comparing the - -- Slocs of Parent_Inst freeze node and Inst. + -- following Inst or at the end of the declarative region, + -- the freeze node for Inst must be inserted after that of + -- Parent_Inst. This relation is established by comparing + -- the Slocs of Parent_Inst freeze node and Inst. if List_Containing (Get_Package_Instantiation_Node (Par)) = List_Containing (N) |