wctrans(3)

wctrans3

Wide-character translation mapping

Usage

#include <wctype.h>

wctrans_t wctrans(const char *name);

Library

Standard C library (libc, -lc)

Overview

The wctrans_t type represents a mapping which can map a wide character to another wide character. Its nature is implementation-dependent, but the special value (wctrans_t) 0 denotes an invalid mapping. Nonzero wctrans_t values can be passed to the towctrans(3) function to actually perform the wide-character mapping.

The wctrans() function returns a mapping, given by its name. The set of valid names depends on the LC_CTYPE category of the current locale, but the following names are valid in all locales.

"tolower" -realizes the tolower(3) mapping
"toupper" -realizes the toupper(3) mapping

Return value

The wctrans() function returns a mapping descriptor if the name is valid. Otherwise, it returns (wctrans_t) 0.

Attributes

For an explanation of the terms used in this section, see attributes(7).

InterfaceAttributeValue
wctrans()Thread safetyMT-Safe locale

Notes

The behavior of wctrans() depends on the LC_CTYPE category of the current locale.

Releases

14 releases since Debian 2.2 (Potato); the text changed 13 times.

  1. 2.2
  2. 3.0
  3. 3.1
  4. 4.0
  5. 5.0
  6. 6.0
  7. 7
  8. 8
  9. 9
  10. 10
  11. 11
  12. 12
  13. 13
  14. Arch

Standards

C11, POSIX.1-2008.

History

POSIX.1-2001, C99.

From man-pages 6.19-1 in Arch Linux 2026-11-01. Parsed by carta from the page's man source.