Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

wctob(3c) [sunos man page]

wctob(3C)						   Standard C Library Functions 						 wctob(3C)

NAME
wctob - wide-character to single-byte conversion SYNOPSIS
#include <stdio.h> #include <wchar.h> int wctob(wint_t c); DESCRIPTION
The wctob() function determines whether c corresponds to a member of the extended character set whose character representation is a single byte when in the initial shift state. The behavior of this function is affected by the LC_CTYPE category of the current locale. See environ(5) RETURN VALUES
The wctob() function returns EOF if c does not correspond to a character with length one in the initial shift state. Otherwise, it returns the single-byte representation of that character. ERRORS
No errors are defined. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Interface Stability |Standard | +-----------------------------+-----------------------------+ |MT-Level |MT-Safe with exceptions | +-----------------------------+-----------------------------+ SEE ALSO
btowc(3C), setlocale(3C), attributes(5), environ(5), standards(5) NOTES
The wctob() function can be used safely in multithreaded applications, as long as setlocale(3C) is not being called to change the locale. SunOS 5.10 14 Aug 2002 wctob(3C)

Check Out this Related Man Page

BTOWC(3)						   BSD Library Functions Manual 						  BTOWC(3)

NAME
btowc, wctob -- convert between wide and single-byte characters LIBRARY
Standard C Library (libc, -lc) SYNOPSIS
#include <wchar.h> wint_t btowc(int c); int wctob(wint_t c); #include <wchar.h> #include <xlocale.h> wint_t btowc_l(int c, locale_t loc); int wctob_l(wint_t c, locale_t loc); DESCRIPTION
The btowc() function converts a single-byte character into a corresponding wide character. If the character is EOF or not valid in the ini- tial shift state, btowc() returns WEOF. The wctob() function converts a wide character into a corresponding single-byte character. If the wide character is WEOF or not able to be represented as a single byte in the initial shift state, wctob() returns EOF. The _l-suffixed versions take an explicit locale argument, while the non-suffixed versions use the current global or per-thread locale. SEE ALSO
mbrtowc(3), multibyte(3), wcrtomb(3) STANDARDS
The btowc() and wctob() functions conform to IEEE Std 1003.1-2001 (``POSIX.1''). HISTORY
The btowc() and wctob() functions first appeared in FreeBSD 5.0. BSD
February 13, 2012 BSD
Man Page