1WCTYPE(3) Linux Programmer's Manual WCTYPE(3)
2
3
4
6 wctype - wide-character classification
7
9 #include <wctype.h>
10
11 wctype_t wctype(const char *name);
12
14 The wctype_t type represents a property which a wide character may or
15 may not have. In other words, it represents a class of wide charac‐
16 ters. This type's nature is implementation-dependent, but the special
17 value (wctype_t) 0 denotes an invalid property. Nonzero wctype_t val‐
18 ues can be passed to the iswctype(3) function to actually test whether
19 a given wide character has the property.
20
21 The wctype() function returns a property, given by its name. The set
22 of valid names depends on the LC_CTYPE category of the current locale,
23 but the following names are valid in all locales.
24
25 "alnum" - realizes the isalnum(3) classification function
26 "alpha" - realizes the isalpha(3) classification function
27 "blank" - realizes the isblank(3) classification function
28 "cntrl" - realizes the iscntrl(3) classification function
29 "digit" - realizes the isdigit(3) classification function
30 "graph" - realizes the isgraph(3) classification function
31 "lower" - realizes the islower(3) classification function
32 "print" - realizes the isprint(3) classification function
33 "punct" - realizes the ispunct(3) classification function
34 "space" - realizes the isspace(3) classification function
35 "upper" - realizes the isupper(3) classification function
36 "xdigit" - realizes the isxdigit(3) classification function
37
39 The wctype() function returns a property descriptor if the name is
40 valid. Otherwise, it returns (wctype_t) 0.
41
43 For an explanation of the terms used in this section, see at‐
44 tributes(7).
45
46 ┌─────────────────────────────────────┬───────────────┬────────────────┐
47 │Interface │ Attribute │ Value │
48 ├─────────────────────────────────────┼───────────────┼────────────────┤
49 │wctype() │ Thread safety │ MT-Safe locale │
50 └─────────────────────────────────────┴───────────────┴────────────────┘
51
53 POSIX.1-2001, POSIX.1-2008, C99.
54
56 The behavior of wctype() depends on the LC_CTYPE category of the cur‐
57 rent locale.
58
60 iswctype(3)
61
63 This page is part of release 5.12 of the Linux man-pages project. A
64 description of the project, information about reporting bugs, and the
65 latest version of this page, can be found at
66 https://www.kernel.org/doc/man-pages/.
67
68
69
70GNU 2021-03-22 WCTYPE(3)