[multiple changes]
authorArnaud Charlet <charlet@gcc.gnu.org>
Thu, 20 Nov 2014 14:41:49 +0000 (15:41 +0100)
committerArnaud Charlet <charlet@gcc.gnu.org>
Thu, 20 Nov 2014 14:41:49 +0000 (15:41 +0100)
2014-11-20  Robert Dewar  <dewar@adacore.com>

* errout.adb (Error_Msg): Don't suppress continuation msgs for
run-time files.
* sem_prag.adb (Analyze_Pragma, case Elaborate): Forbid pragma
Elaborate in SPARK mode.

2014-11-20  Yannick Moy  <moy@adacore.com>

* gnat_rm.texi: Update GNAT RM with rule about expressions in
Update attribute.

From-SVN: r217862

gcc/ada/ChangeLog
gcc/ada/errout.adb
gcc/ada/gnat_rm.texi
gcc/ada/sem_prag.adb

index 5c3df6f..0ccf7ea 100644 (file)
@@ -1,3 +1,15 @@
+2014-11-20  Robert Dewar  <dewar@adacore.com>
+
+       * errout.adb (Error_Msg): Don't suppress continuation msgs for
+       run-time files.
+       * sem_prag.adb (Analyze_Pragma, case Elaborate): Forbid pragma
+       Elaborate in SPARK mode.
+
+2014-11-20  Yannick Moy  <moy@adacore.com>
+
+       * gnat_rm.texi: Update GNAT RM with rule about expressions in
+       Update attribute.
+
 2014-11-20  Thomas Quinot  <quinot@adacore.com>
 
        * g-socket.adb (To_Host_Entry): Guard against case of a
index 911820c..803e2d4 100644 (file)
@@ -308,11 +308,13 @@ package body Errout is
       end if;
 
       --  If we already have messages, and we are trying to place a message at
-      --  No_Location or in package Standard, then just ignore the attempt
-      --  since we assume that what is happening is some cascaded junk. Note
-      --  that this is safe in the sense that proceeding will surely bomb.
+      --  No_Location, then just ignore the attempt since we assume that what
+      --  is happening is some cascaded junk. Note that this is safe in the
+      --  sense that proceeding will surely bomb. We will also bomb if the flag
+      --  location is No_Location and we don't have any messages so far, but
+      --  that is a real bug and a legitimate bomb, so we go ahead.
 
-      if Flag_Location < First_Source_Ptr
+      if Flag_Location = No_Location
         and then Total_Errors_Detected > 0
       then
          return;
index 923957e..3824ee8 100644 (file)
@@ -10146,12 +10146,14 @@ INDEX_EXPRESSION_LIST                        ::= ( EXPRESSION @{, EXPRESSION @}
 @end smallexample
 
 @noindent
-where @code{PREFIX} is the name of an array or record object, and
-the association list in parentheses does not contain an @code{others}
-choice. The effect is to yield a copy of the array or record value which
-is unchanged apart from the components mentioned in the association list, which
-are changed to the indicated value. The original value of the array or
-record value is not affected. For example:
+where @code{PREFIX} is the name of an array or record object, the
+association list in parentheses does not contain an @code{others}
+choice and the box symbol @code{<>} may not appear in any
+expression. The effect is to yield a copy of the array or record value
+which is unchanged apart from the components mentioned in the
+association list, which are changed to the indicated value. The
+original value of the array or record value is not affected. For
+example:
 
 @smallexample @c ada
 type Arr is Array (1 .. 5) of Integer;
index d155b06..94bbf93 100644 (file)
@@ -13125,6 +13125,8 @@ package body Sem_Prag is
             Citem : Node_Id;
 
          begin
+            SPARK_Msg_N ("pragma Elaborate not allowed", N);
+
             --  Pragma must be in context items list of a compilation unit
 
             if not Is_In_Context_Clause then