diff options
Diffstat (limited to 'gcc/cpplex.c')
-rw-r--r-- | gcc/cpplex.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/gcc/cpplex.c b/gcc/cpplex.c index a15fcca..f9af8b7 100644 --- a/gcc/cpplex.c +++ b/gcc/cpplex.c @@ -1601,13 +1601,10 @@ static unsigned int hex_digit_value (c) unsigned int c; { - if (c >= 'a' && c <= 'f') - return c - 'a' + 10; - if (c >= 'A' && c <= 'F') - return c - 'A' + 10; - if (c >= '0' && c <= '9') - return c - '0'; - abort (); + if (hex_p (c)) + return hex_value (c); + else + abort (); } /* Parse a '\uNNNN' or '\UNNNNNNNN' sequence. Returns 1 to indicate |