diff options
author | Arnaud Charlet <charlet@gcc.gnu.org> | 2017-01-19 14:10:09 +0100 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2017-01-19 14:10:09 +0100 |
commit | 6b1d24137789242dd580e98830689a28fc289e8a (patch) | |
tree | 0fc8f6d2af68d79cf97ab6767af3670bf4db0b4c /gcc | |
parent | 104c99ef18d7f5550ef18ca443dc2e4b2ac1641a (diff) | |
download | gcc-6b1d24137789242dd580e98830689a28fc289e8a.zip gcc-6b1d24137789242dd580e98830689a28fc289e8a.tar.gz gcc-6b1d24137789242dd580e98830689a28fc289e8a.tar.bz2 |
[multiple changes]
2017-01-19 Pierre-Marie de Rodat <derodat@adacore.com>
* exp_dbug.adb (Debug_Renaming_Declaration): Process underlying types.
Emit GNAT encodings for object renamings involving record components
whose normalized bit offset is not null.
* uintp.h (UI_No_Uint): Declare.
2017-01-19 Ed Schonberg <schonberg@adacore.com>
* sem_ch5.adb (Analyze_Loop_Statement): In GNATprove mode the
statements within an element iterator loop are only analyzed
agter the loop is rewritten. Within a generic the analysis must
be performed in any case to complete name capture.
2017-01-19 Bob Duff <duff@adacore.com>
* sem_prag.adb (Analyze_Pragma): Check for ignored pragmas first,
before checking for unrecognized pragmas.
Initialize Pname on its declarations; that's always good style.
From-SVN: r244630
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ada/ChangeLog | 20 | ||||
-rw-r--r-- | gcc/ada/sem_ch5.adb | 5 | ||||
-rw-r--r-- | gcc/ada/sem_prag.adb | 16 |
3 files changed, 31 insertions, 10 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 9743e60..8287640 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,23 @@ +2017-01-19 Pierre-Marie de Rodat <derodat@adacore.com> + + * exp_dbug.adb (Debug_Renaming_Declaration): Process underlying types. + Emit GNAT encodings for object renamings involving record components + whose normalized bit offset is not null. + * uintp.h (UI_No_Uint): Declare. + +2017-01-19 Ed Schonberg <schonberg@adacore.com> + + * sem_ch5.adb (Analyze_Loop_Statement): In GNATprove mode the + statements within an element iterator loop are only analyzed + agter the loop is rewritten. Within a generic the analysis must + be performed in any case to complete name capture. + +2017-01-19 Bob Duff <duff@adacore.com> + + * sem_prag.adb (Analyze_Pragma): Check for ignored pragmas first, + before checking for unrecognized pragmas. + Initialize Pname on its declarations; that's always good style. + 2017-01-19 Claire Dross <dross@adacore.com> * exp_ch7.adb (Build_Invariant_Procedure_Body): Semi-insert the diff --git a/gcc/ada/sem_ch5.adb b/gcc/ada/sem_ch5.adb index 1a47be5..0a72320 100644 --- a/gcc/ada/sem_ch5.adb +++ b/gcc/ada/sem_ch5.adb @@ -3411,13 +3411,16 @@ package body Sem_Ch5 is -- expanded). -- In other cases in GNATprove mode then we want to analyze the loop - -- body now, since no rewriting will occur. + -- body now, since no rewriting will occur. Within a generic the + -- GNATprove mode is irrelevant, we must analyze the generic for + -- non-local name capture. if Present (Iter) and then Present (Iterator_Specification (Iter)) then if GNATprove_Mode and then Is_Iterator_Over_Array (Iterator_Specification (Iter)) + and then not Inside_A_Generic then null; diff --git a/gcc/ada/sem_prag.adb b/gcc/ada/sem_prag.adb index 87228eb..9d2490f 100644 --- a/gcc/ada/sem_prag.adb +++ b/gcc/ada/sem_prag.adb @@ -3416,7 +3416,7 @@ package body Sem_Prag is Loc : constant Source_Ptr := Sloc (N); Prag_Id : Pragma_Id; - Pname : Name_Id; + Pname : Name_Id := Pragma_Name (N); -- Name of the source pragma, or name of the corresponding aspect for -- pragmas which originate in a source aspect. In the latter case, the -- name may be different from the pragma name. @@ -10354,9 +10354,13 @@ package body Sem_Prag is Check_Restriction_No_Use_Of_Pragma (N); - -- Deal with unrecognized pragma + -- Ignore pragma if Ignore_Pragma applies - Pname := Pragma_Name (N); + if Get_Name_Table_Boolean3 (Pname) then + return; + end if; + + -- Deal with unrecognized pragma if not Is_Pragma_Name (Pname) then if Warn_On_Unrecognized_Pragma then @@ -10376,12 +10380,6 @@ package body Sem_Prag is return; end if; - -- Ignore pragma if Ignore_Pragma applies - - if Get_Name_Table_Boolean3 (Pname) then - return; - end if; - -- Here to start processing for recognized pragma Prag_Id := Get_Pragma_Id (Pname); |