aboutsummaryrefslogtreecommitdiff
path: root/lctype.h
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2009-05-18 14:15:14 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2009-05-18 14:15:14 -0300
commit92479f1a8bf62ab3ca0fe69f323407cf02c09719 (patch)
tree44e4d82be8cb4d77b97912a9af3c7798ac919db0 /lctype.h
parente67dc3a22722837a968122a77d9e0398d103378d (diff)
downloadlua-92479f1a8bf62ab3ca0fe69f323407cf02c09719.tar.gz
lua-92479f1a8bf62ab3ca0fe69f323407cf02c09719.tar.bz2
lua-92479f1a8bf62ab3ca0fe69f323407cf02c09719.zip
new property 'lisupper' (needed to compute values for hexa digits)
Diffstat (limited to 'lctype.h')
-rw-r--r--lctype.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/lctype.h b/lctype.h
index 4569ec28..24a19ae7 100644
--- a/lctype.h
+++ b/lctype.h
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lctype.h,v 1.4 2009/03/11 13:27:32 roberto Exp roberto $ 2** $Id: lctype.h,v 1.5 2009/03/26 18:53:52 roberto Exp roberto $
3** 'ctype' functions for Lua 3** 'ctype' functions for Lua
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -18,6 +18,7 @@
18#define PRINTBIT 2 18#define PRINTBIT 2
19#define SPACEBIT 3 19#define SPACEBIT 3
20#define XDIGITBIT 4 20#define XDIGITBIT 4
21#define UPPERBIT 5
21 22
22 23
23#define MASK(B) (1 << (B)) 24#define MASK(B) (1 << (B))
@@ -33,6 +34,7 @@
33*/ 34*/
34#define lislalpha(c) testprop(c, MASK(ALPHABIT)) 35#define lislalpha(c) testprop(c, MASK(ALPHABIT))
35#define lislalnum(c) testprop(c, (MASK(ALPHABIT) | MASK(DIGITBIT))) 36#define lislalnum(c) testprop(c, (MASK(ALPHABIT) | MASK(DIGITBIT)))
37#define lisupper(c) testprop(c, MASK(UPPERBIT))
36#define lisdigit(c) testprop(c, MASK(DIGITBIT)) 38#define lisdigit(c) testprop(c, MASK(DIGITBIT))
37#define lisspace(c) testprop(c, MASK(SPACEBIT)) 39#define lisspace(c) testprop(c, MASK(SPACEBIT))
38#define lisprint(c) testprop(c, MASK(PRINTBIT)) 40#define lisprint(c) testprop(c, MASK(PRINTBIT))