1 /* Generated by Snowball 2.1.0 - https://snowballstem.org/ */
2 
3 #include "../runtime/header.h"
4 
5 #ifdef __cplusplus
6 extern "C" {
7 #endif
8 extern int english_UTF_8_stem(struct SN_env * z);
9 #ifdef __cplusplus
10 }
11 #endif
12 static int r_exception2(struct SN_env * z);
13 static int r_exception1(struct SN_env * z);
14 static int r_Step_5(struct SN_env * z);
15 static int r_Step_4(struct SN_env * z);
16 static int r_Step_3(struct SN_env * z);
17 static int r_Step_2(struct SN_env * z);
18 static int r_Step_1c(struct SN_env * z);
19 static int r_Step_1b(struct SN_env * z);
20 static int r_Step_1a(struct SN_env * z);
21 static int r_R2(struct SN_env * z);
22 static int r_R1(struct SN_env * z);
23 static int r_shortv(struct SN_env * z);
24 static int r_mark_regions(struct SN_env * z);
25 static int r_postlude(struct SN_env * z);
26 static int r_prelude(struct SN_env * z);
27 #ifdef __cplusplus
28 extern "C" {
29 #endif
30 
31 
32 extern struct SN_env * english_UTF_8_create_env(void);
33 extern void english_UTF_8_close_env(struct SN_env * z);
34 
35 
36 #ifdef __cplusplus
37 }
38 #endif
39 static const symbol s_0_0[5] = { 'a', 'r', 's', 'e', 'n' };
40 static const symbol s_0_1[6] = { 'c', 'o', 'm', 'm', 'u', 'n' };
41 static const symbol s_0_2[5] = { 'g', 'e', 'n', 'e', 'r' };
42 
43 static const struct among a_0[3] =
44 {
45 { 5, s_0_0, -1, -1, 0},
46 { 6, s_0_1, -1, -1, 0},
47 { 5, s_0_2, -1, -1, 0}
48 };
49 
50 static const symbol s_1_0[1] = { '\'' };
51 static const symbol s_1_1[3] = { '\'', 's', '\'' };
52 static const symbol s_1_2[2] = { '\'', 's' };
53 
54 static const struct among a_1[3] =
55 {
56 { 1, s_1_0, -1, 1, 0},
57 { 3, s_1_1, 0, 1, 0},
58 { 2, s_1_2, -1, 1, 0}
59 };
60 
61 static const symbol s_2_0[3] = { 'i', 'e', 'd' };
62 static const symbol s_2_1[1] = { 's' };
63 static const symbol s_2_2[3] = { 'i', 'e', 's' };
64 static const symbol s_2_3[4] = { 's', 's', 'e', 's' };
65 static const symbol s_2_4[2] = { 's', 's' };
66 static const symbol s_2_5[2] = { 'u', 's' };
67 
68 static const struct among a_2[6] =
69 {
70 { 3, s_2_0, -1, 2, 0},
71 { 1, s_2_1, -1, 3, 0},
72 { 3, s_2_2, 1, 2, 0},
73 { 4, s_2_3, 1, 1, 0},
74 { 2, s_2_4, 1, -1, 0},
75 { 2, s_2_5, 1, -1, 0}
76 };
77 
78 static const symbol s_3_1[2] = { 'b', 'b' };
79 static const symbol s_3_2[2] = { 'd', 'd' };
80 static const symbol s_3_3[2] = { 'f', 'f' };
81 static const symbol s_3_4[2] = { 'g', 'g' };
82 static const symbol s_3_5[2] = { 'b', 'l' };
83 static const symbol s_3_6[2] = { 'm', 'm' };
84 static const symbol s_3_7[2] = { 'n', 'n' };
85 static const symbol s_3_8[2] = { 'p', 'p' };
86 static const symbol s_3_9[2] = { 'r', 'r' };
87 static const symbol s_3_10[2] = { 'a', 't' };
88 static const symbol s_3_11[2] = { 't', 't' };
89 static const symbol s_3_12[2] = { 'i', 'z' };
90 
91 static const struct among a_3[13] =
92 {
93 { 0, 0, -1, 3, 0},
94 { 2, s_3_1, 0, 2, 0},
95 { 2, s_3_2, 0, 2, 0},
96 { 2, s_3_3, 0, 2, 0},
97 { 2, s_3_4, 0, 2, 0},
98 { 2, s_3_5, 0, 1, 0},
99 { 2, s_3_6, 0, 2, 0},
100 { 2, s_3_7, 0, 2, 0},
101 { 2, s_3_8, 0, 2, 0},
102 { 2, s_3_9, 0, 2, 0},
103 { 2, s_3_10, 0, 1, 0},
104 { 2, s_3_11, 0, 2, 0},
105 { 2, s_3_12, 0, 1, 0}
106 };
107 
108 static const symbol s_4_0[2] = { 'e', 'd' };
109 static const symbol s_4_1[3] = { 'e', 'e', 'd' };
110 static const symbol s_4_2[3] = { 'i', 'n', 'g' };
111 static const symbol s_4_3[4] = { 'e', 'd', 'l', 'y' };
112 static const symbol s_4_4[5] = { 'e', 'e', 'd', 'l', 'y' };
113 static const symbol s_4_5[5] = { 'i', 'n', 'g', 'l', 'y' };
114 
115 static const struct among a_4[6] =
116 {
117 { 2, s_4_0, -1, 2, 0},
118 { 3, s_4_1, 0, 1, 0},
119 { 3, s_4_2, -1, 2, 0},
120 { 4, s_4_3, -1, 2, 0},
121 { 5, s_4_4, 3, 1, 0},
122 { 5, s_4_5, -1, 2, 0}
123 };
124 
125 static const symbol s_5_0[4] = { 'a', 'n', 'c', 'i' };
126 static const symbol s_5_1[4] = { 'e', 'n', 'c', 'i' };
127 static const symbol s_5_2[3] = { 'o', 'g', 'i' };
128 static const symbol s_5_3[2] = { 'l', 'i' };
129 static const symbol s_5_4[3] = { 'b', 'l', 'i' };
130 static const symbol s_5_5[4] = { 'a', 'b', 'l', 'i' };
131 static const symbol s_5_6[4] = { 'a', 'l', 'l', 'i' };
132 static const symbol s_5_7[5] = { 'f', 'u', 'l', 'l', 'i' };
133 static const symbol s_5_8[6] = { 'l', 'e', 's', 's', 'l', 'i' };
134 static const symbol s_5_9[5] = { 'o', 'u', 's', 'l', 'i' };
135 static const symbol s_5_10[5] = { 'e', 'n', 't', 'l', 'i' };
136 static const symbol s_5_11[5] = { 'a', 'l', 'i', 't', 'i' };
137 static const symbol s_5_12[6] = { 'b', 'i', 'l', 'i', 't', 'i' };
138 static const symbol s_5_13[5] = { 'i', 'v', 'i', 't', 'i' };
139 static const symbol s_5_14[6] = { 't', 'i', 'o', 'n', 'a', 'l' };
140 static const symbol s_5_15[7] = { 'a', 't', 'i', 'o', 'n', 'a', 'l' };
141 static const symbol s_5_16[5] = { 'a', 'l', 'i', 's', 'm' };
142 static const symbol s_5_17[5] = { 'a', 't', 'i', 'o', 'n' };
143 static const symbol s_5_18[7] = { 'i', 'z', 'a', 't', 'i', 'o', 'n' };
144 static const symbol s_5_19[4] = { 'i', 'z', 'e', 'r' };
145 static const symbol s_5_20[4] = { 'a', 't', 'o', 'r' };
146 static const symbol s_5_21[7] = { 'i', 'v', 'e', 'n', 'e', 's', 's' };
147 static const symbol s_5_22[7] = { 'f', 'u', 'l', 'n', 'e', 's', 's' };
148 static const symbol s_5_23[7] = { 'o', 'u', 's', 'n', 'e', 's', 's' };
149 
150 static const struct among a_5[24] =
151 {
152 { 4, s_5_0, -1, 3, 0},
153 { 4, s_5_1, -1, 2, 0},
154 { 3, s_5_2, -1, 13, 0},
155 { 2, s_5_3, -1, 15, 0},
156 { 3, s_5_4, 3, 12, 0},
157 { 4, s_5_5, 4, 4, 0},
158 { 4, s_5_6, 3, 8, 0},
159 { 5, s_5_7, 3, 9, 0},
160 { 6, s_5_8, 3, 14, 0},
161 { 5, s_5_9, 3, 10, 0},
162 { 5, s_5_10, 3, 5, 0},
163 { 5, s_5_11, -1, 8, 0},
164 { 6, s_5_12, -1, 12, 0},
165 { 5, s_5_13, -1, 11, 0},
166 { 6, s_5_14, -1, 1, 0},
167 { 7, s_5_15, 14, 7, 0},
168 { 5, s_5_16, -1, 8, 0},
169 { 5, s_5_17, -1, 7, 0},
170 { 7, s_5_18, 17, 6, 0},
171 { 4, s_5_19, -1, 6, 0},
172 { 4, s_5_20, -1, 7, 0},
173 { 7, s_5_21, -1, 11, 0},
174 { 7, s_5_22, -1, 9, 0},
175 { 7, s_5_23, -1, 10, 0}
176 };
177 
178 static const symbol s_6_0[5] = { 'i', 'c', 'a', 't', 'e' };
179 static const symbol s_6_1[5] = { 'a', 't', 'i', 'v', 'e' };
180 static const symbol s_6_2[5] = { 'a', 'l', 'i', 'z', 'e' };
181 static const symbol s_6_3[5] = { 'i', 'c', 'i', 't', 'i' };
182 static const symbol s_6_4[4] = { 'i', 'c', 'a', 'l' };
183 static const symbol s_6_5[6] = { 't', 'i', 'o', 'n', 'a', 'l' };
184 static const symbol s_6_6[7] = { 'a', 't', 'i', 'o', 'n', 'a', 'l' };
185 static const symbol s_6_7[3] = { 'f', 'u', 'l' };
186 static const symbol s_6_8[4] = { 'n', 'e', 's', 's' };
187 
188 static const struct among a_6[9] =
189 {
190 { 5, s_6_0, -1, 4, 0},
191 { 5, s_6_1, -1, 6, 0},
192 { 5, s_6_2, -1, 3, 0},
193 { 5, s_6_3, -1, 4, 0},
194 { 4, s_6_4, -1, 4, 0},
195 { 6, s_6_5, -1, 1, 0},
196 { 7, s_6_6, 5, 2, 0},
197 { 3, s_6_7, -1, 5, 0},
198 { 4, s_6_8, -1, 5, 0}
199 };
200 
201 static const symbol s_7_0[2] = { 'i', 'c' };
202 static const symbol s_7_1[4] = { 'a', 'n', 'c', 'e' };
203 static const symbol s_7_2[4] = { 'e', 'n', 'c', 'e' };
204 static const symbol s_7_3[4] = { 'a', 'b', 'l', 'e' };
205 static const symbol s_7_4[4] = { 'i', 'b', 'l', 'e' };
206 static const symbol s_7_5[3] = { 'a', 't', 'e' };
207 static const symbol s_7_6[3] = { 'i', 'v', 'e' };
208 static const symbol s_7_7[3] = { 'i', 'z', 'e' };
209 static const symbol s_7_8[3] = { 'i', 't', 'i' };
210 static const symbol s_7_9[2] = { 'a', 'l' };
211 static const symbol s_7_10[3] = { 'i', 's', 'm' };
212 static const symbol s_7_11[3] = { 'i', 'o', 'n' };
213 static const symbol s_7_12[2] = { 'e', 'r' };
214 static const symbol s_7_13[3] = { 'o', 'u', 's' };
215 static const symbol s_7_14[3] = { 'a', 'n', 't' };
216 static const symbol s_7_15[3] = { 'e', 'n', 't' };
217 static const symbol s_7_16[4] = { 'm', 'e', 'n', 't' };
218 static const symbol s_7_17[5] = { 'e', 'm', 'e', 'n', 't' };
219 
220 static const struct among a_7[18] =
221 {
222 { 2, s_7_0, -1, 1, 0},
223 { 4, s_7_1, -1, 1, 0},
224 { 4, s_7_2, -1, 1, 0},
225 { 4, s_7_3, -1, 1, 0},
226 { 4, s_7_4, -1, 1, 0},
227 { 3, s_7_5, -1, 1, 0},
228 { 3, s_7_6, -1, 1, 0},
229 { 3, s_7_7, -1, 1, 0},
230 { 3, s_7_8, -1, 1, 0},
231 { 2, s_7_9, -1, 1, 0},
232 { 3, s_7_10, -1, 1, 0},
233 { 3, s_7_11, -1, 2, 0},
234 { 2, s_7_12, -1, 1, 0},
235 { 3, s_7_13, -1, 1, 0},
236 { 3, s_7_14, -1, 1, 0},
237 { 3, s_7_15, -1, 1, 0},
238 { 4, s_7_16, 15, 1, 0},
239 { 5, s_7_17, 16, 1, 0}
240 };
241 
242 static const symbol s_8_0[1] = { 'e' };
243 static const symbol s_8_1[1] = { 'l' };
244 
245 static const struct among a_8[2] =
246 {
247 { 1, s_8_0, -1, 1, 0},
248 { 1, s_8_1, -1, 2, 0}
249 };
250 
251 static const symbol s_9_0[7] = { 's', 'u', 'c', 'c', 'e', 'e', 'd' };
252 static const symbol s_9_1[7] = { 'p', 'r', 'o', 'c', 'e', 'e', 'd' };
253 static const symbol s_9_2[6] = { 'e', 'x', 'c', 'e', 'e', 'd' };
254 static const symbol s_9_3[7] = { 'c', 'a', 'n', 'n', 'i', 'n', 'g' };
255 static const symbol s_9_4[6] = { 'i', 'n', 'n', 'i', 'n', 'g' };
256 static const symbol s_9_5[7] = { 'e', 'a', 'r', 'r', 'i', 'n', 'g' };
257 static const symbol s_9_6[7] = { 'h', 'e', 'r', 'r', 'i', 'n', 'g' };
258 static const symbol s_9_7[6] = { 'o', 'u', 't', 'i', 'n', 'g' };
259 
260 static const struct among a_9[8] =
261 {
262 { 7, s_9_0, -1, -1, 0},
263 { 7, s_9_1, -1, -1, 0},
264 { 6, s_9_2, -1, -1, 0},
265 { 7, s_9_3, -1, -1, 0},
266 { 6, s_9_4, -1, -1, 0},
267 { 7, s_9_5, -1, -1, 0},
268 { 7, s_9_6, -1, -1, 0},
269 { 6, s_9_7, -1, -1, 0}
270 };
271 
272 static const symbol s_10_0[5] = { 'a', 'n', 'd', 'e', 's' };
273 static const symbol s_10_1[5] = { 'a', 't', 'l', 'a', 's' };
274 static const symbol s_10_2[4] = { 'b', 'i', 'a', 's' };
275 static const symbol s_10_3[6] = { 'c', 'o', 's', 'm', 'o', 's' };
276 static const symbol s_10_4[5] = { 'd', 'y', 'i', 'n', 'g' };
277 static const symbol s_10_5[5] = { 'e', 'a', 'r', 'l', 'y' };
278 static const symbol s_10_6[6] = { 'g', 'e', 'n', 't', 'l', 'y' };
279 static const symbol s_10_7[4] = { 'h', 'o', 'w', 'e' };
280 static const symbol s_10_8[4] = { 'i', 'd', 'l', 'y' };
281 static const symbol s_10_9[5] = { 'l', 'y', 'i', 'n', 'g' };
282 static const symbol s_10_10[4] = { 'n', 'e', 'w', 's' };
283 static const symbol s_10_11[4] = { 'o', 'n', 'l', 'y' };
284 static const symbol s_10_12[6] = { 's', 'i', 'n', 'g', 'l', 'y' };
285 static const symbol s_10_13[5] = { 's', 'k', 'i', 'e', 's' };
286 static const symbol s_10_14[4] = { 's', 'k', 'i', 's' };
287 static const symbol s_10_15[3] = { 's', 'k', 'y' };
288 static const symbol s_10_16[5] = { 't', 'y', 'i', 'n', 'g' };
289 static const symbol s_10_17[4] = { 'u', 'g', 'l', 'y' };
290 
291 static const struct among a_10[18] =
292 {
293 { 5, s_10_0, -1, -1, 0},
294 { 5, s_10_1, -1, -1, 0},
295 { 4, s_10_2, -1, -1, 0},
296 { 6, s_10_3, -1, -1, 0},
297 { 5, s_10_4, -1, 3, 0},
298 { 5, s_10_5, -1, 9, 0},
299 { 6, s_10_6, -1, 7, 0},
300 { 4, s_10_7, -1, -1, 0},
301 { 4, s_10_8, -1, 6, 0},
302 { 5, s_10_9, -1, 4, 0},
303 { 4, s_10_10, -1, -1, 0},
304 { 4, s_10_11, -1, 10, 0},
305 { 6, s_10_12, -1, 11, 0},
306 { 5, s_10_13, -1, 2, 0},
307 { 4, s_10_14, -1, 1, 0},
308 { 3, s_10_15, -1, -1, 0},
309 { 5, s_10_16, -1, 5, 0},
310 { 4, s_10_17, -1, 8, 0}
311 };
312 
313 static const unsigned char g_v[] = { 17, 65, 16, 1 };
314 
315 static const unsigned char g_v_WXY[] = { 1, 17, 65, 208, 1 };
316 
317 static const unsigned char g_valid_LI[] = { 55, 141, 2 };
318 
319 static const symbol s_0[] = { 'Y' };
320 static const symbol s_1[] = { 'Y' };
321 static const symbol s_2[] = { 's', 's' };
322 static const symbol s_3[] = { 'i' };
323 static const symbol s_4[] = { 'i', 'e' };
324 static const symbol s_5[] = { 'e', 'e' };
325 static const symbol s_6[] = { 'e' };
326 static const symbol s_7[] = { 'e' };
327 static const symbol s_8[] = { 'i' };
328 static const symbol s_9[] = { 't', 'i', 'o', 'n' };
329 static const symbol s_10[] = { 'e', 'n', 'c', 'e' };
330 static const symbol s_11[] = { 'a', 'n', 'c', 'e' };
331 static const symbol s_12[] = { 'a', 'b', 'l', 'e' };
332 static const symbol s_13[] = { 'e', 'n', 't' };
333 static const symbol s_14[] = { 'i', 'z', 'e' };
334 static const symbol s_15[] = { 'a', 't', 'e' };
335 static const symbol s_16[] = { 'a', 'l' };
336 static const symbol s_17[] = { 'f', 'u', 'l' };
337 static const symbol s_18[] = { 'o', 'u', 's' };
338 static const symbol s_19[] = { 'i', 'v', 'e' };
339 static const symbol s_20[] = { 'b', 'l', 'e' };
340 static const symbol s_21[] = { 'o', 'g' };
341 static const symbol s_22[] = { 'l', 'e', 's', 's' };
342 static const symbol s_23[] = { 't', 'i', 'o', 'n' };
343 static const symbol s_24[] = { 'a', 't', 'e' };
344 static const symbol s_25[] = { 'a', 'l' };
345 static const symbol s_26[] = { 'i', 'c' };
346 static const symbol s_27[] = { 's', 'k', 'i' };
347 static const symbol s_28[] = { 's', 'k', 'y' };
348 static const symbol s_29[] = { 'd', 'i', 'e' };
349 static const symbol s_30[] = { 'l', 'i', 'e' };
350 static const symbol s_31[] = { 't', 'i', 'e' };
351 static const symbol s_32[] = { 'i', 'd', 'l' };
352 static const symbol s_33[] = { 'g', 'e', 'n', 't', 'l' };
353 static const symbol s_34[] = { 'u', 'g', 'l', 'i' };
354 static const symbol s_35[] = { 'e', 'a', 'r', 'l', 'i' };
355 static const symbol s_36[] = { 'o', 'n', 'l', 'i' };
356 static const symbol s_37[] = { 's', 'i', 'n', 'g', 'l' };
357 static const symbol s_38[] = { 'y' };
358 
r_prelude(struct SN_env * z)359 static int r_prelude(struct SN_env * z) {
360     z->I[2] = 0;
361     {   int c1 = z->c;
362         z->bra = z->c;
363         if (z->c == z->l || z->p[z->c] != '\'') goto lab0;
364         z->c++;
365         z->ket = z->c;
366         {   int ret = slice_del(z);
367             if (ret < 0) return ret;
368         }
369     lab0:
370         z->c = c1;
371     }
372     {   int c2 = z->c;
373         z->bra = z->c;
374         if (z->c == z->l || z->p[z->c] != 'y') goto lab1;
375         z->c++;
376         z->ket = z->c;
377         {   int ret = slice_from_s(z, 1, s_0);
378             if (ret < 0) return ret;
379         }
380         z->I[2] = 1;
381     lab1:
382         z->c = c2;
383     }
384     {   int c3 = z->c;
385         while(1) {
386             int c4 = z->c;
387             while(1) {
388                 int c5 = z->c;
389                 if (in_grouping_U(z, g_v, 97, 121, 0)) goto lab4;
390                 z->bra = z->c;
391                 if (z->c == z->l || z->p[z->c] != 'y') goto lab4;
392                 z->c++;
393                 z->ket = z->c;
394                 z->c = c5;
395                 break;
396             lab4:
397                 z->c = c5;
398                 {   int ret = skip_utf8(z->p, z->c, z->l, 1);
399                     if (ret < 0) goto lab3;
400                     z->c = ret;
401                 }
402             }
403             {   int ret = slice_from_s(z, 1, s_1);
404                 if (ret < 0) return ret;
405             }
406             z->I[2] = 1;
407             continue;
408         lab3:
409             z->c = c4;
410             break;
411         }
412         z->c = c3;
413     }
414     return 1;
415 }
416 
r_mark_regions(struct SN_env * z)417 static int r_mark_regions(struct SN_env * z) {
418     z->I[1] = z->l;
419     z->I[0] = z->l;
420     {   int c1 = z->c;
421         {   int c2 = z->c;
422             if (z->c + 4 >= z->l || z->p[z->c + 4] >> 5 != 3 || !((2375680 >> (z->p[z->c + 4] & 0x1f)) & 1)) goto lab2;
423             if (!(find_among(z, a_0, 3))) goto lab2;
424             goto lab1;
425         lab2:
426             z->c = c2;
427             {
428                 int ret = out_grouping_U(z, g_v, 97, 121, 1);
429                 if (ret < 0) goto lab0;
430                 z->c += ret;
431             }
432             {
433                 int ret = in_grouping_U(z, g_v, 97, 121, 1);
434                 if (ret < 0) goto lab0;
435                 z->c += ret;
436             }
437         }
438     lab1:
439         z->I[1] = z->c;
440         {
441             int ret = out_grouping_U(z, g_v, 97, 121, 1);
442             if (ret < 0) goto lab0;
443             z->c += ret;
444         }
445         {
446             int ret = in_grouping_U(z, g_v, 97, 121, 1);
447             if (ret < 0) goto lab0;
448             z->c += ret;
449         }
450         z->I[0] = z->c;
451     lab0:
452         z->c = c1;
453     }
454     return 1;
455 }
456 
r_shortv(struct SN_env * z)457 static int r_shortv(struct SN_env * z) {
458     {   int m1 = z->l - z->c; (void)m1;
459         if (out_grouping_b_U(z, g_v_WXY, 89, 121, 0)) goto lab1;
460         if (in_grouping_b_U(z, g_v, 97, 121, 0)) goto lab1;
461         if (out_grouping_b_U(z, g_v, 97, 121, 0)) goto lab1;
462         goto lab0;
463     lab1:
464         z->c = z->l - m1;
465         if (out_grouping_b_U(z, g_v, 97, 121, 0)) return 0;
466         if (in_grouping_b_U(z, g_v, 97, 121, 0)) return 0;
467         if (z->c > z->lb) return 0;
468     }
469 lab0:
470     return 1;
471 }
472 
r_R1(struct SN_env * z)473 static int r_R1(struct SN_env * z) {
474     if (!(z->I[1] <= z->c)) return 0;
475     return 1;
476 }
477 
r_R2(struct SN_env * z)478 static int r_R2(struct SN_env * z) {
479     if (!(z->I[0] <= z->c)) return 0;
480     return 1;
481 }
482 
r_Step_1a(struct SN_env * z)483 static int r_Step_1a(struct SN_env * z) {
484     int among_var;
485     {   int m1 = z->l - z->c; (void)m1;
486         z->ket = z->c;
487         if (z->c <= z->lb || (z->p[z->c - 1] != 39 && z->p[z->c - 1] != 115)) { z->c = z->l - m1; goto lab0; }
488         if (!(find_among_b(z, a_1, 3))) { z->c = z->l - m1; goto lab0; }
489         z->bra = z->c;
490         {   int ret = slice_del(z);
491             if (ret < 0) return ret;
492         }
493     lab0:
494         ;
495     }
496     z->ket = z->c;
497     if (z->c <= z->lb || (z->p[z->c - 1] != 100 && z->p[z->c - 1] != 115)) return 0;
498     among_var = find_among_b(z, a_2, 6);
499     if (!(among_var)) return 0;
500     z->bra = z->c;
501     switch (among_var) {
502         case 1:
503             {   int ret = slice_from_s(z, 2, s_2);
504                 if (ret < 0) return ret;
505             }
506             break;
507         case 2:
508             {   int m2 = z->l - z->c; (void)m2;
509                 {   int ret = skip_b_utf8(z->p, z->c, z->lb, 2);
510                     if (ret < 0) goto lab2;
511                     z->c = ret;
512                 }
513                 {   int ret = slice_from_s(z, 1, s_3);
514                     if (ret < 0) return ret;
515                 }
516                 goto lab1;
517             lab2:
518                 z->c = z->l - m2;
519                 {   int ret = slice_from_s(z, 2, s_4);
520                     if (ret < 0) return ret;
521                 }
522             }
523         lab1:
524             break;
525         case 3:
526             {   int ret = skip_b_utf8(z->p, z->c, z->lb, 1);
527                 if (ret < 0) return 0;
528                 z->c = ret;
529             }
530             {
531                 int ret = out_grouping_b_U(z, g_v, 97, 121, 1);
532                 if (ret < 0) return 0;
533                 z->c -= ret;
534             }
535             {   int ret = slice_del(z);
536                 if (ret < 0) return ret;
537             }
538             break;
539     }
540     return 1;
541 }
542 
r_Step_1b(struct SN_env * z)543 static int r_Step_1b(struct SN_env * z) {
544     int among_var;
545     z->ket = z->c;
546     if (z->c - 1 <= z->lb || z->p[z->c - 1] >> 5 != 3 || !((33554576 >> (z->p[z->c - 1] & 0x1f)) & 1)) return 0;
547     among_var = find_among_b(z, a_4, 6);
548     if (!(among_var)) return 0;
549     z->bra = z->c;
550     switch (among_var) {
551         case 1:
552             {   int ret = r_R1(z);
553                 if (ret <= 0) return ret;
554             }
555             {   int ret = slice_from_s(z, 2, s_5);
556                 if (ret < 0) return ret;
557             }
558             break;
559         case 2:
560             {   int m_test1 = z->l - z->c;
561                 {
562                     int ret = out_grouping_b_U(z, g_v, 97, 121, 1);
563                     if (ret < 0) return 0;
564                     z->c -= ret;
565                 }
566                 z->c = z->l - m_test1;
567             }
568             {   int ret = slice_del(z);
569                 if (ret < 0) return ret;
570             }
571             {   int m_test2 = z->l - z->c;
572                 if (z->c - 1 <= z->lb || z->p[z->c - 1] >> 5 != 3 || !((68514004 >> (z->p[z->c - 1] & 0x1f)) & 1)) among_var = 3; else
573                 among_var = find_among_b(z, a_3, 13);
574                 if (!(among_var)) return 0;
575                 z->c = z->l - m_test2;
576             }
577             switch (among_var) {
578                 case 1:
579                     {   int ret;
580                         {   int saved_c = z->c;
581                             ret = insert_s(z, z->c, z->c, 1, s_6);
582                             z->c = saved_c;
583                         }
584                         if (ret < 0) return ret;
585                     }
586                     break;
587                 case 2:
588                     z->ket = z->c;
589                     {   int ret = skip_b_utf8(z->p, z->c, z->lb, 1);
590                         if (ret < 0) return 0;
591                         z->c = ret;
592                     }
593                     z->bra = z->c;
594                     {   int ret = slice_del(z);
595                         if (ret < 0) return ret;
596                     }
597                     break;
598                 case 3:
599                     if (z->c != z->I[1]) return 0;
600                     {   int m_test3 = z->l - z->c;
601                         {   int ret = r_shortv(z);
602                             if (ret <= 0) return ret;
603                         }
604                         z->c = z->l - m_test3;
605                     }
606                     {   int ret;
607                         {   int saved_c = z->c;
608                             ret = insert_s(z, z->c, z->c, 1, s_7);
609                             z->c = saved_c;
610                         }
611                         if (ret < 0) return ret;
612                     }
613                     break;
614             }
615             break;
616     }
617     return 1;
618 }
619 
r_Step_1c(struct SN_env * z)620 static int r_Step_1c(struct SN_env * z) {
621     z->ket = z->c;
622     {   int m1 = z->l - z->c; (void)m1;
623         if (z->c <= z->lb || z->p[z->c - 1] != 'y') goto lab1;
624         z->c--;
625         goto lab0;
626     lab1:
627         z->c = z->l - m1;
628         if (z->c <= z->lb || z->p[z->c - 1] != 'Y') return 0;
629         z->c--;
630     }
631 lab0:
632     z->bra = z->c;
633     if (out_grouping_b_U(z, g_v, 97, 121, 0)) return 0;
634 
635     if (z->c > z->lb) goto lab2;
636     return 0;
637 lab2:
638     {   int ret = slice_from_s(z, 1, s_8);
639         if (ret < 0) return ret;
640     }
641     return 1;
642 }
643 
r_Step_2(struct SN_env * z)644 static int r_Step_2(struct SN_env * z) {
645     int among_var;
646     z->ket = z->c;
647     if (z->c - 1 <= z->lb || z->p[z->c - 1] >> 5 != 3 || !((815616 >> (z->p[z->c - 1] & 0x1f)) & 1)) return 0;
648     among_var = find_among_b(z, a_5, 24);
649     if (!(among_var)) return 0;
650     z->bra = z->c;
651     {   int ret = r_R1(z);
652         if (ret <= 0) return ret;
653     }
654     switch (among_var) {
655         case 1:
656             {   int ret = slice_from_s(z, 4, s_9);
657                 if (ret < 0) return ret;
658             }
659             break;
660         case 2:
661             {   int ret = slice_from_s(z, 4, s_10);
662                 if (ret < 0) return ret;
663             }
664             break;
665         case 3:
666             {   int ret = slice_from_s(z, 4, s_11);
667                 if (ret < 0) return ret;
668             }
669             break;
670         case 4:
671             {   int ret = slice_from_s(z, 4, s_12);
672                 if (ret < 0) return ret;
673             }
674             break;
675         case 5:
676             {   int ret = slice_from_s(z, 3, s_13);
677                 if (ret < 0) return ret;
678             }
679             break;
680         case 6:
681             {   int ret = slice_from_s(z, 3, s_14);
682                 if (ret < 0) return ret;
683             }
684             break;
685         case 7:
686             {   int ret = slice_from_s(z, 3, s_15);
687                 if (ret < 0) return ret;
688             }
689             break;
690         case 8:
691             {   int ret = slice_from_s(z, 2, s_16);
692                 if (ret < 0) return ret;
693             }
694             break;
695         case 9:
696             {   int ret = slice_from_s(z, 3, s_17);
697                 if (ret < 0) return ret;
698             }
699             break;
700         case 10:
701             {   int ret = slice_from_s(z, 3, s_18);
702                 if (ret < 0) return ret;
703             }
704             break;
705         case 11:
706             {   int ret = slice_from_s(z, 3, s_19);
707                 if (ret < 0) return ret;
708             }
709             break;
710         case 12:
711             {   int ret = slice_from_s(z, 3, s_20);
712                 if (ret < 0) return ret;
713             }
714             break;
715         case 13:
716             if (z->c <= z->lb || z->p[z->c - 1] != 'l') return 0;
717             z->c--;
718             {   int ret = slice_from_s(z, 2, s_21);
719                 if (ret < 0) return ret;
720             }
721             break;
722         case 14:
723             {   int ret = slice_from_s(z, 4, s_22);
724                 if (ret < 0) return ret;
725             }
726             break;
727         case 15:
728             if (in_grouping_b_U(z, g_valid_LI, 99, 116, 0)) return 0;
729             {   int ret = slice_del(z);
730                 if (ret < 0) return ret;
731             }
732             break;
733     }
734     return 1;
735 }
736 
r_Step_3(struct SN_env * z)737 static int r_Step_3(struct SN_env * z) {
738     int among_var;
739     z->ket = z->c;
740     if (z->c - 2 <= z->lb || z->p[z->c - 1] >> 5 != 3 || !((528928 >> (z->p[z->c - 1] & 0x1f)) & 1)) return 0;
741     among_var = find_among_b(z, a_6, 9);
742     if (!(among_var)) return 0;
743     z->bra = z->c;
744     {   int ret = r_R1(z);
745         if (ret <= 0) return ret;
746     }
747     switch (among_var) {
748         case 1:
749             {   int ret = slice_from_s(z, 4, s_23);
750                 if (ret < 0) return ret;
751             }
752             break;
753         case 2:
754             {   int ret = slice_from_s(z, 3, s_24);
755                 if (ret < 0) return ret;
756             }
757             break;
758         case 3:
759             {   int ret = slice_from_s(z, 2, s_25);
760                 if (ret < 0) return ret;
761             }
762             break;
763         case 4:
764             {   int ret = slice_from_s(z, 2, s_26);
765                 if (ret < 0) return ret;
766             }
767             break;
768         case 5:
769             {   int ret = slice_del(z);
770                 if (ret < 0) return ret;
771             }
772             break;
773         case 6:
774             {   int ret = r_R2(z);
775                 if (ret <= 0) return ret;
776             }
777             {   int ret = slice_del(z);
778                 if (ret < 0) return ret;
779             }
780             break;
781     }
782     return 1;
783 }
784 
r_Step_4(struct SN_env * z)785 static int r_Step_4(struct SN_env * z) {
786     int among_var;
787     z->ket = z->c;
788     if (z->c - 1 <= z->lb || z->p[z->c - 1] >> 5 != 3 || !((1864232 >> (z->p[z->c - 1] & 0x1f)) & 1)) return 0;
789     among_var = find_among_b(z, a_7, 18);
790     if (!(among_var)) return 0;
791     z->bra = z->c;
792     {   int ret = r_R2(z);
793         if (ret <= 0) return ret;
794     }
795     switch (among_var) {
796         case 1:
797             {   int ret = slice_del(z);
798                 if (ret < 0) return ret;
799             }
800             break;
801         case 2:
802             {   int m1 = z->l - z->c; (void)m1;
803                 if (z->c <= z->lb || z->p[z->c - 1] != 's') goto lab1;
804                 z->c--;
805                 goto lab0;
806             lab1:
807                 z->c = z->l - m1;
808                 if (z->c <= z->lb || z->p[z->c - 1] != 't') return 0;
809                 z->c--;
810             }
811         lab0:
812             {   int ret = slice_del(z);
813                 if (ret < 0) return ret;
814             }
815             break;
816     }
817     return 1;
818 }
819 
r_Step_5(struct SN_env * z)820 static int r_Step_5(struct SN_env * z) {
821     int among_var;
822     z->ket = z->c;
823     if (z->c <= z->lb || (z->p[z->c - 1] != 101 && z->p[z->c - 1] != 108)) return 0;
824     among_var = find_among_b(z, a_8, 2);
825     if (!(among_var)) return 0;
826     z->bra = z->c;
827     switch (among_var) {
828         case 1:
829             {   int m1 = z->l - z->c; (void)m1;
830                 {   int ret = r_R2(z);
831                     if (ret == 0) goto lab1;
832                     if (ret < 0) return ret;
833                 }
834                 goto lab0;
835             lab1:
836                 z->c = z->l - m1;
837                 {   int ret = r_R1(z);
838                     if (ret <= 0) return ret;
839                 }
840                 {   int m2 = z->l - z->c; (void)m2;
841                     {   int ret = r_shortv(z);
842                         if (ret == 0) goto lab2;
843                         if (ret < 0) return ret;
844                     }
845                     return 0;
846                 lab2:
847                     z->c = z->l - m2;
848                 }
849             }
850         lab0:
851             {   int ret = slice_del(z);
852                 if (ret < 0) return ret;
853             }
854             break;
855         case 2:
856             {   int ret = r_R2(z);
857                 if (ret <= 0) return ret;
858             }
859             if (z->c <= z->lb || z->p[z->c - 1] != 'l') return 0;
860             z->c--;
861             {   int ret = slice_del(z);
862                 if (ret < 0) return ret;
863             }
864             break;
865     }
866     return 1;
867 }
868 
r_exception2(struct SN_env * z)869 static int r_exception2(struct SN_env * z) {
870     z->ket = z->c;
871     if (z->c - 5 <= z->lb || (z->p[z->c - 1] != 100 && z->p[z->c - 1] != 103)) return 0;
872     if (!(find_among_b(z, a_9, 8))) return 0;
873     z->bra = z->c;
874     if (z->c > z->lb) return 0;
875     return 1;
876 }
877 
r_exception1(struct SN_env * z)878 static int r_exception1(struct SN_env * z) {
879     int among_var;
880     z->bra = z->c;
881     if (z->c + 2 >= z->l || z->p[z->c + 2] >> 5 != 3 || !((42750482 >> (z->p[z->c + 2] & 0x1f)) & 1)) return 0;
882     among_var = find_among(z, a_10, 18);
883     if (!(among_var)) return 0;
884     z->ket = z->c;
885     if (z->c < z->l) return 0;
886     switch (among_var) {
887         case 1:
888             {   int ret = slice_from_s(z, 3, s_27);
889                 if (ret < 0) return ret;
890             }
891             break;
892         case 2:
893             {   int ret = slice_from_s(z, 3, s_28);
894                 if (ret < 0) return ret;
895             }
896             break;
897         case 3:
898             {   int ret = slice_from_s(z, 3, s_29);
899                 if (ret < 0) return ret;
900             }
901             break;
902         case 4:
903             {   int ret = slice_from_s(z, 3, s_30);
904                 if (ret < 0) return ret;
905             }
906             break;
907         case 5:
908             {   int ret = slice_from_s(z, 3, s_31);
909                 if (ret < 0) return ret;
910             }
911             break;
912         case 6:
913             {   int ret = slice_from_s(z, 3, s_32);
914                 if (ret < 0) return ret;
915             }
916             break;
917         case 7:
918             {   int ret = slice_from_s(z, 5, s_33);
919                 if (ret < 0) return ret;
920             }
921             break;
922         case 8:
923             {   int ret = slice_from_s(z, 4, s_34);
924                 if (ret < 0) return ret;
925             }
926             break;
927         case 9:
928             {   int ret = slice_from_s(z, 5, s_35);
929                 if (ret < 0) return ret;
930             }
931             break;
932         case 10:
933             {   int ret = slice_from_s(z, 4, s_36);
934                 if (ret < 0) return ret;
935             }
936             break;
937         case 11:
938             {   int ret = slice_from_s(z, 5, s_37);
939                 if (ret < 0) return ret;
940             }
941             break;
942     }
943     return 1;
944 }
945 
r_postlude(struct SN_env * z)946 static int r_postlude(struct SN_env * z) {
947     if (!(z->I[2])) return 0;
948     while(1) {
949         int c1 = z->c;
950         while(1) {
951             int c2 = z->c;
952             z->bra = z->c;
953             if (z->c == z->l || z->p[z->c] != 'Y') goto lab1;
954             z->c++;
955             z->ket = z->c;
956             z->c = c2;
957             break;
958         lab1:
959             z->c = c2;
960             {   int ret = skip_utf8(z->p, z->c, z->l, 1);
961                 if (ret < 0) goto lab0;
962                 z->c = ret;
963             }
964         }
965         {   int ret = slice_from_s(z, 1, s_38);
966             if (ret < 0) return ret;
967         }
968         continue;
969     lab0:
970         z->c = c1;
971         break;
972     }
973     return 1;
974 }
975 
english_UTF_8_stem(struct SN_env * z)976 extern int english_UTF_8_stem(struct SN_env * z) {
977     {   int c1 = z->c;
978         {   int ret = r_exception1(z);
979             if (ret == 0) goto lab1;
980             if (ret < 0) return ret;
981         }
982         goto lab0;
983     lab1:
984         z->c = c1;
985         {   int c2 = z->c;
986             {   int ret = skip_utf8(z->p, z->c, z->l, 3);
987                 if (ret < 0) goto lab3;
988                 z->c = ret;
989             }
990             goto lab2;
991         lab3:
992             z->c = c2;
993         }
994         goto lab0;
995     lab2:
996         z->c = c1;
997 
998         {   int ret = r_prelude(z);
999             if (ret < 0) return ret;
1000         }
1001 
1002         {   int ret = r_mark_regions(z);
1003             if (ret < 0) return ret;
1004         }
1005         z->lb = z->c; z->c = z->l;
1006 
1007         {   int m3 = z->l - z->c; (void)m3;
1008             {   int ret = r_Step_1a(z);
1009                 if (ret < 0) return ret;
1010             }
1011             z->c = z->l - m3;
1012         }
1013         {   int m4 = z->l - z->c; (void)m4;
1014             {   int ret = r_exception2(z);
1015                 if (ret == 0) goto lab5;
1016                 if (ret < 0) return ret;
1017             }
1018             goto lab4;
1019         lab5:
1020             z->c = z->l - m4;
1021             {   int m5 = z->l - z->c; (void)m5;
1022                 {   int ret = r_Step_1b(z);
1023                     if (ret < 0) return ret;
1024                 }
1025                 z->c = z->l - m5;
1026             }
1027             {   int m6 = z->l - z->c; (void)m6;
1028                 {   int ret = r_Step_1c(z);
1029                     if (ret < 0) return ret;
1030                 }
1031                 z->c = z->l - m6;
1032             }
1033             {   int m7 = z->l - z->c; (void)m7;
1034                 {   int ret = r_Step_2(z);
1035                     if (ret < 0) return ret;
1036                 }
1037                 z->c = z->l - m7;
1038             }
1039             {   int m8 = z->l - z->c; (void)m8;
1040                 {   int ret = r_Step_3(z);
1041                     if (ret < 0) return ret;
1042                 }
1043                 z->c = z->l - m8;
1044             }
1045             {   int m9 = z->l - z->c; (void)m9;
1046                 {   int ret = r_Step_4(z);
1047                     if (ret < 0) return ret;
1048                 }
1049                 z->c = z->l - m9;
1050             }
1051             {   int m10 = z->l - z->c; (void)m10;
1052                 {   int ret = r_Step_5(z);
1053                     if (ret < 0) return ret;
1054                 }
1055                 z->c = z->l - m10;
1056             }
1057         }
1058     lab4:
1059         z->c = z->lb;
1060         {   int c11 = z->c;
1061             {   int ret = r_postlude(z);
1062                 if (ret < 0) return ret;
1063             }
1064             z->c = c11;
1065         }
1066     }
1067 lab0:
1068     return 1;
1069 }
1070 
english_UTF_8_create_env(void)1071 extern struct SN_env * english_UTF_8_create_env(void) { return SN_create_env(0, 3); }
1072 
english_UTF_8_close_env(struct SN_env * z)1073 extern void english_UTF_8_close_env(struct SN_env * z) { SN_close_env(z, 0); }
1074 
1075