Installed-header hygiene (BZ#20366): conditionally defined structures.
[glibc.git] / localedata / tests-mbwc / dat_wcsspn.c
blob138279b38cc9df3ecc88095d4965aeea24eb17e7
1 /*
2 * TEST SUITE FOR MB/WC FUNCTIONS IN C LIBRARY
4 * FILE: dat_wcsspn.c
6 * WCSSPN: size_t wcsspn (const wchar_t *ws1, const wchar_t *ws2);
7 */
9 TST_WCSSPN tst_wcsspn_loc [] = {
11 { Twcsspn, TST_LOC_de },
13 { /*input.*/ { { 0x00D1,0x00D2,0x00D3,0x0000 },
14 { 0x00D1,0x0000 }, }, /* #01 */
15 /*expect*/ { 0,1,1, },
17 { /*input.*/ { { 0x00D1,0x00D2,0x00D3,0x0000 },
18 { 0x00D2,0x0000 }, }, /* #02 */
19 /*expect*/ { 0,1,0, },
21 { /*input.*/ { { 0x00D1,0x00D2,0x00D3,0x0000 },
22 { 0x00D3,0x0000 }, }, /* #03 */
23 /*expect*/ { 0,1,0, },
25 { /*input.*/ { { 0x00D1,0x00D2,0x00D3,0x0000 },
26 { 0x00D4,0x0000 }, }, /* #04 */
27 /*expect*/ { 0,1,0, },
29 { /*input.*/ { { 0x00D1,0x00D2,0x00D3,0x0000 },
30 { 0x00D2,0x00D3,0x0000 }, }, /* #05 */
31 /*expect*/ { 0,1,0, },
33 { /*input.*/ { { 0x00D1,0x00D2,0x00D3,0x0000 },
34 { 0x00D3,0x00D4,0x0000 }, }, /* #06 */
35 /*expect*/ { 0,1,0, },
37 { /*input.*/ { { 0x00D1,0x00D2,0x00D3,0x0000 },
38 { 0x00D1,0x00D2,0x00D3,0x0000 }, }, /* #07 */
39 /*expect*/ { 0,1,3, },
41 { /*input.*/ { { 0x00D1,0x00D2,0x0000 },
42 { 0x00D1,0x00D2,0x00D3,0x0000 }, }, /* #08 */
43 /*expect*/ { 0,1,2, },
45 { /*input.*/ { { 0x0000,0x00D2,0x00D3,0x0000 },
46 { 0x00D2,0x0000 }, }, /* #09 */
47 /*expect*/ { 0,1,0, },
49 { /*input.*/ { { 0x00D1,0x00D2,0x00D3,0x0000 },
50 { 0x0000,0x00D2,0x0000 }, }, /* #10 */
51 /*expect*/ { 0,1,0, },
53 { /*input.*/ { { 0x0000,0x00D2,0x00D3,0x0000 },
54 { 0x0000,0x00D2,0x0000 }, }, /* #11 */
55 /*expect*/ { 0,1,0, },
57 { /*input.*/ { { 0x00D1,0x00D2,0x00D3,0x0000 },
58 { 0x00D2,0x00D1,0x0000 }, }, /* #12 */
59 /*expect*/ { 0,1,2, },
61 { .is_last = 1 }
65 { Twcsspn, TST_LOC_enUS },
67 { /*input.*/ { { 0x0041,0x0042,0x0043,0x0000 },
68 { 0x0041,0x0000 }, }, /* #01 */
69 /*expect*/ { 0,1,1, },
71 { /*input.*/ { { 0x0041,0x0042,0x0043,0x0000 },
72 { 0x0042,0x0000 }, }, /* #02 */
73 /*expect*/ { 0,1,0, },
75 { /*input.*/ { { 0x0041,0x0042,0x0043,0x0000 },
76 { 0x0043,0x0000 }, }, /* #03 */
77 /*expect*/ { 0,1,0, },
79 { /*input.*/ { { 0x0041,0x0042,0x0043,0x0000 },
80 { 0x0044,0x0000 }, }, /* #04 */
81 /*expect*/ { 0,1,0, },
83 { /*input.*/ { { 0x0041,0x0042,0x0043,0x0000 },
84 { 0x0042,0x0043,0x0000 }, }, /* #05 */
85 /*expect*/ { 0,1,0, },
87 { /*input.*/ { { 0x0041,0x0042,0x0043,0x0000 },
88 { 0x0043,0x0044,0x0000 }, }, /* #06 */
89 /*expect*/ { 0,1,0, },
91 { /*input.*/ { { 0x0041,0x0042,0x0043,0x0000 },
92 { 0x0041,0x0042,0x0043,0x0000 }, }, /* #07 */
93 /*expect*/ { 0,1,3, },
95 { /*input.*/ { { 0x0041,0x0042,0x0000 },
96 { 0x0041,0x0042,0x0043,0x0000 }, }, /* #08 */
97 /*expect*/ { 0,1,2, },
99 { /*input.*/ { { 0x0000,0x0042,0x0043,0x0000 },
100 { 0x0042,0x0000 }, }, /* #09 */
101 /*expect*/ { 0,1,0, },
103 { /*input.*/ { { 0x0041,0x0042,0x0043,0x0000 },
104 { 0x0000,0x0042,0x0000 }, }, /* #10 */
105 /*expect*/ { 0,1,0, },
107 { /*input.*/ { { 0x0000,0x0042,0x0043,0x0000 },
108 { 0x0000,0x0042,0x0000 }, }, /* #11 */
109 /*expect*/ { 0,1,0, },
111 { /*input.*/ { { 0x0041,0x0042,0x0043,0x0000 },
112 { 0x0042,0x0041,0x0000 }, }, /* #12 */
113 /*expect*/ { 0,1,2, },
115 { .is_last = 1 }
119 { Twcsspn, TST_LOC_eucJP },
121 { /*input.*/ { { 0x3041,0x3042,0x3043,0x0000 },
122 { 0x3041,0x0000 }, }, /* #1 */
123 /*expect*/ { 0,1,1, },
125 { /*input.*/ { { 0x3041,0x3042,0x3043,0x0000 },
126 { 0x3042,0x0000 }, }, /* #2 */
127 /*expect*/ { 0,1,0, },
129 { /*input.*/ { { 0x3041,0x3042,0x3043,0x0000 },
130 { 0x3043,0x0000 }, }, /* #3 */
131 /*expect*/ { 0,1,0, },
133 { /*input.*/ { { 0x3041,0x3042,0x3043,0x0000 },
134 { 0x3044,0x0000 }, }, /* #4 */
135 /*expect*/ { 0,1,0, },
137 { /*input.*/ { { 0x3041,0x3042,0x3043,0x0000 },
138 { 0x3042,0x3043,0x0000 }, }, /* #5 */
139 /*expect*/ { 0,1,0, },
141 { /*input.*/ { { 0x3041,0x3042,0x3043,0x0000 },
142 { 0x3043,0x3044,0x0000 }, }, /* #6 */
143 /*expect*/ { 0,1,0, },
145 { /*input.*/ { { 0x3041,0x3042,0x3043,0x0000 },
146 { 0x3041,0x3042,0x3043,0x0000 }, }, /* #7 */
147 /*expect*/ { 0,1,3, },
149 { /*input.*/ { { 0x3041,0x3042,0x0000 },
150 { 0x3041,0x3042,0x3043,0x0000 }, }, /* #8 */
151 /*expect*/ { 0,1,2, },
153 { /*input.*/ { { 0x0000,0x3042,0x3043,0x0000 },
154 { 0x3042,0x0000 }, }, /* #9 */
155 /*expect*/ { 0,1,0, },
157 { /*input.*/ { { 0x3041,0x3042,0x3043,0x0000 },
158 { 0x0000,0x3042,0x0000 }, }, /* #10 */
159 /*expect*/ { 0,1,0, },
161 { /*input.*/ { { 0x0000,0x3042,0x3043,0x0000 },
162 { 0x0000,0x3042,0x0000 }, }, /* #11 */
163 /*expect*/ { 0,1,0, },
165 { /*input.*/ { { 0x3041,0x3042,0x3043,0x0000 },
166 { 0x3042,0x3041,0x0000 }, }, /* #12 */
167 /*expect*/ { 0,1,2, },
169 { .is_last = 1 }
173 { Twcsspn, TST_LOC_end }