2 * TEST SUITE FOR MB/WC FUNCTIONS IN C LIBRARY
6 * MBRLEN: size_t mbrlen (const char *s, size_t n, mbstate_t *ps);
11 * (1) A mbstate object is initialized for
12 * every new data record by the test program.
14 * (2) USE_MBCURMAX is defined as a value of 99.
19 TST_MBRLEN tst_mbrlen_loc
[] = {
21 { Tmbrlen
, TST_LOC_de
},
23 { /*----------------- #01 -----------------*/
28 { 1, "\300", USE_MBCURMAX
, 0, 0 },
39 { /*----------------- #02 -----------------*/
42 { 1, "\300\001", 0, 0, 0 },
43 { 1, "\300\001", 1, 0, 0 },
44 { 1, "\317\001", USE_MBCURMAX
, 0, 0 },
59 { Tmbrlen
, TST_LOC_enUS
},
61 { /*----------------- #01 -----------------*/
66 { 1, "A", USE_MBCURMAX
, 0, 0 },
77 { /*----------------- #02 -----------------*/
80 { 1, "\317\001", 0, 1, 0 },
81 { 1, "\317\001", 1, 1, 0 },
82 { 1, "\317\001", USE_MBCURMAX
, 1, 0 },
98 { Tmbrlen
, TST_LOC_eucJP
},
100 { /*----------------- #01 -----------------*/
103 { 1, "\317\302", 1, 1, 1 },
105 { 1, "\317\302", USE_MBCURMAX
, 1, 1 },
116 { /*----------------- #02 -----------------*/
119 { 1, "\317", 1, 1, 0 },
120 { 1, "\302", 1, 1, 0 },
121 { 1, "\317\302", USE_MBCURMAX
, 0, 0 },
127 #ifdef SHOJI_IS_RIGHT
130 /* XXX ISO C explicitly says that the return value does not
131 XXX reflect the bytes contained in the state. */
138 { /*----------------- #03 -----------------*/
141 { 1, "\216\217", 0, 0, 0 },
142 { 1, "\216\217", 1, 0, 0 },
143 { 1, "\216\217", USE_MBCURMAX
, 0, 0 },
159 { Tmbrlen
, TST_LOC_ja_UTF8
},
161 { /*----------------- #01 -----------------*/
164 { 1, "\345\222\214", 1, 1, 1 },
166 { 1, "\345\222\214", USE_MBCURMAX
, 1, 1 },
177 { /*----------------- #02 -----------------*/
180 { 1, "\317", 1, 1, 0 },
181 { 1, "\266", 1, 1, 0 },
182 { 1, "\345\222\214", USE_MBCURMAX
, 0, 0 },
188 #ifdef SHOJI_IS_RIGHT
191 /* XXX ISO C explicitly says that the return value does not
192 XXX reflect the bytes contained in the state. */
199 { /*----------------- #03 -----------------*/
202 { 1, "\302\303", 0, 0, 0 },
203 { 1, "\302\303", 1, 0, 0 },
204 { 1, "\302\303", USE_MBCURMAX
, 0, 0 },
220 { Tmbrlen
, TST_LOC_end
}