[multiple changes]
authorArnaud Charlet <charlet@gcc.gnu.org>
Wed, 20 Apr 2016 09:07:12 +0000 (11:07 +0200)
committerArnaud Charlet <charlet@gcc.gnu.org>
Wed, 20 Apr 2016 09:07:12 +0000 (11:07 +0200)
2016-04-20  Vincent Celier  <celier@adacore.com>

* clean.adb (Gnatclean): Fail if project file specified and
gprclean is not available.
* gnatname.adb: Fail is -P is used and gprname is not available.
* make.adb (Initialize): Fail if project file specified and
gprbuild is not available.

2016-04-20  Bob Duff  <duff@adacore.com>

* sem_ch5.adb (Analyze_Iterator_Specification): Do not use secondary
stack when possible.

From-SVN: r235241

gcc/ada/ChangeLog
gcc/ada/clean.adb
gcc/ada/gnatname.adb
gcc/ada/make.adb
gcc/ada/sem_ch5.adb

index 75201ec493e10021fa3ce242f5eb4c86bc6d4b95..fd077b3b01f72b04a8dd931daf83318597c52691 100644 (file)
@@ -1,3 +1,16 @@
+2016-04-20  Vincent Celier  <celier@adacore.com>
+
+       * clean.adb (Gnatclean): Fail if project file specified and
+       gprclean is not available.
+       * gnatname.adb: Fail is -P is used and gprname is not available.
+       * make.adb (Initialize): Fail if project file specified and
+       gprbuild is not available.
+
+2016-04-20  Bob Duff  <duff@adacore.com>
+
+       * sem_ch5.adb (Analyze_Iterator_Specification): Do not use secondary
+       stack when possible.
+
 2016-04-20  Gary Dismukes  <dismukes@adacore.com>
 
        * par_sco.adb, sem_util.adb, sem_ch13.adb: Minor typo corrections and
index 805f65393a8871b111b56985aba63e68c8644708..814f47107b3216efcb586926378767e7e7ec7bdd 100644 (file)
@@ -1386,9 +1386,8 @@ package body Clean is
          --  Warn about 'gnatclean -P'
 
          if Project_File_Name /= null then
-            Put_Line
-              ("warning: gnatclean -P is obsolete and will not be available "
-               & "in the next release; use gprclean instead.");
+            Fail
+              ("project files are no longer supported; use gprclean instead.");
          end if;
 
          --  A project file was specified by a -P switch
index a01bbb20eebcf1dbcf7d326c34eb6f1046b7e3c6..bd0c861204531bf6f22a19e73a966354455c0d47 100644 (file)
@@ -659,9 +659,7 @@ begin
    --  gprname did not succeed.
 
    if Create_Project then
-      Write_Line
-        ("warning: gnatname -P is obsolete and will not be available in the "
-         & "next release; use gprname instead");
+      Fail ("project files are no longer supported; use gprname instead");
    end if;
 
    --  If no Ada or foreign pattern was specified, print the usage and return
index c5bf2b901b8954dfb3974f645e2ed66bad070348..fb70e378a2121892009833c50e3cfdb4062899a9 100644 (file)
@@ -6509,9 +6509,8 @@ package body Make is
       --  Warn about 'gnatmake -P'
 
       if Project_File_Name /= null then
-         Write_Line
-           ("warning: gnatmake -P is obsolete and will not be available "
-            & "in the next release; use gprbuild instead");
+         Make_Failed
+           ("project files are no longer supported; use gprbuild instead");
       end if;
 
       --  If --subdirs= is specified, but not -P, this is equivalent to -D,
index 64b05ff95020075e415a960a3d9ee87b7380f20e..2309ada48a2126500e6e65c287a357292ea2cc0c 100644 (file)
@@ -1753,14 +1753,6 @@ package body Sem_Ch5 is
    ------------------------------------
 
    procedure Analyze_Iterator_Specification (N : Node_Id) is
-      Loc       : constant Source_Ptr := Sloc (N);
-      Def_Id    : constant Node_Id    := Defining_Identifier (N);
-      Subt      : constant Node_Id    := Subtype_Indication (N);
-      Iter_Name : constant Node_Id    := Name (N);
-
-      Typ : Entity_Id;
-      Bas : Entity_Id;
-
       procedure Check_Reverse_Iteration (Typ : Entity_Id);
       --  For an iteration over a container, if the loop carries the Reverse
       --  indicator, verify that the container type has an Iterate aspect that
@@ -1822,6 +1814,16 @@ package body Sem_Ch5 is
          return Etype (Ent);
       end Get_Cursor_Type;
 
+      --  Local variables
+
+      Def_Id    : constant Node_Id    := Defining_Identifier (N);
+      Iter_Name : constant Node_Id    := Name (N);
+      Loc       : constant Source_Ptr := Sloc (N);
+      Subt      : constant Node_Id    := Subtype_Indication (N);
+
+      Bas : Entity_Id;
+      Typ : Entity_Id;
+
    --   Start of processing for Analyze_iterator_Specification
 
    begin
@@ -1925,7 +1927,7 @@ package body Sem_Ch5 is
 
         --  Do not perform this expansion in SPARK mode, since the formal
         --  verification directly deals with the source form of the iterator.
-        --  Ditto for ASIS and when expansion is disabled,, where the temporary
+        --  Ditto for ASIS and when expansion is disabled, where the temporary
         --  may hide the transformation of a selected component into a prefixed
         --  function call, and references need to see the original expression.
 
@@ -2001,7 +2003,7 @@ package body Sem_Ch5 is
             --  to it. It has no effect on the generated code if no actions
             --  are added to it (see Wrap_Transient_Declaration).
 
-            if Expander_Active then
+            if not Is_Array_Type (Typ) and then Expander_Active then
                Establish_Transient_Scope (Name (Decl), Sec_Stack => True);
             end if;