1WCTYPE(3P)                 POSIX Programmer's Manual                WCTYPE(3P)
2
3
4

PROLOG

6       This  manual  page is part of the POSIX Programmer's Manual.  The Linux
7       implementation of this interface may differ (consult the  corresponding
8       Linux  manual page for details of Linux behavior), or the interface may
9       not be implemented on Linux.
10

NAME

12       wctype, wctype_l — define character class
13

SYNOPSIS

15       #include <wctype.h>
16
17       wctype_t wctype(const char *property);
18       wctype_t wctype_l(const char *property, locale_t locale);
19

DESCRIPTION

21       For wctype(): The functionality described on  this  reference  page  is
22       aligned  with the ISO C standard. Any conflict between the requirements
23       described here and the ISO C standard is unintentional. This volume  of
24       POSIX.1‐2017 defers to the ISO C standard.
25
26       The  wctype()  and wctype_l() functions are defined for valid character
27       class names as defined in the current locale or in  the  locale  repre‐
28       sented by locale, respectively.
29
30       The property argument is a string identifying a generic character class
31       for which codeset-specific type information is required. The  following
32       character class names shall be defined in all locales:
33
34
35              alnum   digit   punct
36              alpha   graph   space
37              blank   lower   upper
38              cntrl   print   xdigit
39
40       Additional  character class names defined in the locale definition file
41       (category LC_CTYPE) can also be specified.
42
43       These functions shall return a value of type  wctype_t,  which  can  be
44       used as the second argument to subsequent calls of iswctype() and iswc‐
45       type_l().
46
47       The  wctype()  and  wctype_l()  functions  shall  determine  values  of
48       wctype_t  according  to the rules of the coded character set defined by
49       character type information in the current locale or in the locale  rep‐
50       resented by locale, respectively (category LC_CTYPE).
51
52       The  values  returned by wctype() shall be valid until a call to setlo‐
53       cale() that modifies the category LC_CTYPE.
54
55       The values returned by wctype_l() shall be valid only in calls to iswc‐
56       type_l()  with  a  locale  represented by locale with the same LC_CTYPE
57       category value.
58
59       The behavior is undefined if the locale argument to wctype_l()  is  the
60       special  locale object LC_GLOBAL_LOCALE or is not a valid locale object
61       handle.
62

RETURN VALUE

64       The wctype() and wctype_l() functions shall return 0 if the given char‐
65       acter  class  name  is  not  valid  for  the  current  locale (category
66       LC_CTYPE); otherwise, they shall return an object of type wctype_t that
67       can be used in calls to iswctype() and iswctype_l().
68

ERRORS

70       No errors are defined.
71
72       The following sections are informative.
73

EXAMPLES

75       None.
76

APPLICATION USAGE

78       None.
79

RATIONALE

81       None.
82

FUTURE DIRECTIONS

84       None.
85

SEE ALSO

87       iswctype()
88
89       The Base Definitions volume of POSIX.1‐2017, <wctype.h>
90
92       Portions  of  this text are reprinted and reproduced in electronic form
93       from IEEE Std 1003.1-2017, Standard for Information Technology --  Por‐
94       table  Operating System Interface (POSIX), The Open Group Base Specifi‐
95       cations Issue 7, 2018 Edition, Copyright (C) 2018 by the  Institute  of
96       Electrical  and  Electronics Engineers, Inc and The Open Group.  In the
97       event of any discrepancy between this version and the original IEEE and
98       The  Open Group Standard, the original IEEE and The Open Group Standard
99       is the referee document. The original Standard can be  obtained  online
100       at http://www.opengroup.org/unix/online.html .
101
102       Any  typographical  or  formatting  errors that appear in this page are
103       most likely to have been introduced during the conversion of the source
104       files  to  man page format. To report such errors, see https://www.ker
105       nel.org/doc/man-pages/reporting_bugs.html .
106
107
108
109IEEE/The Open Group                  2017                           WCTYPE(3P)
Impressum