]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
[multiple changes]
authorArnaud Charlet <charlet@gcc.gnu.org>
Wed, 21 May 2014 10:54:48 +0000 (12:54 +0200)
committerArnaud Charlet <charlet@gcc.gnu.org>
Wed, 21 May 2014 10:54:48 +0000 (12:54 +0200)
2014-05-21  Ed Schonberg  <schonberg@adacore.com>

* sem_util.adb: Code clean up.

2014-05-21  Eric Botcazou  <ebotcazou@adacore.com>

* gnat_ugn.texi: Document -Werror.

From-SVN: r210691

gcc/ada/ChangeLog
gcc/ada/gnat_ugn.texi
gcc/ada/sem_util.adb

index b605eca8317260296ca620603581aa62a5d6a12d..7e65a87ccf7897b7912180a6bdeae0ca20c62a2f 100644 (file)
@@ -1,3 +1,11 @@
+2014-05-21  Ed Schonberg  <schonberg@adacore.com>
+
+       * sem_util.adb: Code clean up.
+
+2014-05-21  Eric Botcazou  <ebotcazou@adacore.com>
+
+       * gnat_ugn.texi: Document -Werror.
+
 2014-05-21  Bob Duff  <duff@adacore.com>
 
        * sem_util.adb (Is_Dependent_Component_Of_Mutable_Object):
index 78d682b36b67efb0ca1bfea94a0fe6b49013040e..4912c972755cd0ea29310fe7c8616b112785ce8d 100644 (file)
@@ -5867,6 +5867,12 @@ Conversely, this switch suppresses warnings from the @option{GCC} back end.
 The use of this switch also sets the default front end warning mode to
 @option{-gnatws}, that is, front end warnings suppressed as well.
 
+@item -Werror
+@cindex @option{-Werror}
+This switch causes warnings from the @option{GCC} back end to be treated as
+errors.  The warning string still appears, but the warning messages are
+counted as errors, and prevent the generation of an object file.
+
 @end table
 
 @noindent
index 13e74daf95205c7dc97b3a0f544decba96215eb2..70f7fd44bee16dc20955cd5e93e308cbfbbd9239 100644 (file)
@@ -5521,10 +5521,12 @@ package body Sem_Util is
 
             --  An actual that is the prefix in a prefixed call may have
             --  been rewritten in the call, after the deferred reference
-            --  was collected. Check if sloc and kinds match.
+            --  was collected. Check if sloc and kinds and names match.
 
             elsif Sloc (Actual) = Sloc (N)
+              and then Nkind (Actual) = N_Identifier
               and then Nkind (Actual) = Nkind (N)
+              and then Chars (Actual) = Chars (N)
             then
                return;
 
@@ -9789,7 +9791,7 @@ package body Sem_Util is
 
       if Is_Variable (Object)
         or else (Ada_Version >= Ada_2005
-                   and then Nkind (Deref) = N_Explicit_Dereference)
+                  and then Nkind (Deref) = N_Explicit_Dereference)
       then
          if Nkind (Object) = N_Selected_Component then
             P := Prefix (Object);