diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 6f08ad2efff..bea321400f3 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,8 @@ +2018-05-28 Eric Botcazou + + * repinfo.adb (Compute_Max_Length): Skip _Parent component. + (List_Record_Layout): Likewise. + 2018-05-28 Ed Schonberg * sem_util.adb (Is_Function_Result): Add a warning if a postcondition diff --git a/gcc/ada/repinfo.adb b/gcc/ada/repinfo.adb index 07c034bf77c..38b2334b3de 100644 --- a/gcc/ada/repinfo.adb +++ b/gcc/ada/repinfo.adb @@ -915,6 +915,12 @@ package body Repinfo is goto Continue; end if; + -- Skip _Parent component in extension (to avoid overlap) + + if Chars (Comp) = Name_uParent then + goto Continue; + end if; + -- All other cases declare @@ -1010,6 +1016,12 @@ package body Repinfo is goto Continue; end if; + -- Skip _Parent component in extension (to avoid overlap) + + if Chars (Comp) = Name_uParent then + goto Continue; + end if; + -- All other cases declare