Annotation of mstools/h/tchar.h, revision 1.1.1.2

1.1       root        1: /***
                      2: *tchar.h - definitions for generic international functions
                      3: *
                      4: *      Copyright (c) 1991-1992, Microsoft Corporation. All rights reserved.
                      5: *
                      6: *Purpose:
                      7: *      Definitions for generic international functions, mostly defines
                      8: *      which map string/formatted-io/ctype functions to char or wide-char
                      9: *      versions.
                     10: *
                     11: *      NOTE: it is meaningless to support multibyte/wide-char conversions
                     12: *
                     13: ****/
                     14: 
                     15: #ifndef _INC_TCHAR
                     16: 
                     17: #ifdef __cplusplus
                     18: extern "C" {
                     19: #endif
                     20: 
                     21: 
                     22: /* obsolete: remove any references */
                     23: #define _TSTART
                     24: 
                     25: #ifdef _UNICODE
                     26: 
1.1.1.2 ! root       27: #ifndef _TCHAR_DEFINED
1.1       root       28: typedef wchar_t                TCHAR;
1.1.1.2 ! root       29: #define _TCHAR_DEFINED
        !            30: #endif
        !            31: 
1.1       root       32: #define _T(x)          L ## x
                     33: 
                     34: #define _tprintf       wprintf
                     35: #define _ftprintf      fwprintf
                     36: #define _stprintf      swprintf
                     37: #define _sntprintf     _snwprintf
                     38: #define _vtprintf      vwprintf
                     39: #define _vftprintf     vfwprintf
                     40: #define _vstprintf     vswprintf
                     41: #define _vsntprintf    _vsnwprintf
1.1.1.2 ! root       42: #define _tscanf                wscanf
        !            43: #define _ftscanf       fwscanf
        !            44: #define _stscanf       swscanf
        !            45: 
        !            46: #define _tcstod                wcstod
        !            47: #define _tcstol                wcstol
        !            48: #define _tcstoul       wcstoul
1.1       root       49: 
                     50: #define _tcscat                wcscat
                     51: #define _tcschr                wcschr
                     52: #define _tcscmp                wcscmp
                     53: #define _tcscpy                wcscpy
                     54: #define _tcscspn       wcscspn
                     55: #define _tcslen                wcslen
                     56: #define _tcsncat       wcsncat
                     57: #define _tcsncmp       wcsncmp
                     58: #define _tcsncpy       wcsncpy
                     59: #define _tcspbrk       wcspbrk
                     60: #define _tcsrchr       wcsrchr
                     61: #define _tcsspn                wcsspn
                     62: #define _tcsstr                wcsstr
1.1.1.2 ! root       63: #define _tcstok                wcstok
1.1       root       64: 
                     65: #define _tcsdup                _wcsdup
                     66: #define _tcsicmp       _wcsicmp
                     67: #define _tcsnicmp      _wcsnicmp
                     68: #define _tcsnset       _wcsnset
                     69: #define _tcsrev                _wcsrev
                     70: #define _tcsset                _wcsset
                     71: 
                     72: #define _tcslwr                _wcslwr
                     73: #define _tcsupr                _wcsupr
                     74: #define _tcsxfrm       wcsxfrm
                     75: #define _tcscoll       wcscoll
                     76: #define _tcsicoll      _wcsicoll
                     77: 
                     78: #define _istalpha      iswalpha
                     79: #define _istupper      iswupper
                     80: #define _istlower      iswlower
                     81: #define _istdigit      iswdigit
                     82: #define _istxdigit     iswxdigit
                     83: #define _istspace      iswspace
                     84: #define _istpunct      iswpunct
                     85: #define _istalnum      iswalnum
                     86: #define _istprint      iswprint
                     87: #define _istgraph      iswgraph
                     88: #define _istcntrl      iswcntrl
                     89: #define _istascii      iswascii
                     90: 
                     91: #define _totupper      towupper
                     92: #define _totlower      towlower
                     93: 
                     94: #else
                     95: 
1.1.1.2 ! root       96: #ifndef _TCHAR_DEFINED
1.1       root       97: typedef char           TCHAR;
1.1.1.2 ! root       98: #define _TCHAR_DEFINED
        !            99: #endif
        !           100: 
1.1       root      101: #define _T(x)          x
                    102: 
                    103: #define _tprintf       printf
                    104: #define _ftprintf      fprintf
                    105: #define _stprintf      sprintf
                    106: #define _sntprintf     _snprintf
                    107: #define _vtprintf      vprintf
                    108: #define _vftprintf     vfprintf
                    109: #define _vstprintf     vsprintf
                    110: #define _vsntprintf    _vsnprintf
                    111: #define _tscanf                scanf
                    112: #define _ftscanf       fscanf
                    113: #define _stscanf       sscanf
                    114: 
1.1.1.2 ! root      115: #define _tcstod                strtod
        !           116: #define _tcstol                strtol
        !           117: #define _tcstoul       strtoul
        !           118: 
1.1       root      119: #define _tcscat                strcat
                    120: #define _tcschr                strchr
                    121: #define _tcscmp                strcmp
                    122: #define _tcscpy                strcpy
                    123: #define _tcscspn       strcspn
                    124: #define _tcslen                strlen
                    125: #define _tcsncat       strncat
                    126: #define _tcsncmp       strncmp
                    127: #define _tcsncpy       strncpy
                    128: #define _tcspbrk       strpbrk
                    129: #define _tcsrchr       strrchr
                    130: #define _tcsspn                strspn
                    131: #define _tcsstr                strstr
                    132: #define _tcstok                strtok
                    133: 
                    134: #define _tcsdup                _strdup
                    135: #define _tcsicmp       _stricmp
                    136: #define _tcsnicmp      _strnicmp
                    137: #define _tcsnset       _strnset
                    138: #define _tcsrev                _strrev
                    139: #define _tcsset                _strset
                    140: 
                    141: #define _tcslwr                _strlwr
                    142: #define _tcsupr                _strupr
                    143: #define _tcsxfrm       strxfrm
                    144: #define _tcscoll       strcoll
                    145: #define _tcsicoll      _stricoll
                    146: 
                    147: #define _istalpha      isalpha
                    148: #define _istupper      isupper
                    149: #define _istlower      islower
                    150: #define _istdigit      isdigit
                    151: #define _istxdigit     isxdigit
                    152: #define _istspace      isspace
                    153: #define _istpunct      ispunct
                    154: #define _istalnum      isalnum
                    155: #define _istprint      isprint
                    156: #define _istgraph      isgraph
                    157: #define _istcntrl      iscntrl
                    158: #define _istascii      isascii
                    159: 
                    160: #define _totupper      toupper
                    161: #define _totlower      tolower
                    162: 
                    163: #endif /* _UNICODE */
                    164: 
                    165: #ifdef __cplusplus
                    166: }
                    167: #endif
                    168: 
                    169: #define _INC_TCHAR
                    170: #endif /* _INC_TCHAR */

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.