Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ conv(3C) — Reliant UNIX 5.44c4

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

ctype(3C)

setlocale(3C)

getc(3S)

ctype(5)

wctype(5)

conv(3C)                                                           conv(3C)

NAME
     conv: toupper, tolower, toupper, tolower, toascii, towlower,
     towupper - convert characters

SYNOPSIS
     #include <ctype.h>

     int toupper(int c);

     int tolower(int c);

     int toupper(int c);

     int tolower(int c);

     int toascii(int c);

     #include <wctype.h>

     wintt towlower(wint wc);

     wintt towupper(wint wc);

DESCRIPTION
     toupper() and tolower() have as their domain the range of the function
     getc(3S): all the values represented in an unsigned char and the value
     of the macro EOF as defined in stdio.h. If the argument of toupper()
     represents a lower-case letter, the result is the corresponding
     upper-case letter. If the argument of tolower() represents an upper-
     case letter, the result is the corresponding lower-case letter. All
     other arguments in the domain are returned unchanged.

     The macros toupper() and tolower() accomplish the same things as
     toupper() and tolower(), respectively, but have restricted domains and
     are faster. toupper() requires a lower-case letter as its argument;
     its result is the corresponding upper-case letter. tolower() requires
     an upper-case letter as its argument; its result is the corresponding
     lower-case letter. Arguments outside the domain cause undefined
     results.

     toascii() yields its argument with all bits turned off that are not
     part of a standard 7-bit ASCII character; it is intended for compati-
     bility with other systems.

     For an upper-case wide character, the towlower() function returns the
     corresponding lower-case wide character if the corresponding wide
     character exists in lower-case in the locale. The wc argument that is
     passed to the function must be representable with the data type wchart,
     and must match the current language setting or WEOF. If wc does not
     satisfy one of these conditions, the result of the function is unde-
     fined. If the argument passed is not an upper-case wide character, but
     corresponds to the character set of wchart, it will not be converted.



Page 1                       Reliant UNIX 5.44                Printed 11/98

conv(3C)                                                           conv(3C)

     The same applies for the towupper() function, but towupper() returns,
     for a lower-case wide character, the corresponding upper-case wide
     character as defined in the category LCCTYPE.

SEE ALSO
     ctype(3C), setlocale(3C), getc(3S), ctype(5), wctype(5).
















































Page 2                       Reliant UNIX 5.44                Printed 11/98

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026