diff options
author | Arnaud Charlet <charlet@gcc.gnu.org> | 2015-05-12 10:21:47 +0200 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2015-05-12 10:21:47 +0200 |
commit | a0a10853345a395b64e44df41dbb743661301ef0 (patch) | |
tree | 7758316dfe8e369a2ce9f9e4c5ded52a049019d8 /gcc/ada/sem_ch3.adb | |
parent | e23e04db7b649db2d3f575f883385d0aa83aa64f (diff) | |
download | gcc-a0a10853345a395b64e44df41dbb743661301ef0.zip gcc-a0a10853345a395b64e44df41dbb743661301ef0.tar.gz gcc-a0a10853345a395b64e44df41dbb743661301ef0.tar.bz2 |
[multiple changes]
2015-05-12 Tristan Gingold <gingold@adacore.com>
* i-cpoint.adb (Copy_Terminated_Array): Copy nothing if Length is 0.
2015-05-12 Ed Schonberg <schonberg@adacore.com>
* sem_ch3.adb (Complete_Private_Subtype): Propagate
Has_Delayed_Aspects flag from private to full view, to ensure
that predicate functions are constructed.
2015-05-12 Ed Schonberg <schonberg@adacore.com>
* sem_ch6.adb (Process_Formals): If a tagged formal is an
incomplete class-wide type, the subprogram must have a delayed
freeze even though the opertation is not a primitive of the
type. THis ensures that the backend can recover the full view
when elaborating the subprogram declaration.
2015-05-12 Ed Schonberg <schonberg@adacore.com>
* exp_util.adb (Get_Current_Value_Condition): Nothing to be
done if an elsif part has been rewritten so that it is not part
of an enclosing if_statement.
From-SVN: r223040
Diffstat (limited to 'gcc/ada/sem_ch3.adb')
-rw-r--r-- | gcc/ada/sem_ch3.adb | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/gcc/ada/sem_ch3.adb b/gcc/ada/sem_ch3.adb index addfc0a..b8a74d1 100644 --- a/gcc/ada/sem_ch3.adb +++ b/gcc/ada/sem_ch3.adb @@ -11625,7 +11625,8 @@ package body Sem_Ch3 is -- Freeze the private subtype entity if its parent is delayed, and not -- already frozen. We skip this processing if the type is an anonymous -- subtype of a record component, or is the corresponding record of a - -- protected type, since ??? + -- protected type, since these are processed when the enclosing type + -- is frozen. if not Is_Type (Scope (Full)) then Set_Has_Delayed_Freeze (Full, @@ -11804,11 +11805,19 @@ package body Sem_Ch3 is -- Make sure Has_Predicates is set on full type if it is set on the -- private type. Note that it may already be set on the full type and - -- if so, we don't want to unset it. + -- if so, we don't want to unset it. Similarly, propagate information + -- about delayed aspects, because the corresponding pragmas must be + -- analyzed when one of the views is frozen. This last step is needed + -- in particular when the full type is a scalar type for which an + -- anonymous base type is constructed. if Has_Predicates (Priv) then Set_Has_Predicates (Full); end if; + + if Has_Delayed_Aspects (Priv) then + Set_Has_Delayed_Aspects (Full); + end if; end Complete_Private_Subtype; ---------------------------- |