about summary refs log tree commit diff
path: root/include
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2015-06-06 18:16:22 +0000
committerRich Felker <dalias@aerifal.cx>2015-06-06 18:16:22 +0000
commit3d7e32d28dc9962e9efc1c317c5b44b5b2df3008 (patch)
tree5bbac0946f27f20dfefbf54ce2adb84a58b8121c /include
parent7e816a6487932cbb3cb71d94b609e50e81f4e5bf (diff)
downloadmusl-3d7e32d28dc9962e9efc1c317c5b44b5b2df3008.tar.gz
musl-3d7e32d28dc9962e9efc1c317c5b44b5b2df3008.tar.xz
musl-3d7e32d28dc9962e9efc1c317c5b44b5b2df3008.zip
add macro version of ctype.h isascii function
presumably internal code (ungetwc and fputwc) was written assuming a
macro implementation existed; otherwise use of isascii is just a
pessimization.
Diffstat (limited to 'include')
-rw-r--r--include/ctype.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/ctype.h b/include/ctype.h
index cd2e0169..7936536f 100644
--- a/include/ctype.h
+++ b/include/ctype.h
@@ -64,6 +64,7 @@ int   isascii(int);
 int   toascii(int);
 #define _tolower(a) ((a)|0x20)
 #define _toupper(a) ((a)&0x5f)
+#define isascii(a) (0 ? isascii(a) : (unsigned)(a) < 128)
 
 #endif