ctype.c 34 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119
  1. /* Copyright (C) 2003 Manuel Novoa III
  2. *
  3. * This library is free software; you can redistribute it and/or
  4. * modify it under the terms of the GNU Library General Public
  5. * License as published by the Free Software Foundation; either
  6. * version 2 of the License, or (at your option) any later version.
  7. *
  8. * This library is distributed in the hope that it will be useful,
  9. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  11. * Library General Public License for more details.
  12. *
  13. * You should have received a copy of the GNU Library General Public
  14. * License along with this library; if not, write to the Free
  15. * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  16. */
  17. /* ATTENTION! ATTENTION! ATTENTION! ATTENTION! ATTENTION!
  18. *
  19. * Besides uClibc, I'm using this code in my libc for elks, which is
  20. * a 16-bit environment with a fairly limited compiler. It would make
  21. * things much easier for me if this file isn't modified unnecessarily.
  22. * In particular, please put any new or replacement functions somewhere
  23. * else, and modify the makefile to use your version instead.
  24. * Thanks. Manuel
  25. *
  26. * ATTENTION! ATTENTION! ATTENTION! ATTENTION! ATTENTION! */
  27. #define __NO_CTYPE
  28. #include <ctype.h>
  29. #include <stdio.h>
  30. #include <stdlib.h>
  31. #include <limits.h>
  32. #include <stdint.h>
  33. #include <assert.h>
  34. #include <locale.h>
  35. #ifdef __UCLIBC_HAS_XLOCALE__
  36. libc_hidden_proto(__ctype_b_loc)
  37. #elif defined __UCLIBC_HAS_CTYPE_TABLES__
  38. libc_hidden_proto(__ctype_b)
  39. #endif
  40. #ifdef __UCLIBC_HAS_XLOCALE__
  41. #include <xlocale.h>
  42. #endif /* __UCLIBC_HAS_XLOCALE__ */
  43. /**********************************************************************/
  44. #ifdef __UCLIBC_HAS_CTYPE_TABLES__
  45. #ifdef __UCLIBC_HAS_CTYPE_SIGNED__
  46. #if EOF >= CHAR_MIN
  47. #define CTYPE_DOMAIN_CHECK(C) \
  48. (((unsigned int)((C) - CHAR_MIN)) <= (UCHAR_MAX - CHAR_MIN))
  49. #else
  50. #define CTYPE_DOMAIN_CHECK(C) \
  51. ((((unsigned int)((C) - CHAR_MIN)) <= (UCHAR_MAX - CHAR_MIN)) || ((C) == EOF))
  52. #endif
  53. #else /* __UCLIBC_HAS_CTYPE_SIGNED__ */
  54. #if EOF == -1
  55. #define CTYPE_DOMAIN_CHECK(C) \
  56. (((unsigned int)((C) - EOF)) <= (UCHAR_MAX - EOF))
  57. #else
  58. #define CTYPE_DOMAIN_CHECK(C) \
  59. ((((unsigned int)(C)) <= UCHAR_MAX) || ((C) == EOF))
  60. #endif
  61. #endif /* __UCLIBC_HAS_CTYPE_SIGNED__ */
  62. #endif /* __UCLIBC_HAS_CTYPE_TABLES__ */
  63. /**********************************************************************/
  64. #ifdef __UCLIBC_MJN3_ONLY__
  65. #ifdef L_isspace
  66. /* emit only once */
  67. #warning CONSIDER: Should we assert when debugging and __UCLIBC_HAS_CTYPE_CHECKED?
  68. #warning TODO: Fix asserts in to{upper|lower}{_l}.
  69. #warning TODO: Optimize the isx*() funcs.
  70. #endif
  71. #endif /* __UCLIBC_MJN3_ONLY__ */
  72. /**********************************************************************/
  73. #undef PASTE2
  74. #define PASTE2(X,Y) X ## Y
  75. #ifdef __UCLIBC_HAS_CTYPE_TABLES__
  76. #undef CTYPE_NAME
  77. #undef ISCTYPE
  78. #undef CTYPE_ALIAS
  79. #ifdef __UCLIBC_DO_XLOCALE
  80. #define CTYPE_NAME(X) __is ## X ## _l
  81. #define ISCTYPE(C,F) __isctype_l( C, F, locale_arg)
  82. #define CTYPE_ALIAS(NAME) strong_alias( __is ## NAME ## _l , is ## NAME ## _l)
  83. #else
  84. #define CTYPE_NAME(X) is ## X
  85. #define ISCTYPE(C,F) __isctype( C, F )
  86. #define CTYPE_ALIAS(NAME)
  87. #endif
  88. #undef CTYPE_BODY
  89. #if defined(__UCLIBC_HAS_CTYPE_ENFORCED__)
  90. /* Make sure assert is active for to*() funcs below. */
  91. #undef NDEBUG
  92. #include <assert.h>
  93. extern void __isctype_assert(int c, int mask) __attribute__ ((__noreturn__)) attribute_hidden;
  94. #define CTYPE_BODY(NAME,C,MASK) \
  95. if (CTYPE_DOMAIN_CHECK(C)) { \
  96. return ISCTYPE(C, MASK); \
  97. } \
  98. __isctype_assert(C, MASK);
  99. #elif defined(__UCLIBC_HAS_CTYPE_CHECKED__)
  100. #define CTYPE_BODY(NAME,C,MASK) \
  101. return CTYPE_DOMAIN_CHECK(C) \
  102. ? ISCTYPE(C, MASK) \
  103. : 0;
  104. #elif defined(__UCLIBC_HAS_CTYPE_UNSAFE__)
  105. #define CTYPE_BODY(NAME,C,MASK) \
  106. return ISCTYPE(C, MASK);
  107. #else /* No checking done. */
  108. #error Unknown type of ctype checking!
  109. #endif
  110. #define IS_FUNC_BODY(NAME) \
  111. int CTYPE_NAME(NAME) (int c __LOCALE_PARAM ); \
  112. int CTYPE_NAME(NAME) (int c __LOCALE_PARAM ) \
  113. { \
  114. CTYPE_BODY(NAME,c,PASTE2(_IS,NAME)) \
  115. } \
  116. CTYPE_ALIAS(NAME)
  117. #else /* __UCLIBC_HAS_CTYPE_TABLES__ */
  118. #define C_MACRO(X) PASTE2(__C_is,X)(c)
  119. #define CTYPE_NAME(X) is ## X
  120. #define IS_FUNC_BODY(NAME) \
  121. int CTYPE_NAME(NAME) (int c) \
  122. { \
  123. return C_MACRO(NAME); \
  124. }
  125. #endif /* __UCLIBC_HAS_CTYPE_TABLES__ */
  126. /**********************************************************************/
  127. #ifdef L___ctype_assert
  128. #ifdef __UCLIBC_HAS_CTYPE_ENFORCED__
  129. libc_hidden_proto(fprintf)
  130. libc_hidden_proto(abort)
  131. attribute_hidden void __isctype_assert(int c, int mask)
  132. {
  133. fprintf(stderr, "%s: __is*{_l}(%d,%#x {locale})\n", __uclibc_progname, c, mask);
  134. abort();
  135. }
  136. #endif
  137. #endif
  138. /**********************************************************************/
  139. #if defined(L_isalnum) || defined(L_isalnum_l)
  140. IS_FUNC_BODY(alnum);
  141. #endif
  142. /**********************************************************************/
  143. #if defined(L_isalpha) || defined(L_isalpha_l)
  144. IS_FUNC_BODY(alpha);
  145. #endif
  146. /**********************************************************************/
  147. #if defined(L_isblank) || defined(L_isblank_l)
  148. IS_FUNC_BODY(blank);
  149. #endif
  150. /**********************************************************************/
  151. #if defined(L_iscntrl) || defined(L_iscntrl_l)
  152. IS_FUNC_BODY(cntrl);
  153. #endif
  154. /**********************************************************************/
  155. #if defined(L_isdigit) || defined(L_isdigit_l)
  156. #ifdef __UCLIBC_HAS_CTYPE_TABLES__
  157. /* The standards require EOF < 0. */
  158. #if EOF >= CHAR_MIN
  159. #define __isdigit_char_or_EOF(C) __isdigit_char((C))
  160. #else
  161. #define __isdigit_char_or_EOF(C) __isdigit_int((C))
  162. #endif
  163. int CTYPE_NAME(digit) (int C __LOCALE_PARAM);
  164. int CTYPE_NAME(digit) (int C __LOCALE_PARAM)
  165. {
  166. #if defined(__UCLIBC_HAS_CTYPE_ENFORCED__)
  167. if (CTYPE_DOMAIN_CHECK(C)) {
  168. return __isdigit_char_or_EOF(C); /* C is (unsigned) char or EOF. */
  169. }
  170. __isctype_assert(C, _ISdigit);
  171. #else
  172. return __isdigit_int(C); /* C could be invalid. */
  173. #endif
  174. }
  175. CTYPE_ALIAS(digit)
  176. #else /* __UCLIBC_HAS_CTYPE_TABLES__ */
  177. IS_FUNC_BODY(digit);
  178. #endif /* __UCLIBC_HAS_CTYPE_TABLES__ */
  179. #endif
  180. /**********************************************************************/
  181. #if defined(L_isgraph) || defined(L_isgraph_l)
  182. IS_FUNC_BODY(graph);
  183. #endif
  184. /**********************************************************************/
  185. #if defined(L_islower) || defined(L_islower_l)
  186. IS_FUNC_BODY(lower);
  187. #endif
  188. /**********************************************************************/
  189. #if defined(L_isprint) || defined(L_isprint_l)
  190. IS_FUNC_BODY(print);
  191. #endif
  192. /**********************************************************************/
  193. #if defined(L_ispunct) || defined(L_ispunct_l)
  194. IS_FUNC_BODY(punct);
  195. #endif
  196. /**********************************************************************/
  197. #if defined(L_isspace) || defined(L_isspace_l)
  198. IS_FUNC_BODY(space);
  199. #endif
  200. /**********************************************************************/
  201. #if defined(L_isupper) || defined(L_isupper_l)
  202. IS_FUNC_BODY(upper);
  203. #endif
  204. /**********************************************************************/
  205. #if defined(L_isxdigit) || defined(L_isxdigit_l)
  206. IS_FUNC_BODY(xdigit);
  207. #endif
  208. /**********************************************************************/
  209. #ifdef L_tolower
  210. #undef tolower
  211. #ifdef __UCLIBC_HAS_XLOCALE__
  212. libc_hidden_proto(__ctype_tolower_loc)
  213. #elif defined __UCLIBC_HAS_CTYPE_TABLES__
  214. libc_hidden_proto(__ctype_tolower)
  215. #endif
  216. libc_hidden_proto(tolower)
  217. #ifdef __UCLIBC_HAS_CTYPE_TABLES__
  218. int tolower(int c)
  219. {
  220. #if defined(__UCLIBC_HAS_CTYPE_ENFORCED__)
  221. assert(CTYPE_DOMAIN_CHECK(c));
  222. #endif
  223. return __UCLIBC_CTYPE_IN_TO_DOMAIN(c) ? (__UCLIBC_CTYPE_TOLOWER)[c] : c;
  224. }
  225. #else /* __UCLIBC_HAS_CTYPE_TABLES__ */
  226. int tolower(int c)
  227. {
  228. return __C_tolower(c);
  229. }
  230. #endif /* __UCLIBC_HAS_CTYPE_TABLES__ */
  231. libc_hidden_def(tolower)
  232. #endif
  233. /**********************************************************************/
  234. #ifdef L_tolower_l
  235. #undef tolower_l
  236. libc_hidden_proto(tolower_l)
  237. int tolower_l(int c, __locale_t l)
  238. {
  239. #if defined(__UCLIBC_HAS_CTYPE_ENFORCED__)
  240. assert(CTYPE_DOMAIN_CHECK(c));
  241. #endif
  242. return __UCLIBC_CTYPE_IN_TO_DOMAIN(c) ? l->__ctype_tolower[c] : c;
  243. }
  244. libc_hidden_def(tolower_l)
  245. weak_alias (tolower_l, __tolower_l)
  246. #endif
  247. /**********************************************************************/
  248. #ifdef L_toupper
  249. #undef toupper
  250. #ifdef __UCLIBC_HAS_XLOCALE__
  251. libc_hidden_proto(__ctype_toupper_loc)
  252. #elif defined __UCLIBC_HAS_CTYPE_TABLES__
  253. libc_hidden_proto(__ctype_toupper)
  254. #endif
  255. libc_hidden_proto(toupper)
  256. #ifdef __UCLIBC_HAS_CTYPE_TABLES__
  257. int toupper(int c)
  258. {
  259. #if defined(__UCLIBC_HAS_CTYPE_ENFORCED__)
  260. assert(CTYPE_DOMAIN_CHECK(c));
  261. #endif
  262. return __UCLIBC_CTYPE_IN_TO_DOMAIN(c) ? (__UCLIBC_CTYPE_TOUPPER)[c] : c;
  263. }
  264. #else /* __UCLIBC_HAS_CTYPE_TABLES__ */
  265. int toupper(int c)
  266. {
  267. return __C_toupper(c);
  268. }
  269. #endif /* __UCLIBC_HAS_CTYPE_TABLES__ */
  270. libc_hidden_def(toupper)
  271. #endif
  272. /**********************************************************************/
  273. #ifdef L_toupper_l
  274. #undef toupper_l
  275. libc_hidden_proto(toupper_l)
  276. int toupper_l(int c, __locale_t l)
  277. {
  278. #if defined(__UCLIBC_HAS_CTYPE_ENFORCED__)
  279. assert(CTYPE_DOMAIN_CHECK(c));
  280. #endif
  281. return __UCLIBC_CTYPE_IN_TO_DOMAIN(c) ? l->__ctype_toupper[c] : c;
  282. }
  283. libc_hidden_def(toupper_l)
  284. weak_alias (toupper_l, __toupper_l)
  285. #endif
  286. /**********************************************************************/
  287. #if defined(L_isascii) || defined(L_isascii_l)
  288. #ifdef __UCLIBC_HAS_CTYPE_TABLES__
  289. int __XL_NPP(isascii)(int c);
  290. int __XL_NPP(isascii)(int c)
  291. {
  292. return __isascii(c); /* locale-independent */
  293. }
  294. #else /* __UCLIBC_HAS_CTYPE_TABLES__ */
  295. libc_hidden_proto(isascii)
  296. int isascii(int c)
  297. {
  298. return __isascii(c); /* locale-independent */
  299. }
  300. libc_hidden_def(isascii)
  301. #endif /* __UCLIBC_HAS_CTYPE_TABLES__ */
  302. #endif
  303. /**********************************************************************/
  304. #if defined(L_toascii) || defined(L_toascii_l)
  305. #ifdef __UCLIBC_HAS_CTYPE_TABLES__
  306. int __XL_NPP(toascii)(int c);
  307. int __XL_NPP(toascii)(int c)
  308. {
  309. return __toascii(c); /* locale-independent */
  310. }
  311. #else /* __UCLIBC_HAS_CTYPE_TABLES__ */
  312. int toascii(int c)
  313. {
  314. return __toascii(c); /* locale-independent */
  315. }
  316. #endif /* __UCLIBC_HAS_CTYPE_TABLES__ */
  317. #endif
  318. /**********************************************************************/
  319. /* glibc extensions */
  320. /**********************************************************************/
  321. #ifdef L_isctype
  322. int isctype(int c, int mask)
  323. {
  324. CTYPE_BODY(NAME,c,mask)
  325. }
  326. #endif
  327. /**********************************************************************/
  328. #ifdef L___ctype_b_loc
  329. #ifdef __UCLIBC_HAS_XLOCALE__
  330. const __ctype_mask_t **__ctype_b_loc(void)
  331. {
  332. return &(__UCLIBC_CURLOCALE_DATA).__ctype_b;
  333. }
  334. libc_hidden_def(__ctype_b_loc)
  335. #endif
  336. #endif
  337. /**********************************************************************/
  338. #ifdef L___ctype_tolower_loc
  339. #ifdef __UCLIBC_HAS_XLOCALE__
  340. libc_hidden_proto(__ctype_tolower_loc)
  341. const __ctype_touplow_t **__ctype_tolower_loc(void)
  342. {
  343. return &(__UCLIBC_CURLOCALE_DATA).__ctype_tolower;
  344. }
  345. libc_hidden_def(__ctype_tolower_loc)
  346. #endif
  347. #endif
  348. /**********************************************************************/
  349. #ifdef L___ctype_toupper_loc
  350. #ifdef __UCLIBC_HAS_XLOCALE__
  351. libc_hidden_proto(__ctype_toupper_loc)
  352. const __ctype_touplow_t **__ctype_toupper_loc(void)
  353. {
  354. return &(__UCLIBC_CURLOCALE_DATA).__ctype_toupper;
  355. }
  356. libc_hidden_def(__ctype_toupper_loc)
  357. #endif
  358. #endif
  359. /**********************************************************************/
  360. #ifdef L___C_ctype_b
  361. extern const __ctype_mask_t __C_ctype_b_data[];
  362. libc_hidden_proto(__C_ctype_b_data)
  363. const __ctype_mask_t __C_ctype_b_data[] = {
  364. #ifdef __UCLIBC_HAS_CTYPE_SIGNED__
  365. /* -128 M-^@ */ 0,
  366. /* -127 M-^A */ 0,
  367. /* -126 M-^B */ 0,
  368. /* -125 M-^C */ 0,
  369. /* -124 M-^D */ 0,
  370. /* -123 M-^E */ 0,
  371. /* -122 M-^F */ 0,
  372. /* -121 M-^G */ 0,
  373. /* -120 M-^H */ 0,
  374. /* -119 M-^I */ 0,
  375. /* -118 M-^J */ 0,
  376. /* -117 M-^K */ 0,
  377. /* -116 M-^L */ 0,
  378. /* -115 M-^M */ 0,
  379. /* -114 M-^N */ 0,
  380. /* -113 M-^O */ 0,
  381. /* -112 M-^P */ 0,
  382. /* -111 M-^Q */ 0,
  383. /* -110 M-^R */ 0,
  384. /* -109 M-^S */ 0,
  385. /* -108 M-^T */ 0,
  386. /* -107 M-^U */ 0,
  387. /* -106 M-^V */ 0,
  388. /* -105 M-^W */ 0,
  389. /* -104 M-^X */ 0,
  390. /* -103 M-^Y */ 0,
  391. /* -102 M-^Z */ 0,
  392. /* -101 M-^[ */ 0,
  393. /* -100 M-^\ */ 0,
  394. /* -99 M-^] */ 0,
  395. /* -98 M-^^ */ 0,
  396. /* -97 M-^_ */ 0,
  397. /* -96 M- */ 0,
  398. /* -95 M-! */ 0,
  399. /* -94 M-" */ 0,
  400. /* -93 M-# */ 0,
  401. /* -92 M-$ */ 0,
  402. /* -91 M-% */ 0,
  403. /* -90 M-& */ 0,
  404. /* -89 M-' */ 0,
  405. /* -88 M-( */ 0,
  406. /* -87 M-) */ 0,
  407. /* -86 M-* */ 0,
  408. /* -85 M-+ */ 0,
  409. /* -84 M-, */ 0,
  410. /* -83 M-- */ 0,
  411. /* -82 M-. */ 0,
  412. /* -81 M-/ */ 0,
  413. /* -80 M-0 */ 0,
  414. /* -79 M-1 */ 0,
  415. /* -78 M-2 */ 0,
  416. /* -77 M-3 */ 0,
  417. /* -76 M-4 */ 0,
  418. /* -75 M-5 */ 0,
  419. /* -74 M-6 */ 0,
  420. /* -73 M-7 */ 0,
  421. /* -72 M-8 */ 0,
  422. /* -71 M-9 */ 0,
  423. /* -70 M-: */ 0,
  424. /* -69 M-; */ 0,
  425. /* -68 M-< */ 0,
  426. /* -67 M-= */ 0,
  427. /* -66 M-> */ 0,
  428. /* -65 M-? */ 0,
  429. /* -64 M-@ */ 0,
  430. /* -63 M-A */ 0,
  431. /* -62 M-B */ 0,
  432. /* -61 M-C */ 0,
  433. /* -60 M-D */ 0,
  434. /* -59 M-E */ 0,
  435. /* -58 M-F */ 0,
  436. /* -57 M-G */ 0,
  437. /* -56 M-H */ 0,
  438. /* -55 M-I */ 0,
  439. /* -54 M-J */ 0,
  440. /* -53 M-K */ 0,
  441. /* -52 M-L */ 0,
  442. /* -51 M-M */ 0,
  443. /* -50 M-N */ 0,
  444. /* -49 M-O */ 0,
  445. /* -48 M-P */ 0,
  446. /* -47 M-Q */ 0,
  447. /* -46 M-R */ 0,
  448. /* -45 M-S */ 0,
  449. /* -44 M-T */ 0,
  450. /* -43 M-U */ 0,
  451. /* -42 M-V */ 0,
  452. /* -41 M-W */ 0,
  453. /* -40 M-X */ 0,
  454. /* -39 M-Y */ 0,
  455. /* -38 M-Z */ 0,
  456. /* -37 M-[ */ 0,
  457. /* -36 M-\ */ 0,
  458. /* -35 M-] */ 0,
  459. /* -34 M-^ */ 0,
  460. /* -33 M-_ */ 0,
  461. /* -32 M-` */ 0,
  462. /* -31 M-a */ 0,
  463. /* -30 M-b */ 0,
  464. /* -29 M-c */ 0,
  465. /* -28 M-d */ 0,
  466. /* -27 M-e */ 0,
  467. /* -26 M-f */ 0,
  468. /* -25 M-g */ 0,
  469. /* -24 M-h */ 0,
  470. /* -23 M-i */ 0,
  471. /* -22 M-j */ 0,
  472. /* -21 M-k */ 0,
  473. /* -20 M-l */ 0,
  474. /* -19 M-m */ 0,
  475. /* -18 M-n */ 0,
  476. /* -17 M-o */ 0,
  477. /* -16 M-p */ 0,
  478. /* -15 M-q */ 0,
  479. /* -14 M-r */ 0,
  480. /* -13 M-s */ 0,
  481. /* -12 M-t */ 0,
  482. /* -11 M-u */ 0,
  483. /* -10 M-v */ 0,
  484. /* -9 M-w */ 0,
  485. /* -8 M-x */ 0,
  486. /* -7 M-y */ 0,
  487. /* -6 M-z */ 0,
  488. /* -5 M-{ */ 0,
  489. /* -4 M-| */ 0,
  490. /* -3 M-} */ 0,
  491. /* -2 M-~ */ 0,
  492. #endif /* __UCLIBC_HAS_CTYPE_SIGNED__*/
  493. /* -1 M-^? */ 0,
  494. /* 0 ^@ */ _IScntrl,
  495. /* 1 ^A */ _IScntrl,
  496. /* 2 ^B */ _IScntrl,
  497. /* 3 ^C */ _IScntrl,
  498. /* 4 ^D */ _IScntrl,
  499. /* 5 ^E */ _IScntrl,
  500. /* 6 ^F */ _IScntrl,
  501. /* 7 ^G */ _IScntrl,
  502. /* 8 ^H */ _IScntrl,
  503. /* 9 ^I */ _ISspace|_ISblank|_IScntrl,
  504. /* 10 ^J */ _ISspace|_IScntrl,
  505. /* 11 ^K */ _ISspace|_IScntrl,
  506. /* 12 ^L */ _ISspace|_IScntrl,
  507. /* 13 ^M */ _ISspace|_IScntrl,
  508. /* 14 ^N */ _IScntrl,
  509. /* 15 ^O */ _IScntrl,
  510. /* 16 ^P */ _IScntrl,
  511. /* 17 ^Q */ _IScntrl,
  512. /* 18 ^R */ _IScntrl,
  513. /* 19 ^S */ _IScntrl,
  514. /* 20 ^T */ _IScntrl,
  515. /* 21 ^U */ _IScntrl,
  516. /* 22 ^V */ _IScntrl,
  517. /* 23 ^W */ _IScntrl,
  518. /* 24 ^X */ _IScntrl,
  519. /* 25 ^Y */ _IScntrl,
  520. /* 26 ^Z */ _IScntrl,
  521. /* 27 ^[ */ _IScntrl,
  522. /* 28 ^\ */ _IScntrl,
  523. /* 29 ^] */ _IScntrl,
  524. /* 30 ^^ */ _IScntrl,
  525. /* 31 ^_ */ _IScntrl,
  526. /* 32 */ _ISspace|_ISprint|_ISblank,
  527. /* 33 ! */ _ISprint|_ISgraph|_ISpunct,
  528. /* 34 " */ _ISprint|_ISgraph|_ISpunct,
  529. /* 35 # */ _ISprint|_ISgraph|_ISpunct,
  530. /* 36 $ */ _ISprint|_ISgraph|_ISpunct,
  531. /* 37 % */ _ISprint|_ISgraph|_ISpunct,
  532. /* 38 & */ _ISprint|_ISgraph|_ISpunct,
  533. /* 39 ' */ _ISprint|_ISgraph|_ISpunct,
  534. /* 40 ( */ _ISprint|_ISgraph|_ISpunct,
  535. /* 41 ) */ _ISprint|_ISgraph|_ISpunct,
  536. /* 42 * */ _ISprint|_ISgraph|_ISpunct,
  537. /* 43 + */ _ISprint|_ISgraph|_ISpunct,
  538. /* 44 , */ _ISprint|_ISgraph|_ISpunct,
  539. /* 45 - */ _ISprint|_ISgraph|_ISpunct,
  540. /* 46 . */ _ISprint|_ISgraph|_ISpunct,
  541. /* 47 / */ _ISprint|_ISgraph|_ISpunct,
  542. /* 48 0 */ _ISdigit|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  543. /* 49 1 */ _ISdigit|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  544. /* 50 2 */ _ISdigit|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  545. /* 51 3 */ _ISdigit|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  546. /* 52 4 */ _ISdigit|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  547. /* 53 5 */ _ISdigit|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  548. /* 54 6 */ _ISdigit|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  549. /* 55 7 */ _ISdigit|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  550. /* 56 8 */ _ISdigit|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  551. /* 57 9 */ _ISdigit|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  552. /* 58 : */ _ISprint|_ISgraph|_ISpunct,
  553. /* 59 ; */ _ISprint|_ISgraph|_ISpunct,
  554. /* 60 < */ _ISprint|_ISgraph|_ISpunct,
  555. /* 61 = */ _ISprint|_ISgraph|_ISpunct,
  556. /* 62 > */ _ISprint|_ISgraph|_ISpunct,
  557. /* 63 ? */ _ISprint|_ISgraph|_ISpunct,
  558. /* 64 @ */ _ISprint|_ISgraph|_ISpunct,
  559. /* 65 A */ _ISupper|_ISalpha|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  560. /* 66 B */ _ISupper|_ISalpha|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  561. /* 67 C */ _ISupper|_ISalpha|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  562. /* 68 D */ _ISupper|_ISalpha|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  563. /* 69 E */ _ISupper|_ISalpha|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  564. /* 70 F */ _ISupper|_ISalpha|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  565. /* 71 G */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  566. /* 72 H */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  567. /* 73 I */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  568. /* 74 J */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  569. /* 75 K */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  570. /* 76 L */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  571. /* 77 M */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  572. /* 78 N */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  573. /* 79 O */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  574. /* 80 P */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  575. /* 81 Q */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  576. /* 82 R */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  577. /* 83 S */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  578. /* 84 T */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  579. /* 85 U */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  580. /* 86 V */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  581. /* 87 W */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  582. /* 88 X */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  583. /* 89 Y */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  584. /* 90 Z */ _ISupper|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  585. /* 91 [ */ _ISprint|_ISgraph|_ISpunct,
  586. /* 92 \ */ _ISprint|_ISgraph|_ISpunct,
  587. /* 93 ] */ _ISprint|_ISgraph|_ISpunct,
  588. /* 94 ^ */ _ISprint|_ISgraph|_ISpunct,
  589. /* 95 _ */ _ISprint|_ISgraph|_ISpunct,
  590. /* 96 ` */ _ISprint|_ISgraph|_ISpunct,
  591. /* 97 a */ _ISlower|_ISalpha|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  592. /* 98 b */ _ISlower|_ISalpha|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  593. /* 99 c */ _ISlower|_ISalpha|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  594. /* 100 d */ _ISlower|_ISalpha|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  595. /* 101 e */ _ISlower|_ISalpha|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  596. /* 102 f */ _ISlower|_ISalpha|_ISxdigit|_ISprint|_ISgraph|_ISalnum,
  597. /* 103 g */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  598. /* 104 h */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  599. /* 105 i */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  600. /* 106 j */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  601. /* 107 k */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  602. /* 108 l */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  603. /* 109 m */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  604. /* 110 n */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  605. /* 111 o */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  606. /* 112 p */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  607. /* 113 q */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  608. /* 114 r */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  609. /* 115 s */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  610. /* 116 t */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  611. /* 117 u */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  612. /* 118 v */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  613. /* 119 w */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  614. /* 120 x */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  615. /* 121 y */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  616. /* 122 z */ _ISlower|_ISalpha|_ISprint|_ISgraph|_ISalnum,
  617. /* 123 { */ _ISprint|_ISgraph|_ISpunct,
  618. /* 124 | */ _ISprint|_ISgraph|_ISpunct,
  619. /* 125 } */ _ISprint|_ISgraph|_ISpunct,
  620. /* 126 ~ */ _ISprint|_ISgraph|_ISpunct,
  621. /* 127 ^? */ _IScntrl,
  622. /* 128 M-^@ */ 0,
  623. /* 129 M-^A */ 0,
  624. /* 130 M-^B */ 0,
  625. /* 131 M-^C */ 0,
  626. /* 132 M-^D */ 0,
  627. /* 133 M-^E */ 0,
  628. /* 134 M-^F */ 0,
  629. /* 135 M-^G */ 0,
  630. /* 136 M-^H */ 0,
  631. /* 137 M-^I */ 0,
  632. /* 138 M-^J */ 0,
  633. /* 139 M-^K */ 0,
  634. /* 140 M-^L */ 0,
  635. /* 141 M-^M */ 0,
  636. /* 142 M-^N */ 0,
  637. /* 143 M-^O */ 0,
  638. /* 144 M-^P */ 0,
  639. /* 145 M-^Q */ 0,
  640. /* 146 M-^R */ 0,
  641. /* 147 M-^S */ 0,
  642. /* 148 M-^T */ 0,
  643. /* 149 M-^U */ 0,
  644. /* 150 M-^V */ 0,
  645. /* 151 M-^W */ 0,
  646. /* 152 M-^X */ 0,
  647. /* 153 M-^Y */ 0,
  648. /* 154 M-^Z */ 0,
  649. /* 155 M-^[ */ 0,
  650. /* 156 M-^\ */ 0,
  651. /* 157 M-^] */ 0,
  652. /* 158 M-^^ */ 0,
  653. /* 159 M-^_ */ 0,
  654. /* 160 M- */ 0,
  655. /* 161 M-! */ 0,
  656. /* 162 M-" */ 0,
  657. /* 163 M-# */ 0,
  658. /* 164 M-$ */ 0,
  659. /* 165 M-% */ 0,
  660. /* 166 M-& */ 0,
  661. /* 167 M-' */ 0,
  662. /* 168 M-( */ 0,
  663. /* 169 M-) */ 0,
  664. /* 170 M-* */ 0,
  665. /* 171 M-+ */ 0,
  666. /* 172 M-, */ 0,
  667. /* 173 M-- */ 0,
  668. /* 174 M-. */ 0,
  669. /* 175 M-/ */ 0,
  670. /* 176 M-0 */ 0,
  671. /* 177 M-1 */ 0,
  672. /* 178 M-2 */ 0,
  673. /* 179 M-3 */ 0,
  674. /* 180 M-4 */ 0,
  675. /* 181 M-5 */ 0,
  676. /* 182 M-6 */ 0,
  677. /* 183 M-7 */ 0,
  678. /* 184 M-8 */ 0,
  679. /* 185 M-9 */ 0,
  680. /* 186 M-: */ 0,
  681. /* 187 M-; */ 0,
  682. /* 188 M-< */ 0,
  683. /* 189 M-= */ 0,
  684. /* 190 M-> */ 0,
  685. /* 191 M-? */ 0,
  686. /* 192 M-@ */ 0,
  687. /* 193 M-A */ 0,
  688. /* 194 M-B */ 0,
  689. /* 195 M-C */ 0,
  690. /* 196 M-D */ 0,
  691. /* 197 M-E */ 0,
  692. /* 198 M-F */ 0,
  693. /* 199 M-G */ 0,
  694. /* 200 M-H */ 0,
  695. /* 201 M-I */ 0,
  696. /* 202 M-J */ 0,
  697. /* 203 M-K */ 0,
  698. /* 204 M-L */ 0,
  699. /* 205 M-M */ 0,
  700. /* 206 M-N */ 0,
  701. /* 207 M-O */ 0,
  702. /* 208 M-P */ 0,
  703. /* 209 M-Q */ 0,
  704. /* 210 M-R */ 0,
  705. /* 211 M-S */ 0,
  706. /* 212 M-T */ 0,
  707. /* 213 M-U */ 0,
  708. /* 214 M-V */ 0,
  709. /* 215 M-W */ 0,
  710. /* 216 M-X */ 0,
  711. /* 217 M-Y */ 0,
  712. /* 218 M-Z */ 0,
  713. /* 219 M-[ */ 0,
  714. /* 220 M-\ */ 0,
  715. /* 221 M-] */ 0,
  716. /* 222 M-^ */ 0,
  717. /* 223 M-_ */ 0,
  718. /* 224 M-` */ 0,
  719. /* 225 M-a */ 0,
  720. /* 226 M-b */ 0,
  721. /* 227 M-c */ 0,
  722. /* 228 M-d */ 0,
  723. /* 229 M-e */ 0,
  724. /* 230 M-f */ 0,
  725. /* 231 M-g */ 0,
  726. /* 232 M-h */ 0,
  727. /* 233 M-i */ 0,
  728. /* 234 M-j */ 0,
  729. /* 235 M-k */ 0,
  730. /* 236 M-l */ 0,
  731. /* 237 M-m */ 0,
  732. /* 238 M-n */ 0,
  733. /* 239 M-o */ 0,
  734. /* 240 M-p */ 0,
  735. /* 241 M-q */ 0,
  736. /* 242 M-r */ 0,
  737. /* 243 M-s */ 0,
  738. /* 244 M-t */ 0,
  739. /* 245 M-u */ 0,
  740. /* 246 M-v */ 0,
  741. /* 247 M-w */ 0,
  742. /* 248 M-x */ 0,
  743. /* 249 M-y */ 0,
  744. /* 250 M-z */ 0,
  745. /* 251 M-{ */ 0,
  746. /* 252 M-| */ 0,
  747. /* 253 M-} */ 0,
  748. /* 254 M-~ */ 0,
  749. /* 255 M-^? */ 0
  750. };
  751. libc_hidden_data_def(__C_ctype_b_data)
  752. libc_hidden_proto(__C_ctype_b)
  753. const __ctype_mask_t *__C_ctype_b = __C_ctype_b_data + __UCLIBC_CTYPE_B_TBL_OFFSET;
  754. libc_hidden_data_def(__C_ctype_b)
  755. #ifndef __UCLIBC_HAS_XLOCALE__
  756. const __ctype_mask_t *__ctype_b = __C_ctype_b_data + __UCLIBC_CTYPE_B_TBL_OFFSET;
  757. libc_hidden_data_def(__ctype_b)
  758. #endif
  759. #endif
  760. /**********************************************************************/
  761. #ifdef L___C_ctype_tolower
  762. extern const __ctype_touplow_t __C_ctype_tolower_data[];
  763. libc_hidden_proto(__C_ctype_tolower_data)
  764. const __ctype_touplow_t __C_ctype_tolower_data[] = {
  765. #ifdef __UCLIBC_HAS_CTYPE_SIGNED__
  766. -128, -127, -126, -125,
  767. -124, -123, -122, -121,
  768. -120, -119, -118, -117,
  769. -116, -115, -114, -113,
  770. -112, -111, -110, -109,
  771. -108, -107, -106, -105,
  772. -104, -103, -102, -101,
  773. -100, -99, -98, -97,
  774. -96, -95, -94, -93,
  775. -92, -91, -90, -89,
  776. -88, -87, -86, -85,
  777. -84, -83, -82, -81,
  778. -80, -79, -78, -77,
  779. -76, -75, -74, -73,
  780. -72, -71, -70, -69,
  781. -68, -67, -66, -65,
  782. -64, -63, -62, -61,
  783. -60, -59, -58, -57,
  784. -56, -55, -54, -53,
  785. -52, -51, -50, -49,
  786. -48, -47, -46, -45,
  787. -44, -43, -42, -41,
  788. -40, -39, -38, -37,
  789. -36, -35, -34, -33,
  790. -32, -31, -30, -29,
  791. -28, -27, -26, -25,
  792. -24, -23, -22, -21,
  793. -20, -19, -18, -17,
  794. -16, -15, -14, -13,
  795. -12, -11, -10, -9,
  796. -8, -7, -6, -5,
  797. -4, -3, -2, -1,
  798. #endif /* __UCLIBC_HAS_CTYPE_SIGNED__*/
  799. 0, 1, 2, 3,
  800. 4, 5, 6, 7,
  801. 8, 9, 10, 11,
  802. 12, 13, 14, 15,
  803. 16, 17, 18, 19,
  804. 20, 21, 22, 23,
  805. 24, 25, 26, 27,
  806. 28, 29, 30, 31,
  807. 32, 33, 34, 35,
  808. 36, 37, 38, 39,
  809. 40, 41, 42, 43,
  810. 44, 45, 46, 47,
  811. 48, 49, 50, 51,
  812. 52, 53, 54, 55,
  813. 56, 57, 58, 59,
  814. 60, 61, 62, 63,
  815. 64, 97 /* a */, 98 /* b */, 99 /* c */,
  816. 100 /* d */, 101 /* e */, 102 /* f */, 103 /* g */,
  817. 104 /* h */, 105 /* i */, 106 /* j */, 107 /* k */,
  818. 108 /* l */, 109 /* m */, 110 /* n */, 111 /* o */,
  819. 112 /* p */, 113 /* q */, 114 /* r */, 115 /* s */,
  820. 116 /* t */, 117 /* u */, 118 /* v */, 119 /* w */,
  821. 120 /* x */, 121 /* y */, 122 /* z */, 91,
  822. 92, 93, 94, 95,
  823. 96, 97, 98, 99,
  824. 100, 101, 102, 103,
  825. 104, 105, 106, 107,
  826. 108, 109, 110, 111,
  827. 112, 113, 114, 115,
  828. 116, 117, 118, 119,
  829. 120, 121, 122, 123,
  830. 124, 125, 126, 127,
  831. 128, 129, 130, 131,
  832. 132, 133, 134, 135,
  833. 136, 137, 138, 139,
  834. 140, 141, 142, 143,
  835. 144, 145, 146, 147,
  836. 148, 149, 150, 151,
  837. 152, 153, 154, 155,
  838. 156, 157, 158, 159,
  839. 160, 161, 162, 163,
  840. 164, 165, 166, 167,
  841. 168, 169, 170, 171,
  842. 172, 173, 174, 175,
  843. 176, 177, 178, 179,
  844. 180, 181, 182, 183,
  845. 184, 185, 186, 187,
  846. 188, 189, 190, 191,
  847. 192, 193, 194, 195,
  848. 196, 197, 198, 199,
  849. 200, 201, 202, 203,
  850. 204, 205, 206, 207,
  851. 208, 209, 210, 211,
  852. 212, 213, 214, 215,
  853. 216, 217, 218, 219,
  854. 220, 221, 222, 223,
  855. 224, 225, 226, 227,
  856. 228, 229, 230, 231,
  857. 232, 233, 234, 235,
  858. 236, 237, 238, 239,
  859. 240, 241, 242, 243,
  860. 244, 245, 246, 247,
  861. 248, 249, 250, 251,
  862. 252, 253, 254, 255
  863. };
  864. libc_hidden_data_def(__C_ctype_tolower_data)
  865. libc_hidden_proto(__C_ctype_tolower)
  866. const __ctype_touplow_t *__C_ctype_tolower = __C_ctype_tolower_data
  867. + __UCLIBC_CTYPE_TO_TBL_OFFSET;
  868. libc_hidden_data_def(__C_ctype_tolower)
  869. #ifndef __UCLIBC_HAS_XLOCALE__
  870. libc_hidden_proto(__ctype_tolower)
  871. const __ctype_touplow_t *__ctype_tolower = __C_ctype_tolower_data
  872. + __UCLIBC_CTYPE_TO_TBL_OFFSET;
  873. libc_hidden_data_def(__ctype_tolower)
  874. #endif
  875. #endif
  876. /**********************************************************************/
  877. #ifdef L___C_ctype_toupper
  878. extern const __ctype_touplow_t __C_ctype_toupper_data[];
  879. libc_hidden_proto(__C_ctype_toupper_data)
  880. const __ctype_touplow_t __C_ctype_toupper_data[] = {
  881. #ifdef __UCLIBC_HAS_CTYPE_SIGNED__
  882. -128, -127, -126, -125,
  883. -124, -123, -122, -121,
  884. -120, -119, -118, -117,
  885. -116, -115, -114, -113,
  886. -112, -111, -110, -109,
  887. -108, -107, -106, -105,
  888. -104, -103, -102, -101,
  889. -100, -99, -98, -97,
  890. -96, -95, -94, -93,
  891. -92, -91, -90, -89,
  892. -88, -87, -86, -85,
  893. -84, -83, -82, -81,
  894. -80, -79, -78, -77,
  895. -76, -75, -74, -73,
  896. -72, -71, -70, -69,
  897. -68, -67, -66, -65,
  898. -64, -63, -62, -61,
  899. -60, -59, -58, -57,
  900. -56, -55, -54, -53,
  901. -52, -51, -50, -49,
  902. -48, -47, -46, -45,
  903. -44, -43, -42, -41,
  904. -40, -39, -38, -37,
  905. -36, -35, -34, -33,
  906. -32, -31, -30, -29,
  907. -28, -27, -26, -25,
  908. -24, -23, -22, -21,
  909. -20, -19, -18, -17,
  910. -16, -15, -14, -13,
  911. -12, -11, -10, -9,
  912. -8, -7, -6, -5,
  913. -4, -3, -2, -1,
  914. #endif /* __UCLIBC_HAS_CTYPE_SIGNED__*/
  915. 0, 1, 2, 3,
  916. 4, 5, 6, 7,
  917. 8, 9, 10, 11,
  918. 12, 13, 14, 15,
  919. 16, 17, 18, 19,
  920. 20, 21, 22, 23,
  921. 24, 25, 26, 27,
  922. 28, 29, 30, 31,
  923. 32, 33, 34, 35,
  924. 36, 37, 38, 39,
  925. 40, 41, 42, 43,
  926. 44, 45, 46, 47,
  927. 48, 49, 50, 51,
  928. 52, 53, 54, 55,
  929. 56, 57, 58, 59,
  930. 60, 61, 62, 63,
  931. 64, 65, 66, 67,
  932. 68, 69, 70, 71,
  933. 72, 73, 74, 75,
  934. 76, 77, 78, 79,
  935. 80, 81, 82, 83,
  936. 84, 85, 86, 87,
  937. 88, 89, 90, 91,
  938. 92, 93, 94, 95,
  939. 96, 65 /* A */, 66 /* B */, 67 /* C */,
  940. 68 /* D */, 69 /* E */, 70 /* F */, 71 /* G */,
  941. 72 /* H */, 73 /* I */, 74 /* J */, 75 /* K */,
  942. 76 /* L */, 77 /* M */, 78 /* N */, 79 /* O */,
  943. 80 /* P */, 81 /* Q */, 82 /* R */, 83 /* S */,
  944. 84 /* T */, 85 /* U */, 86 /* V */, 87 /* W */,
  945. 88 /* X */, 89 /* Y */, 90 /* Z */, 123,
  946. 124, 125, 126, 127,
  947. 128, 129, 130, 131,
  948. 132, 133, 134, 135,
  949. 136, 137, 138, 139,
  950. 140, 141, 142, 143,
  951. 144, 145, 146, 147,
  952. 148, 149, 150, 151,
  953. 152, 153, 154, 155,
  954. 156, 157, 158, 159,
  955. 160, 161, 162, 163,
  956. 164, 165, 166, 167,
  957. 168, 169, 170, 171,
  958. 172, 173, 174, 175,
  959. 176, 177, 178, 179,
  960. 180, 181, 182, 183,
  961. 184, 185, 186, 187,
  962. 188, 189, 190, 191,
  963. 192, 193, 194, 195,
  964. 196, 197, 198, 199,
  965. 200, 201, 202, 203,
  966. 204, 205, 206, 207,
  967. 208, 209, 210, 211,
  968. 212, 213, 214, 215,
  969. 216, 217, 218, 219,
  970. 220, 221, 222, 223,
  971. 224, 225, 226, 227,
  972. 228, 229, 230, 231,
  973. 232, 233, 234, 235,
  974. 236, 237, 238, 239,
  975. 240, 241, 242, 243,
  976. 244, 245, 246, 247,
  977. 248, 249, 250, 251,
  978. 252, 253, 254, 255
  979. };
  980. libc_hidden_data_def(__C_ctype_toupper_data)
  981. libc_hidden_proto(__C_ctype_toupper)
  982. const __ctype_touplow_t *__C_ctype_toupper = __C_ctype_toupper_data
  983. + __UCLIBC_CTYPE_TO_TBL_OFFSET;
  984. libc_hidden_data_def(__C_ctype_toupper)
  985. #ifndef __UCLIBC_HAS_XLOCALE__
  986. libc_hidden_proto(__ctype_toupper)
  987. const __ctype_touplow_t *__ctype_toupper = __C_ctype_toupper_data
  988. + __UCLIBC_CTYPE_TO_TBL_OFFSET;
  989. libc_hidden_data_def(__ctype_toupper)
  990. #endif
  991. #endif
  992. /**********************************************************************/