(readescape): No warning if digits in \x are all 0's.
authorRichard Stallman <rms@gnu.org>
Sun, 4 Oct 1992 04:58:30 +0000 (04:58 +0000)
committerRichard Stallman <rms@gnu.org>
Sun, 4 Oct 1992 04:58:30 +0000 (04:58 +0000)
From-SVN: r2318

gcc/c-lex.c

index 0e07781b4bbf89a2fab4ae4fcc75f9712ed741f7..bfbc92027f4f5a512b7c5a93227e241848c570da 100644 (file)
@@ -845,6 +845,9 @@ readescape (ignore_ptr)
        }
       if (! nonnull)
        error ("\\x used with no following hex digits");
+      else if (count == 0)
+       /* Digits are all 0's.  Ok.  */
+       ;
       else if ((count - 1) * 4 >= TYPE_PRECISION (integer_type_node)
               || (count > 1
                   && ((1 << (TYPE_PRECISION (integer_type_node) - (count - 1) * 4))