diff options
author | Neil Booth <neil@daikokuya.demon.co.uk> | 2002-05-04 19:42:01 +0000 |
---|---|---|
committer | Neil Booth <neil@gcc.gnu.org> | 2002-05-04 19:42:01 +0000 |
commit | 625458d0b97e2665f53f56832778214e7e7ae6b6 (patch) | |
tree | 93fad2ddad4007e009671f2fd3bcb16a3937b345 /gcc/cpplex.c | |
parent | 916b60b71e4ac6ef8184427616df27b843de4271 (diff) | |
download | gcc-625458d0b97e2665f53f56832778214e7e7ae6b6.zip gcc-625458d0b97e2665f53f56832778214e7e7ae6b6.tar.gz gcc-625458d0b97e2665f53f56832778214e7e7ae6b6.tar.bz2 |
cppinit.c (MAX_WCHAR_TYPE_SIZE): Move to cpplib.h
* cppinit.c (MAX_WCHAR_TYPE_SIZE): Move to cpplib.h
(cpp_post_options): Move sanity checks to...
(sanity_checks): New.
* cpplex.c (maybe_read_ucs): Fix prototype.
(parse_string, cpp_parse_escape): Cast for %c format specifier.
* cpplib.h (cppchar_t): Use unsigned long or unsigned long long
if necessary.
From-SVN: r53163
Diffstat (limited to 'gcc/cpplex.c')
-rw-r--r-- | gcc/cpplex.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/gcc/cpplex.c b/gcc/cpplex.c index 0a26049..51c82b2 100644 --- a/gcc/cpplex.c +++ b/gcc/cpplex.c @@ -80,7 +80,7 @@ static void save_comment PARAMS ((cpp_reader *, cpp_token *, const uchar *, cppchar_t)); static int name_p PARAMS ((cpp_reader *, const cpp_string *)); static int maybe_read_ucs PARAMS ((cpp_reader *, const unsigned char **, - const unsigned char *, unsigned int *)); + const unsigned char *, cppchar_t *)); static tokenrun *next_tokenrun PARAMS ((tokenrun *)); static unsigned int hex_digit_value PARAMS ((unsigned int)); @@ -695,7 +695,7 @@ parse_string (pfile, token, terminator) unterminated: if (CPP_OPTION (pfile, lang) != CLK_ASM || terminator == '>') cpp_error (pfile, DL_ERROR, "missing terminating %c character", - terminator); + (int) terminator); buffer->cur--; break; } @@ -1648,7 +1648,7 @@ maybe_read_ucs (pfile, pstr, limit, pc) cpp_reader *pfile; const unsigned char **pstr; const unsigned char *limit; - unsigned int *pc; + cppchar_t *pc; { const unsigned char *p = *pstr; unsigned int code = 0; @@ -1763,7 +1763,7 @@ cpp_parse_escape (pfile, pstr, limit, wide) case 'e': case 'E': if (CPP_PEDANTIC (pfile)) cpp_error (pfile, DL_PEDWARN, - "non-ISO-standard escape sequence, '\\%c'", c); + "non-ISO-standard escape sequence, '\\%c'", (int) c); c = TARGET_ESC; break; @@ -1838,9 +1838,11 @@ cpp_parse_escape (pfile, pstr, limit, wide) if (unknown) { if (ISGRAPH (c)) - cpp_error (pfile, DL_PEDWARN, "unknown escape sequence '\\%c'", c); + cpp_error (pfile, DL_PEDWARN, + "unknown escape sequence '\\%c'", (int) c); else - cpp_error (pfile, DL_PEDWARN, "unknown escape sequence: '\\%03o'", c); + cpp_error (pfile, DL_PEDWARN, + "unknown escape sequence: '\\%03o'", (int) c); } if (c > mask) |