Changeset a35fc17 in mainline


Ignore:
Timestamp:
2011-07-03T13:26:57Z (13 years ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
4f86fa3
Parents:
a6d908c1
Message:

Add obsolete functions to ctype.h

Location:
uspace/lib/posix
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/posix/ctype.c

    ra6d908c1 ra35fc17  
    108108}
    109109
     110/**
     111 * Checks whether character is ASCII. (obsolete)
     112 *
     113 * @param c
     114 * @return
     115 */
     116extern int posix_isascii(int c)
     117{
     118        return c >= 0 && c < 128;
     119}
     120
     121/**
     122 * Converts argument to a 7-bit ASCII character. (obsolete)
     123 *
     124 * @param c
     125 * @return
     126 */
     127extern int posix_toascii(int c)
     128{
     129        return c & 0x7F;
     130}
     131
    110132/** @}
    111133 */
  • uspace/lib/posix/ctype.h

    ra6d908c1 ra35fc17  
    4747extern int posix_ispunct(int c);
    4848
     49/* Obsolete Functions and Macros */
     50extern int posix_isascii(int c);
     51extern int posix_toascii(int c);
     52#undef _tolower
     53#define _tolower(c) ((c) - 'A' + 'a')
     54#undef _toupper
     55#define _toupper(c) ((c) - 'a' + 'A')
     56
     57
    4958#ifndef LIBPOSIX_INTERNAL
    5059        #define isxdigit posix_isxdigit
     
    5463        #define isprint posix_isprint
    5564        #define ispunct posix_ispunct
     65       
     66        #define isascii posix_isascii
     67        #define toascii posix_toascii
    5668#endif
    5769
Note: See TracChangeset for help on using the changeset viewer.