ctype.c 34 KB

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