diff options
author | zack <zack@138bc75d-0d04-0410-961f-82ee72b054a4> | 2000-05-04 04:38:01 +0000 |
---|---|---|
committer | zack <zack@138bc75d-0d04-0410-961f-82ee72b054a4> | 2000-05-04 04:38:01 +0000 |
commit | e057cf7c280391a0148b6fb6e23947c0ba071ffb (patch) | |
tree | 32af1382b7b6344ab51affdb8e243e9ecedf4e69 /gcc/cppexp.c | |
parent | 187cdc0268474120a8ce52c455f8a25f7ff372eb (diff) | |
download | gcc-e057cf7c280391a0148b6fb6e23947c0ba071ffb.tar.gz |
gcc:
* cpphash.h (U): New define, to correct type of string constants.
(ustrcmp, ustrncmp, ustrlen, uxstrdup, ustrchr): New wrapper
routines, to do casts when passing unsigned strings to libc.
* cppexp.c, cppfiles.c, cpphash.c, cppinit.c, cpplib.c: Use them.
* cppfiles.c (_cpp_execute_include): Make filename an U_CHAR *.
* cpphash.c (_cpp_quote_string): Make string an U_CHAR *.
* cppinit.c (dump_special_to_buffer): Make macro name an U_CHAR *.
* cpplex.c (parse_ifdef, parse_include, validate_else): Make
second argument an U_CHAR *.
* cppinit.c (builtin_array): Make name and value U_CHAR *, add
length field, clean up initializer.
(ISTABLE): Add __extension__ to designated-
initializers version.
* cpplex.c (CHARTAB): Likewise.
* mbchar.c: Add dummy external declaration to the !MULTIBYTE_CHARS
case so the file won't be empty.
include:
* symcat.h: Remove #endif label.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33657 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cppexp.c')
-rw-r--r-- | gcc/cppexp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/cppexp.c b/gcc/cppexp.c index dd7f431d9f3..00eaea73aa2 100644 --- a/gcc/cppexp.c +++ b/gcc/cppexp.c @@ -313,7 +313,7 @@ parse_charconst (pfile, start, end) /* If char type is signed, sign-extend the constant. */ num_bits = num_chars * width; - if (cpp_defined (pfile, (const U_CHAR *)"__CHAR_UNSIGNED__", + if (cpp_defined (pfile, U"__CHAR_UNSIGNED__", sizeof ("__CHAR_UNSIGNED__")-1) || ((result >> (num_bits - 1)) & 1) == 0) op.value = result & ((unsigned HOST_WIDEST_INT) ~0 @@ -439,7 +439,7 @@ lex (pfile, skip_evaluation) return parse_charconst (pfile, tok_start, tok_end); case CPP_NAME: - if (!strncmp (tok_start, "defined", 7)) + if (!ustrncmp (tok_start, U"defined", 7)) return parse_defined (pfile); op.op = INT; |