00001
00002
00003 #include <limits.h>
00004 #include "turkish.h"
00005
00006 static const symbol s_0_0[1] = { 'm' };
00007 static const symbol s_0_1[1] = { 'n' };
00008 static const symbol s_0_2[3] = { 'm', 'i', 'z' };
00009 static const symbol s_0_3[3] = { 'n', 'i', 'z' };
00010 static const symbol s_0_4[3] = { 'm', 'u', 'z' };
00011 static const symbol s_0_5[3] = { 'n', 'u', 'z' };
00012 static const symbol s_0_6[4] = { 'm', 0xC4, 0xB1, 'z' };
00013 static const symbol s_0_7[4] = { 'n', 0xC4, 0xB1, 'z' };
00014 static const symbol s_0_8[4] = { 'm', 0xC3, 0xBC, 'z' };
00015 static const symbol s_0_9[4] = { 'n', 0xC3, 0xBC, 'z' };
00016
00017 static const struct among a_0[10] =
00018 {
00019 { 1, s_0_0, -1, -1},
00020 { 1, s_0_1, -1, -1},
00021 { 3, s_0_2, -1, -1},
00022 { 3, s_0_3, -1, -1},
00023 { 3, s_0_4, -1, -1},
00024 { 3, s_0_5, -1, -1},
00025 { 4, s_0_6, -1, -1},
00026 { 4, s_0_7, -1, -1},
00027 { 4, s_0_8, -1, -1},
00028 { 4, s_0_9, -1, -1}
00029 };
00030
00031 static const symbol s_1_0[4] = { 'l', 'e', 'r', 'i' };
00032 static const symbol s_1_1[5] = { 'l', 'a', 'r', 0xC4, 0xB1 };
00033
00034 static const struct among a_1[2] =
00035 {
00036 { 4, s_1_0, -1, -1},
00037 { 5, s_1_1, -1, -1}
00038 };
00039
00040 static const symbol s_2_0[2] = { 'n', 'i' };
00041 static const symbol s_2_1[2] = { 'n', 'u' };
00042 static const symbol s_2_2[3] = { 'n', 0xC4, 0xB1 };
00043 static const symbol s_2_3[3] = { 'n', 0xC3, 0xBC };
00044
00045 static const struct among a_2[4] =
00046 {
00047 { 2, s_2_0, -1, -1},
00048 { 2, s_2_1, -1, -1},
00049 { 3, s_2_2, -1, -1},
00050 { 3, s_2_3, -1, -1}
00051 };
00052
00053 static const symbol s_3_0[2] = { 'i', 'n' };
00054 static const symbol s_3_1[2] = { 'u', 'n' };
00055 static const symbol s_3_2[3] = { 0xC4, 0xB1, 'n' };
00056 static const symbol s_3_3[3] = { 0xC3, 0xBC, 'n' };
00057
00058 static const struct among a_3[4] =
00059 {
00060 { 2, s_3_0, -1, -1},
00061 { 2, s_3_1, -1, -1},
00062 { 3, s_3_2, -1, -1},
00063 { 3, s_3_3, -1, -1}
00064 };
00065
00066 static const symbol s_4_0[1] = { 'a' };
00067 static const symbol s_4_1[1] = { 'e' };
00068
00069 static const struct among a_4[2] =
00070 {
00071 { 1, s_4_0, -1, -1},
00072 { 1, s_4_1, -1, -1}
00073 };
00074
00075 static const symbol s_5_0[2] = { 'n', 'a' };
00076 static const symbol s_5_1[2] = { 'n', 'e' };
00077
00078 static const struct among a_5[2] =
00079 {
00080 { 2, s_5_0, -1, -1},
00081 { 2, s_5_1, -1, -1}
00082 };
00083
00084 static const symbol s_6_0[2] = { 'd', 'a' };
00085 static const symbol s_6_1[2] = { 't', 'a' };
00086 static const symbol s_6_2[2] = { 'd', 'e' };
00087 static const symbol s_6_3[2] = { 't', 'e' };
00088
00089 static const struct among a_6[4] =
00090 {
00091 { 2, s_6_0, -1, -1},
00092 { 2, s_6_1, -1, -1},
00093 { 2, s_6_2, -1, -1},
00094 { 2, s_6_3, -1, -1}
00095 };
00096
00097 static const symbol s_7_0[3] = { 'n', 'd', 'a' };
00098 static const symbol s_7_1[3] = { 'n', 'd', 'e' };
00099
00100 static const struct among a_7[2] =
00101 {
00102 { 3, s_7_0, -1, -1},
00103 { 3, s_7_1, -1, -1}
00104 };
00105
00106 static const symbol s_8_0[3] = { 'd', 'a', 'n' };
00107 static const symbol s_8_1[3] = { 't', 'a', 'n' };
00108 static const symbol s_8_2[3] = { 'd', 'e', 'n' };
00109 static const symbol s_8_3[3] = { 't', 'e', 'n' };
00110
00111 static const struct among a_8[4] =
00112 {
00113 { 3, s_8_0, -1, -1},
00114 { 3, s_8_1, -1, -1},
00115 { 3, s_8_2, -1, -1},
00116 { 3, s_8_3, -1, -1}
00117 };
00118
00119 static const symbol s_9_0[4] = { 'n', 'd', 'a', 'n' };
00120 static const symbol s_9_1[4] = { 'n', 'd', 'e', 'n' };
00121
00122 static const struct among a_9[2] =
00123 {
00124 { 4, s_9_0, -1, -1},
00125 { 4, s_9_1, -1, -1}
00126 };
00127
00128 static const symbol s_10_0[2] = { 'l', 'a' };
00129 static const symbol s_10_1[2] = { 'l', 'e' };
00130
00131 static const struct among a_10[2] =
00132 {
00133 { 2, s_10_0, -1, -1},
00134 { 2, s_10_1, -1, -1}
00135 };
00136
00137 static const symbol s_11_0[2] = { 'c', 'a' };
00138 static const symbol s_11_1[2] = { 'c', 'e' };
00139
00140 static const struct among a_11[2] =
00141 {
00142 { 2, s_11_0, -1, -1},
00143 { 2, s_11_1, -1, -1}
00144 };
00145
00146 static const symbol s_12_0[2] = { 'i', 'm' };
00147 static const symbol s_12_1[2] = { 'u', 'm' };
00148 static const symbol s_12_2[3] = { 0xC4, 0xB1, 'm' };
00149 static const symbol s_12_3[3] = { 0xC3, 0xBC, 'm' };
00150
00151 static const struct among a_12[4] =
00152 {
00153 { 2, s_12_0, -1, -1},
00154 { 2, s_12_1, -1, -1},
00155 { 3, s_12_2, -1, -1},
00156 { 3, s_12_3, -1, -1}
00157 };
00158
00159 static const symbol s_13_0[3] = { 's', 'i', 'n' };
00160 static const symbol s_13_1[3] = { 's', 'u', 'n' };
00161 static const symbol s_13_2[4] = { 's', 0xC4, 0xB1, 'n' };
00162 static const symbol s_13_3[4] = { 's', 0xC3, 0xBC, 'n' };
00163
00164 static const struct among a_13[4] =
00165 {
00166 { 3, s_13_0, -1, -1},
00167 { 3, s_13_1, -1, -1},
00168 { 4, s_13_2, -1, -1},
00169 { 4, s_13_3, -1, -1}
00170 };
00171
00172 static const symbol s_14_0[2] = { 'i', 'z' };
00173 static const symbol s_14_1[2] = { 'u', 'z' };
00174 static const symbol s_14_2[3] = { 0xC4, 0xB1, 'z' };
00175 static const symbol s_14_3[3] = { 0xC3, 0xBC, 'z' };
00176
00177 static const struct among a_14[4] =
00178 {
00179 { 2, s_14_0, -1, -1},
00180 { 2, s_14_1, -1, -1},
00181 { 3, s_14_2, -1, -1},
00182 { 3, s_14_3, -1, -1}
00183 };
00184
00185 static const symbol s_15_0[5] = { 's', 'i', 'n', 'i', 'z' };
00186 static const symbol s_15_1[5] = { 's', 'u', 'n', 'u', 'z' };
00187 static const symbol s_15_2[7] = { 's', 0xC4, 0xB1, 'n', 0xC4, 0xB1, 'z' };
00188 static const symbol s_15_3[7] = { 's', 0xC3, 0xBC, 'n', 0xC3, 0xBC, 'z' };
00189
00190 static const struct among a_15[4] =
00191 {
00192 { 5, s_15_0, -1, -1},
00193 { 5, s_15_1, -1, -1},
00194 { 7, s_15_2, -1, -1},
00195 { 7, s_15_3, -1, -1}
00196 };
00197
00198 static const symbol s_16_0[3] = { 'l', 'a', 'r' };
00199 static const symbol s_16_1[3] = { 'l', 'e', 'r' };
00200
00201 static const struct among a_16[2] =
00202 {
00203 { 3, s_16_0, -1, -1},
00204 { 3, s_16_1, -1, -1}
00205 };
00206
00207 static const symbol s_17_0[3] = { 'n', 'i', 'z' };
00208 static const symbol s_17_1[3] = { 'n', 'u', 'z' };
00209 static const symbol s_17_2[4] = { 'n', 0xC4, 0xB1, 'z' };
00210 static const symbol s_17_3[4] = { 'n', 0xC3, 0xBC, 'z' };
00211
00212 static const struct among a_17[4] =
00213 {
00214 { 3, s_17_0, -1, -1},
00215 { 3, s_17_1, -1, -1},
00216 { 4, s_17_2, -1, -1},
00217 { 4, s_17_3, -1, -1}
00218 };
00219
00220 static const symbol s_18_0[3] = { 'd', 'i', 'r' };
00221 static const symbol s_18_1[3] = { 't', 'i', 'r' };
00222 static const symbol s_18_2[3] = { 'd', 'u', 'r' };
00223 static const symbol s_18_3[3] = { 't', 'u', 'r' };
00224 static const symbol s_18_4[4] = { 'd', 0xC4, 0xB1, 'r' };
00225 static const symbol s_18_5[4] = { 't', 0xC4, 0xB1, 'r' };
00226 static const symbol s_18_6[4] = { 'd', 0xC3, 0xBC, 'r' };
00227 static const symbol s_18_7[4] = { 't', 0xC3, 0xBC, 'r' };
00228
00229 static const struct among a_18[8] =
00230 {
00231 { 3, s_18_0, -1, -1},
00232 { 3, s_18_1, -1, -1},
00233 { 3, s_18_2, -1, -1},
00234 { 3, s_18_3, -1, -1},
00235 { 4, s_18_4, -1, -1},
00236 { 4, s_18_5, -1, -1},
00237 { 4, s_18_6, -1, -1},
00238 { 4, s_18_7, -1, -1}
00239 };
00240
00241 static const symbol s_19_0[7] = { 'c', 'a', 's', 0xC4, 0xB1, 'n', 'a' };
00242 static const symbol s_19_1[6] = { 'c', 'e', 's', 'i', 'n', 'e' };
00243
00244 static const struct among a_19[2] =
00245 {
00246 { 7, s_19_0, -1, -1},
00247 { 6, s_19_1, -1, -1}
00248 };
00249
00250 static const symbol s_20_0[2] = { 'd', 'i' };
00251 static const symbol s_20_1[2] = { 't', 'i' };
00252 static const symbol s_20_2[3] = { 'd', 'i', 'k' };
00253 static const symbol s_20_3[3] = { 't', 'i', 'k' };
00254 static const symbol s_20_4[3] = { 'd', 'u', 'k' };
00255 static const symbol s_20_5[3] = { 't', 'u', 'k' };
00256 static const symbol s_20_6[4] = { 'd', 0xC4, 0xB1, 'k' };
00257 static const symbol s_20_7[4] = { 't', 0xC4, 0xB1, 'k' };
00258 static const symbol s_20_8[4] = { 'd', 0xC3, 0xBC, 'k' };
00259 static const symbol s_20_9[4] = { 't', 0xC3, 0xBC, 'k' };
00260 static const symbol s_20_10[3] = { 'd', 'i', 'm' };
00261 static const symbol s_20_11[3] = { 't', 'i', 'm' };
00262 static const symbol s_20_12[3] = { 'd', 'u', 'm' };
00263 static const symbol s_20_13[3] = { 't', 'u', 'm' };
00264 static const symbol s_20_14[4] = { 'd', 0xC4, 0xB1, 'm' };
00265 static const symbol s_20_15[4] = { 't', 0xC4, 0xB1, 'm' };
00266 static const symbol s_20_16[4] = { 'd', 0xC3, 0xBC, 'm' };
00267 static const symbol s_20_17[4] = { 't', 0xC3, 0xBC, 'm' };
00268 static const symbol s_20_18[3] = { 'd', 'i', 'n' };
00269 static const symbol s_20_19[3] = { 't', 'i', 'n' };
00270 static const symbol s_20_20[3] = { 'd', 'u', 'n' };
00271 static const symbol s_20_21[3] = { 't', 'u', 'n' };
00272 static const symbol s_20_22[4] = { 'd', 0xC4, 0xB1, 'n' };
00273 static const symbol s_20_23[4] = { 't', 0xC4, 0xB1, 'n' };
00274 static const symbol s_20_24[4] = { 'd', 0xC3, 0xBC, 'n' };
00275 static const symbol s_20_25[4] = { 't', 0xC3, 0xBC, 'n' };
00276 static const symbol s_20_26[2] = { 'd', 'u' };
00277 static const symbol s_20_27[2] = { 't', 'u' };
00278 static const symbol s_20_28[3] = { 'd', 0xC4, 0xB1 };
00279 static const symbol s_20_29[3] = { 't', 0xC4, 0xB1 };
00280 static const symbol s_20_30[3] = { 'd', 0xC3, 0xBC };
00281 static const symbol s_20_31[3] = { 't', 0xC3, 0xBC };
00282
00283 static const struct among a_20[32] =
00284 {
00285 { 2, s_20_0, -1, -1},
00286 { 2, s_20_1, -1, -1},
00287 { 3, s_20_2, -1, -1},
00288 { 3, s_20_3, -1, -1},
00289 { 3, s_20_4, -1, -1},
00290 { 3, s_20_5, -1, -1},
00291 { 4, s_20_6, -1, -1},
00292 { 4, s_20_7, -1, -1},
00293 { 4, s_20_8, -1, -1},
00294 { 4, s_20_9, -1, -1},
00295 { 3, s_20_10, -1, -1},
00296 { 3, s_20_11, -1, -1},
00297 { 3, s_20_12, -1, -1},
00298 { 3, s_20_13, -1, -1},
00299 { 4, s_20_14, -1, -1},
00300 { 4, s_20_15, -1, -1},
00301 { 4, s_20_16, -1, -1},
00302 { 4, s_20_17, -1, -1},
00303 { 3, s_20_18, -1, -1},
00304 { 3, s_20_19, -1, -1},
00305 { 3, s_20_20, -1, -1},
00306 { 3, s_20_21, -1, -1},
00307 { 4, s_20_22, -1, -1},
00308 { 4, s_20_23, -1, -1},
00309 { 4, s_20_24, -1, -1},
00310 { 4, s_20_25, -1, -1},
00311 { 2, s_20_26, -1, -1},
00312 { 2, s_20_27, -1, -1},
00313 { 3, s_20_28, -1, -1},
00314 { 3, s_20_29, -1, -1},
00315 { 3, s_20_30, -1, -1},
00316 { 3, s_20_31, -1, -1}
00317 };
00318
00319 static const symbol s_21_0[2] = { 's', 'a' };
00320 static const symbol s_21_1[2] = { 's', 'e' };
00321 static const symbol s_21_2[3] = { 's', 'a', 'k' };
00322 static const symbol s_21_3[3] = { 's', 'e', 'k' };
00323 static const symbol s_21_4[3] = { 's', 'a', 'm' };
00324 static const symbol s_21_5[3] = { 's', 'e', 'm' };
00325 static const symbol s_21_6[3] = { 's', 'a', 'n' };
00326 static const symbol s_21_7[3] = { 's', 'e', 'n' };
00327
00328 static const struct among a_21[8] =
00329 {
00330 { 2, s_21_0, -1, -1},
00331 { 2, s_21_1, -1, -1},
00332 { 3, s_21_2, -1, -1},
00333 { 3, s_21_3, -1, -1},
00334 { 3, s_21_4, -1, -1},
00335 { 3, s_21_5, -1, -1},
00336 { 3, s_21_6, -1, -1},
00337 { 3, s_21_7, -1, -1}
00338 };
00339
00340 static const symbol s_22_0[4] = { 'm', 'i', 0xC5, 0x9F };
00341 static const symbol s_22_1[4] = { 'm', 'u', 0xC5, 0x9F };
00342 static const symbol s_22_2[5] = { 'm', 0xC4, 0xB1, 0xC5, 0x9F };
00343 static const symbol s_22_3[5] = { 'm', 0xC3, 0xBC, 0xC5, 0x9F };
00344
00345 static const struct among a_22[4] =
00346 {
00347 { 4, s_22_0, -1, -1},
00348 { 4, s_22_1, -1, -1},
00349 { 5, s_22_2, -1, -1},
00350 { 5, s_22_3, -1, -1}
00351 };
00352
00353 static const symbol s_23_0[1] = { 'b' };
00354 static const symbol s_23_1[1] = { 'c' };
00355 static const symbol s_23_2[1] = { 'd' };
00356 static const symbol s_23_3[2] = { 0xC4, 0x9F };
00357
00358 static const struct among a_23[4] =
00359 {
00360 { 1, s_23_0, -1, 1},
00361 { 1, s_23_1, -1, 2},
00362 { 1, s_23_2, -1, 3},
00363 { 2, s_23_3, -1, 4}
00364 };
00365
00366 static const unsigned char g_vowel[] = { 17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 8, 0, 0, 0, 0, 0, 0, 1 };
00367
00368 static const unsigned char g_U[] = { 1, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 1 };
00369
00370 static const unsigned char g_vowel1[] = { 1, 64, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1 };
00371
00372 static const unsigned char g_vowel2[] = { 17, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 130 };
00373
00374 static const unsigned char g_vowel3[] = { 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1 };
00375
00376 static const unsigned char g_vowel4[] = { 17 };
00377
00378 static const unsigned char g_vowel5[] = { 65 };
00379
00380 static const unsigned char g_vowel6[] = { 65 };
00381
00382 static const symbol s_0[] = { 0xC4, 0xB1 };
00383 static const symbol s_1[] = { 0xC3, 0xB6 };
00384 static const symbol s_2[] = { 0xC3, 0xBC };
00385 static const symbol s_3[] = { 'k', 'i' };
00386 static const symbol s_4[] = { 'k', 'e', 'n' };
00387 static const symbol s_5[] = { 'p' };
00388 static const symbol s_6[] = { 0xC3, 0xA7 };
00389 static const symbol s_7[] = { 't' };
00390 static const symbol s_8[] = { 'k' };
00391 static const symbol s_9[] = { 0xC4, 0xB1 };
00392 static const symbol s_10[] = { 0xC4, 0xB1 };
00393 static const symbol s_11[] = { 'i' };
00394 static const symbol s_12[] = { 'u' };
00395 static const symbol s_13[] = { 0xC3, 0xB6 };
00396 static const symbol s_14[] = { 0xC3, 0xBC };
00397 static const symbol s_15[] = { 0xC3, 0xBC };
00398 static const symbol s_16[] = { 'a', 'd' };
00399 static const symbol s_17[] = { 's', 'o', 'y', 'a', 'd' };
00400
00401 int Xapian::InternalStemTurkish::r_check_vowel_harmony() {
00402 { int m_test1 = l - c;
00403 if (out_grouping_b_U(g_vowel, 97, 305, 1) < 0) return 0;
00404 { int m2 = l - c; (void)m2;
00405 if (c <= lb || p[c - 1] != 'a') goto lab1;
00406 c--;
00407 if (out_grouping_b_U(g_vowel1, 97, 305, 1) < 0) goto lab1;
00408 goto lab0;
00409 lab1:
00410 c = l - m2;
00411 if (c <= lb || p[c - 1] != 'e') goto lab2;
00412 c--;
00413 if (out_grouping_b_U(g_vowel2, 101, 252, 1) < 0) goto lab2;
00414 goto lab0;
00415 lab2:
00416 c = l - m2;
00417 if (!(eq_s_b(2, s_0))) goto lab3;
00418 if (out_grouping_b_U(g_vowel3, 97, 305, 1) < 0) goto lab3;
00419 goto lab0;
00420 lab3:
00421 c = l - m2;
00422 if (c <= lb || p[c - 1] != 'i') goto lab4;
00423 c--;
00424 if (out_grouping_b_U(g_vowel4, 101, 105, 1) < 0) goto lab4;
00425 goto lab0;
00426 lab4:
00427 c = l - m2;
00428 if (c <= lb || p[c - 1] != 'o') goto lab5;
00429 c--;
00430 if (out_grouping_b_U(g_vowel5, 111, 117, 1) < 0) goto lab5;
00431 goto lab0;
00432 lab5:
00433 c = l - m2;
00434 if (!(eq_s_b(2, s_1))) goto lab6;
00435 if (out_grouping_b_U(g_vowel6, 246, 252, 1) < 0) goto lab6;
00436 goto lab0;
00437 lab6:
00438 c = l - m2;
00439 if (c <= lb || p[c - 1] != 'u') goto lab7;
00440 c--;
00441 if (out_grouping_b_U(g_vowel5, 111, 117, 1) < 0) goto lab7;
00442 goto lab0;
00443 lab7:
00444 c = l - m2;
00445 if (!(eq_s_b(2, s_2))) return 0;
00446 if (out_grouping_b_U(g_vowel6, 246, 252, 1) < 0) return 0;
00447 }
00448 lab0:
00449 c = l - m_test1;
00450 }
00451 return 1;
00452 }
00453
00454 int Xapian::InternalStemTurkish::r_mark_suffix_with_optional_n_consonant() {
00455 { int m1 = l - c; (void)m1;
00456 if (c <= lb || p[c - 1] != 'n') goto lab1;
00457 c--;
00458 { int m_test2 = l - c;
00459 if (in_grouping_b_U(g_vowel, 97, 305, 0)) goto lab1;
00460 c = l - m_test2;
00461 }
00462 goto lab0;
00463 lab1:
00464 c = l - m1;
00465 { int m3 = l - c; (void)m3;
00466 { int m_test4 = l - c;
00467 if (c <= lb || p[c - 1] != 'n') goto lab2;
00468 c--;
00469 c = l - m_test4;
00470 }
00471 return 0;
00472 lab2:
00473 c = l - m3;
00474 }
00475 { int m_test5 = l - c;
00476 { int ret = skip_utf8(p, c, lb, 0, -1);
00477 if (ret < 0) return 0;
00478 c = ret;
00479 }
00480 if (in_grouping_b_U(g_vowel, 97, 305, 0)) return 0;
00481 c = l - m_test5;
00482 }
00483 }
00484 lab0:
00485 return 1;
00486 }
00487
00488 int Xapian::InternalStemTurkish::r_mark_suffix_with_optional_s_consonant() {
00489 { int m1 = l - c; (void)m1;
00490 if (c <= lb || p[c - 1] != 's') goto lab1;
00491 c--;
00492 { int m_test2 = l - c;
00493 if (in_grouping_b_U(g_vowel, 97, 305, 0)) goto lab1;
00494 c = l - m_test2;
00495 }
00496 goto lab0;
00497 lab1:
00498 c = l - m1;
00499 { int m3 = l - c; (void)m3;
00500 { int m_test4 = l - c;
00501 if (c <= lb || p[c - 1] != 's') goto lab2;
00502 c--;
00503 c = l - m_test4;
00504 }
00505 return 0;
00506 lab2:
00507 c = l - m3;
00508 }
00509 { int m_test5 = l - c;
00510 { int ret = skip_utf8(p, c, lb, 0, -1);
00511 if (ret < 0) return 0;
00512 c = ret;
00513 }
00514 if (in_grouping_b_U(g_vowel, 97, 305, 0)) return 0;
00515 c = l - m_test5;
00516 }
00517 }
00518 lab0:
00519 return 1;
00520 }
00521
00522 int Xapian::InternalStemTurkish::r_mark_suffix_with_optional_y_consonant() {
00523 { int m1 = l - c; (void)m1;
00524 if (c <= lb || p[c - 1] != 'y') goto lab1;
00525 c--;
00526 { int m_test2 = l - c;
00527 if (in_grouping_b_U(g_vowel, 97, 305, 0)) goto lab1;
00528 c = l - m_test2;
00529 }
00530 goto lab0;
00531 lab1:
00532 c = l - m1;
00533 { int m3 = l - c; (void)m3;
00534 { int m_test4 = l - c;
00535 if (c <= lb || p[c - 1] != 'y') goto lab2;
00536 c--;
00537 c = l - m_test4;
00538 }
00539 return 0;
00540 lab2:
00541 c = l - m3;
00542 }
00543 { int m_test5 = l - c;
00544 { int ret = skip_utf8(p, c, lb, 0, -1);
00545 if (ret < 0) return 0;
00546 c = ret;
00547 }
00548 if (in_grouping_b_U(g_vowel, 97, 305, 0)) return 0;
00549 c = l - m_test5;
00550 }
00551 }
00552 lab0:
00553 return 1;
00554 }
00555
00556 int Xapian::InternalStemTurkish::r_mark_suffix_with_optional_U_vowel() {
00557 { int m1 = l - c; (void)m1;
00558 if (in_grouping_b_U(g_U, 105, 305, 0)) goto lab1;
00559 { int m_test2 = l - c;
00560 if (out_grouping_b_U(g_vowel, 97, 305, 0)) goto lab1;
00561 c = l - m_test2;
00562 }
00563 goto lab0;
00564 lab1:
00565 c = l - m1;
00566 { int m3 = l - c; (void)m3;
00567 { int m_test4 = l - c;
00568 if (in_grouping_b_U(g_U, 105, 305, 0)) goto lab2;
00569 c = l - m_test4;
00570 }
00571 return 0;
00572 lab2:
00573 c = l - m3;
00574 }
00575 { int m_test5 = l - c;
00576 { int ret = skip_utf8(p, c, lb, 0, -1);
00577 if (ret < 0) return 0;
00578 c = ret;
00579 }
00580 if (out_grouping_b_U(g_vowel, 97, 305, 0)) return 0;
00581 c = l - m_test5;
00582 }
00583 }
00584 lab0:
00585 return 1;
00586 }
00587
00588 int Xapian::InternalStemTurkish::r_mark_possessives() {
00589 if (c <= lb || p[c - 1] >> 5 != 3 || !((67133440 >> (p[c - 1] & 0x1f)) & 1)) return 0;
00590 if (!(find_among_b(a_0, 10, 0, 0))) return 0;
00591 { int ret = r_mark_suffix_with_optional_U_vowel();
00592 if (ret <= 0) return ret;
00593 }
00594 return 1;
00595 }
00596
00597 int Xapian::InternalStemTurkish::r_mark_sU() {
00598 { int ret = r_check_vowel_harmony();
00599 if (ret <= 0) return ret;
00600 }
00601 if (in_grouping_b_U(g_U, 105, 305, 0)) return 0;
00602 { int ret = r_mark_suffix_with_optional_s_consonant();
00603 if (ret <= 0) return ret;
00604 }
00605 return 1;
00606 }
00607
00608 int Xapian::InternalStemTurkish::r_mark_lArI() {
00609 if (c - 3 <= lb || (p[c - 1] != 105 && p[c - 1] != 177)) return 0;
00610 if (!(find_among_b(a_1, 2, 0, 0))) return 0;
00611 return 1;
00612 }
00613
00614 int Xapian::InternalStemTurkish::r_mark_yU() {
00615 { int ret = r_check_vowel_harmony();
00616 if (ret <= 0) return ret;
00617 }
00618 if (in_grouping_b_U(g_U, 105, 305, 0)) return 0;
00619 { int ret = r_mark_suffix_with_optional_y_consonant();
00620 if (ret <= 0) return ret;
00621 }
00622 return 1;
00623 }
00624
00625 int Xapian::InternalStemTurkish::r_mark_nU() {
00626 { int ret = r_check_vowel_harmony();
00627 if (ret <= 0) return ret;
00628 }
00629 if (!(find_among_b(a_2, 4, 0, 0))) return 0;
00630 return 1;
00631 }
00632
00633 int Xapian::InternalStemTurkish::r_mark_nUn() {
00634 { int ret = r_check_vowel_harmony();
00635 if (ret <= 0) return ret;
00636 }
00637 if (c - 1 <= lb || p[c - 1] != 110) return 0;
00638 if (!(find_among_b(a_3, 4, 0, 0))) return 0;
00639 { int ret = r_mark_suffix_with_optional_n_consonant();
00640 if (ret <= 0) return ret;
00641 }
00642 return 1;
00643 }
00644
00645 int Xapian::InternalStemTurkish::r_mark_yA() {
00646 { int ret = r_check_vowel_harmony();
00647 if (ret <= 0) return ret;
00648 }
00649 if (c <= lb || (p[c - 1] != 97 && p[c - 1] != 101)) return 0;
00650 if (!(find_among_b(a_4, 2, 0, 0))) return 0;
00651 { int ret = r_mark_suffix_with_optional_y_consonant();
00652 if (ret <= 0) return ret;
00653 }
00654 return 1;
00655 }
00656
00657 int Xapian::InternalStemTurkish::r_mark_nA() {
00658 { int ret = r_check_vowel_harmony();
00659 if (ret <= 0) return ret;
00660 }
00661 if (c - 1 <= lb || (p[c - 1] != 97 && p[c - 1] != 101)) return 0;
00662 if (!(find_among_b(a_5, 2, 0, 0))) return 0;
00663 return 1;
00664 }
00665
00666 int Xapian::InternalStemTurkish::r_mark_DA() {
00667 { int ret = r_check_vowel_harmony();
00668 if (ret <= 0) return ret;
00669 }
00670 if (c - 1 <= lb || (p[c - 1] != 97 && p[c - 1] != 101)) return 0;
00671 if (!(find_among_b(a_6, 4, 0, 0))) return 0;
00672 return 1;
00673 }
00674
00675 int Xapian::InternalStemTurkish::r_mark_ndA() {
00676 { int ret = r_check_vowel_harmony();
00677 if (ret <= 0) return ret;
00678 }
00679 if (c - 2 <= lb || (p[c - 1] != 97 && p[c - 1] != 101)) return 0;
00680 if (!(find_among_b(a_7, 2, 0, 0))) return 0;
00681 return 1;
00682 }
00683
00684 int Xapian::InternalStemTurkish::r_mark_DAn() {
00685 { int ret = r_check_vowel_harmony();
00686 if (ret <= 0) return ret;
00687 }
00688 if (c - 2 <= lb || p[c - 1] != 110) return 0;
00689 if (!(find_among_b(a_8, 4, 0, 0))) return 0;
00690 return 1;
00691 }
00692
00693 int Xapian::InternalStemTurkish::r_mark_ndAn() {
00694 { int ret = r_check_vowel_harmony();
00695 if (ret <= 0) return ret;
00696 }
00697 if (c - 3 <= lb || p[c - 1] != 110) return 0;
00698 if (!(find_among_b(a_9, 2, 0, 0))) return 0;
00699 return 1;
00700 }
00701
00702 int Xapian::InternalStemTurkish::r_mark_ylA() {
00703 { int ret = r_check_vowel_harmony();
00704 if (ret <= 0) return ret;
00705 }
00706 if (c - 1 <= lb || (p[c - 1] != 97 && p[c - 1] != 101)) return 0;
00707 if (!(find_among_b(a_10, 2, 0, 0))) return 0;
00708 { int ret = r_mark_suffix_with_optional_y_consonant();
00709 if (ret <= 0) return ret;
00710 }
00711 return 1;
00712 }
00713
00714 int Xapian::InternalStemTurkish::r_mark_ki() {
00715 if (!(eq_s_b(2, s_3))) return 0;
00716 return 1;
00717 }
00718
00719 int Xapian::InternalStemTurkish::r_mark_ncA() {
00720 { int ret = r_check_vowel_harmony();
00721 if (ret <= 0) return ret;
00722 }
00723 if (c - 1 <= lb || (p[c - 1] != 97 && p[c - 1] != 101)) return 0;
00724 if (!(find_among_b(a_11, 2, 0, 0))) return 0;
00725 { int ret = r_mark_suffix_with_optional_n_consonant();
00726 if (ret <= 0) return ret;
00727 }
00728 return 1;
00729 }
00730
00731 int Xapian::InternalStemTurkish::r_mark_yUm() {
00732 { int ret = r_check_vowel_harmony();
00733 if (ret <= 0) return ret;
00734 }
00735 if (c - 1 <= lb || p[c - 1] != 109) return 0;
00736 if (!(find_among_b(a_12, 4, 0, 0))) return 0;
00737 { int ret = r_mark_suffix_with_optional_y_consonant();
00738 if (ret <= 0) return ret;
00739 }
00740 return 1;
00741 }
00742
00743 int Xapian::InternalStemTurkish::r_mark_sUn() {
00744 { int ret = r_check_vowel_harmony();
00745 if (ret <= 0) return ret;
00746 }
00747 if (c - 2 <= lb || p[c - 1] != 110) return 0;
00748 if (!(find_among_b(a_13, 4, 0, 0))) return 0;
00749 return 1;
00750 }
00751
00752 int Xapian::InternalStemTurkish::r_mark_yUz() {
00753 { int ret = r_check_vowel_harmony();
00754 if (ret <= 0) return ret;
00755 }
00756 if (c - 1 <= lb || p[c - 1] != 122) return 0;
00757 if (!(find_among_b(a_14, 4, 0, 0))) return 0;
00758 { int ret = r_mark_suffix_with_optional_y_consonant();
00759 if (ret <= 0) return ret;
00760 }
00761 return 1;
00762 }
00763
00764 int Xapian::InternalStemTurkish::r_mark_sUnUz() {
00765 if (c - 4 <= lb || p[c - 1] != 122) return 0;
00766 if (!(find_among_b(a_15, 4, 0, 0))) return 0;
00767 return 1;
00768 }
00769
00770 int Xapian::InternalStemTurkish::r_mark_lAr() {
00771 { int ret = r_check_vowel_harmony();
00772 if (ret <= 0) return ret;
00773 }
00774 if (c - 2 <= lb || p[c - 1] != 114) return 0;
00775 if (!(find_among_b(a_16, 2, 0, 0))) return 0;
00776 return 1;
00777 }
00778
00779 int Xapian::InternalStemTurkish::r_mark_nUz() {
00780 { int ret = r_check_vowel_harmony();
00781 if (ret <= 0) return ret;
00782 }
00783 if (c - 2 <= lb || p[c - 1] != 122) return 0;
00784 if (!(find_among_b(a_17, 4, 0, 0))) return 0;
00785 return 1;
00786 }
00787
00788 int Xapian::InternalStemTurkish::r_mark_DUr() {
00789 { int ret = r_check_vowel_harmony();
00790 if (ret <= 0) return ret;
00791 }
00792 if (c - 2 <= lb || p[c - 1] != 114) return 0;
00793 if (!(find_among_b(a_18, 8, 0, 0))) return 0;
00794 return 1;
00795 }
00796
00797 int Xapian::InternalStemTurkish::r_mark_cAsInA() {
00798 if (c - 5 <= lb || (p[c - 1] != 97 && p[c - 1] != 101)) return 0;
00799 if (!(find_among_b(a_19, 2, 0, 0))) return 0;
00800 return 1;
00801 }
00802
00803 int Xapian::InternalStemTurkish::r_mark_yDU() {
00804 { int ret = r_check_vowel_harmony();
00805 if (ret <= 0) return ret;
00806 }
00807 if (!(find_among_b(a_20, 32, 0, 0))) return 0;
00808 { int ret = r_mark_suffix_with_optional_y_consonant();
00809 if (ret <= 0) return ret;
00810 }
00811 return 1;
00812 }
00813
00814 int Xapian::InternalStemTurkish::r_mark_ysA() {
00815 if (c - 1 <= lb || p[c - 1] >> 5 != 3 || !((26658 >> (p[c - 1] & 0x1f)) & 1)) return 0;
00816 if (!(find_among_b(a_21, 8, 0, 0))) return 0;
00817 { int ret = r_mark_suffix_with_optional_y_consonant();
00818 if (ret <= 0) return ret;
00819 }
00820 return 1;
00821 }
00822
00823 int Xapian::InternalStemTurkish::r_mark_ymUs_() {
00824 { int ret = r_check_vowel_harmony();
00825 if (ret <= 0) return ret;
00826 }
00827 if (c - 3 <= lb || p[c - 1] != 159) return 0;
00828 if (!(find_among_b(a_22, 4, 0, 0))) return 0;
00829 { int ret = r_mark_suffix_with_optional_y_consonant();
00830 if (ret <= 0) return ret;
00831 }
00832 return 1;
00833 }
00834
00835 int Xapian::InternalStemTurkish::r_mark_yken() {
00836 if (!(eq_s_b(3, s_4))) return 0;
00837 { int ret = r_mark_suffix_with_optional_y_consonant();
00838 if (ret <= 0) return ret;
00839 }
00840 return 1;
00841 }
00842
00843 int Xapian::InternalStemTurkish::r_stem_nominal_verb_suffixes() {
00844 ket = c;
00845 B_continue_stemming_noun_suffixes = 1;
00846 { int m1 = l - c; (void)m1;
00847 { int m2 = l - c; (void)m2;
00848 { int ret = r_mark_ymUs_();
00849 if (ret == 0) goto lab3;
00850 if (ret < 0) return ret;
00851 }
00852 goto lab2;
00853 lab3:
00854 c = l - m2;
00855 { int ret = r_mark_yDU();
00856 if (ret == 0) goto lab4;
00857 if (ret < 0) return ret;
00858 }
00859 goto lab2;
00860 lab4:
00861 c = l - m2;
00862 { int ret = r_mark_ysA();
00863 if (ret == 0) goto lab5;
00864 if (ret < 0) return ret;
00865 }
00866 goto lab2;
00867 lab5:
00868 c = l - m2;
00869 { int ret = r_mark_yken();
00870 if (ret == 0) goto lab1;
00871 if (ret < 0) return ret;
00872 }
00873 }
00874 lab2:
00875 goto lab0;
00876 lab1:
00877 c = l - m1;
00878 { int ret = r_mark_cAsInA();
00879 if (ret == 0) goto lab6;
00880 if (ret < 0) return ret;
00881 }
00882 { int m3 = l - c; (void)m3;
00883 { int ret = r_mark_sUnUz();
00884 if (ret == 0) goto lab8;
00885 if (ret < 0) return ret;
00886 }
00887 goto lab7;
00888 lab8:
00889 c = l - m3;
00890 { int ret = r_mark_lAr();
00891 if (ret == 0) goto lab9;
00892 if (ret < 0) return ret;
00893 }
00894 goto lab7;
00895 lab9:
00896 c = l - m3;
00897 { int ret = r_mark_yUm();
00898 if (ret == 0) goto lab10;
00899 if (ret < 0) return ret;
00900 }
00901 goto lab7;
00902 lab10:
00903 c = l - m3;
00904 { int ret = r_mark_sUn();
00905 if (ret == 0) goto lab11;
00906 if (ret < 0) return ret;
00907 }
00908 goto lab7;
00909 lab11:
00910 c = l - m3;
00911 { int ret = r_mark_yUz();
00912 if (ret == 0) goto lab12;
00913 if (ret < 0) return ret;
00914 }
00915 goto lab7;
00916 lab12:
00917 c = l - m3;
00918 }
00919 lab7:
00920 { int ret = r_mark_ymUs_();
00921 if (ret == 0) goto lab6;
00922 if (ret < 0) return ret;
00923 }
00924 goto lab0;
00925 lab6:
00926 c = l - m1;
00927 { int ret = r_mark_lAr();
00928 if (ret == 0) goto lab13;
00929 if (ret < 0) return ret;
00930 }
00931 bra = c;
00932 if (slice_del() == -1) return -1;
00933 { int m4 = l - c; (void)m4;
00934 ket = c;
00935 { int m5 = l - c; (void)m5;
00936 { int ret = r_mark_DUr();
00937 if (ret == 0) goto lab16;
00938 if (ret < 0) return ret;
00939 }
00940 goto lab15;
00941 lab16:
00942 c = l - m5;
00943 { int ret = r_mark_yDU();
00944 if (ret == 0) goto lab17;
00945 if (ret < 0) return ret;
00946 }
00947 goto lab15;
00948 lab17:
00949 c = l - m5;
00950 { int ret = r_mark_ysA();
00951 if (ret == 0) goto lab18;
00952 if (ret < 0) return ret;
00953 }
00954 goto lab15;
00955 lab18:
00956 c = l - m5;
00957 { int ret = r_mark_ymUs_();
00958 if (ret == 0) { c = l - m4; goto lab14; }
00959 if (ret < 0) return ret;
00960 }
00961 }
00962 lab15:
00963 lab14:
00964 ;
00965 }
00966 B_continue_stemming_noun_suffixes = 0;
00967 goto lab0;
00968 lab13:
00969 c = l - m1;
00970 { int ret = r_mark_nUz();
00971 if (ret == 0) goto lab19;
00972 if (ret < 0) return ret;
00973 }
00974 { int m6 = l - c; (void)m6;
00975 { int ret = r_mark_yDU();
00976 if (ret == 0) goto lab21;
00977 if (ret < 0) return ret;
00978 }
00979 goto lab20;
00980 lab21:
00981 c = l - m6;
00982 { int ret = r_mark_ysA();
00983 if (ret == 0) goto lab19;
00984 if (ret < 0) return ret;
00985 }
00986 }
00987 lab20:
00988 goto lab0;
00989 lab19:
00990 c = l - m1;
00991 { int m7 = l - c; (void)m7;
00992 { int ret = r_mark_sUnUz();
00993 if (ret == 0) goto lab24;
00994 if (ret < 0) return ret;
00995 }
00996 goto lab23;
00997 lab24:
00998 c = l - m7;
00999 { int ret = r_mark_yUz();
01000 if (ret == 0) goto lab25;
01001 if (ret < 0) return ret;
01002 }
01003 goto lab23;
01004 lab25:
01005 c = l - m7;
01006 { int ret = r_mark_sUn();
01007 if (ret == 0) goto lab26;
01008 if (ret < 0) return ret;
01009 }
01010 goto lab23;
01011 lab26:
01012 c = l - m7;
01013 { int ret = r_mark_yUm();
01014 if (ret == 0) goto lab22;
01015 if (ret < 0) return ret;
01016 }
01017 }
01018 lab23:
01019 bra = c;
01020 if (slice_del() == -1) return -1;
01021 { int m8 = l - c; (void)m8;
01022 ket = c;
01023 { int ret = r_mark_ymUs_();
01024 if (ret == 0) { c = l - m8; goto lab27; }
01025 if (ret < 0) return ret;
01026 }
01027 lab27:
01028 ;
01029 }
01030 goto lab0;
01031 lab22:
01032 c = l - m1;
01033 { int ret = r_mark_DUr();
01034 if (ret <= 0) return ret;
01035 }
01036 bra = c;
01037 if (slice_del() == -1) return -1;
01038 { int m9 = l - c; (void)m9;
01039 ket = c;
01040 { int m10 = l - c; (void)m10;
01041 { int ret = r_mark_sUnUz();
01042 if (ret == 0) goto lab30;
01043 if (ret < 0) return ret;
01044 }
01045 goto lab29;
01046 lab30:
01047 c = l - m10;
01048 { int ret = r_mark_lAr();
01049 if (ret == 0) goto lab31;
01050 if (ret < 0) return ret;
01051 }
01052 goto lab29;
01053 lab31:
01054 c = l - m10;
01055 { int ret = r_mark_yUm();
01056 if (ret == 0) goto lab32;
01057 if (ret < 0) return ret;
01058 }
01059 goto lab29;
01060 lab32:
01061 c = l - m10;
01062 { int ret = r_mark_sUn();
01063 if (ret == 0) goto lab33;
01064 if (ret < 0) return ret;
01065 }
01066 goto lab29;
01067 lab33:
01068 c = l - m10;
01069 { int ret = r_mark_yUz();
01070 if (ret == 0) goto lab34;
01071 if (ret < 0) return ret;
01072 }
01073 goto lab29;
01074 lab34:
01075 c = l - m10;
01076 }
01077 lab29:
01078 { int ret = r_mark_ymUs_();
01079 if (ret == 0) { c = l - m9; goto lab28; }
01080 if (ret < 0) return ret;
01081 }
01082 lab28:
01083 ;
01084 }
01085 }
01086 lab0:
01087 bra = c;
01088 if (slice_del() == -1) return -1;
01089 return 1;
01090 }
01091
01092 int Xapian::InternalStemTurkish::r_stem_suffix_chain_before_ki() {
01093 ket = c;
01094 { int ret = r_mark_ki();
01095 if (ret <= 0) return ret;
01096 }
01097 { int m1 = l - c; (void)m1;
01098 { int ret = r_mark_DA();
01099 if (ret == 0) goto lab1;
01100 if (ret < 0) return ret;
01101 }
01102 bra = c;
01103 if (slice_del() == -1) return -1;
01104 { int m2 = l - c; (void)m2;
01105 ket = c;
01106 { int m3 = l - c; (void)m3;
01107 { int ret = r_mark_lAr();
01108 if (ret == 0) goto lab4;
01109 if (ret < 0) return ret;
01110 }
01111 bra = c;
01112 if (slice_del() == -1) return -1;
01113 { int m4 = l - c; (void)m4;
01114 { int ret = r_stem_suffix_chain_before_ki();
01115 if (ret == 0) { c = l - m4; goto lab5; }
01116 if (ret < 0) return ret;
01117 }
01118 lab5:
01119 ;
01120 }
01121 goto lab3;
01122 lab4:
01123 c = l - m3;
01124 { int ret = r_mark_possessives();
01125 if (ret == 0) { c = l - m2; goto lab2; }
01126 if (ret < 0) return ret;
01127 }
01128 bra = c;
01129 if (slice_del() == -1) return -1;
01130 { int m5 = l - c; (void)m5;
01131 ket = c;
01132 { int ret = r_mark_lAr();
01133 if (ret == 0) { c = l - m5; goto lab6; }
01134 if (ret < 0) return ret;
01135 }
01136 bra = c;
01137 if (slice_del() == -1) return -1;
01138 { int ret = r_stem_suffix_chain_before_ki();
01139 if (ret == 0) { c = l - m5; goto lab6; }
01140 if (ret < 0) return ret;
01141 }
01142 lab6:
01143 ;
01144 }
01145 }
01146 lab3:
01147 lab2:
01148 ;
01149 }
01150 goto lab0;
01151 lab1:
01152 c = l - m1;
01153 { int ret = r_mark_nUn();
01154 if (ret == 0) goto lab7;
01155 if (ret < 0) return ret;
01156 }
01157 bra = c;
01158 if (slice_del() == -1) return -1;
01159 { int m6 = l - c; (void)m6;
01160 ket = c;
01161 { int m7 = l - c; (void)m7;
01162 { int ret = r_mark_lArI();
01163 if (ret == 0) goto lab10;
01164 if (ret < 0) return ret;
01165 }
01166 bra = c;
01167 if (slice_del() == -1) return -1;
01168 goto lab9;
01169 lab10:
01170 c = l - m7;
01171 ket = c;
01172 { int m8 = l - c; (void)m8;
01173 { int ret = r_mark_possessives();
01174 if (ret == 0) goto lab13;
01175 if (ret < 0) return ret;
01176 }
01177 goto lab12;
01178 lab13:
01179 c = l - m8;
01180 { int ret = r_mark_sU();
01181 if (ret == 0) goto lab11;
01182 if (ret < 0) return ret;
01183 }
01184 }
01185 lab12:
01186 bra = c;
01187 if (slice_del() == -1) return -1;
01188 { int m9 = l - c; (void)m9;
01189 ket = c;
01190 { int ret = r_mark_lAr();
01191 if (ret == 0) { c = l - m9; goto lab14; }
01192 if (ret < 0) return ret;
01193 }
01194 bra = c;
01195 if (slice_del() == -1) return -1;
01196 { int ret = r_stem_suffix_chain_before_ki();
01197 if (ret == 0) { c = l - m9; goto lab14; }
01198 if (ret < 0) return ret;
01199 }
01200 lab14:
01201 ;
01202 }
01203 goto lab9;
01204 lab11:
01205 c = l - m7;
01206 { int ret = r_stem_suffix_chain_before_ki();
01207 if (ret == 0) { c = l - m6; goto lab8; }
01208 if (ret < 0) return ret;
01209 }
01210 }
01211 lab9:
01212 lab8:
01213 ;
01214 }
01215 goto lab0;
01216 lab7:
01217 c = l - m1;
01218 { int ret = r_mark_ndA();
01219 if (ret <= 0) return ret;
01220 }
01221 { int m10 = l - c; (void)m10;
01222 { int ret = r_mark_lArI();
01223 if (ret == 0) goto lab16;
01224 if (ret < 0) return ret;
01225 }
01226 bra = c;
01227 if (slice_del() == -1) return -1;
01228 goto lab15;
01229 lab16:
01230 c = l - m10;
01231 { int ret = r_mark_sU();
01232 if (ret == 0) goto lab17;
01233 if (ret < 0) return ret;
01234 }
01235 bra = c;
01236 if (slice_del() == -1) return -1;
01237 { int m11 = l - c; (void)m11;
01238 ket = c;
01239 { int ret = r_mark_lAr();
01240 if (ret == 0) { c = l - m11; goto lab18; }
01241 if (ret < 0) return ret;
01242 }
01243 bra = c;
01244 if (slice_del() == -1) return -1;
01245 { int ret = r_stem_suffix_chain_before_ki();
01246 if (ret == 0) { c = l - m11; goto lab18; }
01247 if (ret < 0) return ret;
01248 }
01249 lab18:
01250 ;
01251 }
01252 goto lab15;
01253 lab17:
01254 c = l - m10;
01255 { int ret = r_stem_suffix_chain_before_ki();
01256 if (ret <= 0) return ret;
01257 }
01258 }
01259 lab15:
01260 ;
01261 }
01262 lab0:
01263 return 1;
01264 }
01265
01266 int Xapian::InternalStemTurkish::r_stem_noun_suffixes() {
01267 { int m1 = l - c; (void)m1;
01268 ket = c;
01269 { int ret = r_mark_lAr();
01270 if (ret == 0) goto lab1;
01271 if (ret < 0) return ret;
01272 }
01273 bra = c;
01274 if (slice_del() == -1) return -1;
01275 { int m2 = l - c; (void)m2;
01276 { int ret = r_stem_suffix_chain_before_ki();
01277 if (ret == 0) { c = l - m2; goto lab2; }
01278 if (ret < 0) return ret;
01279 }
01280 lab2:
01281 ;
01282 }
01283 goto lab0;
01284 lab1:
01285 c = l - m1;
01286 ket = c;
01287 { int ret = r_mark_ncA();
01288 if (ret == 0) goto lab3;
01289 if (ret < 0) return ret;
01290 }
01291 bra = c;
01292 if (slice_del() == -1) return -1;
01293 { int m3 = l - c; (void)m3;
01294 { int m4 = l - c; (void)m4;
01295 ket = c;
01296 { int ret = r_mark_lArI();
01297 if (ret == 0) goto lab6;
01298 if (ret < 0) return ret;
01299 }
01300 bra = c;
01301 if (slice_del() == -1) return -1;
01302 goto lab5;
01303 lab6:
01304 c = l - m4;
01305 ket = c;
01306 { int m5 = l - c; (void)m5;
01307 { int ret = r_mark_possessives();
01308 if (ret == 0) goto lab9;
01309 if (ret < 0) return ret;
01310 }
01311 goto lab8;
01312 lab9:
01313 c = l - m5;
01314 { int ret = r_mark_sU();
01315 if (ret == 0) goto lab7;
01316 if (ret < 0) return ret;
01317 }
01318 }
01319 lab8:
01320 bra = c;
01321 if (slice_del() == -1) return -1;
01322 { int m6 = l - c; (void)m6;
01323 ket = c;
01324 { int ret = r_mark_lAr();
01325 if (ret == 0) { c = l - m6; goto lab10; }
01326 if (ret < 0) return ret;
01327 }
01328 bra = c;
01329 if (slice_del() == -1) return -1;
01330 { int ret = r_stem_suffix_chain_before_ki();
01331 if (ret == 0) { c = l - m6; goto lab10; }
01332 if (ret < 0) return ret;
01333 }
01334 lab10:
01335 ;
01336 }
01337 goto lab5;
01338 lab7:
01339 c = l - m4;
01340 ket = c;
01341 { int ret = r_mark_lAr();
01342 if (ret == 0) { c = l - m3; goto lab4; }
01343 if (ret < 0) return ret;
01344 }
01345 bra = c;
01346 if (slice_del() == -1) return -1;
01347 { int ret = r_stem_suffix_chain_before_ki();
01348 if (ret == 0) { c = l - m3; goto lab4; }
01349 if (ret < 0) return ret;
01350 }
01351 }
01352 lab5:
01353 lab4:
01354 ;
01355 }
01356 goto lab0;
01357 lab3:
01358 c = l - m1;
01359 ket = c;
01360 { int m7 = l - c; (void)m7;
01361 { int ret = r_mark_ndA();
01362 if (ret == 0) goto lab13;
01363 if (ret < 0) return ret;
01364 }
01365 goto lab12;
01366 lab13:
01367 c = l - m7;
01368 { int ret = r_mark_nA();
01369 if (ret == 0) goto lab11;
01370 if (ret < 0) return ret;
01371 }
01372 }
01373 lab12:
01374 { int m8 = l - c; (void)m8;
01375 { int ret = r_mark_lArI();
01376 if (ret == 0) goto lab15;
01377 if (ret < 0) return ret;
01378 }
01379 bra = c;
01380 if (slice_del() == -1) return -1;
01381 goto lab14;
01382 lab15:
01383 c = l - m8;
01384 { int ret = r_mark_sU();
01385 if (ret == 0) goto lab16;
01386 if (ret < 0) return ret;
01387 }
01388 bra = c;
01389 if (slice_del() == -1) return -1;
01390 { int m9 = l - c; (void)m9;
01391 ket = c;
01392 { int ret = r_mark_lAr();
01393 if (ret == 0) { c = l - m9; goto lab17; }
01394 if (ret < 0) return ret;
01395 }
01396 bra = c;
01397 if (slice_del() == -1) return -1;
01398 { int ret = r_stem_suffix_chain_before_ki();
01399 if (ret == 0) { c = l - m9; goto lab17; }
01400 if (ret < 0) return ret;
01401 }
01402 lab17:
01403 ;
01404 }
01405 goto lab14;
01406 lab16:
01407 c = l - m8;
01408 { int ret = r_stem_suffix_chain_before_ki();
01409 if (ret == 0) goto lab11;
01410 if (ret < 0) return ret;
01411 }
01412 }
01413 lab14:
01414 goto lab0;
01415 lab11:
01416 c = l - m1;
01417 ket = c;
01418 { int m10 = l - c; (void)m10;
01419 { int ret = r_mark_ndAn();
01420 if (ret == 0) goto lab20;
01421 if (ret < 0) return ret;
01422 }
01423 goto lab19;
01424 lab20:
01425 c = l - m10;
01426 { int ret = r_mark_nU();
01427 if (ret == 0) goto lab18;
01428 if (ret < 0) return ret;
01429 }
01430 }
01431 lab19:
01432 { int m11 = l - c; (void)m11;
01433 { int ret = r_mark_sU();
01434 if (ret == 0) goto lab22;
01435 if (ret < 0) return ret;
01436 }
01437 bra = c;
01438 if (slice_del() == -1) return -1;
01439 { int m12 = l - c; (void)m12;
01440 ket = c;
01441 { int ret = r_mark_lAr();
01442 if (ret == 0) { c = l - m12; goto lab23; }
01443 if (ret < 0) return ret;
01444 }
01445 bra = c;
01446 if (slice_del() == -1) return -1;
01447 { int ret = r_stem_suffix_chain_before_ki();
01448 if (ret == 0) { c = l - m12; goto lab23; }
01449 if (ret < 0) return ret;
01450 }
01451 lab23:
01452 ;
01453 }
01454 goto lab21;
01455 lab22:
01456 c = l - m11;
01457 { int ret = r_mark_lArI();
01458 if (ret == 0) goto lab18;
01459 if (ret < 0) return ret;
01460 }
01461 }
01462 lab21:
01463 goto lab0;
01464 lab18:
01465 c = l - m1;
01466 ket = c;
01467 { int ret = r_mark_DAn();
01468 if (ret == 0) goto lab24;
01469 if (ret < 0) return ret;
01470 }
01471 bra = c;
01472 if (slice_del() == -1) return -1;
01473 { int m13 = l - c; (void)m13;
01474 ket = c;
01475 { int m14 = l - c; (void)m14;
01476 { int ret = r_mark_possessives();
01477 if (ret == 0) goto lab27;
01478 if (ret < 0) return ret;
01479 }
01480 bra = c;
01481 if (slice_del() == -1) return -1;
01482 { int m15 = l - c; (void)m15;
01483 ket = c;
01484 { int ret = r_mark_lAr();
01485 if (ret == 0) { c = l - m15; goto lab28; }
01486 if (ret < 0) return ret;
01487 }
01488 bra = c;
01489 if (slice_del() == -1) return -1;
01490 { int ret = r_stem_suffix_chain_before_ki();
01491 if (ret == 0) { c = l - m15; goto lab28; }
01492 if (ret < 0) return ret;
01493 }
01494 lab28:
01495 ;
01496 }
01497 goto lab26;
01498 lab27:
01499 c = l - m14;
01500 { int ret = r_mark_lAr();
01501 if (ret == 0) goto lab29;
01502 if (ret < 0) return ret;
01503 }
01504 bra = c;
01505 if (slice_del() == -1) return -1;
01506 { int m16 = l - c; (void)m16;
01507 { int ret = r_stem_suffix_chain_before_ki();
01508 if (ret == 0) { c = l - m16; goto lab30; }
01509 if (ret < 0) return ret;
01510 }
01511 lab30:
01512 ;
01513 }
01514 goto lab26;
01515 lab29:
01516 c = l - m14;
01517 { int ret = r_stem_suffix_chain_before_ki();
01518 if (ret == 0) { c = l - m13; goto lab25; }
01519 if (ret < 0) return ret;
01520 }
01521 }
01522 lab26:
01523 lab25:
01524 ;
01525 }
01526 goto lab0;
01527 lab24:
01528 c = l - m1;
01529 ket = c;
01530 { int m17 = l - c; (void)m17;
01531 { int ret = r_mark_nUn();
01532 if (ret == 0) goto lab33;
01533 if (ret < 0) return ret;
01534 }
01535 goto lab32;
01536 lab33:
01537 c = l - m17;
01538 { int ret = r_mark_ylA();
01539 if (ret == 0) goto lab31;
01540 if (ret < 0) return ret;
01541 }
01542 }
01543 lab32:
01544 bra = c;
01545 if (slice_del() == -1) return -1;
01546 { int m18 = l - c; (void)m18;
01547 { int m19 = l - c; (void)m19;
01548 ket = c;
01549 { int ret = r_mark_lAr();
01550 if (ret == 0) goto lab36;
01551 if (ret < 0) return ret;
01552 }
01553 bra = c;
01554 if (slice_del() == -1) return -1;
01555 { int ret = r_stem_suffix_chain_before_ki();
01556 if (ret == 0) goto lab36;
01557 if (ret < 0) return ret;
01558 }
01559 goto lab35;
01560 lab36:
01561 c = l - m19;
01562 ket = c;
01563 { int m20 = l - c; (void)m20;
01564 { int ret = r_mark_possessives();
01565 if (ret == 0) goto lab39;
01566 if (ret < 0) return ret;
01567 }
01568 goto lab38;
01569 lab39:
01570 c = l - m20;
01571 { int ret = r_mark_sU();
01572 if (ret == 0) goto lab37;
01573 if (ret < 0) return ret;
01574 }
01575 }
01576 lab38:
01577 bra = c;
01578 if (slice_del() == -1) return -1;
01579 { int m21 = l - c; (void)m21;
01580 ket = c;
01581 { int ret = r_mark_lAr();
01582 if (ret == 0) { c = l - m21; goto lab40; }
01583 if (ret < 0) return ret;
01584 }
01585 bra = c;
01586 if (slice_del() == -1) return -1;
01587 { int ret = r_stem_suffix_chain_before_ki();
01588 if (ret == 0) { c = l - m21; goto lab40; }
01589 if (ret < 0) return ret;
01590 }
01591 lab40:
01592 ;
01593 }
01594 goto lab35;
01595 lab37:
01596 c = l - m19;
01597 { int ret = r_stem_suffix_chain_before_ki();
01598 if (ret == 0) { c = l - m18; goto lab34; }
01599 if (ret < 0) return ret;
01600 }
01601 }
01602 lab35:
01603 lab34:
01604 ;
01605 }
01606 goto lab0;
01607 lab31:
01608 c = l - m1;
01609 ket = c;
01610 { int ret = r_mark_lArI();
01611 if (ret == 0) goto lab41;
01612 if (ret < 0) return ret;
01613 }
01614 bra = c;
01615 if (slice_del() == -1) return -1;
01616 goto lab0;
01617 lab41:
01618 c = l - m1;
01619 { int ret = r_stem_suffix_chain_before_ki();
01620 if (ret == 0) goto lab42;
01621 if (ret < 0) return ret;
01622 }
01623 goto lab0;
01624 lab42:
01625 c = l - m1;
01626 ket = c;
01627 { int m22 = l - c; (void)m22;
01628 { int ret = r_mark_DA();
01629 if (ret == 0) goto lab45;
01630 if (ret < 0) return ret;
01631 }
01632 goto lab44;
01633 lab45:
01634 c = l - m22;
01635 { int ret = r_mark_yU();
01636 if (ret == 0) goto lab46;
01637 if (ret < 0) return ret;
01638 }
01639 goto lab44;
01640 lab46:
01641 c = l - m22;
01642 { int ret = r_mark_yA();
01643 if (ret == 0) goto lab43;
01644 if (ret < 0) return ret;
01645 }
01646 }
01647 lab44:
01648 bra = c;
01649 if (slice_del() == -1) return -1;
01650 { int m23 = l - c; (void)m23;
01651 ket = c;
01652 { int m24 = l - c; (void)m24;
01653 { int ret = r_mark_possessives();
01654 if (ret == 0) goto lab49;
01655 if (ret < 0) return ret;
01656 }
01657 bra = c;
01658 if (slice_del() == -1) return -1;
01659 { int m25 = l - c; (void)m25;
01660 ket = c;
01661 { int ret = r_mark_lAr();
01662 if (ret == 0) { c = l - m25; goto lab50; }
01663 if (ret < 0) return ret;
01664 }
01665 lab50:
01666 ;
01667 }
01668 goto lab48;
01669 lab49:
01670 c = l - m24;
01671 { int ret = r_mark_lAr();
01672 if (ret == 0) { c = l - m23; goto lab47; }
01673 if (ret < 0) return ret;
01674 }
01675 }
01676 lab48:
01677 bra = c;
01678 if (slice_del() == -1) return -1;
01679 ket = c;
01680 { int ret = r_stem_suffix_chain_before_ki();
01681 if (ret == 0) { c = l - m23; goto lab47; }
01682 if (ret < 0) return ret;
01683 }
01684 lab47:
01685 ;
01686 }
01687 goto lab0;
01688 lab43:
01689 c = l - m1;
01690 ket = c;
01691 { int m26 = l - c; (void)m26;
01692 { int ret = r_mark_possessives();
01693 if (ret == 0) goto lab52;
01694 if (ret < 0) return ret;
01695 }
01696 goto lab51;
01697 lab52:
01698 c = l - m26;
01699 { int ret = r_mark_sU();
01700 if (ret <= 0) return ret;
01701 }
01702 }
01703 lab51:
01704 bra = c;
01705 if (slice_del() == -1) return -1;
01706 { int m27 = l - c; (void)m27;
01707 ket = c;
01708 { int ret = r_mark_lAr();
01709 if (ret == 0) { c = l - m27; goto lab53; }
01710 if (ret < 0) return ret;
01711 }
01712 bra = c;
01713 if (slice_del() == -1) return -1;
01714 { int ret = r_stem_suffix_chain_before_ki();
01715 if (ret == 0) { c = l - m27; goto lab53; }
01716 if (ret < 0) return ret;
01717 }
01718 lab53:
01719 ;
01720 }
01721 }
01722 lab0:
01723 return 1;
01724 }
01725
01726 int Xapian::InternalStemTurkish::r_post_process_last_consonants() {
01727 int among_var;
01728 ket = c;
01729 among_var = find_among_b(a_23, 4, 0, 0);
01730 if (!(among_var)) return 0;
01731 bra = c;
01732 switch(among_var) {
01733 case 0: return 0;
01734 case 1:
01735 { int ret = slice_from_s(1, s_5);
01736 if (ret < 0) return ret;
01737 }
01738 break;
01739 case 2:
01740 { int ret = slice_from_s(2, s_6);
01741 if (ret < 0) return ret;
01742 }
01743 break;
01744 case 3:
01745 { int ret = slice_from_s(1, s_7);
01746 if (ret < 0) return ret;
01747 }
01748 break;
01749 case 4:
01750 { int ret = slice_from_s(1, s_8);
01751 if (ret < 0) return ret;
01752 }
01753 break;
01754 }
01755 return 1;
01756 }
01757
01758 int Xapian::InternalStemTurkish::r_append_U_to_stems_ending_with_d_or_g() {
01759 { int m_test1 = l - c;
01760 { int m2 = l - c; (void)m2;
01761 if (c <= lb || p[c - 1] != 'd') goto lab1;
01762 c--;
01763 goto lab0;
01764 lab1:
01765 c = l - m2;
01766 if (c <= lb || p[c - 1] != 'g') return 0;
01767 c--;
01768 }
01769 lab0:
01770 c = l - m_test1;
01771 }
01772 { int m3 = l - c; (void)m3;
01773 { int m_test4 = l - c;
01774 if (out_grouping_b_U(g_vowel, 97, 305, 1) < 0) goto lab3;
01775 { int m5 = l - c; (void)m5;
01776 if (c <= lb || p[c - 1] != 'a') goto lab5;
01777 c--;
01778 goto lab4;
01779 lab5:
01780 c = l - m5;
01781 if (!(eq_s_b(2, s_9))) goto lab3;
01782 }
01783 lab4:
01784 c = l - m_test4;
01785 }
01786 { int saved_c = c;
01787 insert_s(c, c, 2, s_10);
01788 c = saved_c;
01789 }
01790 goto lab2;
01791 lab3:
01792 c = l - m3;
01793 { int m_test6 = l - c;
01794 if (out_grouping_b_U(g_vowel, 97, 305, 1) < 0) goto lab6;
01795 { int m7 = l - c; (void)m7;
01796 if (c <= lb || p[c - 1] != 'e') goto lab8;
01797 c--;
01798 goto lab7;
01799 lab8:
01800 c = l - m7;
01801 if (c <= lb || p[c - 1] != 'i') goto lab6;
01802 c--;
01803 }
01804 lab7:
01805 c = l - m_test6;
01806 }
01807 { int saved_c = c;
01808 insert_s(c, c, 1, s_11);
01809 c = saved_c;
01810 }
01811 goto lab2;
01812 lab6:
01813 c = l - m3;
01814 { int m_test8 = l - c;
01815 if (out_grouping_b_U(g_vowel, 97, 305, 1) < 0) goto lab9;
01816 { int m9 = l - c; (void)m9;
01817 if (c <= lb || p[c - 1] != 'o') goto lab11;
01818 c--;
01819 goto lab10;
01820 lab11:
01821 c = l - m9;
01822 if (c <= lb || p[c - 1] != 'u') goto lab9;
01823 c--;
01824 }
01825 lab10:
01826 c = l - m_test8;
01827 }
01828 { int saved_c = c;
01829 insert_s(c, c, 1, s_12);
01830 c = saved_c;
01831 }
01832 goto lab2;
01833 lab9:
01834 c = l - m3;
01835 { int m_test10 = l - c;
01836 if (out_grouping_b_U(g_vowel, 97, 305, 1) < 0) return 0;
01837 { int m11 = l - c; (void)m11;
01838 if (!(eq_s_b(2, s_13))) goto lab13;
01839 goto lab12;
01840 lab13:
01841 c = l - m11;
01842 if (!(eq_s_b(2, s_14))) return 0;
01843 }
01844 lab12:
01845 c = l - m_test10;
01846 }
01847 { int saved_c = c;
01848 insert_s(c, c, 2, s_15);
01849 c = saved_c;
01850 }
01851 }
01852 lab2:
01853 return 1;
01854 }
01855
01856 int Xapian::InternalStemTurkish::r_more_than_one_syllable_word() {
01857 { int c_test1 = c;
01858 { int i = 2;
01859 while(1) {
01860 int c2 = c;
01861 { int ret = out_grouping_U(g_vowel, 97, 305, 1);
01862 if (ret < 0) goto lab0;
01863 c += ret;
01864 }
01865 i--;
01866 continue;
01867 lab0:
01868 c = c2;
01869 break;
01870 }
01871 if (i > 0) return 0;
01872 }
01873 c = c_test1;
01874 }
01875 return 1;
01876 }
01877
01878 int Xapian::InternalStemTurkish::r_is_reserved_word() {
01879 { int c1 = c;
01880 { int c_test2 = c;
01881 while(1) {
01882 if (!(eq_s(2, s_16))) goto lab2;
01883 break;
01884 lab2:
01885 { int ret = skip_utf8(p, c, 0, l, 1);
01886 if (ret < 0) goto lab1;
01887 c = ret;
01888 }
01889 }
01890 I_strlen = 2;
01891 if (!(I_strlen == l)) goto lab1;
01892 c = c_test2;
01893 }
01894 goto lab0;
01895 lab1:
01896 c = c1;
01897 { int c_test3 = c;
01898 while(1) {
01899 if (!(eq_s(5, s_17))) goto lab3;
01900 break;
01901 lab3:
01902 { int ret = skip_utf8(p, c, 0, l, 1);
01903 if (ret < 0) return 0;
01904 c = ret;
01905 }
01906 }
01907 I_strlen = 5;
01908 if (!(I_strlen == l)) return 0;
01909 c = c_test3;
01910 }
01911 }
01912 lab0:
01913 return 1;
01914 }
01915
01916 int Xapian::InternalStemTurkish::r_postlude() {
01917 { int c1 = c;
01918 { int ret = r_is_reserved_word();
01919 if (ret == 0) goto lab0;
01920 if (ret < 0) return ret;
01921 }
01922 return 0;
01923 lab0:
01924 c = c1;
01925 }
01926 lb = c; c = l;
01927
01928 { int m2 = l - c; (void)m2;
01929 { int ret = r_append_U_to_stems_ending_with_d_or_g();
01930 if (ret == 0) goto lab1;
01931 if (ret < 0) return ret;
01932 }
01933 lab1:
01934 c = l - m2;
01935 }
01936 { int m3 = l - c; (void)m3;
01937 { int ret = r_post_process_last_consonants();
01938 if (ret == 0) goto lab2;
01939 if (ret < 0) return ret;
01940 }
01941 lab2:
01942 c = l - m3;
01943 }
01944 c = lb;
01945 return 1;
01946 }
01947
01948 int Xapian::InternalStemTurkish::stem() {
01949 { int ret = r_more_than_one_syllable_word();
01950 if (ret <= 0) return ret;
01951 }
01952 lb = c; c = l;
01953
01954 { int m1 = l - c; (void)m1;
01955 { int ret = r_stem_nominal_verb_suffixes();
01956 if (ret == 0) goto lab0;
01957 if (ret < 0) return ret;
01958 }
01959 lab0:
01960 c = l - m1;
01961 }
01962 if (!(B_continue_stemming_noun_suffixes)) return 0;
01963 { int m2 = l - c; (void)m2;
01964 { int ret = r_stem_noun_suffixes();
01965 if (ret == 0) goto lab1;
01966 if (ret < 0) return ret;
01967 }
01968 lab1:
01969 c = l - m2;
01970 }
01971 c = lb;
01972 { int ret = r_postlude();
01973 if (ret <= 0) return ret;
01974 }
01975 return 1;
01976 }
01977
01978 Xapian::InternalStemTurkish::InternalStemTurkish()
01979 : B_continue_stemming_noun_suffixes(0), I_strlen(0)
01980 {
01981 }
01982
01983 Xapian::InternalStemTurkish::~InternalStemTurkish()
01984 {
01985 }
01986
01987 const char *
01988 Xapian::InternalStemTurkish::get_description() const
01989 {
01990 return "turkish";
01991 }