summaryrefslogtreecommitdiff
path: root/include/xlocale
diff options
context:
space:
mode:
authorBaptiste Daroussin <bapt@FreeBSD.org>2015-10-13 20:43:49 +0000
committerBaptiste Daroussin <bapt@FreeBSD.org>2015-10-13 20:43:49 +0000
commitf5dde0166d6658309344f309845075707f207509 (patch)
tree60bcb837e37411501444484bb02600e974770e25 /include/xlocale
parent7cefd8ca2a915e8fe9d5565dcc9a562e67c07970 (diff)
downloadsrc-test2-f5dde0166d6658309344f309845075707f207509.tar.gz
src-test2-f5dde0166d6658309344f309845075707f207509.zip
Commit log from Dragonfly:
FreeBSD extended ctypes to include numbers (e.g. isnumber()) but never actually implemented it. The isnumber() function was equivalent to the isdigit() function in every case. Now that DragonFly's ctype source files have number definitions, the number ctype can finally be implemented. It's given a new flag _CTYPE_N. The isalnum() and iswalnum() functions have been changed to use this flag rather than the _CTYPE_D digit flag. While isalnum(), isnumber(), and their wide equivalents now return different values in locale cases, the ishexnumber() and iswhexnumber() functions are unchanged. They are still aliases for isxdigit() and iswxdigit(). Also change ctype.h for isdigit and isxdigit to use sbistype like the other functions. Obtained from: dragonfly
Notes
Notes: svn path=/projects/collation/; revision=289263
Diffstat (limited to 'include/xlocale')
-rw-r--r--include/xlocale/_ctype.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/xlocale/_ctype.h b/include/xlocale/_ctype.h
index b048c55bbb03..25a9c723c964 100644
--- a/include/xlocale/_ctype.h
+++ b/include/xlocale/_ctype.h
@@ -119,7 +119,7 @@ __sbistype_l(__ct_rune_t __c, unsigned long __f, locale_t __loc)
{ return __sbistype_l(__c, __cat, __l); }
#endif
-XLOCALE_ISCTYPE(alnum, _CTYPE_A|_CTYPE_D)
+XLOCALE_ISCTYPE(alnum, _CTYPE_A|_CTYPE_D|_CTYPE_N)
XLOCALE_ISCTYPE(alpha, _CTYPE_A)
XLOCALE_ISCTYPE(blank, _CTYPE_B)
XLOCALE_ISCTYPE(cntrl, _CTYPE_C)
@@ -128,7 +128,7 @@ XLOCALE_ISCTYPE(graph, _CTYPE_G)
XLOCALE_ISCTYPE(hexnumber, _CTYPE_X)
XLOCALE_ISCTYPE(ideogram, _CTYPE_I)
XLOCALE_ISCTYPE(lower, _CTYPE_L)
-XLOCALE_ISCTYPE(number, _CTYPE_D)
+XLOCALE_ISCTYPE(number, _CTYPE_D|_CTYPE_N)
XLOCALE_ISCTYPE(phonogram, _CTYPE_Q)
XLOCALE_ISCTYPE(print, _CTYPE_R)
XLOCALE_ISCTYPE(punct, _CTYPE_P)