diff options
author | Arnaud Charlet <charlet@gcc.gnu.org> | 2010-06-17 09:42:04 +0200 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2010-06-17 09:42:04 +0200 |
commit | b26be063b3ef38c6ddc67e68992a4ecd9c92cd8d (patch) | |
tree | 24565076b0bd54cc2731f9f111de628d53b3aa07 /gcc/ada/scos.ads | |
parent | 038253e614ae4a012cceeffdabd92185164b4f15 (diff) | |
download | gcc-b26be063b3ef38c6ddc67e68992a4ecd9c92cd8d.zip gcc-b26be063b3ef38c6ddc67e68992a4ecd9c92cd8d.tar.gz gcc-b26be063b3ef38c6ddc67e68992a4ecd9c92cd8d.tar.bz2 |
[multiple changes]
2010-06-17 Ed Schonberg <schonberg@adacore.com>
* sem_ch12.adb: propagate Pragma_Enabled flag to generic.
* get_scos.adb: Set C2 flag in decision entry of pragma to 'e' (enabled)
* par_sco.ads, par_sco.adb (Set_SCO_Pragma_Enabled): New procedure
Remove use of Node field in SCOs table
(Output_Header): Set 'd' to initially disable pragma entry
* put_scos.adb (Put_SCOs): New flag indicating if pragma is enabled
* scos.ads, scos.adb: Remove Node field from internal SCOs table.
Use C2 field of pragma decision header to indicate enabled.
* sem_prag.adb: Add calls to Set_SCO_Pragma_Enabled.
* gcc-interface/Make-lang.in: Update dependencies.
2010-06-17 Vincent Celier <celier@adacore.com>
* back_end.adb (Next_Arg): Moved to procedure Scan_Compiler_Arguments
(Scan_Compiler_Arguments): Call Scan_Front_End_Switches with Next_Arg
(Switch_Subsequently_Cancelled): Function moved to the body of Switch.C
* back_end.ads (Scan_Front_End_Switches): Function moved to the body of
Switch.C.
* switch-c.adb: Copied a number of global declarations from back_end.adb
(Len_Arg): New function copied from back_end.adb
(Switch_Subsequently_Cancelled): New function moved from back_end.adb
(Scan_Front_End_Switches): New parameter Arg_Rank used to call
Switch_Subsequently_Cancelled.
* switch-c.ads (Scan_Front_End_Switches): New parameter Arg_Rank.
* gcc-interface/Makefile.in: Add line so that shared libgnat is linked
with -lexc on Tru64.
From-SVN: r160878
Diffstat (limited to 'gcc/ada/scos.ads')
-rw-r--r-- | gcc/ada/scos.ads | 25 |
1 files changed, 10 insertions, 15 deletions
diff --git a/gcc/ada/scos.ads b/gcc/ada/scos.ads index 9e6a973..dc02e28 100644 --- a/gcc/ada/scos.ads +++ b/gcc/ada/scos.ads @@ -286,7 +286,6 @@ package SCOs is type SCO_Table_Entry is record From : Source_Location; To : Source_Location; - Node : Node_Id; C1 : Character; C2 : Character; Last : Boolean; @@ -306,7 +305,6 @@ package SCOs is -- C2 = statement type code to appear on CS line (or ' ' if none) -- From = starting source location -- To = ending source location - -- Node = Empty -- Last = False for all but the last entry, True for last entry -- Note: successive statements (possibly interspersed with entries of @@ -321,32 +319,32 @@ package SCOs is -- C2 = ' ' -- From = IF/EXIT/WHILE token -- To = No_Source_Location - -- Node = Empty -- Last = unused -- Decision (PRAGMA) -- C1 = 'P' - -- C2 = ' ' + -- C2 = 'e'/'d' for enabled/disabled -- From = PRAGMA token -- To = No_Source_Location - -- Node = N_Pragma node or Empty when reading SCO data (see below) -- Last = unused -- Note: when the parse tree is first scanned, we unconditionally build -- a pragma decision entry for any decision in a pragma (here as always - -- in SCO contexts, the only relevant pragmas are Assert, Check, - -- Precondition and Postcondition). Then when we output the SCO info - -- to the ALI file, we use the Node field to check the Pragma_Enabled - -- flag, and if it is False, we suppress output of the pragma decision - -- line. On reading back SCO data from an ALI file, the Node field is - -- always set to Empty. + -- in SCO contexts, the only pragmas with decisions are Assert, Check, + -- Precondition and Postcondition), and we mark the pragma as disabled. + -- + -- During analysis, if the pragma is enabled, Set_SCO_Pragma_Enabled to + -- mark the SCO decision table entry as enabled (C2 set to 'e'). Then + -- in Put_SCOs, we only output the decision for a pragma if C2 is 'e'. + -- + -- When we read SCOs from an ALI file (in Get_SCOs), we always set C2 + -- to 'e', since clearly the pragma is enabled if it was written out. -- Decision (Expression) -- C1 = 'X' -- C2 = ' ' -- From = No_Source_Location -- To = No_Source_Location - -- Node = Empty -- Last = unused -- Operator @@ -354,7 +352,6 @@ package SCOs is -- C2 = ' ' -- From = location of NOT/AND/OR token -- To = No_Source_Location - -- Node = Empty -- Last = False -- Element (condition) @@ -362,7 +359,6 @@ package SCOs is -- C2 = 'c', 't', or 'f' (condition/true/false) -- From = starting source location -- To = ending source location - -- Node = Empty -- Last = False for all but the last entry, True for last entry -- Note: the sequence starting with a decision, and continuing with @@ -415,7 +411,6 @@ package SCOs is To : Source_Location := No_Source_Location; C1 : Character := ' '; C2 : Character := ' '; - Node : Node_Id := Empty; Last : Boolean := False); -- Adds one entry to SCO table with given field values |