OSDN Git Service

2011-08-30 Robert Dewar <dewar@adacore.com>
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 30 Aug 2011 14:12:00 +0000 (14:12 +0000)
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 30 Aug 2011 14:12:00 +0000 (14:12 +0000)
* opt.ads, s-soflin.adb, exp_ch9.adb, sem_res.adb: Update comment.
Minor code reorg/reformatting.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@178314 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ada/ChangeLog
gcc/ada/exp_ch9.adb
gcc/ada/opt.ads
gcc/ada/s-soflin.adb
gcc/ada/sem_res.adb

index 47a989f..e39ed6a 100644 (file)
@@ -1,3 +1,8 @@
+2011-08-30  Robert Dewar  <dewar@adacore.com>
+
+       * opt.ads, s-soflin.adb, exp_ch9.adb, sem_res.adb: Update comment.
+       Minor code reorg/reformatting.
+
 2011-08-30  Yannick Moy  <moy@adacore.com>
 
        * opt.adb, opt.ads (Full_Expander_Active): New function defines a
index 7620236..58d6df0 100644 (file)
@@ -4905,6 +4905,7 @@ package body Exp_Ch9 is
 
    begin
       if Full_Expander_Active then
+
          --  If we have no handled statement sequence, we may need to build
          --  a dummy sequence consisting of a null statement. This can be
          --  skipped if the trivial accept optimization is permitted.
@@ -11504,6 +11505,7 @@ package body Exp_Ch9 is
          return;
 
       elsif Full_Expander_Active then
+
          --  Associate discriminals with the first subprogram or entry body to
          --  be expanded.
 
index 3bc4ad9..d50f77b 100644 (file)
@@ -1832,14 +1832,6 @@ package Opt is
    --  behavior can be disabled using switch -gnatd.t which will set this flag
    --  to False and revert to the previous dynamic behavior.
 
-   function Full_Expander_Active return Boolean;
-   --  Returns the value of (Expander_Active and not ALFA_Mode). This "flag"
-   --  indicates that expansion is fully active, that is, not in the reduced
-   --  mode for Alfa (True) or that expansion is either deactivated, or active
-   --  in the reduced mode for Alfa (False). For more information on full
-   --  expansion, see package Expander. For more information on reduced
-   --  Alfa expansion, see package Exp_Alfa.
-
    -----------------------
    -- Tree I/O Routines --
    -----------------------
@@ -1876,17 +1868,24 @@ package Opt is
    --  Used to store the ASIS version number read from a tree file to check if
    --  it is the same as stored in the ASIS version number in Tree_IO.
 
-   ----------------------------------
-   -- Mode for Formal Verification --
-   ----------------------------------
-
-   --  This mode is currently defined through a debug flag
+   -----------------------------------
+   -- Modes for Formal Verification --
+   -----------------------------------
 
    ALFA_Mode : Boolean := False;
    --  Specific compiling mode targeting formal verification through the
    --  generation of Why code for those parts of the input code that belong to
    --  the ALFA subset of Ada. Set by debug flag -gnatd.F.
 
+   function Full_Expander_Active return Boolean;
+   pragma Inline (Full_Expander_Active);
+   --  Returns the value of (Expander_Active and not ALFA_Mode). This "flag"
+   --  indicates that expansion is fully active, that is, not in the reduced
+   --  mode for Alfa (True) or that expansion is either deactivated, or active
+   --  in the reduced mode for Alfa (False). For more information on full
+   --  expansion, see package Expander. For more information on reduced
+   --  Alfa expansion, see package Exp_Alfa.
+
 private
 
    --  The following type is used to save and restore settings of switches in
index f12ed9a..ca3df4a 100644 (file)
@@ -120,11 +120,8 @@ package body System.Soft_Links is
    ----------------
 
    procedure Create_TSD (New_TSD : in out TSD) is
-      use type Parameters.Size_Type;
-
-      SS_Ratio_Dynamic : constant Boolean :=
-                          Parameters.Sec_Stack_Percentage = Parameters.Dynamic;
-
+      use Parameters;
+      SS_Ratio_Dynamic : constant Boolean := Sec_Stack_Percentage = Dynamic;
    begin
       if SS_Ratio_Dynamic then
          SST.SS_Init
index bf3814c..074f5f2 100644 (file)
@@ -8095,6 +8095,7 @@ package body Sem_Res is
          Expander_Mode_Restore;
 
       --  In ALFA_Mode, no magic needed, we just resolve the underlying nodes
+      --  But why is this special handling for ALFA_Mode required ???
 
       else
          Resolve (Condition (N), Typ);