aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Stallman <rms@gnu.org>1992-10-04 04:58:30 +0000
committerRichard Stallman <rms@gnu.org>1992-10-04 04:58:30 +0000
commitbe63d912063987c1f714c37b7dfd76ff06133960 (patch)
tree1d393635e770094a49169aa86108065bd0cbf217 /gcc
parentbf15a311e9a03f87ab9f9c95767c163bb700906b (diff)
downloadgcc-be63d912063987c1f714c37b7dfd76ff06133960.zip
gcc-be63d912063987c1f714c37b7dfd76ff06133960.tar.gz
gcc-be63d912063987c1f714c37b7dfd76ff06133960.tar.bz2
(readescape): No warning if digits in \x are all 0's.
From-SVN: r2318
Diffstat (limited to 'gcc')
-rw-r--r--gcc/c-lex.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/c-lex.c b/gcc/c-lex.c
index 0e07781..bfbc920 100644
--- a/gcc/c-lex.c
+++ b/gcc/c-lex.c
@@ -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))