Use the ctype.h version of isascii() - it doesn't loose precision and think

that 0x100 (int) is an ascii character.

Submitted by:	bde
This commit is contained in:
Peter Wemm 1999-12-28 11:48:23 +00:00
parent 9abf30435b
commit 317b1ddf87
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=55181

View File

@ -165,7 +165,7 @@ extern struct open_file files[];
#define isspace(c) ((c) == ' ' || ((c) >= 0x9 && (c) <= 0xd))
#define isdigit(c) ((c) >= '0' && (c) <= '9')
#define isxdigit(c) (isdigit(c) || ((c) >= 'a' && (c) <= 'f') || ((c) >= 'A' && (c) <= 'F'))
#define isascii(c) (((unsigned char)c) <= 0x7f)
#define isascii(c) (((c) & ~0x7F) == 0)
#define isalpha(c) (isupper(c) || (islower(c)))
static __inline int toupper(int c)