Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ conv(S) — Xenix 2.3.4

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

ctype(S)



     CONV(S)                  XENIX System V                   CONV(S)



     Name
          conv, toupper, tolower, toascii - Translates characters.

     Syntax
          #include <ctype.h>

          int toupper (c)
          int c;

          int tolower (c)
          int c;

          int _toupper (c)
          int c;

          int _tolower (c)
          int c;

          int toascii (c)
          int c;

     Description
          toupper and tolower convert the argument c to a letter of
          opposite case.  Arguments may be the integers -1 through 255
          (the same values returned by getc(S)).  If the argument of
          toupper represents a lowercase letter, the result is the
          corresponding uppercase letter.  If the argument of tolower
          represents an uppercase letter, the result is the
          corresponding lowercase letter.  All other arguments are
          returned unchanged.

          _toupper and _tolower are macros that accomplish the same
          thing as toupper and tolower but have restricted argument
          values and are faster.  _toupper requires a lowercase letter
          as its argument; its result is the corresponding uppercase
          letter.  _tolower requires an uppercase letter as its
          argument; its result is the corresponding lowercase letter.
          All other arguments cause unpredictable results.

          toascii converts integer values to ASCII characters.  The
          function clears all bits of the integer that are not part of
          a standard ASCII character; it is intended for compatibility
          with other systems.

     See Also
          ctype(S)

     Notes
          Because _toupper and _tolower are implemented as macros,
          they should not be used where unwanted side effects may
          occur.  Removing the _toupper and _tolower macros with the
          #undef directive causes the corresponding library functions



     Page 1                                           (printed 8/7/87)





     CONV(S)                  XENIX System V                   CONV(S)



          to be linked instead.  This allows any arguments to be used
          without worry about side effects.





















































     Page 2                                           (printed 8/7/87)



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