diff options
author | H. Peter Anvin <hpa@zytor.com> | 2008-06-21 10:23:17 -0700 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2008-06-21 10:23:17 -0700 |
commit | bda7a6e3715b270ebb0854b3cef667976d241d96 (patch) | |
tree | 86e645d4e025b1dbf0169d0a4ce1c6ec602a15d5 /nasm.h | |
parent | 86877b294aabac1059d32611c8dce65910243454 (diff) | |
download | nasm-bda7a6e3715b270ebb0854b3cef667976d241d96.tar.gz nasm-bda7a6e3715b270ebb0854b3cef667976d241d96.tar.bz2 nasm-bda7a6e3715b270ebb0854b3cef667976d241d96.zip |
ctype.h: wrapper ctype functions with a cast to (unsigned char)
ctype functions take an *int*, which the user is expected to have
taken the input character from getc() and friends, or taken a
character and cast it to (unsigned char).
We don't care about EOF (-1), so use macros that cast to (unsigned
char) for us.
Diffstat (limited to 'nasm.h')
-rw-r--r-- | nasm.h | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -356,13 +356,13 @@ extern Preproc nasmpp; #define isidstart(c) ( isalpha(c) || (c)=='_' || (c)=='.' || (c)=='?' \ || (c)=='@' ) -#define isidchar(c) ( isidstart(c) || isdigit(c) || (c)=='$' || (c)=='#' \ +#define isidchar(c) ( isidstart(c) || nasm_isdigit(c) || (c)=='$' || (c)=='#' \ || (c)=='~' ) /* Ditto for numeric constants. */ -#define isnumstart(c) ( isdigit(c) || (c)=='$' ) -#define isnumchar(c) ( isalnum(c) || (c)=='_' ) +#define isnumstart(c) ( nasm_isdigit(c) || (c)=='$' ) +#define isnumchar(c) ( nasm_isalnum(c) || (c)=='_' ) /* This returns the numeric value of a given 'digit'. */ |