4 #define YY_INT_ALIGNED short int
6 /* A lexical scanner generated by flex */
9 #define YY_FLEX_MAJOR_VERSION 2
10 #define YY_FLEX_MINOR_VERSION 5
11 #define YY_FLEX_SUBMINOR_VERSION 34
12 #if YY_FLEX_SUBMINOR_VERSION > 0
16 /* First, we deal with platform-specific or compiler-specific issues. */
18 /* begin standard C headers. */
24 /* end standard C headers. */
26 /* flex integer type definitions */
31 /* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
33 #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
35 /* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
36 * if you want the limit (max/min) macros for int types.
38 #ifndef __STDC_LIMIT_MACROS
39 #define __STDC_LIMIT_MACROS 1
43 typedef int8_t flex_int8_t;
44 typedef uint8_t flex_uint8_t;
45 typedef int16_t flex_int16_t;
46 typedef uint16_t flex_uint16_t;
47 typedef int32_t flex_int32_t;
48 typedef uint32_t flex_uint32_t;
50 typedef signed char flex_int8_t;
51 typedef short int flex_int16_t;
52 typedef int flex_int32_t;
53 typedef unsigned char flex_uint8_t;
54 typedef unsigned short int flex_uint16_t;
55 typedef unsigned int flex_uint32_t;
58 /* Limits of integral types. */
60 #define INT8_MIN (-128)
63 #define INT16_MIN (-32767-1)
66 #define INT32_MIN (-2147483647-1)
69 #define INT8_MAX (127)
72 #define INT16_MAX (32767)
75 #define INT32_MAX (2147483647)
78 #define UINT8_MAX (255U)
81 #define UINT16_MAX (65535U)
84 #define UINT32_MAX (4294967295U)
87 #endif /* ! FLEXINT_H */
91 /* The "const" storage-class-modifier is valid. */
94 #else /* ! __cplusplus */
96 /* C99 requires __STDC__ to be defined as 1. */
97 #if defined (__STDC__)
101 #endif /* defined (__STDC__) */
102 #endif /* ! __cplusplus */
105 #define yyconst const
110 /* Returned upon end-of-file. */
113 /* Promotes a possibly negative, possibly signed char to an unsigned
114 * integer for use as an array index. If the signed char is negative,
115 * we want to instead treat it as an 8-bit unsigned char, hence the
118 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
120 /* Enter a start condition. This macro really ought to take a parameter,
121 * but we do it the disgusting crufty way forced on us by the ()-less
122 * definition of BEGIN.
124 #define BEGIN (yy_start) = 1 + 2 *
126 /* Translate the current start state into a value that can be later handed
127 * to BEGIN to return to the state. The YYSTATE alias is for lex
130 #define YY_START (((yy_start) - 1) / 2)
131 #define YYSTATE YY_START
133 /* Action number for EOF rule of a given start state. */
134 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
136 /* Special action meaning "start processing a new file". */
137 #define YY_NEW_FILE yyrestart(yyin )
139 #define YY_END_OF_BUFFER_CHAR 0
141 /* Size of default input buffer. */
143 #define YY_BUF_SIZE 16384
146 /* The state buf must be large enough to hold one state per character in the main buffer.
148 #define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
150 #ifndef YY_TYPEDEF_YY_BUFFER_STATE
151 #define YY_TYPEDEF_YY_BUFFER_STATE
152 typedef struct yy_buffer_state *YY_BUFFER_STATE;
157 extern FILE *yyin, *yyout;
159 #define EOB_ACT_CONTINUE_SCAN 0
160 #define EOB_ACT_END_OF_FILE 1
161 #define EOB_ACT_LAST_MATCH 2
163 #define YY_LESS_LINENO(n)
165 /* Return all but the first "n" matched characters back to the input stream. */
169 /* Undo effects of setting up yytext. */ \
170 int yyless_macro_arg = (n); \
171 YY_LESS_LINENO(yyless_macro_arg);\
172 *yy_cp = (yy_hold_char); \
173 YY_RESTORE_YY_MORE_OFFSET \
174 (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
175 YY_DO_BEFORE_ACTION; /* set up yytext again */ \
179 #define unput(c) yyunput( c, (yytext_ptr) )
181 /* The following is because we cannot portably get our hands on size_t
182 * (without autoconf's help, which isn't available because we want
183 * flex-generated scanners to compile on their own).
184 * Given that the standard has decreed that size_t exists since 1989,
185 * I guess we can afford to depend on it. Manoj.
188 #ifndef YY_TYPEDEF_YY_SIZE_T
189 #define YY_TYPEDEF_YY_SIZE_T
190 typedef size_t yy_size_t;
193 #ifndef YY_STRUCT_YY_BUFFER_STATE
194 #define YY_STRUCT_YY_BUFFER_STATE
195 struct yy_buffer_state
199 char *yy_ch_buf; /* input buffer */
200 char *yy_buf_pos; /* current position in input buffer */
202 /* Size of input buffer in bytes, not including room for EOB
205 yy_size_t yy_buf_size;
207 /* Number of characters read into yy_ch_buf, not including EOB
212 /* Whether we "own" the buffer - i.e., we know we created it,
213 * and can realloc() it to grow it, and should free() it to
216 int yy_is_our_buffer;
218 /* Whether this is an "interactive" input source; if so, and
219 * if we're using stdio for input, then we want to use getc()
220 * instead of fread(), to make sure we stop fetching input after
223 int yy_is_interactive;
225 /* Whether we're considered to be at the beginning of a line.
226 * If so, '^' rules will be active on the next match, otherwise
231 int yy_bs_lineno; /**< The line count. */
232 int yy_bs_column; /**< The column count. */
234 /* Whether to try to fill the input buffer when we reach the
239 int yy_buffer_status;
241 #define YY_BUFFER_NEW 0
242 #define YY_BUFFER_NORMAL 1
243 /* When an EOF's been seen but there's still some text to process
244 * then we mark the buffer as YY_EOF_PENDING, to indicate that we
245 * shouldn't try reading from the input source any more. We might
246 * still have a bunch of tokens to match, though, because of
247 * possible backing-up.
249 * When we actually see the EOF, we change the status to "new"
250 * (via yyrestart()), so that the user can continue scanning by
251 * just pointing yyin at a new input file.
253 #define YY_BUFFER_EOF_PENDING 2
256 #endif /* !YY_STRUCT_YY_BUFFER_STATE */
258 /* Stack of input buffers. */
259 static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */
260 static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */
261 static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */
263 /* We provide macros for accessing buffer states in case in the
264 * future we want to put the buffer states in a more general
267 * Returns the top of the stack, or NULL.
269 #define YY_CURRENT_BUFFER ( (yy_buffer_stack) \
270 ? (yy_buffer_stack)[(yy_buffer_stack_top)] \
273 /* Same as previous macro, but useful when we know that the buffer stack is not
274 * NULL or when we need an lvalue. For internal use only.
276 #define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)]
278 /* yy_hold_char holds the character lost when yytext is formed. */
279 static char yy_hold_char;
280 static int yy_n_chars; /* number of characters read into yy_ch_buf */
283 /* Points to current character in buffer. */
284 static char *yy_c_buf_p = (char *) 0;
285 static int yy_init = 0; /* whether we need to initialize */
286 static int yy_start = 0; /* start state number */
288 /* Flag which is used to allow yywrap()'s to do buffer switches
289 * instead of setting up a fresh yyin. A bit of a hack ...
291 static int yy_did_buffer_switch_on_eof;
293 void yyrestart (FILE *input_file );
294 void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer );
295 YY_BUFFER_STATE yy_create_buffer (FILE *file,int size );
296 void yy_delete_buffer (YY_BUFFER_STATE b );
297 void yy_flush_buffer (YY_BUFFER_STATE b );
298 void yypush_buffer_state (YY_BUFFER_STATE new_buffer );
299 void yypop_buffer_state (void );
301 static void yyensure_buffer_stack (void );
302 static void yy_load_buffer_state (void );
303 static void yy_init_buffer (YY_BUFFER_STATE b,FILE *file );
305 #define YY_FLUSH_BUFFER yy_flush_buffer(YY_CURRENT_BUFFER )
307 YY_BUFFER_STATE yy_scan_buffer (char *base,yy_size_t size );
308 YY_BUFFER_STATE yy_scan_string (yyconst char *yy_str );
309 YY_BUFFER_STATE yy_scan_bytes (yyconst char *bytes,int len );
311 void *yyalloc (yy_size_t );
312 void *yyrealloc (void *,yy_size_t );
313 void yyfree (void * );
315 #define yy_new_buffer yy_create_buffer
317 #define yy_set_interactive(is_interactive) \
319 if ( ! YY_CURRENT_BUFFER ){ \
320 yyensure_buffer_stack (); \
321 YY_CURRENT_BUFFER_LVALUE = \
322 yy_create_buffer(yyin,YY_BUF_SIZE ); \
324 YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
327 #define yy_set_bol(at_bol) \
329 if ( ! YY_CURRENT_BUFFER ){\
330 yyensure_buffer_stack (); \
331 YY_CURRENT_BUFFER_LVALUE = \
332 yy_create_buffer(yyin,YY_BUF_SIZE ); \
334 YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
337 #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
339 /* Begin user sect3 */
341 typedef unsigned char YY_CHAR;
343 FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
345 typedef int yy_state_type;
352 #define yytext_ptr yytext
354 static yy_state_type yy_get_previous_state (void );
355 static yy_state_type yy_try_NUL_trans (yy_state_type current_state );
356 static int yy_get_next_buffer (void );
357 static void yy_fatal_error (yyconst char msg[] );
359 /* Done after the current pattern has been matched and before the
360 * corresponding action - sets up yytext.
362 #define YY_DO_BEFORE_ACTION \
363 (yytext_ptr) = yy_bp; \
364 yyleng = (size_t) (yy_cp - yy_bp); \
365 (yy_hold_char) = *yy_cp; \
367 (yy_c_buf_p) = yy_cp;
369 #define YY_NUM_RULES 43
370 #define YY_END_OF_BUFFER 44
371 /* This struct is not used in this scanner,
372 but its presence is necessary. */
375 flex_int32_t yy_verify;
378 static yyconst flex_int16_t yy_acclist[629] =
380 44, 42, 43, 42, 43, 42, 43, 41, 42, 43,
381 42, 43, 26, 42, 43, 42, 43, 41, 42, 43,
382 41, 42, 43,16411, 41, 42, 43,16411, 42, 43,
383 41, 42, 43, 41, 42, 43, 41, 42, 43, 41,
384 42, 43, 41, 42, 43, 41, 42, 43, 41, 42,
385 43, 41, 42, 43, 41, 42, 43, 41, 42, 43,
386 41, 42, 43, 42, 43, 41, 42, 43, 41, 42,
387 43, 41, 42, 43, 41, 42, 43, 41, 42, 43,
388 41, 42, 43, 41, 42, 43, 41, 42, 43, 41,
389 42, 43, 41, 42, 43, 41, 42, 43, 41, 42,
391 43, 41, 42, 43, 41, 42, 43, 41, 42, 43,
392 41, 42, 43, 41, 42, 43, 41, 42, 43, 42,
393 43, 42, 43, 41, 42, 43, 41, 42, 43, 41,
394 42, 43,16411, 41, 42, 43,16411, 42, 43, 41,
395 42, 43, 41, 42, 43, 41, 42, 43, 41, 42,
396 43, 41, 42, 43, 41, 42, 43, 41, 42, 43,
397 41, 42, 43, 41, 42, 43, 41, 42, 43, 41,
398 42, 43, 41, 42, 43, 41, 42, 43, 41, 42,
399 43, 41, 42, 43, 41, 42, 43, 41, 42, 43,
400 41, 42, 43, 41, 42, 43, 41, 42, 43, 41,
402 42, 43, 41, 42, 43, 41, 42, 43, 41, 42,
403 43, 41, 42, 43, 41, 42, 43, 41, 42, 43,
404 41, 42, 43, 41, 42, 43, 42, 43, 34, 41,
405 18, 41, 10, 41, 41, 41,16411, 8219, 41, 36,
406 41, 41, 41, 41, 41, 41, 41, 41, 41, 41,
407 41, 10, 41, 41, 41, 41, 37, 41, 4, 41,
408 41, 5, 41, 41, 41, 41, 41, 41, 10, 41,
409 41, 41, 35, 41, 41, 10, 41, 41, 41,16411,
410 8219, 41, 41, 41, 41, 41, 41, 41, 41, 41,
411 41, 41, 41, 10, 41, 41, 41, 41, 41, 4,
413 41, 41, 5, 41, 41, 41, 41, 41, 41, 10,
414 41, 41, 41, 16, 10, 41, 24, 41, 24, 9,
415 41, 8219, 23, 41, 23, 25, 41, 41, 41, 41,
416 41, 7, 41, 41, 41, 41, 41, 41, 10, 41,
417 41, 41, 41, 5, 41, 41, 4, 4, 41, 4,
418 41, 4, 41, 5, 6, 41, 5, 5, 41, 41,
419 41, 41, 10, 41, 41, 35, 40, 10, 41, 24,
420 41, 9, 41, 23, 41, 36, 41, 41, 41, 41,
421 41, 7, 41, 41, 41, 41, 41, 41, 10, 41,
422 41, 41, 41, 5, 41, 41, 4, 41, 4, 41,
424 4, 41, 6, 41, 5, 41, 41, 41, 41, 10,
425 41, 41, 39, 39, 39, 38, 26, 26, 7, 41,
426 11, 7, 41, 3, 41, 8, 41, 7, 41, 7,
427 41, 41, 41, 20, 41, 41, 17, 41, 41, 41,
428 41, 41, 37, 4, 41, 4, 2, 41, 6, 5,
429 6, 6, 41, 41, 5, 5, 41, 41, 26, 40,
430 41, 7, 41, 3, 41, 8, 41, 41, 41, 41,
431 41, 20, 41, 41, 17, 41, 41, 41, 41, 41,
432 41, 2, 41, 6, 41, 41, 5, 41, 41, 39,
433 8, 3, 8, 1, 41, 21, 41, 41, 20, 41,
435 41, 41, 41, 41, 41, 31, 37, 2, 2, 2,
436 41, 6, 6, 6, 41, 40, 1, 41, 41, 41,
437 20, 41, 41, 41, 41, 41, 41, 2, 41, 6,
438 41, 28, 39, 1, 24, 24, 23, 23, 25, 25,
439 1, 1, 41, 22, 21, 41, 41, 41, 12, 41,
440 41, 29, 37, 31, 2, 2, 28, 35, 40, 40,
441 1, 41, 41, 41, 41, 12, 41, 41, 19, 1,
442 25, 1, 22, 20, 41, 41, 41, 12, 41, 41,
443 41, 41, 41, 12, 41, 41, 13, 41, 41, 41,
444 41, 13, 41, 41, 15, 41, 41, 41, 15, 41,
446 41, 41, 40, 41, 41, 41, 41, 40, 40, 41,
447 41, 32, 41, 40, 40, 32, 41, 14, 32, 33,
448 33, 36, 40, 40, 32, 40, 35, 30
451 static yyconst flex_int16_t yy_accept[707] =
453 1, 1, 1, 2, 4, 6, 8, 11, 13, 16,
454 18, 21, 25, 29, 31, 34, 37, 40, 43, 46,
455 49, 52, 55, 58, 61, 64, 66, 69, 72, 75,
456 78, 81, 84, 87, 90, 93, 96, 99, 102, 105,
457 108, 111, 114, 117, 120, 122, 124, 127, 130, 134,
458 138, 140, 143, 146, 149, 152, 155, 158, 161, 164,
459 167, 170, 173, 176, 179, 182, 185, 188, 191, 194,
460 197, 200, 203, 206, 209, 212, 215, 218, 221, 224,
461 227, 229, 229, 230, 231, 231, 231, 231, 231, 232,
462 232, 232, 232, 233, 233, 235, 235, 235, 235, 236,
464 236, 236, 238, 238, 240, 240, 241, 241, 242, 242,
465 243, 243, 244, 244, 245, 246, 247, 248, 249, 250,
466 251, 252, 254, 255, 256, 257, 257, 257, 257, 257,
467 258, 259, 261, 261, 262, 264, 265, 266, 267, 268,
468 269, 271, 272, 273, 273, 273, 273, 274, 274, 275,
469 275, 276, 278, 278, 279, 281, 281, 283, 283, 284,
470 285, 285, 286, 287, 288, 289, 290, 291, 292, 293,
471 294, 296, 297, 298, 299, 300, 302, 302, 303, 305,
472 306, 307, 308, 309, 310, 312, 313, 314, 314, 314,
473 314, 314, 314, 314, 314, 314, 314, 314, 314, 315,
475 315, 315, 315, 315, 315, 317, 319, 320, 322, 323,
476 323, 323, 323, 325, 326, 327, 327, 328, 328, 329,
477 329, 330, 331, 331, 332, 334, 334, 334, 334, 334,
478 334, 334, 334, 335, 336, 337, 338, 339, 341, 342,
479 343, 344, 344, 344, 344, 344, 346, 346, 347, 347,
480 348, 350, 352, 354, 355, 355, 357, 358, 360, 361,
481 362, 363, 365, 366, 367, 367, 367, 367, 367, 368,
482 370, 372, 374, 376, 376, 377, 377, 378, 379, 379,
483 380, 381, 382, 384, 384, 385, 386, 387, 388, 389,
484 391, 392, 393, 394, 396, 397, 397, 399, 401, 403,
486 405, 407, 408, 409, 410, 412, 413, 413, 413, 414,
487 415, 415, 415, 416, 416, 416, 417, 417, 417, 418,
488 418, 419, 419, 420, 420, 420, 420, 421, 421, 421,
489 421, 421, 421, 421, 421, 422, 424, 424, 424, 426,
490 428, 429, 430, 430, 431, 432, 432, 432, 432, 432,
491 432, 432, 433, 434, 436, 436, 437, 439, 440, 441,
492 442, 443, 443, 443, 443, 443, 444, 445, 446, 446,
493 447, 449, 450, 451, 451, 451, 452, 454, 455, 456,
494 456, 458, 459, 459, 460, 460, 460, 460, 460, 461,
495 461, 462, 462, 462, 464, 466, 468, 469, 469, 470,
497 471, 472, 474, 475, 477, 478, 479, 480, 481, 482,
498 484, 486, 487, 489, 490, 490, 490, 490, 490, 491,
499 491, 491, 491, 491, 492, 492, 492, 492, 492, 492,
500 492, 492, 492, 492, 493, 494, 496, 496, 496, 496,
501 496, 496, 497, 498, 499, 499, 501, 501, 502, 503,
502 504, 505, 506, 506, 506, 508, 508, 508, 509, 509,
503 510, 512, 513, 513, 514, 514, 516, 516, 516, 516,
504 516, 516, 516, 516, 517, 517, 517, 519, 520, 521,
505 523, 524, 525, 526, 527, 528, 530, 532, 532, 532,
506 532, 532, 532, 532, 534, 534, 535, 535, 536, 536,
508 537, 537, 538, 538, 539, 539, 540, 540, 541, 541,
509 541, 541, 542, 544, 544, 544, 545, 545, 545, 546,
510 547, 547, 547, 547, 547, 547, 548, 549, 551, 552,
511 554, 554, 555, 556, 557, 557, 557, 559, 559, 559,
512 560, 561, 561, 561, 563, 564, 565, 566, 568, 569,
513 569, 570, 570, 570, 570, 570, 571, 571, 572, 573,
514 573, 573, 574, 574, 574, 575, 575, 575, 575, 575,
515 576, 577, 578, 580, 581, 581, 581, 581, 581, 581,
516 582, 583, 584, 586, 587, 587, 587, 587, 587, 587,
517 587, 588, 588, 588, 588, 588, 589, 590, 590, 590,
519 590, 590, 591, 592, 592, 592, 592, 592, 593, 593,
520 593, 593, 594, 595, 597, 597, 597, 597, 597, 598,
521 598, 599, 601, 601, 601, 601, 601, 602, 603, 603,
522 603, 603, 603, 604, 605, 606, 606, 606, 606, 606,
523 606, 607, 608, 608, 608, 608, 608, 609, 610, 611,
524 612, 612, 612, 612, 612, 612, 614, 614, 614, 614,
525 614, 615, 616, 618, 618, 618, 619, 619, 620, 620,
526 621, 621, 621, 623, 623, 624, 625, 625, 625, 625,
527 625, 627, 627, 627, 627, 627, 627, 627, 627, 627,
528 627, 627, 627, 627, 627, 627, 627, 627, 627, 627,
530 627, 627, 627, 628, 629, 629
533 static yyconst flex_int32_t yy_ec[256] =
535 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
536 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
537 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
538 1, 4, 1, 5, 6, 7, 8, 1, 9, 10,
539 11, 12, 13, 1, 14, 15, 16, 17, 18, 19,
540 20, 20, 20, 20, 20, 20, 20, 21, 22, 1,
541 23, 1, 1, 24, 25, 26, 27, 28, 29, 30,
542 31, 32, 33, 33, 34, 35, 36, 37, 38, 39,
543 39, 40, 41, 42, 43, 42, 44, 45, 42, 42,
544 46, 1, 47, 1, 48, 1, 49, 50, 51, 52,
546 53, 54, 55, 56, 57, 58, 59, 60, 61, 62,
547 63, 64, 65, 66, 67, 68, 69, 70, 71, 72,
548 73, 70, 74, 1, 75, 1, 1, 1, 1, 1,
549 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
550 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
551 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
552 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
553 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
554 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
555 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
557 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
558 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
559 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
560 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
561 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
565 static yyconst flex_int32_t yy_meta[76] =
567 1, 2, 3, 2, 1, 1, 1, 1, 4, 5,
568 6, 1, 7, 8, 1, 1, 9, 9, 9, 9,
569 10, 1, 11, 1, 12, 12, 12, 12, 12, 12,
570 12, 12, 13, 12, 13, 13, 12, 12, 12, 12,
571 13, 13, 13, 12, 14, 1, 1, 1, 15, 15,
572 15, 15, 16, 15, 15, 15, 15, 15, 15, 15,
573 17, 18, 18, 18, 18, 18, 17, 17, 17, 17,
577 static yyconst flex_int16_t yy_base[787] =
579 0, 75, 3653, 4176, 126, 135, 0, 146, 3569, 144,
580 155, 175, 166, 3569, 237, 163, 3512, 3501, 123, 249,
581 245, 261, 253, 283, 300, 356, 418, 256, 259, 272,
582 277, 286, 336, 293, 227, 295, 347, 334, 149, 150,
583 387, 322, 376, 404, 406, 3560, 401, 437, 489, 441,
584 218, 554, 329, 3490, 3461, 275, 400, 395, 562, 482,
585 468, 573, 616, 429, 391, 535, 566, 589, 591, 599,
586 601, 628, 631, 633, 685, 686, 687, 691, 693, 709,
587 721, 3309, 477, 0, 3350, 303, 735, 176, 4176, 3346,
588 783, 167, 364, 3340, 3300, 3294, 462, 755, 3293, 480,
590 180, 715, 3292, 0, 3305, 4176, 0, 807, 0, 859,
591 0, 919, 964, 3172, 3167, 3167, 3172, 3145, 577, 3144,
592 3156, 3137, 3002, 3016, 3007, 3016, 1035, 465, 1110, 4176,
593 1137, 1189, 0, 1214, 1266, 604, 729, 755, 2916, 2918,
594 2917, 2911, 2920, 352, 2901, 774, 2971, 2970, 643, 2969,
595 789, 711, 565, 796, 1338, 370, 695, 561, 1403, 1455,
596 2968, 1515, 2922, 2883, 802, 742, 758, 763, 2854, 2880,
597 809, 2850, 803, 2859, 1539, 1591, 2850, 1616, 1668, 925,
598 932, 1002, 716, 926, 939, 805, 946, 806, 2787, 652,
599 712, 716, 732, 776, 1043, 995, 2841, 2761, 4176, 945,
601 1051, 2818, 2817, 2814, 2803, 2812, 2808, 0, 4176, 2807,
602 2806, 2805, 2804, 2803, 1063, 965, 978, 1009, 1717, 1753,
603 1014, 1056, 1068, 1072, 1800, 1128, 2749, 2742, 2741, 2754,
604 2749, 568, 1073, 1110, 2730, 818, 2747, 2785, 2741, 2737,
605 1133, 613, 1133, 300, 1872, 1938, 0, 1943, 0, 2786,
606 2784, 2782, 1128, 1149, 1412, 1994, 2782, 2780, 751, 2739,
607 2738, 2774, 2716, 4176, 1527, 836, 2779, 397, 2779, 861,
608 1154, 810, 1156, 785, 2777, 534, 1419, 2039, 2776, 1424,
609 1522, 1523, 2086, 2775, 1744, 1780, 1134, 1811, 1425, 1162,
610 1807, 1153, 1881, 2150, 2155, 2774, 1339, 2766, 1816, 2206,
612 1340, 1404, 1057, 1820, 1406, 1821, 1463, 2723, 4176, 895,
613 946, 951, 976, 999, 1069, 4176, 1566, 2764, 2763, 2698,
614 2697, 1326, 1825, 2753, 2751, 2750, 2750, 385, 2749, 494,
615 2748, 978, 1910, 989, 4176, 2741, 1890, 1430, 0, 2736,
616 2735, 2211, 1864, 4176, 1561, 2690, 2690, 2686, 2674, 2670,
617 2674, 2676, 2675, 270, 823, 851, 0, 2695, 2677, 2678,
618 2677, 1164, 1190, 824, 1559, 2724, 2717, 1737, 1773, 4176,
619 1920, 1898, 2716, 1080, 1900, 1902, 2715, 1118, 4176, 2661,
620 0, 2661, 1939, 2719, 1901, 1912, 2673, 2658, 2717, 758,
621 1886, 767, 1091, 2031, 1269, 2032, 2223, 2713, 2066, 1997,
623 2042, 1923, 2093, 1405, 2040, 2095, 2094, 2099, 2109, 2147,
624 2101, 2275, 1458, 2277, 1938, 2663, 1130, 2704, 1225, 1271,
625 1277, 1302, 1406, 2686, 1848, 2697, 2632, 2695, 2630, 2693,
626 2628, 2684, 1599, 4176, 4176, 2331, 2650, 2646, 1990, 2645,
627 2640, 2629, 2688, 785, 2245, 2687, 1330, 2660, 2631, 2621,
628 2621, 2677, 1371, 1712, 4176, 2673, 2077, 1669, 2036, 2096,
629 2662, 2656, 1779, 4176, 2598, 0, 2646, 2148, 2642, 1803,
630 2642, 2597, 2589, 1499, 1757, 1755, 2368, 2041, 2282, 2283,
631 2279, 2102, 2112, 2284, 2285, 2209, 2096, 2002, 902, 1460,
632 2644, 1627, 1670, 4176, 2302, 2287, 2643, 2640, 2575, 2574,
634 2636, 2629, 2564, 2559, 2615, 2614, 2549, 2548, 2601, 2597,
635 2291, 2292, 2598, 2545, 2550, 2256, 550, 2531, 4176, 2536,
636 2570, 2527, 2506, 2548, 2519, 2526, 2485, 1773, 2501, 4176,
637 2332, 4176, 2538, 4176, 2533, 2313, 2542, 2491, 2475, 2525,
638 1984, 1957, 787, 2316, 2371, 2308, 2317, 2405, 2406, 2341,
639 4176, 2464, 2501, 1673, 2411, 2500, 2506, 2505, 4176, 2446,
640 2450, 4176, 2432, 2473, 2468, 2326, 2383, 2342, 2285, 2307,
641 2279, 2202, 0, 2159, 2415, 2213, 2101, 1888, 1113, 2415,
642 2416, 2429, 2430, 2431, 2439, 2072, 2094, 1876, 2014, 1974,
643 1794, 1962, 1573, 1968, 1940, 2514, 1936, 1891, 1849, 1860,
645 1951, 2589, 2436, 2456, 1801, 1791, 1744, 4176, 1622, 2117,
646 2166, 2664, 2173, 0, 1550, 1541, 1987, 2193, 2739, 2197,
647 2175, 2439, 2459, 1531, 1502, 2392, 1501, 1390, 1363, 1322,
648 765, 2196, 2440, 1318, 1253, 2464, 1211, 1209, 2413, 2430,
649 1150, 1117, 1111, 1085, 2079, 2008, 2443, 2451, 972, 927,
650 2466, 2275, 908, 2446, 2433, 0, 955, 710, 681, 2199,
651 2520, 2502, 0, 2489, 627, 4176, 504, 2432, 453, 4176,
652 372, 418, 4176, 2296, 2537, 2575, 2490, 266, 199, 2159,
653 2552, 2499, 199, 2254, 373, 2150, 2151, 2539, 2540, 2544,
654 2556, 2568, 2570, 2573, 2615, 2618, 2619, 2624, 2638, 2639,
656 2643, 2344, 165, 4176, 4176, 2811, 2830, 2843, 2857, 2876,
657 2895, 2911, 2930, 2949, 2967, 2335, 2366, 2370, 2985, 3004,
658 2450, 3023, 3042, 3058, 3077, 3096, 3115, 3134, 3153, 3172,
659 3191, 3203, 3222, 3241, 3260, 3279, 3287, 2481, 3302, 3318,
660 3337, 3353, 3372, 3391, 3410, 3429, 3448, 3467, 3486, 3505,
661 3524, 3543, 3555, 3574, 3593, 3612, 3631, 3647, 3662, 3678,
662 3697, 3713, 3732, 3751, 3770, 3789, 3808, 3827, 3846, 3865,
663 3884, 3903, 3922, 3941, 3956, 3975, 3994, 4009, 4023, 4042,
664 4061, 4080, 4099, 4118, 4137, 4156
667 static yyconst flex_int16_t yy_def[787] =
669 705, 705, 705, 705, 705, 705, 706, 707, 705, 708,
670 706, 705, 12, 709, 706, 15, 15, 15, 15, 15,
671 15, 15, 15, 15, 15, 710, 15, 27, 27, 27,
672 27, 27, 27, 27, 27, 27, 27, 27, 706, 706,
673 706, 706, 706, 706, 711, 705, 712, 712, 705, 49,
674 709, 712, 52, 52, 52, 52, 52, 52, 52, 52,
675 52, 52, 52, 63, 63, 63, 63, 63, 63, 63,
676 63, 63, 63, 63, 712, 712, 712, 712, 712, 712,
677 711, 705, 705, 706, 713, 714, 713, 705, 705, 705,
678 705, 705, 706, 705, 706, 705, 715, 715, 706, 715,
680 705, 12, 705, 706, 709, 705, 716, 706, 717, 705,
681 718, 706, 705, 112, 112, 706, 706, 706, 112, 112,
682 108, 706, 112, 706, 112, 719, 710, 719, 720, 705,
683 706, 705, 721, 706, 705, 706, 706, 706, 706, 706,
684 706, 706, 706, 711, 722, 711, 705, 723, 724, 705,
685 724, 724, 705, 724, 705, 705, 724, 725, 724, 705,
686 718, 159, 162, 162, 724, 724, 724, 162, 162, 159,
687 724, 162, 724, 162, 159, 705, 721, 159, 705, 724,
688 724, 724, 724, 724, 724, 724, 724, 711, 705, 726,
689 727, 727, 728, 729, 726, 726, 730, 731, 705, 732,
691 732, 705, 705, 705, 706, 706, 705, 706, 705, 705,
692 705, 705, 706, 705, 705, 705, 706, 705, 706, 705,
693 706, 706, 705, 219, 224, 732, 705, 705, 705, 705,
694 705, 705, 706, 706, 706, 706, 706, 706, 706, 706,
695 706, 733, 734, 735, 736, 706, 737, 706, 738, 737,
696 706, 248, 706, 739, 739, 706, 255, 706, 706, 706,
697 706, 706, 706, 705, 711, 705, 740, 705, 741, 742,
698 742, 742, 742, 743, 740, 744, 742, 742, 220, 742,
699 742, 278, 282, 226, 742, 742, 742, 742, 742, 742,
700 742, 742, 742, 742, 282, 738, 742, 295, 742, 294,
702 742, 742, 742, 742, 742, 742, 711, 705, 705, 745,
703 746, 747, 748, 745, 749, 705, 750, 751, 751, 752,
704 752, 705, 753, 705, 705, 705, 706, 705, 705, 705,
705 705, 705, 705, 705, 705, 706, 753, 705, 706, 706,
706 705, 706, 337, 705, 706, 705, 705, 705, 705, 705,
707 705, 706, 706, 706, 705, 706, 706, 706, 706, 706,
708 706, 754, 754, 755, 756, 757, 705, 706, 705, 705,
709 758, 759, 705, 705, 759, 759, 706, 706, 705, 705,
710 706, 706, 711, 705, 705, 705, 705, 705, 760, 705,
711 742, 761, 761, 742, 742, 742, 295, 343, 742, 742,
713 742, 742, 742, 742, 742, 742, 742, 742, 742, 762,
714 742, 742, 742, 742, 711, 705, 747, 763, 764, 748,
715 765, 749, 750, 705, 705, 766, 767, 768, 769, 770,
716 771, 705, 705, 705, 705, 706, 705, 705, 705, 705,
717 705, 705, 706, 706, 705, 706, 705, 706, 706, 706,
718 706, 706, 772, 773, 705, 774, 705, 775, 775, 775,
719 706, 705, 705, 705, 705, 706, 705, 711, 705, 705,
720 705, 705, 705, 776, 761, 761, 742, 742, 742, 742,
721 742, 742, 742, 742, 742, 742, 742, 711, 705, 764,
722 777, 748, 765, 705, 750, 778, 766, 766, 767, 767,
724 768, 768, 769, 769, 770, 770, 771, 771, 705, 705,
725 778, 778, 706, 705, 705, 705, 705, 705, 705, 706,
726 779, 705, 705, 705, 705, 706, 706, 706, 706, 705,
727 705, 705, 705, 705, 705, 711, 705, 705, 705, 776,
728 776, 761, 761, 742, 742, 742, 742, 742, 742, 711,
729 705, 705, 777, 764, 750, 705, 705, 705, 705, 705,
730 705, 705, 705, 779, 779, 705, 705, 705, 705, 706,
731 706, 706, 706, 706, 711, 705, 705, 761, 761, 742,
732 742, 742, 742, 742, 711, 705, 705, 705, 705, 705,
733 705, 705, 705, 705, 705, 780, 706, 705, 705, 761,
735 761, 781, 742, 711, 705, 705, 705, 705, 705, 782,
736 782, 780, 612, 706, 705, 705, 761, 761, 781, 782,
737 619, 742, 711, 705, 705, 782, 612, 612, 705, 705,
738 761, 761, 783, 619, 619, 711, 705, 705, 782, 782,
739 612, 612, 705, 705, 761, 761, 783, 783, 619, 619,
740 711, 705, 705, 782, 782, 612, 784, 705, 785, 761,
741 783, 783, 619, 711, 705, 705, 705, 782, 784, 705,
742 705, 785, 705, 761, 783, 783, 711, 705, 705, 761,
743 783, 711, 705, 761, 711, 786, 786, 786, 786, 786,
744 786, 786, 786, 786, 786, 786, 786, 786, 786, 786,
746 786, 786, 705, 705, 0, 705, 705, 705, 705, 705,
747 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
748 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
749 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
750 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
751 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
752 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
753 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
754 705, 705, 705, 705, 705, 705
757 static yyconst flex_int16_t yy_nxt[4252] =
759 4, 4, 4, 5, 4, 4, 6, 4, 7, 8,
760 4, 9, 10, 7, 4, 4, 11, 12, 13, 13,
761 4, 14, 4, 4, 15, 16, 17, 18, 15, 15,
762 19, 15, 15, 15, 15, 20, 21, 22, 21, 23,
763 24, 21, 21, 25, 21, 26, 4, 4, 27, 28,
764 29, 30, 31, 32, 33, 34, 35, 36, 37, 38,
765 39, 40, 41, 40, 40, 42, 43, 40, 40, 40,
766 44, 40, 40, 45, 4, 4, 4, 4, 5, 4,
767 46, 6, 46, 7, 8, 4, 9, 10, 47, 4,
768 4, 48, 49, 50, 50, 4, 51, 4, 4, 52,
770 53, 54, 55, 52, 52, 56, 52, 52, 52, 52,
771 57, 58, 59, 58, 60, 61, 58, 58, 62, 58,
772 26, 4, 4, 63, 64, 65, 66, 67, 68, 69,
773 70, 71, 72, 73, 74, 75, 76, 77, 76, 76,
774 78, 79, 76, 76, 76, 80, 76, 76, 81, 4,
775 82, 83, 83, 83, 83, 86, 89, 90, 92, 117,
776 107, 107, 87, 87, 87, 87, 113, 704, 93, 97,
777 94, 95, 107, 107, 82, 96, 97, 97, 98, 84,
778 202, 705, 203, 84, 118, 197, 705, 204, 99, 100,
779 101, 102, 102, 102, 102, 103, 214, 139, 215, 104,
781 104, 104, 104, 104, 104, 104, 104, 84, 104, 84,
782 84, 104, 104, 104, 104, 84, 84, 84, 104, 84,
783 106, 158, 114, 104, 104, 104, 104, 104, 104, 104,
784 104, 104, 104, 104, 104, 84, 104, 104, 104, 104,
785 104, 84, 84, 84, 84, 84, 84, 84, 107, 198,
786 108, 657, 109, 110, 110, 110, 110, 111, 683, 113,
787 107, 119, 119, 119, 119, 119, 119, 119, 119, 119,
788 119, 119, 119, 445, 121, 136, 136, 119, 119, 119,
789 119, 108, 135, 135, 135, 112, 112, 112, 112, 112,
790 112, 112, 112, 112, 112, 112, 112, 120, 122, 119,
792 119, 119, 119, 113, 365, 123, 135, 136, 108, 135,
793 135, 166, 193, 194, 138, 137, 119, 119, 119, 119,
794 136, 136, 135, 135, 135, 136, 136, 551, 135, 135,
795 135, 446, 113, 107, 136, 136, 167, 116, 135, 135,
796 135, 136, 136, 136, 136, 107, 366, 135, 135, 135,
797 124, 135, 135, 135, 145, 125, 126, 127, 127, 127,
798 126, 126, 126, 126, 126, 126, 126, 126, 126, 128,
799 126, 126, 117, 269, 142, 686, 126, 126, 126, 126,
800 205, 206, 136, 136, 136, 136, 214, 107, 163, 135,
801 135, 135, 135, 135, 426, 136, 136, 118, 107, 107,
803 140, 126, 130, 126, 135, 135, 135, 113, 145, 84,
804 107, 168, 168, 168, 168, 107, 168, 168, 168, 168,
805 673, 150, 146, 146, 146, 146, 147, 107, 679, 126,
806 126, 131, 113, 705, 132, 132, 132, 132, 133, 180,
807 92, 179, 179, 124, 97, 84, 182, 147, 169, 141,
808 151, 387, 94, 152, 149, 670, 705, 153, 427, 143,
809 388, 150, 134, 97, 97, 97, 135, 135, 136, 136,
810 136, 136, 136, 136, 136, 136, 136, 136, 242, 179,
811 147, 97, 97, 97, 168, 168, 168, 168, 181, 134,
812 97, 97, 98, 83, 83, 83, 83, 84, 168, 168,
814 168, 168, 154, 100, 101, 155, 155, 155, 155, 156,
815 214, 130, 215, 157, 157, 157, 157, 157, 157, 157,
816 157, 149, 157, 149, 149, 157, 157, 157, 157, 149,
817 149, 149, 157, 149, 172, 173, 106, 157, 157, 157,
818 157, 157, 157, 157, 157, 157, 157, 157, 157, 149,
819 157, 157, 157, 157, 157, 149, 149, 149, 149, 149,
820 149, 149, 84, 275, 276, 107, 678, 159, 269, 109,
821 160, 160, 160, 160, 161, 170, 113, 107, 168, 168,
822 168, 168, 207, 180, 180, 179, 179, 179, 392, 168,
823 168, 168, 168, 84, 84, 84, 84, 393, 159, 171,
825 165, 562, 162, 162, 162, 162, 162, 162, 162, 162,
826 162, 162, 162, 162, 180, 180, 519, 179, 179, 179,
827 256, 256, 256, 256, 351, 159, 363, 166, 174, 175,
828 351, 705, 176, 176, 176, 176, 177, 180, 180, 180,
829 180, 179, 179, 179, 179, 179, 179, 180, 180, 180,
830 180, 84, 167, 179, 179, 179, 179, 179, 179, 130,
831 178, 191, 309, 150, 179, 179, 180, 180, 180, 180,
832 180, 180, 180, 180, 180, 180, 180, 180, 666, 180,
833 180, 180, 180, 673, 179, 179, 179, 178, 179, 179,
834 179, 179, 179, 84, 84, 84, 107, 107, 107, 84,
836 184, 84, 107, 84, 107, 150, 150, 150, 107, 107,
837 107, 150, 113, 150, 107, 150, 107, 84, 97, 84,
838 107, 193, 310, 145, 84, 193, 310, 272, 84, 150,
839 705, 150, 107, 183, 188, 705, 150, 146, 146, 146,
840 146, 312, 313, 186, 191, 256, 256, 256, 256, 185,
841 84, 195, 195, 195, 195, 196, 97, 97, 97, 474,
842 173, 474, 150, 671, 187, 380, 84, 106, 210, 106,
843 211, 256, 256, 256, 256, 212, 145, 260, 150, 149,
844 149, 149, 149, 289, 288, 315, 316, 275, 276, 106,
845 146, 146, 146, 146, 265, 147, 111, 84, 109, 200,
847 200, 200, 200, 111, 84, 270, 271, 261, 145, 150,
848 84, 84, 273, 84, 381, 475, 150, 84, 84, 307,
849 520, 355, 150, 150, 645, 150, 288, 111, 365, 150,
850 150, 201, 201, 201, 201, 201, 201, 201, 201, 201,
851 201, 201, 201, 579, 356, 520, 272, 384, 147, 447,
852 287, 292, 385, 386, 111, 217, 217, 217, 217, 217,
853 217, 217, 217, 217, 217, 217, 217, 84, 356, 84,
854 366, 291, 219, 447, 391, 84, 84, 84, 84, 220,
855 147, 150, 448, 221, 221, 221, 221, 221, 221, 221,
856 221, 221, 221, 221, 84, 84, 84, 84, 84, 84,
858 84, 84, 84, 219, 315, 316, 449, 222, 222, 222,
859 222, 222, 222, 222, 222, 222, 222, 222, 222, 84,
860 84, 84, 84, 84, 84, 84, 84, 84, 84, 84,
861 219, 84, 224, 84, 84, 225, 225, 225, 225, 226,
862 84, 300, 300, 300, 300, 150, 150, 84, 300, 300,
863 300, 300, 150, 551, 84, 312, 313, 670, 226, 150,
864 418, 419, 552, 224, 667, 226, 150, 222, 222, 222,
865 222, 222, 222, 222, 222, 222, 222, 222, 222, 663,
866 303, 335, 335, 335, 335, 421, 194, 428, 305, 226,
867 224, 227, 432, 228, 336, 336, 336, 336, 229, 230,
869 663, 272, 306, 231, 191, 309, 433, 232, 315, 316,
870 84, 317, 317, 317, 317, 227, 226, 228, 300, 300,
871 300, 300, 150, 229, 230, 337, 337, 337, 337, 231,
872 339, 339, 339, 339, 232, 126, 127, 127, 127, 126,
873 126, 126, 126, 126, 126, 126, 126, 126, 126, 126,
874 126, 429, 191, 309, 304, 126, 126, 126, 126, 195,
875 195, 195, 195, 196, 226, 84, 333, 323, 323, 323,
876 323, 226, 340, 340, 340, 340, 334, 150, 421, 194,
877 126, 130, 126, 334, 341, 341, 341, 341, 658, 340,
878 340, 340, 340, 106, 380, 226, 84, 84, 84, 84,
880 84, 84, 84, 84, 84, 84, 84, 400, 126, 126,
881 126, 243, 243, 243, 244, 106, 126, 126, 126, 126,
882 126, 126, 226, 352, 126, 126, 340, 340, 340, 340,
883 126, 126, 465, 126, 243, 243, 243, 244, 370, 418,
884 419, 705, 84, 379, 371, 371, 371, 371, 705, 340,
885 340, 340, 340, 476, 150, 126, 130, 328, 255, 332,
886 353, 84, 84, 657, 84, 372, 372, 372, 372, 656,
887 84, 257, 705, 150, 150, 405, 150, 363, 656, 130,
888 601, 466, 150, 126, 126, 246, 246, 246, 246, 246,
889 246, 246, 246, 246, 246, 246, 246, 84, 247, 705,
891 361, 374, 248, 453, 402, 84, 84, 84, 84, 249,
892 130, 250, 407, 251, 251, 251, 251, 251, 251, 251,
893 251, 251, 251, 251, 251, 251, 251, 251, 251, 251,
894 251, 251, 251, 252, 491, 492, 130, 253, 253, 253,
895 253, 253, 253, 253, 253, 253, 253, 253, 253, 251,
896 251, 251, 251, 251, 251, 251, 251, 251, 251, 251,
897 252, 251, 135, 135, 135, 135, 135, 135, 135, 135,
898 135, 135, 135, 135, 84, 255, 653, 84, 652, 84,
899 421, 194, 256, 256, 256, 256, 491, 492, 257, 150,
900 258, 258, 258, 258, 258, 258, 258, 258, 258, 258,
902 258, 258, 258, 258, 258, 258, 258, 258, 258, 258,
903 258, 421, 194, 650, 84, 84, 84, 84, 259, 84,
904 84, 84, 84, 84, 84, 84, 84, 84, 84, 84,
905 84, 84, 84, 84, 84, 84, 84, 84, 84, 97,
906 97, 97, 424, 424, 424, 424, 84, 84, 84, 370,
907 379, 149, 100, 649, 155, 155, 155, 155, 150, 150,
908 150, 524, 157, 157, 157, 157, 157, 157, 157, 157,
909 149, 157, 149, 149, 157, 157, 157, 157, 149, 149,
910 149, 157, 149, 644, 453, 525, 157, 157, 157, 157,
911 157, 157, 157, 157, 157, 157, 157, 157, 149, 157,
913 157, 157, 157, 157, 149, 149, 149, 149, 149, 149,
914 149, 84, 84, 84, 84, 191, 494, 530, 380, 414,
915 495, 705, 643, 150, 150, 150, 150, 84, 705, 705,
916 705, 705, 84, 84, 705, 394, 394, 394, 394, 150,
917 395, 395, 395, 395, 150, 150, 434, 434, 434, 434,
918 642, 277, 277, 277, 277, 277, 277, 277, 277, 277,
919 277, 277, 277, 84, 705, 145, 84, 413, 278, 491,
920 492, 149, 149, 149, 149, 279, 415, 404, 150, 280,
921 280, 280, 280, 280, 280, 280, 280, 280, 280, 280,
922 149, 149, 149, 149, 149, 149, 149, 149, 149, 278,
924 541, 390, 541, 281, 281, 281, 281, 281, 281, 281,
925 281, 281, 281, 281, 281, 149, 149, 149, 149, 149,
926 149, 149, 149, 149, 149, 149, 278, 149, 282, 145,
927 84, 283, 283, 283, 283, 284, 641, 147, 396, 396,
928 396, 396, 150, 383, 383, 383, 383, 149, 149, 149,
929 149, 149, 149, 149, 149, 149, 149, 149, 638, 282,
930 454, 454, 454, 281, 281, 281, 281, 281, 281, 281,
931 281, 281, 281, 281, 281, 191, 309, 436, 436, 436,
932 436, 637, 423, 423, 423, 423, 282, 294, 294, 294,
933 294, 294, 294, 294, 294, 294, 294, 294, 294, 84,
935 247, 147, 509, 630, 295, 455, 629, 149, 149, 149,
936 149, 296, 522, 250, 510, 297, 297, 297, 297, 297,
937 297, 297, 297, 297, 297, 297, 297, 297, 297, 297,
938 297, 297, 297, 297, 297, 298, 421, 194, 522, 299,
939 299, 299, 299, 299, 299, 299, 299, 299, 299, 299,
940 299, 297, 297, 297, 297, 297, 297, 297, 297, 297,
941 297, 297, 298, 297, 179, 179, 179, 179, 179, 179,
942 179, 179, 179, 179, 179, 179, 84, 255, 459, 491,
943 492, 149, 491, 492, 300, 300, 300, 300, 150, 625,
944 257, 460, 301, 301, 301, 301, 301, 301, 301, 301,
946 301, 301, 301, 301, 301, 301, 301, 301, 301, 301,
947 301, 301, 301, 454, 454, 454, 149, 149, 149, 149,
948 302, 149, 149, 149, 149, 149, 149, 149, 149, 149,
949 149, 149, 149, 149, 149, 149, 149, 149, 149, 149,
950 149, 221, 221, 221, 221, 221, 221, 221, 221, 221,
951 221, 221, 84, 371, 371, 371, 371, 106, 455, 106,
952 396, 396, 396, 396, 150, 222, 222, 222, 222, 222,
953 222, 222, 222, 222, 222, 222, 222, 338, 338, 338,
954 338, 338, 338, 338, 338, 338, 338, 338, 84, 458,
955 458, 458, 458, 465, 400, 608, 396, 396, 396, 396,
957 150, 322, 322, 322, 322, 322, 322, 322, 322, 322,
958 322, 322, 322, 342, 355, 84, 210, 542, 211, 84,
959 343, 543, 344, 212, 84, 572, 370, 150, 84, 84,
960 401, 150, 410, 410, 410, 410, 150, 403, 343, 573,
961 150, 150, 464, 624, 342, 343, 607, 344, 345, 345,
962 345, 345, 345, 345, 345, 345, 345, 345, 345, 345,
963 608, 403, 106, 406, 496, 496, 496, 496, 551, 343,
964 401, 342, 126, 243, 243, 243, 244, 705, 126, 126,
965 126, 126, 126, 126, 705, 430, 126, 126, 408, 84,
966 106, 600, 126, 126, 84, 126, 343, 396, 396, 396,
968 396, 150, 272, 343, 92, 616, 150, 375, 705, 705,
969 343, 375, 705, 617, 469, 470, 94, 126, 130, 430,
970 376, 96, 705, 334, 705, 471, 445, 101, 84, 459,
971 334, 84, 103, 84, 343, 705, 84, 84, 84, 84,
972 145, 145, 460, 150, 615, 126, 126, 255, 408, 431,
973 463, 488, 705, 106, 705, 468, 468, 468, 468, 106,
974 257, 343, 258, 258, 258, 258, 258, 258, 258, 258,
975 258, 258, 258, 258, 258, 258, 258, 258, 258, 258,
976 258, 258, 258, 431, 480, 541, 390, 541, 614, 106,
977 259, 368, 368, 368, 368, 368, 368, 368, 368, 368,
979 368, 368, 368, 375, 145, 84, 610, 618, 610, 578,
980 106, 660, 147, 147, 609, 550, 376, 150, 377, 377,
981 377, 377, 377, 377, 377, 377, 377, 377, 377, 377,
982 377, 377, 377, 377, 377, 377, 377, 377, 377, 84,
983 84, 591, 516, 631, 113, 705, 378, 84, 84, 84,
984 84, 150, 150, 344, 435, 478, 516, 516, 705, 150,
985 150, 150, 150, 280, 280, 280, 280, 280, 280, 280,
986 280, 280, 280, 280, 84, 606, 147, 272, 531, 531,
987 531, 106, 477, 477, 477, 477, 150, 281, 281, 281,
988 281, 281, 281, 281, 281, 281, 281, 281, 281, 397,
990 479, 84, 84, 84, 84, 459, 398, 84, 344, 84,
991 84, 464, 558, 150, 150, 150, 150, 84, 705, 150,
992 84, 150, 150, 532, 481, 410, 410, 410, 410, 150,
993 397, 659, 150, 605, 399, 399, 399, 399, 399, 399,
994 399, 399, 399, 399, 399, 399, 484, 626, 482, 483,
995 145, 485, 688, 688, 547, 84, 459, 397, 84, 255,
996 149, 106, 536, 149, 149, 149, 149, 150, 599, 460,
997 150, 626, 257, 548, 301, 301, 301, 301, 301, 301,
998 301, 301, 301, 301, 301, 301, 301, 301, 301, 301,
999 301, 301, 301, 301, 301, 106, 626, 627, 106, 634,
1001 633, 106, 302, 409, 409, 409, 409, 409, 409, 409,
1002 409, 409, 409, 409, 409, 375, 598, 84, 684, 534,
1003 626, 628, 537, 635, 264, 264, 597, 626, 376, 150,
1004 411, 411, 411, 411, 411, 411, 411, 411, 411, 411,
1005 411, 411, 411, 411, 411, 411, 411, 411, 411, 411,
1006 411, 626, 674, 573, 521, 632, 106, 646, 412, 345,
1007 345, 345, 345, 345, 345, 345, 345, 345, 345, 345,
1008 345, 399, 399, 399, 399, 399, 399, 399, 399, 399,
1009 399, 399, 399, 84, 522, 84, 445, 84, 113, 465,
1010 84, 84, 84, 84, 523, 150, 511, 150, 106, 150,
1012 705, 511, 150, 150, 150, 150, 659, 546, 516, 512,
1013 522, 191, 309, 705, 705, 145, 84, 545, 555, 555,
1014 555, 555, 516, 516, 84, 84, 559, 665, 150, 575,
1015 575, 575, 575, 531, 531, 531, 150, 150, 487, 272,
1016 511, 666, 545, 145, 549, 596, 688, 596, 580, 216,
1017 216, 595, 680, 512, 585, 513, 513, 513, 513, 513,
1018 513, 513, 513, 513, 513, 513, 513, 513, 513, 513,
1019 513, 513, 513, 513, 513, 513, 84, 511, 532, 84,
1020 218, 218, 594, 581, 223, 223, 593, 147, 150, 592,
1021 512, 150, 544, 544, 544, 544, 544, 544, 544, 544,
1023 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
1024 544, 544, 544, 84, 84, 147, 639, 145, 703, 183,
1025 191, 494, 626, 84, 84, 150, 150, 555, 555, 555,
1026 555, 575, 575, 575, 575, 150, 150, 84, 84, 84,
1027 640, 145, 390, 626, 84, 390, 626, 84, 654, 150,
1028 150, 150, 604, 390, 584, 602, 150, 582, 145, 150,
1029 626, 145, 626, 626, 254, 254, 145, 626, 145, 623,
1030 648, 583, 636, 648, 668, 661, 626, 651, 565, 664,
1031 583, 648, 602, 565, 626, 668, 626, 626, 622, 537,
1032 655, 145, 145, 591, 648, 369, 369, 648, 603, 662,
1034 626, 145, 677, 682, 390, 648, 590, 589, 588, 587,
1035 559, 554, 685, 147, 611, 611, 586, 611, 611, 611,
1036 611, 611, 390, 611, 611, 611, 611, 390, 611, 611,
1037 147, 577, 648, 147, 611, 611, 611, 611, 147, 390,
1038 147, 688, 688, 576, 613, 266, 688, 464, 534, 574,
1039 648, 571, 689, 690, 390, 675, 648, 691, 688, 611,
1040 611, 611, 676, 147, 147, 681, 570, 648, 613, 692,
1041 688, 569, 688, 147, 648, 688, 568, 390, 567, 566,
1042 565, 693, 648, 694, 139, 563, 695, 611, 611, 611,
1043 611, 648, 611, 611, 611, 611, 611, 612, 611, 611,
1045 611, 611, 561, 611, 611, 648, 648, 560, 559, 620,
1046 611, 611, 611, 264, 264, 558, 557, 688, 264, 621,
1047 688, 688, 508, 508, 506, 506, 688, 681, 696, 648,
1048 264, 697, 698, 504, 611, 611, 611, 699, 504, 502,
1049 688, 688, 264, 621, 264, 688, 502, 264, 500, 500,
1050 498, 700, 701, 498, 554, 539, 702, 538, 214, 207,
1051 379, 535, 611, 611, 611, 611, 464, 611, 611, 611,
1052 611, 611, 534, 611, 611, 611, 611, 457, 611, 611,
1053 113, 529, 528, 527, 611, 611, 611, 611, 526, 264,
1054 445, 113, 264, 264, 613, 519, 518, 517, 264, 515,
1056 514, 433, 508, 506, 504, 502, 500, 498, 435, 611,
1057 611, 611, 264, 264, 309, 489, 269, 264, 613, 390,
1058 473, 472, 88, 208, 467, 464, 379, 370, 457, 452,
1059 451, 450, 208, 444, 443, 442, 441, 611, 611, 611,
1060 611, 440, 611, 611, 611, 611, 611, 612, 611, 611,
1061 611, 611, 439, 611, 611, 438, 437, 344, 435, 620,
1062 611, 611, 611, 344, 214, 214, 208, 207, 207, 621,
1063 207, 321, 321, 319, 319, 416, 370, 269, 269, 269,
1064 268, 390, 268, 361, 611, 611, 611, 382, 353, 352,
1065 379, 255, 370, 621, 370, 247, 360, 359, 358, 357,
1067 354, 350, 349, 348, 347, 346, 332, 332, 331, 330,
1068 329, 328, 611, 611, 84, 328, 327, 326, 84, 84,
1069 325, 324, 84, 84, 84, 84, 84, 84, 84, 84,
1070 85, 85, 85, 85, 85, 321, 85, 85, 85, 85,
1071 85, 85, 85, 85, 85, 85, 85, 85, 85, 91,
1072 91, 319, 308, 269, 91, 91, 91, 105, 105, 105,
1073 105, 105, 105, 105, 105, 105, 105, 105, 105, 105,
1074 105, 105, 105, 105, 105, 105, 129, 129, 129, 129,
1075 129, 129, 129, 129, 129, 129, 129, 129, 129, 129,
1076 129, 129, 129, 129, 129, 144, 144, 144, 144, 144,
1078 144, 144, 144, 144, 144, 144, 144, 144, 144, 144,
1079 144, 144, 144, 144, 149, 293, 291, 290, 149, 149,
1080 149, 289, 149, 149, 149, 149, 149, 149, 149, 149,
1081 190, 190, 190, 190, 190, 286, 190, 190, 190, 190,
1082 190, 190, 190, 190, 190, 190, 190, 190, 190, 192,
1083 192, 192, 192, 192, 192, 192, 192, 192, 192, 192,
1084 192, 192, 192, 192, 192, 192, 192, 192, 209, 209,
1085 285, 269, 269, 268, 266, 264, 263, 239, 209, 208,
1086 262, 209, 209, 237, 209, 126, 126, 126, 126, 126,
1087 126, 126, 126, 126, 126, 126, 126, 126, 126, 126,
1089 126, 126, 126, 126, 245, 245, 245, 245, 245, 245,
1090 245, 245, 245, 245, 245, 245, 245, 245, 245, 245,
1091 245, 245, 245, 145, 145, 145, 145, 145, 145, 145,
1092 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
1093 145, 145, 267, 267, 267, 267, 267, 267, 267, 267,
1094 267, 267, 267, 267, 267, 267, 267, 267, 267, 267,
1095 267, 149, 130, 241, 240, 149, 149, 149, 239, 149,
1096 149, 149, 149, 149, 149, 149, 149, 274, 274, 274,
1097 274, 274, 274, 274, 274, 274, 274, 274, 274, 274,
1098 274, 274, 274, 274, 274, 274, 190, 190, 190, 190,
1100 190, 190, 190, 190, 190, 190, 190, 190, 190, 190,
1101 190, 190, 190, 190, 190, 192, 192, 192, 192, 192,
1102 192, 192, 192, 192, 192, 192, 192, 192, 192, 192,
1103 192, 192, 192, 192, 311, 311, 311, 311, 311, 311,
1104 311, 311, 311, 311, 311, 311, 311, 311, 311, 311,
1105 311, 311, 311, 314, 314, 314, 314, 314, 314, 314,
1106 314, 314, 314, 314, 314, 314, 314, 314, 314, 314,
1107 314, 314, 318, 318, 208, 318, 318, 318, 318, 318,
1108 318, 318, 318, 318, 318, 318, 318, 318, 318, 318,
1109 318, 320, 320, 238, 320, 320, 320, 320, 320, 320,
1111 320, 320, 320, 320, 320, 320, 320, 320, 320, 320,
1112 322, 237, 322, 236, 236, 235, 322, 322, 322, 234,
1113 233, 322, 362, 362, 362, 362, 362, 362, 362, 362,
1114 362, 362, 362, 362, 362, 362, 362, 362, 362, 362,
1115 362, 126, 126, 126, 126, 126, 126, 126, 126, 126,
1116 126, 126, 126, 126, 126, 126, 126, 126, 126, 126,
1117 364, 364, 364, 364, 364, 364, 364, 364, 364, 364,
1118 364, 364, 364, 364, 364, 364, 364, 364, 364, 245,
1119 245, 245, 245, 245, 245, 245, 245, 245, 245, 245,
1120 245, 245, 245, 245, 245, 245, 245, 245, 367, 367,
1122 367, 367, 367, 367, 367, 367, 373, 106, 214, 213,
1123 373, 207, 373, 373, 373, 373, 208, 373, 267, 267,
1124 267, 267, 267, 267, 267, 267, 267, 267, 267, 267,
1125 267, 267, 267, 267, 267, 267, 267, 389, 389, 389,
1126 389, 389, 389, 389, 389, 389, 389, 389, 389, 389,
1127 389, 389, 389, 389, 389, 389, 149, 207, 199, 191,
1128 149, 149, 149, 189, 149, 149, 149, 149, 149, 149,
1129 149, 149, 274, 274, 274, 274, 274, 274, 274, 274,
1130 274, 274, 274, 274, 274, 274, 274, 274, 274, 274,
1131 274, 105, 105, 105, 105, 105, 105, 105, 105, 105,
1133 105, 105, 105, 105, 105, 105, 105, 105, 105, 105,
1134 314, 314, 314, 314, 314, 314, 314, 314, 314, 314,
1135 314, 314, 314, 314, 314, 314, 314, 314, 314, 311,
1136 311, 311, 311, 311, 311, 311, 311, 311, 311, 311,
1137 311, 311, 311, 311, 311, 311, 311, 311, 417, 417,
1138 417, 417, 417, 417, 417, 417, 417, 417, 417, 417,
1139 417, 417, 417, 417, 417, 417, 417, 420, 420, 420,
1140 420, 420, 420, 420, 420, 420, 420, 420, 420, 420,
1141 420, 420, 420, 420, 420, 420, 422, 422, 422, 422,
1142 422, 422, 422, 422, 422, 422, 422, 422, 422, 422,
1144 422, 422, 422, 422, 422, 190, 190, 190, 190, 190,
1145 190, 190, 190, 190, 190, 190, 190, 190, 190, 190,
1146 190, 190, 190, 190, 318, 318, 165, 318, 318, 318,
1147 318, 318, 318, 318, 318, 318, 318, 318, 318, 318,
1148 318, 318, 318, 320, 320, 164, 320, 320, 320, 320,
1149 320, 320, 320, 320, 320, 320, 320, 320, 320, 320,
1150 320, 320, 425, 148, 425, 425, 116, 115, 425, 425,
1151 425, 106, 88, 425, 362, 362, 362, 362, 362, 362,
1152 362, 362, 362, 362, 362, 362, 362, 362, 362, 362,
1153 362, 362, 362, 364, 364, 364, 364, 364, 364, 364,
1155 364, 364, 364, 364, 364, 364, 364, 364, 364, 364,
1156 364, 364, 126, 126, 126, 126, 126, 126, 126, 126,
1157 126, 126, 126, 126, 126, 126, 126, 126, 126, 126,
1158 126, 456, 456, 456, 456, 456, 456, 456, 456, 456,
1159 456, 456, 456, 456, 456, 456, 456, 456, 456, 456,
1160 461, 461, 705, 705, 461, 461, 705, 461, 461, 461,
1161 461, 461, 461, 461, 461, 461, 462, 705, 705, 705,
1162 705, 705, 462, 462, 462, 462, 705, 462, 389, 389,
1163 389, 389, 389, 389, 389, 389, 389, 389, 389, 389,
1164 389, 389, 389, 389, 389, 389, 389, 105, 105, 105,
1166 105, 105, 105, 105, 105, 105, 105, 105, 105, 105,
1167 105, 105, 105, 105, 105, 105, 486, 486, 705, 705,
1168 486, 486, 486, 486, 486, 486, 486, 486, 486, 486,
1169 486, 486, 418, 418, 418, 418, 418, 418, 418, 418,
1170 418, 418, 418, 418, 418, 418, 418, 418, 418, 418,
1171 418, 490, 490, 490, 490, 490, 490, 490, 490, 490,
1172 490, 490, 490, 490, 490, 490, 490, 490, 490, 490,
1173 493, 493, 493, 493, 493, 493, 493, 493, 493, 493,
1174 493, 493, 493, 493, 493, 493, 493, 493, 493, 497,
1175 497, 705, 497, 497, 497, 497, 497, 497, 497, 497,
1177 497, 497, 497, 497, 497, 497, 497, 497, 499, 499,
1178 705, 499, 499, 499, 499, 499, 499, 499, 499, 499,
1179 499, 499, 499, 499, 499, 499, 499, 501, 501, 705,
1180 501, 501, 501, 501, 501, 501, 501, 501, 501, 501,
1181 501, 501, 501, 501, 501, 501, 503, 503, 705, 503,
1182 503, 503, 503, 503, 503, 503, 503, 503, 503, 503,
1183 503, 503, 503, 503, 503, 505, 505, 705, 505, 505,
1184 505, 505, 505, 505, 505, 505, 505, 505, 505, 505,
1185 505, 505, 505, 505, 507, 507, 705, 507, 507, 507,
1186 507, 507, 507, 507, 507, 507, 507, 507, 507, 507,
1188 507, 507, 507, 362, 362, 362, 362, 362, 362, 362,
1189 362, 362, 362, 362, 362, 362, 362, 362, 362, 362,
1190 362, 362, 126, 126, 126, 126, 126, 126, 126, 126,
1191 126, 126, 126, 126, 126, 126, 126, 126, 126, 126,
1192 126, 456, 456, 456, 456, 456, 456, 456, 456, 456,
1193 456, 456, 456, 456, 456, 456, 456, 456, 456, 456,
1194 533, 705, 705, 705, 705, 705, 533, 533, 533, 533,
1195 533, 533, 533, 533, 533, 540, 540, 540, 540, 540,
1196 540, 540, 540, 540, 540, 540, 540, 540, 540, 540,
1197 540, 540, 540, 540, 553, 553, 553, 553, 705, 553,
1199 553, 553, 553, 553, 553, 553, 553, 553, 553, 553,
1200 553, 553, 553, 556, 705, 705, 705, 705, 705, 556,
1201 556, 556, 556, 564, 564, 705, 564, 564, 564, 564,
1202 564, 564, 564, 564, 564, 564, 564, 564, 564, 564,
1203 564, 564, 612, 612, 705, 612, 612, 612, 612, 612,
1204 612, 612, 612, 612, 612, 612, 612, 612, 612, 612,
1205 612, 619, 619, 705, 619, 619, 619, 619, 619, 619,
1206 619, 619, 619, 619, 619, 619, 619, 619, 619, 619,
1207 611, 611, 705, 611, 611, 611, 611, 611, 611, 611,
1208 611, 611, 611, 611, 611, 611, 611, 611, 611, 647,
1210 647, 647, 647, 647, 647, 647, 647, 647, 647, 647,
1211 647, 647, 647, 647, 647, 647, 647, 647, 669, 669,
1212 669, 669, 669, 669, 669, 669, 669, 669, 669, 669,
1213 669, 669, 669, 669, 669, 669, 669, 672, 672, 672,
1214 672, 672, 672, 672, 672, 672, 672, 672, 672, 672,
1215 672, 672, 672, 672, 672, 672, 687, 687, 687, 687,
1216 687, 687, 687, 687, 687, 687, 687, 687, 687, 687,
1217 687, 687, 687, 687, 687, 3, 705, 705, 705, 705,
1218 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1219 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1221 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1222 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1223 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1224 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1225 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1229 static yyconst flex_int16_t yy_chk[4252] =
1231 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1232 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1233 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1234 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1235 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1236 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1237 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1238 1, 1, 1, 1, 1, 2, 2, 2, 2, 2,
1239 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1240 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1242 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1243 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1244 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1245 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1246 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1247 5, 6, 6, 6, 6, 8, 10, 10, 11, 19,
1248 39, 40, 8, 8, 8, 8, 16, 703, 11, 13,
1249 11, 11, 39, 40, 5, 11, 12, 12, 12, 13,
1250 92, 13, 92, 12, 19, 88, 13, 92, 12, 12,
1251 12, 12, 12, 12, 12, 12, 101, 39, 101, 12,
1253 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,
1254 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,
1255 51, 51, 16, 12, 12, 12, 12, 12, 12, 12,
1256 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,
1257 12, 12, 12, 12, 12, 12, 12, 12, 15, 88,
1258 15, 683, 15, 15, 15, 15, 15, 15, 679, 28,
1259 15, 21, 21, 21, 21, 20, 20, 20, 20, 23,
1260 23, 23, 23, 354, 22, 35, 35, 22, 22, 22,
1261 22, 15, 35, 35, 35, 15, 15, 15, 15, 15,
1262 15, 15, 15, 15, 15, 15, 15, 20, 22, 24,
1264 24, 24, 24, 25, 244, 23, 28, 29, 15, 29,
1265 29, 56, 86, 86, 29, 28, 25, 25, 25, 25,
1266 30, 30, 30, 30, 30, 31, 31, 678, 31, 31,
1267 31, 354, 53, 42, 32, 32, 56, 30, 32, 32,
1268 32, 34, 34, 36, 36, 42, 244, 34, 34, 34,
1269 24, 36, 36, 36, 144, 25, 26, 26, 26, 26,
1270 26, 26, 26, 26, 26, 26, 26, 26, 26, 26,
1271 26, 26, 33, 156, 42, 685, 26, 26, 26, 26,
1272 93, 93, 38, 38, 33, 33, 156, 43, 53, 33,
1273 33, 33, 38, 38, 328, 37, 37, 33, 41, 43,
1275 41, 26, 26, 26, 37, 37, 37, 44, 45, 47,
1276 41, 58, 58, 58, 58, 44, 57, 57, 57, 57,
1277 672, 47, 45, 45, 45, 45, 144, 44, 671, 26,
1278 26, 27, 64, 27, 27, 27, 27, 27, 27, 65,
1279 48, 65, 65, 43, 50, 48, 65, 685, 57, 41,
1280 48, 268, 48, 48, 50, 669, 50, 48, 328, 44,
1281 268, 50, 27, 97, 97, 97, 27, 27, 27, 27,
1282 27, 27, 27, 27, 27, 27, 27, 27, 128, 64,
1283 45, 100, 100, 100, 61, 61, 61, 61, 64, 27,
1284 49, 49, 49, 83, 83, 83, 83, 49, 60, 60,
1286 60, 60, 49, 49, 49, 49, 49, 49, 49, 49,
1287 330, 128, 330, 49, 49, 49, 49, 49, 49, 49,
1288 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1289 49, 49, 49, 49, 60, 61, 276, 49, 49, 49,
1290 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1291 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1292 49, 49, 52, 158, 158, 52, 667, 52, 153, 52,
1293 52, 52, 52, 52, 52, 59, 62, 52, 59, 59,
1294 59, 59, 153, 66, 66, 66, 66, 66, 276, 62,
1295 62, 62, 62, 119, 119, 119, 119, 276, 52, 59,
1297 66, 517, 52, 52, 52, 52, 52, 52, 52, 52,
1298 52, 52, 52, 52, 67, 67, 517, 67, 67, 67,
1299 136, 136, 136, 136, 232, 52, 242, 69, 62, 63,
1300 232, 63, 63, 63, 63, 63, 63, 68, 68, 69,
1301 69, 68, 68, 68, 69, 69, 69, 70, 70, 71,
1302 71, 149, 69, 70, 70, 70, 71, 71, 71, 242,
1303 63, 190, 190, 149, 63, 63, 63, 63, 63, 63,
1304 63, 63, 63, 63, 63, 63, 72, 72, 665, 73,
1305 73, 74, 74, 659, 72, 72, 72, 63, 73, 73,
1306 73, 74, 74, 75, 76, 77, 75, 76, 77, 78,
1308 77, 79, 78, 157, 79, 75, 76, 77, 75, 76,
1309 77, 78, 80, 79, 78, 157, 79, 80, 102, 152,
1310 80, 191, 191, 81, 183, 192, 192, 152, 102, 80,
1311 102, 152, 80, 75, 81, 102, 183, 81, 81, 81,
1312 81, 193, 193, 78, 87, 137, 137, 137, 137, 77,
1313 166, 87, 87, 87, 87, 87, 98, 98, 98, 390,
1314 79, 390, 166, 658, 80, 259, 167, 631, 98, 392,
1315 98, 138, 138, 138, 138, 98, 146, 137, 167, 168,
1316 168, 168, 168, 183, 166, 194, 194, 274, 274, 543,
1317 146, 146, 146, 146, 146, 81, 91, 151, 91, 91,
1319 91, 91, 91, 91, 154, 151, 151, 138, 188, 151,
1320 165, 173, 154, 186, 259, 392, 154, 171, 272, 188,
1321 444, 236, 165, 173, 631, 186, 167, 91, 364, 171,
1322 272, 91, 91, 91, 91, 91, 91, 91, 91, 91,
1323 91, 91, 91, 543, 236, 444, 171, 266, 146, 355,
1324 165, 173, 266, 266, 91, 108, 108, 108, 108, 108,
1325 108, 108, 108, 108, 108, 108, 108, 110, 236, 270,
1326 364, 186, 110, 355, 270, 110, 110, 110, 110, 110,
1327 188, 270, 356, 110, 110, 110, 110, 110, 110, 110,
1328 110, 110, 110, 110, 110, 110, 110, 110, 110, 110,
1330 110, 110, 110, 110, 310, 310, 356, 110, 110, 110,
1331 110, 110, 110, 110, 110, 110, 110, 110, 110, 110,
1332 110, 110, 110, 110, 110, 110, 110, 110, 110, 110,
1333 110, 110, 112, 180, 184, 112, 112, 112, 112, 112,
1334 181, 180, 180, 180, 180, 180, 184, 185, 181, 181,
1335 181, 181, 181, 489, 187, 311, 311, 657, 200, 185,
1336 312, 312, 489, 112, 653, 200, 187, 112, 112, 112,
1337 112, 112, 112, 112, 112, 112, 112, 112, 112, 650,
1338 181, 216, 216, 216, 216, 313, 313, 332, 184, 200,
1339 112, 113, 334, 113, 217, 217, 217, 217, 113, 113,
1341 649, 185, 187, 113, 196, 196, 334, 113, 314, 314,
1342 182, 196, 196, 196, 196, 113, 200, 113, 182, 182,
1343 182, 182, 182, 113, 113, 218, 218, 218, 218, 113,
1344 221, 221, 221, 221, 113, 127, 127, 127, 127, 127,
1345 127, 127, 127, 127, 127, 127, 127, 127, 127, 127,
1346 127, 332, 195, 195, 182, 127, 127, 127, 127, 195,
1347 195, 195, 195, 195, 201, 303, 215, 201, 201, 201,
1348 201, 201, 222, 222, 222, 222, 215, 303, 315, 315,
1349 127, 127, 127, 215, 223, 223, 223, 223, 644, 233,
1350 233, 233, 233, 393, 374, 201, 224, 224, 224, 224,
1352 224, 224, 224, 224, 224, 224, 224, 303, 127, 127,
1353 129, 129, 129, 129, 129, 579, 129, 129, 129, 129,
1354 129, 129, 201, 233, 129, 129, 234, 234, 234, 234,
1355 129, 129, 378, 129, 243, 243, 243, 243, 253, 417,
1356 417, 226, 287, 374, 253, 253, 253, 253, 226, 241,
1357 241, 241, 241, 393, 287, 129, 129, 271, 254, 273,
1358 234, 292, 271, 643, 273, 254, 254, 254, 254, 642,
1359 290, 254, 226, 292, 271, 290, 273, 362, 641, 243,
1360 579, 378, 290, 129, 129, 131, 131, 131, 131, 131,
1361 131, 131, 131, 131, 131, 131, 131, 132, 132, 226,
1363 241, 254, 132, 363, 287, 132, 132, 132, 132, 132,
1364 362, 132, 292, 132, 132, 132, 132, 132, 132, 132,
1365 132, 132, 132, 132, 132, 132, 132, 132, 132, 132,
1366 132, 132, 132, 132, 419, 419, 363, 132, 132, 132,
1367 132, 132, 132, 132, 132, 132, 132, 132, 132, 132,
1368 132, 132, 132, 132, 132, 132, 132, 132, 132, 132,
1369 132, 132, 134, 134, 134, 134, 134, 134, 134, 134,
1370 134, 134, 134, 134, 135, 135, 638, 395, 637, 135,
1371 420, 420, 135, 135, 135, 135, 421, 421, 135, 395,
1372 135, 135, 135, 135, 135, 135, 135, 135, 135, 135,
1374 135, 135, 135, 135, 135, 135, 135, 135, 135, 135,
1375 135, 422, 422, 635, 135, 135, 135, 135, 135, 135,
1376 135, 135, 135, 135, 135, 135, 135, 135, 135, 135,
1377 135, 135, 135, 135, 135, 135, 135, 135, 135, 155,
1378 155, 155, 322, 322, 322, 322, 155, 297, 301, 297,
1379 301, 155, 155, 634, 155, 155, 155, 155, 155, 297,
1380 301, 447, 155, 155, 155, 155, 155, 155, 155, 155,
1381 155, 155, 155, 155, 155, 155, 155, 155, 155, 155,
1382 155, 155, 155, 630, 453, 447, 155, 155, 155, 155,
1383 155, 155, 155, 155, 155, 155, 155, 155, 155, 155,
1385 155, 155, 155, 155, 155, 155, 155, 155, 155, 155,
1386 155, 159, 302, 404, 305, 423, 423, 453, 302, 305,
1387 423, 255, 629, 159, 302, 404, 305, 277, 255, 255,
1388 255, 255, 280, 289, 255, 277, 277, 277, 277, 277,
1389 280, 280, 280, 280, 280, 289, 338, 338, 338, 338,
1390 628, 159, 159, 159, 159, 159, 159, 159, 159, 159,
1391 159, 159, 159, 160, 255, 307, 413, 302, 160, 490,
1392 490, 160, 160, 160, 160, 160, 307, 289, 413, 160,
1393 160, 160, 160, 160, 160, 160, 160, 160, 160, 160,
1394 160, 160, 160, 160, 160, 160, 160, 160, 160, 160,
1396 474, 474, 474, 160, 160, 160, 160, 160, 160, 160,
1397 160, 160, 160, 160, 160, 160, 160, 160, 160, 160,
1398 160, 160, 160, 160, 160, 160, 160, 160, 162, 265,
1399 281, 162, 162, 162, 162, 162, 627, 307, 281, 281,
1400 281, 281, 281, 265, 265, 265, 265, 282, 282, 282,
1401 282, 282, 282, 282, 282, 282, 282, 282, 625, 162,
1402 365, 365, 365, 162, 162, 162, 162, 162, 162, 162,
1403 162, 162, 162, 162, 162, 317, 317, 345, 345, 345,
1404 345, 624, 317, 317, 317, 317, 162, 175, 175, 175,
1405 175, 175, 175, 175, 175, 175, 175, 175, 175, 176,
1407 176, 265, 433, 616, 176, 365, 615, 176, 176, 176,
1408 176, 176, 593, 176, 433, 176, 176, 176, 176, 176,
1409 176, 176, 176, 176, 176, 176, 176, 176, 176, 176,
1410 176, 176, 176, 176, 176, 176, 492, 492, 593, 176,
1411 176, 176, 176, 176, 176, 176, 176, 176, 176, 176,
1412 176, 176, 176, 176, 176, 176, 176, 176, 176, 176,
1413 176, 176, 176, 176, 178, 178, 178, 178, 178, 178,
1414 178, 178, 178, 178, 178, 178, 179, 179, 458, 493,
1415 493, 179, 554, 554, 179, 179, 179, 179, 179, 609,
1416 179, 458, 179, 179, 179, 179, 179, 179, 179, 179,
1418 179, 179, 179, 179, 179, 179, 179, 179, 179, 179,
1419 179, 179, 179, 454, 454, 454, 179, 179, 179, 179,
1420 179, 179, 179, 179, 179, 179, 179, 179, 179, 179,
1421 179, 179, 179, 179, 179, 179, 179, 179, 179, 179,
1422 179, 219, 219, 219, 219, 219, 219, 219, 219, 219,
1423 219, 219, 285, 368, 368, 368, 368, 476, 454, 475,
1424 285, 285, 285, 285, 285, 219, 219, 219, 219, 219,
1425 219, 219, 219, 219, 219, 219, 219, 220, 220, 220,
1426 220, 220, 220, 220, 220, 220, 220, 220, 286, 369,
1427 369, 369, 369, 463, 285, 607, 286, 286, 286, 286,
1429 286, 220, 220, 220, 220, 220, 220, 220, 220, 220,
1430 220, 220, 220, 225, 288, 291, 470, 475, 470, 288,
1431 225, 476, 225, 470, 299, 528, 299, 291, 304, 306,
1432 286, 288, 299, 299, 299, 299, 299, 288, 323, 528,
1433 304, 306, 463, 606, 225, 323, 591, 323, 225, 225,
1434 225, 225, 225, 225, 225, 225, 225, 225, 225, 225,
1435 591, 288, 600, 291, 425, 425, 425, 425, 605, 323,
1436 304, 225, 245, 245, 245, 245, 245, 343, 245, 245,
1437 245, 245, 245, 245, 343, 588, 245, 245, 306, 293,
1438 578, 578, 245, 245, 391, 245, 323, 293, 293, 293,
1440 293, 293, 391, 337, 385, 599, 391, 372, 343, 375,
1441 337, 376, 337, 600, 385, 386, 385, 245, 245, 333,
1442 372, 385, 375, 333, 376, 386, 402, 386, 371, 371,
1443 333, 402, 386, 371, 337, 343, 371, 371, 371, 371,
1444 415, 383, 371, 402, 598, 245, 245, 246, 293, 588,
1445 372, 415, 375, 601, 376, 383, 383, 383, 383, 542,
1446 246, 337, 246, 246, 246, 246, 246, 246, 246, 246,
1447 246, 246, 246, 246, 246, 246, 246, 246, 246, 246,
1448 246, 246, 246, 333, 402, 541, 541, 541, 597, 617,
1449 246, 248, 248, 248, 248, 248, 248, 248, 248, 248,
1451 248, 248, 248, 256, 488, 400, 595, 601, 594, 542,
1452 646, 646, 415, 383, 592, 488, 256, 400, 256, 256,
1453 256, 256, 256, 256, 256, 256, 256, 256, 256, 256,
1454 256, 256, 256, 256, 256, 256, 256, 256, 256, 394,
1455 396, 590, 439, 617, 478, 459, 256, 278, 405, 478,
1456 401, 394, 396, 394, 396, 400, 439, 439, 459, 278,
1457 405, 478, 401, 278, 278, 278, 278, 278, 278, 278,
1458 278, 278, 278, 278, 399, 589, 488, 405, 457, 457,
1459 457, 645, 399, 399, 399, 399, 399, 278, 278, 278,
1460 278, 278, 278, 278, 278, 278, 278, 278, 278, 283,
1462 401, 403, 407, 406, 487, 460, 283, 408, 283, 411,
1463 482, 411, 587, 403, 407, 406, 487, 409, 460, 408,
1464 483, 411, 482, 457, 403, 409, 409, 409, 409, 409,
1465 283, 645, 483, 586, 283, 283, 283, 283, 283, 283,
1466 283, 283, 283, 283, 283, 283, 407, 610, 403, 406,
1467 468, 408, 686, 687, 482, 410, 410, 283, 294, 294,
1468 410, 680, 468, 410, 410, 410, 410, 410, 577, 410,
1469 294, 610, 294, 483, 294, 294, 294, 294, 294, 294,
1470 294, 294, 294, 294, 294, 294, 294, 294, 294, 294,
1471 294, 294, 294, 294, 294, 618, 611, 613, 632, 621,
1473 620, 660, 294, 295, 295, 295, 295, 295, 295, 295,
1474 295, 295, 295, 295, 295, 300, 576, 486, 680, 486,
1475 611, 613, 468, 621, 686, 687, 574, 620, 300, 486,
1476 300, 300, 300, 300, 300, 300, 300, 300, 300, 300,
1477 300, 300, 300, 300, 300, 300, 300, 300, 300, 300,
1478 300, 620, 660, 572, 445, 618, 684, 632, 300, 342,
1479 342, 342, 342, 342, 342, 342, 342, 342, 342, 342,
1480 342, 397, 397, 397, 397, 397, 397, 397, 397, 397,
1481 397, 397, 397, 412, 445, 414, 480, 481, 485, 412,
1482 479, 480, 484, 485, 445, 412, 496, 414, 674, 481,
1484 511, 512, 479, 480, 484, 485, 684, 481, 516, 496,
1485 445, 495, 495, 511, 512, 536, 546, 479, 495, 495,
1486 495, 495, 516, 516, 544, 547, 544, 652, 546, 536,
1487 536, 536, 536, 531, 531, 531, 544, 547, 412, 414,
1488 436, 652, 479, 550, 484, 571, 702, 570, 546, 716,
1489 716, 569, 674, 436, 550, 436, 436, 436, 436, 436,
1490 436, 436, 436, 436, 436, 436, 436, 436, 436, 436,
1491 436, 436, 436, 436, 436, 436, 477, 477, 531, 545,
1492 717, 717, 568, 547, 718, 718, 567, 536, 477, 566,
1493 477, 545, 477, 477, 477, 477, 477, 477, 477, 477,
1495 477, 477, 477, 477, 477, 477, 477, 477, 477, 477,
1496 477, 477, 477, 548, 549, 550, 626, 575, 702, 545,
1497 555, 555, 626, 580, 581, 548, 549, 555, 555, 555,
1498 555, 575, 575, 575, 575, 580, 581, 582, 583, 584,
1499 626, 585, 633, 639, 603, 647, 626, 622, 639, 582,
1500 583, 584, 585, 648, 549, 580, 603, 548, 604, 622,
1501 640, 623, 668, 655, 721, 721, 636, 639, 651, 604,
1502 633, 548, 623, 647, 654, 648, 654, 636, 565, 651,
1503 582, 648, 581, 564, 640, 655, 668, 655, 603, 575,
1504 640, 664, 677, 563, 633, 738, 738, 647, 584, 648,
1506 654, 682, 664, 677, 662, 648, 561, 560, 558, 557,
1507 556, 553, 682, 585, 596, 596, 552, 596, 596, 596,
1508 596, 596, 661, 596, 596, 596, 596, 540, 596, 596,
1509 604, 539, 662, 623, 596, 596, 596, 596, 636, 675,
1510 651, 688, 689, 538, 596, 537, 690, 535, 533, 529,
1511 661, 527, 688, 689, 681, 661, 662, 690, 691, 596,
1512 596, 596, 662, 664, 677, 675, 526, 675, 596, 691,
1513 692, 525, 693, 682, 661, 694, 524, 676, 523, 522,
1514 521, 692, 681, 693, 520, 518, 694, 596, 596, 602,
1515 602, 675, 602, 602, 602, 602, 602, 602, 602, 602,
1517 602, 602, 515, 602, 602, 676, 681, 514, 513, 602,
1518 602, 602, 602, 688, 689, 510, 509, 695, 690, 602,
1519 696, 697, 508, 507, 506, 505, 698, 676, 695, 676,
1520 691, 696, 697, 504, 602, 602, 602, 698, 503, 502,
1521 699, 700, 692, 602, 693, 701, 501, 694, 500, 499,
1522 498, 699, 700, 497, 491, 473, 701, 472, 471, 469,
1523 467, 465, 602, 602, 612, 612, 462, 612, 612, 612,
1524 612, 612, 461, 612, 612, 612, 612, 456, 612, 612,
1525 452, 451, 450, 449, 612, 612, 612, 612, 448, 695,
1526 446, 443, 696, 697, 612, 442, 441, 440, 698, 438,
1528 437, 432, 431, 430, 429, 428, 427, 426, 424, 612,
1529 612, 612, 699, 700, 418, 416, 398, 701, 612, 389,
1530 388, 387, 384, 382, 380, 377, 373, 367, 366, 361,
1531 360, 359, 358, 353, 352, 351, 350, 612, 612, 619,
1532 619, 349, 619, 619, 619, 619, 619, 619, 619, 619,
1533 619, 619, 348, 619, 619, 347, 346, 341, 340, 619,
1534 619, 619, 619, 336, 331, 329, 327, 326, 325, 619,
1535 324, 321, 320, 319, 318, 308, 298, 296, 284, 279,
1536 275, 269, 267, 263, 619, 619, 619, 262, 261, 260,
1537 258, 257, 252, 619, 251, 250, 240, 239, 238, 237,
1539 235, 231, 230, 229, 228, 227, 214, 213, 212, 211,
1540 210, 207, 619, 619, 706, 206, 205, 204, 706, 706,
1541 203, 202, 706, 706, 706, 706, 706, 706, 706, 706,
1542 707, 707, 707, 707, 707, 198, 707, 707, 707, 707,
1543 707, 707, 707, 707, 707, 707, 707, 707, 707, 708,
1544 708, 197, 189, 177, 708, 708, 708, 709, 709, 709,
1545 709, 709, 709, 709, 709, 709, 709, 709, 709, 709,
1546 709, 709, 709, 709, 709, 709, 710, 710, 710, 710,
1547 710, 710, 710, 710, 710, 710, 710, 710, 710, 710,
1548 710, 710, 710, 710, 710, 711, 711, 711, 711, 711,
1550 711, 711, 711, 711, 711, 711, 711, 711, 711, 711,
1551 711, 711, 711, 711, 712, 174, 172, 170, 712, 712,
1552 712, 169, 712, 712, 712, 712, 712, 712, 712, 712,
1553 713, 713, 713, 713, 713, 164, 713, 713, 713, 713,
1554 713, 713, 713, 713, 713, 713, 713, 713, 713, 714,
1555 714, 714, 714, 714, 714, 714, 714, 714, 714, 714,
1556 714, 714, 714, 714, 714, 714, 714, 714, 715, 715,
1557 163, 161, 150, 148, 147, 145, 143, 142, 715, 141,
1558 140, 715, 715, 139, 715, 719, 719, 719, 719, 719,
1559 719, 719, 719, 719, 719, 719, 719, 719, 719, 719,
1561 719, 719, 719, 719, 720, 720, 720, 720, 720, 720,
1562 720, 720, 720, 720, 720, 720, 720, 720, 720, 720,
1563 720, 720, 720, 722, 722, 722, 722, 722, 722, 722,
1564 722, 722, 722, 722, 722, 722, 722, 722, 722, 722,
1565 722, 722, 723, 723, 723, 723, 723, 723, 723, 723,
1566 723, 723, 723, 723, 723, 723, 723, 723, 723, 723,
1567 723, 724, 126, 125, 124, 724, 724, 724, 123, 724,
1568 724, 724, 724, 724, 724, 724, 724, 725, 725, 725,
1569 725, 725, 725, 725, 725, 725, 725, 725, 725, 725,
1570 725, 725, 725, 725, 725, 725, 726, 726, 726, 726,
1572 726, 726, 726, 726, 726, 726, 726, 726, 726, 726,
1573 726, 726, 726, 726, 726, 727, 727, 727, 727, 727,
1574 727, 727, 727, 727, 727, 727, 727, 727, 727, 727,
1575 727, 727, 727, 727, 728, 728, 728, 728, 728, 728,
1576 728, 728, 728, 728, 728, 728, 728, 728, 728, 728,
1577 728, 728, 728, 729, 729, 729, 729, 729, 729, 729,
1578 729, 729, 729, 729, 729, 729, 729, 729, 729, 729,
1579 729, 729, 730, 730, 122, 730, 730, 730, 730, 730,
1580 730, 730, 730, 730, 730, 730, 730, 730, 730, 730,
1581 730, 731, 731, 121, 731, 731, 731, 731, 731, 731,
1583 731, 731, 731, 731, 731, 731, 731, 731, 731, 731,
1584 732, 120, 732, 118, 117, 116, 732, 732, 732, 115,
1585 114, 732, 733, 733, 733, 733, 733, 733, 733, 733,
1586 733, 733, 733, 733, 733, 733, 733, 733, 733, 733,
1587 733, 734, 734, 734, 734, 734, 734, 734, 734, 734,
1588 734, 734, 734, 734, 734, 734, 734, 734, 734, 734,
1589 735, 735, 735, 735, 735, 735, 735, 735, 735, 735,
1590 735, 735, 735, 735, 735, 735, 735, 735, 735, 736,
1591 736, 736, 736, 736, 736, 736, 736, 736, 736, 736,
1592 736, 736, 736, 736, 736, 736, 736, 736, 737, 737,
1594 737, 737, 737, 737, 737, 737, 739, 105, 103, 99,
1595 739, 96, 739, 739, 739, 739, 95, 739, 740, 740,
1596 740, 740, 740, 740, 740, 740, 740, 740, 740, 740,
1597 740, 740, 740, 740, 740, 740, 740, 741, 741, 741,
1598 741, 741, 741, 741, 741, 741, 741, 741, 741, 741,
1599 741, 741, 741, 741, 741, 741, 742, 94, 90, 85,
1600 742, 742, 742, 82, 742, 742, 742, 742, 742, 742,
1601 742, 742, 743, 743, 743, 743, 743, 743, 743, 743,
1602 743, 743, 743, 743, 743, 743, 743, 743, 743, 743,
1603 743, 744, 744, 744, 744, 744, 744, 744, 744, 744,
1605 744, 744, 744, 744, 744, 744, 744, 744, 744, 744,
1606 745, 745, 745, 745, 745, 745, 745, 745, 745, 745,
1607 745, 745, 745, 745, 745, 745, 745, 745, 745, 746,
1608 746, 746, 746, 746, 746, 746, 746, 746, 746, 746,
1609 746, 746, 746, 746, 746, 746, 746, 746, 747, 747,
1610 747, 747, 747, 747, 747, 747, 747, 747, 747, 747,
1611 747, 747, 747, 747, 747, 747, 747, 748, 748, 748,
1612 748, 748, 748, 748, 748, 748, 748, 748, 748, 748,
1613 748, 748, 748, 748, 748, 748, 749, 749, 749, 749,
1614 749, 749, 749, 749, 749, 749, 749, 749, 749, 749,
1616 749, 749, 749, 749, 749, 750, 750, 750, 750, 750,
1617 750, 750, 750, 750, 750, 750, 750, 750, 750, 750,
1618 750, 750, 750, 750, 751, 751, 55, 751, 751, 751,
1619 751, 751, 751, 751, 751, 751, 751, 751, 751, 751,
1620 751, 751, 751, 752, 752, 54, 752, 752, 752, 752,
1621 752, 752, 752, 752, 752, 752, 752, 752, 752, 752,
1622 752, 752, 753, 46, 753, 753, 18, 17, 753, 753,
1623 753, 14, 9, 753, 754, 754, 754, 754, 754, 754,
1624 754, 754, 754, 754, 754, 754, 754, 754, 754, 754,
1625 754, 754, 754, 755, 755, 755, 755, 755, 755, 755,
1627 755, 755, 755, 755, 755, 755, 755, 755, 755, 755,
1628 755, 755, 756, 756, 756, 756, 756, 756, 756, 756,
1629 756, 756, 756, 756, 756, 756, 756, 756, 756, 756,
1630 756, 757, 757, 757, 757, 757, 757, 757, 757, 757,
1631 757, 757, 757, 757, 757, 757, 757, 757, 757, 757,
1632 758, 758, 3, 0, 758, 758, 0, 758, 758, 758,
1633 758, 758, 758, 758, 758, 758, 759, 0, 0, 0,
1634 0, 0, 759, 759, 759, 759, 0, 759, 760, 760,
1635 760, 760, 760, 760, 760, 760, 760, 760, 760, 760,
1636 760, 760, 760, 760, 760, 760, 760, 761, 761, 761,
1638 761, 761, 761, 761, 761, 761, 761, 761, 761, 761,
1639 761, 761, 761, 761, 761, 761, 762, 762, 0, 0,
1640 762, 762, 762, 762, 762, 762, 762, 762, 762, 762,
1641 762, 762, 763, 763, 763, 763, 763, 763, 763, 763,
1642 763, 763, 763, 763, 763, 763, 763, 763, 763, 763,
1643 763, 764, 764, 764, 764, 764, 764, 764, 764, 764,
1644 764, 764, 764, 764, 764, 764, 764, 764, 764, 764,
1645 765, 765, 765, 765, 765, 765, 765, 765, 765, 765,
1646 765, 765, 765, 765, 765, 765, 765, 765, 765, 766,
1647 766, 0, 766, 766, 766, 766, 766, 766, 766, 766,
1649 766, 766, 766, 766, 766, 766, 766, 766, 767, 767,
1650 0, 767, 767, 767, 767, 767, 767, 767, 767, 767,
1651 767, 767, 767, 767, 767, 767, 767, 768, 768, 0,
1652 768, 768, 768, 768, 768, 768, 768, 768, 768, 768,
1653 768, 768, 768, 768, 768, 768, 769, 769, 0, 769,
1654 769, 769, 769, 769, 769, 769, 769, 769, 769, 769,
1655 769, 769, 769, 769, 769, 770, 770, 0, 770, 770,
1656 770, 770, 770, 770, 770, 770, 770, 770, 770, 770,
1657 770, 770, 770, 770, 771, 771, 0, 771, 771, 771,
1658 771, 771, 771, 771, 771, 771, 771, 771, 771, 771,
1660 771, 771, 771, 772, 772, 772, 772, 772, 772, 772,
1661 772, 772, 772, 772, 772, 772, 772, 772, 772, 772,
1662 772, 772, 773, 773, 773, 773, 773, 773, 773, 773,
1663 773, 773, 773, 773, 773, 773, 773, 773, 773, 773,
1664 773, 774, 774, 774, 774, 774, 774, 774, 774, 774,
1665 774, 774, 774, 774, 774, 774, 774, 774, 774, 774,
1666 775, 0, 0, 0, 0, 0, 775, 775, 775, 775,
1667 775, 775, 775, 775, 775, 776, 776, 776, 776, 776,
1668 776, 776, 776, 776, 776, 776, 776, 776, 776, 776,
1669 776, 776, 776, 776, 777, 777, 777, 777, 0, 777,
1671 777, 777, 777, 777, 777, 777, 777, 777, 777, 777,
1672 777, 777, 777, 778, 0, 0, 0, 0, 0, 778,
1673 778, 778, 778, 779, 779, 0, 779, 779, 779, 779,
1674 779, 779, 779, 779, 779, 779, 779, 779, 779, 779,
1675 779, 779, 780, 780, 0, 780, 780, 780, 780, 780,
1676 780, 780, 780, 780, 780, 780, 780, 780, 780, 780,
1677 780, 781, 781, 0, 781, 781, 781, 781, 781, 781,
1678 781, 781, 781, 781, 781, 781, 781, 781, 781, 781,
1679 782, 782, 0, 782, 782, 782, 782, 782, 782, 782,
1680 782, 782, 782, 782, 782, 782, 782, 782, 782, 783,
1682 783, 783, 783, 783, 783, 783, 783, 783, 783, 783,
1683 783, 783, 783, 783, 783, 783, 783, 783, 784, 784,
1684 784, 784, 784, 784, 784, 784, 784, 784, 784, 784,
1685 784, 784, 784, 784, 784, 784, 784, 785, 785, 785,
1686 785, 785, 785, 785, 785, 785, 785, 785, 785, 785,
1687 785, 785, 785, 785, 785, 785, 786, 786, 786, 786,
1688 786, 786, 786, 786, 786, 786, 786, 786, 786, 786,
1689 786, 786, 786, 786, 786, 705, 705, 705, 705, 705,
1690 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1691 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1693 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1694 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1695 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1696 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1697 705, 705, 705, 705, 705, 705, 705, 705, 705, 705,
1701 extern int yy_flex_debug;
1702 int yy_flex_debug = 0;
1704 static yy_state_type *yy_state_buf=0, *yy_state_ptr=0;
1705 static char *yy_full_match;
1707 static int yy_looking_for_trail_begin = 0;
1708 static int yy_full_lp;
1709 static int *yy_full_state;
1710 #define YY_TRAILING_MASK 0x2000
1711 #define YY_TRAILING_HEAD_MASK 0x4000
1714 *yy_cp = (yy_hold_char); /* undo effects of setting up yytext */ \
1715 yy_cp = (yy_full_match); /* restore poss. backed-over text */ \
1716 (yy_lp) = (yy_full_lp); /* restore orig. accepting pos. */ \
1717 (yy_state_ptr) = (yy_full_state); /* restore orig. state */ \
1718 yy_current_state = *(yy_state_ptr); /* restore curr. state */ \
1723 #define yymore() yymore_used_but_not_detected
1724 #define YY_MORE_ADJ 0
1725 #define YY_RESTORE_YY_MORE_OFFSET
1730 * parser.l -- lex parser of algebraic chess moves for XBoard
1732 * Copyright 1991 by Digital Equipment Corporation, Maynard,
1735 * Enhancements Copyright 1992-2001, 2002, 2003, 2004, 2005,
1736 * 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
1738 * The following terms apply to Digital Equipment Corporation's copyright
1739 * interest in XBoard:
1740 * ------------------------------------------------------------------------
1741 * All Rights Reserved
1743 * Permission to use, copy, modify, and distribute this software and its
1744 * documentation for any purpose and without fee is hereby granted,
1745 * provided that the above copyright notice appear in all copies and that
1746 * both that copyright notice and this permission notice appear in
1747 * supporting documentation, and that the name of Digital not be
1748 * used in advertising or publicity pertaining to distribution of the
1749 * software without specific, written prior permission.
1751 * DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
1752 * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
1753 * DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
1754 * ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
1755 * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
1756 * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
1758 * ------------------------------------------------------------------------
1760 * The following terms apply to the enhanced version of XBoard
1761 * distributed by the Free Software Foundation:
1762 * ------------------------------------------------------------------------
1764 * GNU XBoard is free software: you can redistribute it and/or modify
1765 * it under the terms of the GNU General Public License as published by
1766 * the Free Software Foundation, either version 3 of the License, or (at
1767 * your option) any later version.
1769 * GNU XBoard is distributed in the hope that it will be useful, but
1770 * WITHOUT ANY WARRANTY; without even the implied warranty of
1771 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
1772 * General Public License for more details.
1774 * You should have received a copy of the GNU General Public License
1775 * along with this program. If not, see http://www.gnu.org/licenses/.
1777 *------------------------------------------------------------------------
1778 ** See the file ChangeLog for a revision history. */
1780 /* This parser handles all forms of promotion.
1781 * The parser resolves ambiguous moves by searching and check-testing.
1782 * It also parses comments of the form [anything] or (anything).
1784 * [HGM] Parser extensively modified for bigger boards, Shogi-like syntax,
1785 * and unknow pieces. All pieces are now mandatory upper case, but can be
1786 * any letter A-Z. Files must be lower case (as before), but can run upto 'l'.
1787 * Ranks can be 0-9. The parser returns 0 for off-board files and ranks.
1788 * For an unknown piece (as mover or promotion piece) it returns
1789 * IllegalMove, like it does when the piece doesn't match.
1790 * Promotions can now also be appended Shogi-style, a bare '=' or '+',
1791 * and this is then returned as promotion character. The piece indicator
1792 * can be prefixed by a '+' to indicate it is a promoted piece.
1797 #define NO_CONSTRAINT -1
1800 #define UNPUT_BUF_SIZE YYLMAX
1803 /* yytext is probably a char*, but could be a char[]. yy_text is set
1804 in YY_DECL below, because if yytext is a char*, its value is not
1807 #else /*!FLEX_SCANNER*/
1808 /* yytext is definitely a char[], so yy_text can be set here, statically. */
1809 char *yy_text = (char *) yytext;
1814 /* [AP] use prototypes in function declarations */
1815 #define YY_USE_PROTOS
1817 #ifdef YY_USE_PROTOS
1818 #define YY_PROTO(proto) proto
1820 #define YY_PROTO(proto) ()
1822 /* end of [AP] fix */
1825 #define YY_INPUT(buf, result, max_size) my_yy_input(buf, &result, max_size)
1828 int _yylex YY_PROTO((void)); \
1829 int yylex YY_PROTO((void)) \
1831 int result = _yylex(); \
1832 yy_text = (char *) yytext; \
1835 int _yylex YY_PROTO((void))
1843 /* The includes must be here, below the #undef input */
1848 # include <stdlib.h>
1849 # include <string.h>
1850 #else /* not STDC_HEADERS */
1852 # include <string.h>
1853 # else /* not HAVE_STRING_H */
1854 # include <strings.h>
1855 # endif /* not HAVE_STRING_H */
1856 #endif /* not STDC_HEADERS */
1859 # include <unistd.h>
1862 #if defined(_amigados)
1865 # include <fcntl.h> /* isatty() prototype */
1866 # endif /* HAVE_FCNTL_H */
1867 #endif /* defined(_amigados) */
1870 #include "backend.h"
1871 #include "frontend.h"
1875 extern int PosFlags P((int));
1877 extern Board boards[MAX_MOVES];
1879 int yyskipmoves = FALSE;
1880 char currentMoveString[YYLMAX];
1881 #ifndef FLEX_SCANNER
1882 char unputBuffer[UNPUT_BUF_SIZE];
1887 void my_yy_input P((char *buf, int *result, int max_size));
1888 #else /*!FLEX_SCANNER*/
1889 static int input P((void));
1890 static void output P((int ch));
1891 static void unput P((int ch));
1892 int yylook P((void));
1893 int yyback P((int *, int));
1896 int yywrap P((void));
1897 extern void CopyBoard P((Board to, Board from));
1899 #line 1900 "parser.c"
1903 #ifndef YY_NO_UNISTD_H
1904 /* Special case for "unistd.h", since it is non-ANSI. We include it way
1905 * down here because we want the user's section 1 to have been scanned first.
1906 * The user has a chance to override it with an option.
1911 #ifndef YY_EXTRA_TYPE
1912 #define YY_EXTRA_TYPE void *
1915 static int yy_init_globals (void );
1917 /* Macros after this point can all be overridden by user definitions in
1921 #ifndef YY_SKIP_YYWRAP
1923 extern "C" int yywrap (void );
1925 extern int yywrap (void );
1929 static void yyunput (int c,char *buf_ptr );
1932 static void yy_flex_strncpy (char *,yyconst char *,int );
1935 #ifdef YY_NEED_STRLEN
1936 static int yy_flex_strlen (yyconst char * );
1942 static int yyinput (void );
1944 static int input (void );
1949 /* Amount of stuff to slurp up with each read. */
1950 #ifndef YY_READ_BUF_SIZE
1951 #define YY_READ_BUF_SIZE 8192
1954 /* Copy whatever the last rule matched to the standard output. */
1956 /* This used to be an fputs(), but since the string might contain NUL's,
1957 * we now use fwrite().
1959 #define ECHO fwrite( yytext, yyleng, 1, yyout )
1962 /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
1963 * is returned in "result".
1966 #define YY_INPUT(buf,result,max_size) \
1967 if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
1971 for ( n = 0; n < max_size && \
1972 (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
1973 buf[n] = (char) c; \
1975 buf[n++] = (char) c; \
1976 if ( c == EOF && ferror( yyin ) ) \
1977 YY_FATAL_ERROR( "input in flex scanner failed" ); \
1983 while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \
1985 if( errno != EINTR) \
1987 YY_FATAL_ERROR( "input in flex scanner failed" ); \
1998 /* No semi-colon after return; correct usage is to write "yyterminate();" -
1999 * we don't want an extra ';' after the "return" because that will cause
2000 * some compilers to complain about unreachable statements.
2003 #define yyterminate() return YY_NULL
2006 /* Number of entries by which start-condition stack grows. */
2007 #ifndef YY_START_STACK_INCR
2008 #define YY_START_STACK_INCR 25
2011 /* Report a fatal error. */
2012 #ifndef YY_FATAL_ERROR
2013 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
2016 /* end tables serialization structures and prototypes */
2018 /* Default declaration of generated scanner - a define so the user can
2019 * easily add parameters.
2022 #define YY_DECL_IS_OURS 1
2024 extern int yylex (void);
2026 #define YY_DECL int yylex (void)
2027 #endif /* !YY_DECL */
2029 /* Code executed at the beginning of each rule, after yytext and yyleng
2032 #ifndef YY_USER_ACTION
2033 #define YY_USER_ACTION
2036 /* Code executed at the end of each rule. */
2038 #define YY_BREAK break;
2041 #define YY_RULE_SETUP \
2043 YY_CURRENT_BUFFER_LVALUE->yy_at_bol = \
2044 (yytext[yyleng - 1] == '\n'); \
2047 /** The main scanner function which does all the work.
2051 register yy_state_type yy_current_state;
2052 register char *yy_cp, *yy_bp;
2053 register int yy_act;
2055 #line 179 "parser.l"
2058 #line 2059 "parser.c"
2068 /* Create the reject buffer large enough to save one state per allowed character. */
2069 if ( ! (yy_state_buf) )
2070 (yy_state_buf) = (yy_state_type *)yyalloc(YY_STATE_BUF_SIZE );
2071 if ( ! (yy_state_buf) )
2072 YY_FATAL_ERROR( "out of dynamic memory in yylex()" );
2075 (yy_start) = 1; /* first start state */
2083 if ( ! YY_CURRENT_BUFFER ) {
2084 yyensure_buffer_stack ();
2085 YY_CURRENT_BUFFER_LVALUE =
2086 yy_create_buffer(yyin,YY_BUF_SIZE );
2089 yy_load_buffer_state( );
2092 while ( 1 ) /* loops until end-of-file is reached */
2094 yy_cp = (yy_c_buf_p);
2096 /* Support of yytext. */
2097 *yy_cp = (yy_hold_char);
2099 /* yy_bp points to the position in yy_ch_buf of the start of
2104 yy_current_state = (yy_start);
2105 yy_current_state += YY_AT_BOL();
2107 (yy_state_ptr) = (yy_state_buf);
2108 *(yy_state_ptr)++ = yy_current_state;
2113 register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
2114 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
2116 yy_current_state = (int) yy_def[yy_current_state];
2117 if ( yy_current_state >= 706 )
2118 yy_c = yy_meta[(unsigned int) yy_c];
2120 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
2121 *(yy_state_ptr)++ = yy_current_state;
2124 while ( yy_base[yy_current_state] != 4176 );
2127 yy_current_state = *--(yy_state_ptr);
2128 (yy_lp) = yy_accept[yy_current_state];
2129 find_rule: /* we branch to this label when backing up */
2130 for ( ; ; ) /* until we find what rule we matched */
2132 if ( (yy_lp) && (yy_lp) < yy_accept[yy_current_state + 1] )
2134 yy_act = yy_acclist[(yy_lp)];
2135 if ( yy_act & YY_TRAILING_HEAD_MASK ||
2136 (yy_looking_for_trail_begin) )
2138 if ( yy_act == (yy_looking_for_trail_begin) )
2140 (yy_looking_for_trail_begin) = 0;
2141 yy_act &= ~YY_TRAILING_HEAD_MASK;
2145 else if ( yy_act & YY_TRAILING_MASK )
2147 (yy_looking_for_trail_begin) = yy_act & ~YY_TRAILING_MASK;
2148 (yy_looking_for_trail_begin) |= YY_TRAILING_HEAD_MASK;
2152 (yy_full_match) = yy_cp;
2153 (yy_full_state) = (yy_state_ptr);
2154 (yy_full_lp) = (yy_lp);
2161 yy_current_state = *--(yy_state_ptr);
2162 (yy_lp) = yy_accept[yy_current_state];
2165 YY_DO_BEFORE_ACTION;
2167 do_action: /* This label is used only to access EOF actions. */
2170 { /* beginning of action switch */
2173 #line 181 "parser.l"
2176 * Fully-qualified algebraic move, possibly with promotion
2178 int skip1 = 0, skip2 = 0, skip3 = 0, promoted = 0;
2183 if (yyskipmoves) return (int) AmbiguousMove; /* not disambiguated */
2185 if (yytext[0] == '+') skip1 = skip3 = promoted = 1; /* [HGM] Shogi promoted */
2188 if (yytext[1+skip1] == '/') skip1++;
2190 /* remove the [xX:-] */
2191 if ((yytext[3+skip1] == 'x') || (yytext[3+skip1] == 'X') ||
2192 (yytext[3+skip1] == '-') || (yytext[3+skip1] == ':')) skip2 = 1;
2194 currentMoveString[0] = yytext[1+skip1];
2195 currentMoveString[1] = yytext[2+skip1];
2196 currentMoveString[2] = yytext[3+skip1+skip2];
2197 currentMoveString[3] = yytext[4+skip1+skip2];
2198 currentMoveString[4] = NULLCHAR;
2200 if (appData.debugMode) {
2201 fprintf(debugFP, "Parser Qa1b2: yyleng=%d\n",
2205 if (yyleng-skip1-skip2 > 5) { char c;
2206 if (yytext[yyleng-1] == ')') {
2207 c = currentMoveString[4] = ToLower(yytext[yyleng-2]);
2209 c = currentMoveString[4] = ToLower(yytext[yyleng-1]);
2211 currentMoveString[5] = NULLCHAR;
2212 if(c != '=' && c != '+' && CharToPiece(c) == EmptySquare)
2213 return IllegalMove; /* [HGM] promotion to invalid piece */
2216 if (appData.debugMode) {
2217 fprintf(debugFP, "parser: %s\n", currentMoveString);
2219 /* [HGM] do not allow values beyond board size */
2220 if(currentMoveString[1] - ONE >= BOARD_HEIGHT ||
2221 currentMoveString[1] - ONE < 0 ||
2222 currentMoveString[0] - AAA >= BOARD_RGHT ||
2223 currentMoveString[3] - ONE >= BOARD_HEIGHT ||
2224 currentMoveString[3] - ONE < 0 ||
2225 currentMoveString[2] - AAA >= BOARD_RGHT ||
2226 currentMoveString[0] - AAA < BOARD_LEFT ||
2227 currentMoveString[2] - AAA < BOARD_LEFT )
2228 return ImpossibleMove;
2230 piece = boards[yyboardindex]
2231 [currentMoveString[1] - ONE][currentMoveString[0] - AAA];
2232 if(PieceToChar(piece) == '+' && appData.icsActive) promoted = 1, yytext[skip3] = PieceToChar(DEMOTED piece); // trust ICS
2233 if(promoted) piece = (ChessSquare) (DEMOTED piece);
2234 c = PieceToChar(piece);
2235 if(c == '~') c = PieceToChar((ChessSquare) (DEMOTED piece));
2236 if (ToLower(yytext[skip3]) != ToLower(c))
2237 return (int) IllegalMove;
2239 result = LegalityTest(boards[yyboardindex],
2240 PosFlags(yyboardindex)&~F_MANDATORY_CAPTURE, // [HGM] losers: might think we can e.p.!
2241 currentMoveString[1] - ONE,
2242 currentMoveString[0] - AAA,
2243 currentMoveString[3] - ONE,
2244 currentMoveString[2] - AAA,
2245 currentMoveString[4]);
2247 if (currentMoveString[4] == NULLCHAR &&
2248 (result == WhitePromotion || result == BlackPromotion)) {
2249 if(gameInfo.variant == VariantCourier || gameInfo.variant == VariantShatranj)
2250 currentMoveString[4] = PieceToChar(BlackFerz);
2251 else if(gameInfo.variant == VariantGreat)
2252 currentMoveString[4] = PieceToChar(BlackMan);
2253 else if(gameInfo.variant == VariantShogi)
2254 currentMoveString[4] = '+';
2256 currentMoveString[4] = PieceToChar(BlackQueen);
2257 currentMoveString[5] = NULLCHAR;
2260 return (int) result;
2265 #line 270 "parser.l"
2268 * Simple algebraic move, possibly with promotion
2269 * [HGM] Engine moves are received in this format, with lower-case promoChar!
2274 if (yyskipmoves) return (int) AmbiguousMove; /* not disambiguated */
2276 /* remove the [xX:-] */
2277 if ((yytext[2] == 'x') || (yytext[2] == 'X') ||
2278 (yytext[2] == '-') || (yytext[2] == ':')) skip = 1;
2280 currentMoveString[0] = yytext[0];
2281 currentMoveString[1] = yytext[1];
2282 currentMoveString[2] = yytext[2+skip];
2283 currentMoveString[3] = yytext[3+skip];
2284 currentMoveString[4] = NULLCHAR;
2286 if (yyleng-skip > 4) { char c;
2287 if (yytext[yyleng-1] == ')') {
2288 c = currentMoveString[4] = ToLower(yytext[yyleng-2]);
2290 c = currentMoveString[4] = ToLower(yytext[yyleng-1]);
2292 currentMoveString[5] = NULLCHAR;
2293 if(c != '=' && c != '+' && CharToPiece(c) == EmptySquare)
2297 /* [HGM] do not allow values beyond board size */
2298 if(currentMoveString[1] - ONE >= BOARD_HEIGHT ||
2299 currentMoveString[1] - ONE < 0 ||
2300 currentMoveString[0] - AAA >= BOARD_RGHT ||
2301 currentMoveString[3] - ONE >= BOARD_HEIGHT ||
2302 currentMoveString[3] - ONE < 0 ||
2303 currentMoveString[2] - AAA >= BOARD_RGHT ||
2304 currentMoveString[0] - AAA < BOARD_LEFT ||
2305 currentMoveString[2] - AAA < BOARD_LEFT )
2306 return ImpossibleMove;
2308 result = LegalityTest(boards[yyboardindex],
2309 PosFlags(yyboardindex)&~F_MANDATORY_CAPTURE, // [HGM] losers: might think we can e.p.!
2310 currentMoveString[1] - ONE,
2311 currentMoveString[0] - AAA,
2312 currentMoveString[3] - ONE,
2313 currentMoveString[2] - AAA,
2314 currentMoveString[4]);
2316 if (currentMoveString[4] == NULLCHAR) {
2317 if(result == WhitePromotion || result == BlackPromotion) {
2318 if(gameInfo.variant == VariantShatranj || gameInfo.variant == VariantCourier || gameInfo.variant == VariantMakruk)
2319 currentMoveString[4] = PieceToChar(BlackFerz);
2320 else if(gameInfo.variant == VariantGreat)
2321 currentMoveString[4] = PieceToChar(BlackMan);
2322 else if(gameInfo.variant == VariantShogi)
2323 currentMoveString[4] = '+'; // Queen might not be defined in mini variants!
2325 currentMoveString[4] = PieceToChar(BlackQueen);
2326 currentMoveString[5] = NULLCHAR;
2328 } else if(appData.testLegality && // strip off unnecessary and false promo characters
2329 !(result == WhitePromotion || result == BlackPromotion ||
2330 result == WhiteNonPromotion || result == BlackNonPromotion)) currentMoveString[4] = NULLCHAR;
2332 return (int) result;
2337 #line 339 "parser.l"
2340 * Simple algebraic move, in capitals
2341 * [HGM] Engine moves are received in this format, with lower-case promoChar!
2346 if (yyskipmoves) return (int) AmbiguousMove; /* not disambiguated */
2348 /* remove the [xX:-] */
2349 if ((yytext[2] == 'x') || (yytext[2] == 'X') ||
2350 (yytext[2] == '-') || (yytext[2] == ':')) skip = 1;
2352 currentMoveString[0] = yytext[0]+32;
2353 currentMoveString[1] = yytext[1];
2354 currentMoveString[2] = yytext[2+skip]+32;
2355 currentMoveString[3] = yytext[3+skip];
2356 currentMoveString[4] = NULLCHAR;
2358 /* [HGM] do not allow values beyond board size */
2359 if(currentMoveString[1] - ONE >= BOARD_HEIGHT ||
2360 currentMoveString[1] - ONE < 0 ||
2361 currentMoveString[0] - AAA >= BOARD_RGHT ||
2362 currentMoveString[3] - ONE >= BOARD_HEIGHT ||
2363 currentMoveString[3] - ONE < 0 ||
2364 currentMoveString[2] - AAA >= BOARD_RGHT ||
2365 currentMoveString[0] - AAA < BOARD_LEFT ||
2366 currentMoveString[2] - AAA < BOARD_LEFT )
2367 return ImpossibleMove;
2369 result = LegalityTest(boards[yyboardindex],
2370 PosFlags(yyboardindex)&~F_MANDATORY_CAPTURE, // [HGM] losers: might think we can e.p.!
2371 currentMoveString[1] - ONE,
2372 currentMoveString[0] - AAA,
2373 currentMoveString[3] - ONE,
2374 currentMoveString[2] - AAA,
2375 currentMoveString[4]);
2377 if (currentMoveString[4] == NULLCHAR &&
2378 (result == WhitePromotion || result == BlackPromotion)) {
2379 if(gameInfo.variant == VariantShatranj || gameInfo.variant == VariantCourier || gameInfo.variant == VariantMakruk)
2380 currentMoveString[4] = PieceToChar(BlackFerz);
2381 else if(gameInfo.variant == VariantGreat)
2382 currentMoveString[4] = PieceToChar(BlackMan);
2384 currentMoveString[4] = PieceToChar(BlackQueen);
2385 currentMoveString[5] = NULLCHAR;
2388 return (int) result;
2393 #line 392 "parser.l"
2396 * Pawn move, possibly with promotion
2398 DisambiguateClosure cl;
2399 int skip = 0; char c;
2401 if (yyskipmoves) return (int) AmbiguousMove; /* not disambiguated */
2403 /* remove the =() */
2404 if (yytext[2] == '=' && yytext[3] != NULLCHAR) skip++;
2405 if (yytext[2+skip] == '(') skip++;
2407 cl.pieceIn = WhiteOnMove(yyboardindex) ? WhitePawn : BlackPawn;
2409 cl.ffIn = yytext[0] - AAA;
2410 cl.rtIn = yytext[1] - ONE;
2411 cl.ftIn = yytext[0] - AAA;
2412 c = cl.promoCharIn = ToLower(yytext[2+skip]);
2414 /* [HGM] do not allow values beyond board size */
2415 if(cl.rtIn >= BOARD_HEIGHT ||
2417 cl.ffIn >= BOARD_RGHT ||
2418 cl.ftIn < BOARD_LEFT )
2419 return ImpossibleMove;
2421 if(c != '=' && c != '+' && c != NULLCHAR && CharToPiece(c) == EmptySquare)
2425 Disambiguate(boards[yyboardindex], PosFlags(yyboardindex), &cl);
2427 currentMoveString[0] = cl.ff + AAA;
2428 currentMoveString[1] = cl.rf + ONE;
2429 currentMoveString[2] = cl.ft + AAA;
2430 currentMoveString[3] = cl.rt + ONE;
2431 currentMoveString[4] = cl.promoChar;
2432 currentMoveString[5] = NULLCHAR;
2434 return (int) cl.kind;
2439 #line 436 "parser.l"
2442 * Pawn capture, possibly with promotion, possibly ambiguous
2444 DisambiguateClosure cl;
2445 int skip1 = 0, skip2 = 0; char c;
2447 if (yyskipmoves) return (int) AmbiguousMove; /* not disambiguated */
2449 /* remove trailing ep or e.p. (nonstandard PGN) */
2450 if (yytext[yyleng-1] == 'p') {
2452 yytext[yyleng] = NULLCHAR;
2453 } else if (yytext[yyleng-1] == '.') {
2455 yytext[yyleng] = NULLCHAR;
2458 /* remove the [xX:-] and =() */
2459 if ((yytext[1] == 'x') || (yytext[1] == 'X')
2460 || (yytext[1] == ':') || (yytext[1] == '-')) skip1 = 1;
2461 if (yytext[2+skip1] == '=' && yytext[3+skip1] != NULLCHAR) skip2++;
2462 if (yytext[2+skip1+skip2] == '(') skip2++;
2464 cl.pieceIn = WhiteOnMove(yyboardindex) ? WhitePawn : BlackPawn;
2466 cl.ffIn = yytext[0] - AAA;
2468 cl.ftIn = yytext[1+skip1] - AAA;
2469 c = cl.promoCharIn = yytext[2+skip1+skip2];
2471 /* [HGM] do not allow values beyond board size */
2472 if(cl.ffIn >= BOARD_RGHT ||
2473 cl.ffIn < BOARD_LEFT ||
2474 cl.ftIn >= BOARD_RGHT ||
2475 cl.ftIn < BOARD_LEFT )
2476 return ImpossibleMove;
2478 if(c != '=' && c != '+' && c != NULLCHAR && CharToPiece(c) == EmptySquare)
2481 Disambiguate(boards[yyboardindex], PosFlags(yyboardindex), &cl);
2483 currentMoveString[0] = cl.ff + AAA;
2484 currentMoveString[1] = cl.rf + ONE;
2485 currentMoveString[2] = cl.ft + AAA;
2486 currentMoveString[3] = cl.rt + ONE;
2487 currentMoveString[4] = cl.promoChar;
2488 currentMoveString[5] = NULLCHAR;
2490 return (int) cl.kind;
2495 #line 489 "parser.l"
2498 * unambiguously abbreviated Pawn capture, possibly with promotion
2501 ChessMove result; char c;
2503 if (yyskipmoves) return (int) AmbiguousMove; /* not disambiguated */
2505 /* remove trailing ep or e.p. (nonstandard PGN) */
2506 if (yytext[yyleng-1] == 'p') {
2508 yytext[yyleng] = NULLCHAR;
2509 } else if (yytext[yyleng-1] == '.') {
2511 yytext[yyleng] = NULLCHAR;
2514 /* remove the [xX:-] */
2515 if ((yytext[1] == 'x') || (yytext[1] == 'X')
2516 || (yytext[1] == ':') || (yytext[1] == '-')) skip = 1;
2518 currentMoveString[0] = yytext[0];
2519 currentMoveString[2] = yytext[1+skip];
2520 currentMoveString[3] = yytext[2+skip];
2522 /* [HGM] do not allow values beyond board size */
2523 if(currentMoveString[0] - AAA >= BOARD_RGHT ||
2524 currentMoveString[3] - ONE >= BOARD_HEIGHT ||
2525 currentMoveString[3] - ONE < 0 ||
2526 currentMoveString[2] - AAA >= BOARD_RGHT ||
2527 currentMoveString[0] - AAA < BOARD_LEFT ||
2528 currentMoveString[2] - AAA < BOARD_LEFT )
2529 return ImpossibleMove;
2531 if (gameInfo.variant == VariantXiangqi && /* [HGM] In Xiangqi rank stays same */
2532 currentMoveString[0] != currentMoveString[2] ) {
2533 currentMoveString[1] = yytext[2+skip];
2535 if (WhiteOnMove(yyboardindex)) {
2536 if (yytext[2+skip] == ONE) return (int) ImpossibleMove;
2537 currentMoveString[1] = yytext[2+skip] - 1;
2538 if(boards[yyboardindex][currentMoveString[1]-ONE][currentMoveString[0]-AAA] != WhitePawn)
2539 return ImpossibleMove;
2541 currentMoveString[1] = currentMoveString[3] + 1;
2542 if (currentMoveString[3] == ONE+BOARD_HEIGHT-1) return (int) ImpossibleMove;
2543 if(boards[yyboardindex][currentMoveString[1]-ONE][currentMoveString[0]-AAA] != BlackPawn)
2544 return ImpossibleMove;
2546 if (yyleng-skip > 3) {
2547 if (yytext[yyleng-1] == ')')
2548 c = currentMoveString[4] = ToLower(yytext[yyleng-2]);
2550 c = currentMoveString[4] = ToLower(yytext[yyleng-1]);
2551 currentMoveString[5] = NULLCHAR;
2552 if(c != '=' && c != '+' && CharToPiece(c) == EmptySquare)
2555 currentMoveString[4] = NULLCHAR;
2558 result = LegalityTest(boards[yyboardindex],
2559 PosFlags(yyboardindex)&~F_MANDATORY_CAPTURE, // [HGM] losers: might think we can e.p.!
2560 currentMoveString[1] - ONE,
2561 currentMoveString[0] - AAA,
2562 currentMoveString[3] - ONE,
2563 currentMoveString[2] - AAA,
2564 currentMoveString[4]);
2566 if (currentMoveString[4] == NULLCHAR &&
2567 (result == WhitePromotion || result == BlackPromotion)) {
2568 currentMoveString[4] = PieceToChar(BlackQueen);
2569 // [HGM] shatranj: take care of variants without Queen
2570 if(gameInfo.variant == VariantShatranj || gameInfo.variant == VariantCourier || gameInfo.variant == VariantMakruk)
2571 currentMoveString[4] = PieceToChar(BlackFerz);
2572 if(gameInfo.variant == VariantGreat)
2573 currentMoveString[4] = PieceToChar(BlackMan);
2574 currentMoveString[5] = NULLCHAR;
2577 if (result != IllegalMove) return (int) result;
2579 /* Special case: improperly written en passant capture */
2580 if (WhiteOnMove(yyboardindex)) {
2581 if (currentMoveString[3] == '5') {
2582 currentMoveString[1] = '5';
2583 currentMoveString[3] = '6';
2585 return (int) IllegalMove;
2588 if (currentMoveString[3] == '4') {
2589 currentMoveString[1] = '4';
2590 currentMoveString[3] = '3';
2592 return (int) IllegalMove;
2596 result = LegalityTest(boards[yyboardindex],
2597 PosFlags(yyboardindex)&~F_MANDATORY_CAPTURE, // [HGM] losers: might think we can e.p.!
2598 currentMoveString[1] - ONE,
2599 currentMoveString[0] - AAA,
2600 currentMoveString[3] - ONE,
2601 currentMoveString[2] - AAA,
2602 currentMoveString[4]);
2604 if (result == WhiteCapturesEnPassant || result == BlackCapturesEnPassant)
2605 return (int) result;
2607 return (int) IllegalMove;
2612 #line 603 "parser.l"
2615 * piece move, possibly ambiguous
2617 DisambiguateClosure cl;
2618 int skip = 0, skip2 = 0, promoted = 0;
2620 if (yyskipmoves) return (int) AmbiguousMove; /* not disambiguated */
2622 if(yytext[0] == '+') promoted = skip = skip2 = 1;
2624 /* remove the [xX:-] */
2625 if ((yytext[1+skip] == 'x') || (yytext[1+skip] == 'X')
2626 || (yytext[1+skip] == ':') || (yytext[1+skip] == '-')) skip++;
2628 if (WhiteOnMove(yyboardindex)) {
2629 cl.pieceIn = CharToPiece(ToUpper(yytext[skip2]));
2631 cl.pieceIn = CharToPiece(ToLower(yytext[skip2]));
2633 if(promoted) cl.pieceIn = (ChessSquare) (PROMOTED cl.pieceIn);
2637 cl.rtIn = yytext[2+skip] - ONE;
2638 cl.ftIn = yytext[1+skip] - AAA;
2639 cl.promoCharIn = NULLCHAR;
2641 if(yyleng-skip > 3) /* [HGM] can have Shogi-style promotion */
2642 cl.promoCharIn = yytext[yyleng-1];
2644 if (appData.debugMode) {
2645 fprintf(debugFP, "Parser Qa1: yyleng=%d, %d(%d,%d)-(%d,%d) = %d (%c)\n",
2647 cl.pieceIn,cl.ffIn,cl.rfIn,cl.ftIn,cl.rtIn,cl.promoCharIn,cl.promoCharIn?cl.promoCharIn:' ');
2650 /* [HGM] but do not allow values beyond board size */
2651 if(cl.rtIn >= BOARD_HEIGHT ||
2653 cl.ftIn >= BOARD_RGHT ||
2654 cl.ftIn < BOARD_LEFT )
2655 return ImpossibleMove;
2657 Disambiguate(boards[yyboardindex], PosFlags(yyboardindex), &cl);
2659 currentMoveString[0] = cl.ff + AAA;
2660 currentMoveString[1] = cl.rf + ONE;
2661 currentMoveString[2] = cl.ft + AAA;
2662 currentMoveString[3] = cl.rt + ONE;
2663 currentMoveString[4] = cl.promoChar;
2664 currentMoveString[5] = NULLCHAR;
2666 return (int) cl.kind;
2671 #line 659 "parser.l"
2674 * piece move with rank or file disambiguator
2676 DisambiguateClosure cl;
2677 int skip = 0, skip2 = 0; int promoted=0;
2679 if (yyskipmoves) return (int) AmbiguousMove; /* not disambiguated */
2681 if(yytext[0]=='+') promoted = skip = skip2 = 1;
2683 /* remove the [xX:-] */
2684 if ((yytext[2+skip] == 'x') || (yytext[2+skip] == 'X')
2685 || (yytext[2+skip] == ':') || (yytext[2+skip] == '-')) skip++;
2687 if (WhiteOnMove(yyboardindex)) {
2688 cl.pieceIn = CharToPiece(ToUpper(yytext[skip2]));
2690 cl.pieceIn = CharToPiece(ToLower(yytext[skip2]));
2692 if(promoted) cl.pieceIn = (ChessSquare) (PROMOTED cl.pieceIn);
2694 if (isalpha(yytext[1+skip2])) {
2696 cl.ffIn = yytext[1+skip2] - AAA;
2698 if(cl.ffIn >= BOARD_RGHT ||
2699 cl.ffIn < BOARD_LEFT ) return 0;
2701 cl.rfIn = yytext[1+skip2] - ONE;
2703 if(cl.rfIn >= BOARD_HEIGHT ||
2704 cl.rfIn < 0) return 0;
2706 cl.rtIn = yytext[3+skip] - ONE;
2707 cl.ftIn = yytext[2+skip] - AAA;
2708 cl.promoCharIn = NULLCHAR;
2710 if(yyleng-skip > 4) /* [HGM] can have Shogi-style promotion */
2711 cl.promoCharIn = yytext[yyleng-1];
2713 /* [HGM] do not allow values beyond board size */
2714 if(cl.rtIn >= BOARD_HEIGHT ||
2716 cl.ftIn >= BOARD_RGHT ||
2717 cl.ftIn < BOARD_LEFT )
2718 return ImpossibleMove;
2720 Disambiguate(boards[yyboardindex], PosFlags(yyboardindex), &cl);
2722 currentMoveString[0] = cl.ff + AAA;
2723 currentMoveString[1] = cl.rf + ONE;
2724 currentMoveString[2] = cl.ft + AAA;
2725 currentMoveString[3] = cl.rt + ONE;
2726 currentMoveString[4] = cl.promoChar;
2727 currentMoveString[5] = NULLCHAR;
2729 return (int) cl.kind;
2734 #line 719 "parser.l"
2738 if (yyskipmoves) return (int) AmbiguousMove; /* not disambiguated */
2740 /* [HGM] all squares referenced to board edges in stead of absolute */
2741 if (WhiteOnMove(yyboardindex)) {
2742 if (boards[yyboardindex][0][(BOARD_WIDTH-1)>>1] == WhiteKing) {
2743 /* ICS wild castling */
2745 ff = (BOARD_WIDTH-1)>>1;
2750 ff = BOARD_WIDTH>>1;
2755 if (boards[yyboardindex][BOARD_HEIGHT-1][(BOARD_WIDTH-1)>>1] == BlackKing) {
2756 /* ICS wild castling */
2757 rf = BOARD_HEIGHT-1;
2758 ff = (BOARD_WIDTH-1)>>1;
2759 rt = BOARD_HEIGHT-1;
2762 rf = BOARD_HEIGHT-1;
2763 ff = BOARD_WIDTH>>1;
2764 rt = BOARD_HEIGHT-1;
2768 if(PosFlags(0) & F_FRC_TYPE_CASTLING) {
2770 if (WhiteOnMove(yyboardindex)) {
2771 ff = initialRights[2];
2772 ft = initialRights[1];
2774 ff = initialRights[5];
2775 ft = initialRights[4];
2777 if (appData.debugMode)
2779 fprintf(debugFP, "Parser FRC long %d %d\n", ff, ft);
2781 if(ff < 0 || ft < 0) return 0;
2783 sprintf(currentMoveString, "%c%c%c%c",ff+AAA,rf+ONE,ft+AAA,rt+ONE);
2784 if (appData.debugMode) {
2785 fprintf(debugFP, "long castling %d %d\n", ff, ft);
2787 return (int) LegalityTest(boards[yyboardindex],
2788 PosFlags(yyboardindex)&~F_MANDATORY_CAPTURE, // [HGM] losers: e.p.!
2789 rf, ff, rt, ft, NULLCHAR);
2794 #line 776 "parser.l"
2798 if (yyskipmoves) return (int) AmbiguousMove; /* not disambiguated */
2800 if (WhiteOnMove(yyboardindex)) {
2801 if (boards[yyboardindex][0][(BOARD_WIDTH-1)>>1] == WhiteKing) {
2802 /* ICS wild castling */
2804 ff = (BOARD_WIDTH-1)>>1;
2809 ff = BOARD_WIDTH>>1;
2814 if (boards[yyboardindex][BOARD_HEIGHT-1][(BOARD_WIDTH-1)>>1] == BlackKing) {
2815 /* ICS wild castling */
2816 rf = BOARD_HEIGHT-1;
2817 ff = (BOARD_WIDTH-1)>>1;
2818 rt = BOARD_HEIGHT-1;
2821 rf = BOARD_HEIGHT-1;
2822 ff = BOARD_WIDTH>>1;
2823 rt = BOARD_HEIGHT-1;
2827 if(PosFlags(0) & F_FRC_TYPE_CASTLING) {
2828 if (WhiteOnMove(yyboardindex)) {
2829 ff = initialRights[2];
2830 ft = initialRights[0];
2832 ff = initialRights[5];
2833 ft = initialRights[3];
2835 if (appData.debugMode) {
2836 fprintf(debugFP, "Parser FRC short %d %d\n", ff, ft);
2838 if(ff < 0 || ft < 0) return 0;
2840 sprintf(currentMoveString, "%c%c%c%c",ff+AAA,rf+ONE,ft+AAA,rt+ONE);
2841 if (appData.debugMode) {
2842 fprintf(debugFP, "short castling %d %d\n", ff, ft);
2845 return (int) LegalityTest(boards[yyboardindex],
2846 PosFlags(yyboardindex)&~F_MANDATORY_CAPTURE, // [HGM] losers: e.p.!
2847 rf, ff, rt, ft, NULLCHAR);
2852 #line 831 "parser.l"
2854 /* Bughouse piece drop. */
2855 currentMoveString[1] = '@';
2856 currentMoveString[2] = yytext[2];
2857 currentMoveString[3] = yytext[3];
2858 currentMoveString[4] = NULLCHAR;
2860 if (appData.debugMode) {
2861 fprintf(debugFP, "Drop: %s\n", currentMoveString);
2863 /* [HGM] do not allow values beyond board size */
2864 if(currentMoveString[3] - ONE >= BOARD_HEIGHT ||
2865 currentMoveString[2] - AAA >= BOARD_WIDTH )
2866 return ImpossibleMove;
2868 if (WhiteOnMove(yyboardindex)) {
2869 currentMoveString[0] = ToUpper(yytext[0]);
2871 currentMoveString[0] = ToLower(yytext[0]);
2873 return LegalityTest(boards[yyboardindex], PosFlags(yyboardindex), DROP_RANK, // [HGM] does drops now too
2874 CharToPiece(currentMoveString[0]), currentMoveString[3] - ONE, currentMoveString[2] - AAA, NULLCHAR);
2879 #line 855 "parser.l"
2881 if (WhiteOnMove(yyboardindex))
2882 return (int) BlackWins;
2884 return (int) WhiteWins;
2889 #line 862 "parser.l"
2891 return (int) (ToUpper(yytext[0]) == 'W' ? BlackWins : WhiteWins);
2896 #line 866 "parser.l"
2898 return (int) GameUnfinished;
2903 #line 870 "parser.l"
2905 return (int) GameIsDrawn;
2910 #line 874 "parser.l"
2912 return (int) GameIsDrawn;
2917 #line 878 "parser.l"
2919 if (WhiteOnMove(yyboardindex))
2920 return (int) BlackWins;
2922 return (int) WhiteWins;
2927 #line 885 "parser.l"
2929 if (WhiteOnMove(yyboardindex))
2930 return (int) BlackWins;
2932 return (int) WhiteWins;
2937 #line 892 "parser.l"
2939 return (int) GameIsDrawn;
2944 #line 896 "parser.l"
2946 return (int) GameIsDrawn;
2951 #line 900 "parser.l"
2953 return (int) (ToUpper(yytext[0]) == 'W' ? WhiteWins : BlackWins);
2958 #line 904 "parser.l"
2960 return (int) (ToUpper(yytext[0]) == 'W' ? BlackWins : WhiteWins);
2965 #line 908 "parser.l"
2967 return (int) WhiteWins;
2972 #line 912 "parser.l"
2974 return (int) BlackWins;
2979 #line 916 "parser.l"
2981 return (int) GameIsDrawn;
2986 #line 920 "parser.l"
2988 return (int) GameUnfinished;
2992 /* rule 27 can match eol */
2994 #line 924 "parser.l"
2997 if ((yyleng == 1) && (yytext[0] == '1'))
2998 return (int) MoveNumberOne;
3003 #line 930 "parser.l"
3005 /* elapsed time indication, e.g. (0:12) or {10:21.071} */
3006 return (int) ElapsedTime;
3010 /* rule 29 can match eol */
3012 #line 935 "parser.l"
3014 /* position diagram enclosed in [-- --] */
3015 return (int) PositionDiagram;
3019 /* rule 30 can match eol */
3020 *yy_cp = (yy_hold_char); /* undo effects of setting up yytext */
3021 (yy_c_buf_p) = yy_cp -= 1;
3022 YY_DO_BEFORE_ACTION; /* set up yytext again */
3024 #line 940 "parser.l"
3026 /* position diagram enclosed in {-- --} */
3027 return (int) PositionDiagram;
3031 /* rule 31 can match eol */
3033 #line 945 "parser.l"
3035 return (int) PGNTag;
3040 #line 949 "parser.l"
3042 return (int) GNUChessGame;
3046 /* rule 33 can match eol */
3047 *yy_cp = (yy_hold_char); /* undo effects of setting up yytext */
3048 (yy_c_buf_p) = yy_cp -= 1;
3049 YY_DO_BEFORE_ACTION; /* set up yytext again */
3051 #line 953 "parser.l"
3053 return (int) XBoardGame;
3058 #line 957 "parser.l"
3059 { /* numeric annotation glyph */
3064 /* rule 35 can match eol */
3066 #line 961 "parser.l"
3067 { /* anything in {} */
3068 return (int) Comment;
3072 *yy_cp = (yy_hold_char); /* undo effects of setting up yytext */
3073 (yy_c_buf_p) = yy_cp -= 1;
3074 YY_DO_BEFORE_ACTION; /* set up yytext again */
3076 #line 965 "parser.l"
3077 { /* ; to end of line */
3078 return (int) Comment;
3082 /* rule 37 can match eol */
3084 #line 969 "parser.l"
3085 { /* anything in [] */
3086 return (int) Comment;
3090 /* rule 38 can match eol */
3092 #line 973 "parser.l"
3093 { /* very nested () */
3094 return (int) Comment;
3098 /* rule 39 can match eol */
3100 #line 977 "parser.l"
3101 { /* >=2 chars in () */
3102 return (int) Comment;
3106 /* rule 40 can match eol */
3108 #line 981 "parser.l"
3110 /* Skip mail headers */
3115 #line 985 "parser.l"
3117 /* Skip random words */
3121 /* rule 42 can match eol */
3123 #line 989 "parser.l"
3125 /* Skip everything else */
3130 #line 993 "parser.l"
3133 #line 3134 "parser.c"
3134 case YY_STATE_EOF(INITIAL):
3137 case YY_END_OF_BUFFER:
3139 /* Amount of text matched not including the EOB char. */
3140 int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1;
3142 /* Undo the effects of YY_DO_BEFORE_ACTION. */
3143 *yy_cp = (yy_hold_char);
3144 YY_RESTORE_YY_MORE_OFFSET
3146 if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
3148 /* We're scanning a new file or input source. It's
3149 * possible that this happened because the user
3150 * just pointed yyin at a new source and called
3151 * yylex(). If so, then we have to assure
3152 * consistency between YY_CURRENT_BUFFER and our
3153 * globals. Here is the right place to do so, because
3154 * this is the first action (other than possibly a
3155 * back-up) that will match for the new input source.
3157 (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
3158 YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
3159 YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
3162 /* Note that here we test for yy_c_buf_p "<=" to the position
3163 * of the first EOB in the buffer, since yy_c_buf_p will
3164 * already have been incremented past the NUL character
3165 * (since all states make transitions on EOB to the
3166 * end-of-buffer state). Contrast this with the test
3169 if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )
3170 { /* This was really a NUL. */
3171 yy_state_type yy_next_state;
3173 (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text;
3175 yy_current_state = yy_get_previous_state( );
3177 /* Okay, we're now positioned to make the NUL
3178 * transition. We couldn't have
3179 * yy_get_previous_state() go ahead and do it
3180 * for us because it doesn't know how to deal
3181 * with the possibility of jamming (and we don't
3182 * want to build jamming into it because then it
3183 * will run more slowly).
3186 yy_next_state = yy_try_NUL_trans( yy_current_state );
3188 yy_bp = (yytext_ptr) + YY_MORE_ADJ;
3190 if ( yy_next_state )
3192 /* Consume the NUL. */
3193 yy_cp = ++(yy_c_buf_p);
3194 yy_current_state = yy_next_state;
3200 yy_cp = (yy_c_buf_p);
3201 goto yy_find_action;
3205 else switch ( yy_get_next_buffer( ) )
3207 case EOB_ACT_END_OF_FILE:
3209 (yy_did_buffer_switch_on_eof) = 0;
3213 /* Note: because we've taken care in
3214 * yy_get_next_buffer() to have set up
3215 * yytext, we can now set up
3216 * yy_c_buf_p so that if some total
3217 * hoser (like flex itself) wants to
3218 * call the scanner after we return the
3219 * YY_NULL, it'll still work - another
3220 * YY_NULL will get returned.
3222 (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ;
3224 yy_act = YY_STATE_EOF(YY_START);
3230 if ( ! (yy_did_buffer_switch_on_eof) )
3236 case EOB_ACT_CONTINUE_SCAN:
3238 (yytext_ptr) + yy_amount_of_matched_text;
3240 yy_current_state = yy_get_previous_state( );
3242 yy_cp = (yy_c_buf_p);
3243 yy_bp = (yytext_ptr) + YY_MORE_ADJ;
3246 case EOB_ACT_LAST_MATCH:
3248 &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)];
3250 yy_current_state = yy_get_previous_state( );
3252 yy_cp = (yy_c_buf_p);
3253 yy_bp = (yytext_ptr) + YY_MORE_ADJ;
3254 goto yy_find_action;
3261 "fatal flex scanner internal error--no action found" );
3262 } /* end of action switch */
3263 } /* end of scanning one token */
3264 } /* end of yylex */
3266 /* yy_get_next_buffer - try to read in a new buffer
3268 * Returns a code representing an action:
3269 * EOB_ACT_LAST_MATCH -
3270 * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
3271 * EOB_ACT_END_OF_FILE - end of file
3273 static int yy_get_next_buffer (void)
3275 register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
3276 register char *source = (yytext_ptr);
3277 register int number_to_move, i;
3280 if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] )
3282 "fatal flex scanner internal error--end of buffer missed" );
3284 if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
3285 { /* Don't try to fill the buffer, so this is an EOF. */
3286 if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 )
3288 /* We matched a single character, the EOB, so
3289 * treat this as a final EOF.
3291 return EOB_ACT_END_OF_FILE;
3296 /* We matched some text prior to the EOB, first
3299 return EOB_ACT_LAST_MATCH;
3303 /* Try to read more data. */
3305 /* First move last chars to start of buffer. */
3306 number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1;
3308 for ( i = 0; i < number_to_move; ++i )
3309 *(dest++) = *(source++);
3311 if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
3312 /* don't do the read, it's not guaranteed to return an EOF,
3315 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0;
3320 YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
3322 while ( num_to_read <= 0 )
3323 { /* Not enough room in the buffer - grow it. */
3326 "input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
3330 if ( num_to_read > YY_READ_BUF_SIZE )
3331 num_to_read = YY_READ_BUF_SIZE;
3333 /* Read in more data. */
3334 YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
3335 (yy_n_chars), (size_t) num_to_read );
3337 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
3340 if ( (yy_n_chars) == 0 )
3342 if ( number_to_move == YY_MORE_ADJ )
3344 ret_val = EOB_ACT_END_OF_FILE;
3350 ret_val = EOB_ACT_LAST_MATCH;
3351 YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
3352 YY_BUFFER_EOF_PENDING;
3357 ret_val = EOB_ACT_CONTINUE_SCAN;
3359 if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
3360 /* Extend the array by 50%, plus the number we really need. */
3361 yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1);
3362 YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size );
3363 if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
3364 YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
3367 (yy_n_chars) += number_to_move;
3368 YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR;
3369 YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR;
3371 (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
3376 /* yy_get_previous_state - get the state just before the EOB char was reached */
3378 static yy_state_type yy_get_previous_state (void)
3380 register yy_state_type yy_current_state;
3381 register char *yy_cp;
3383 yy_current_state = (yy_start);
3384 yy_current_state += YY_AT_BOL();
3386 (yy_state_ptr) = (yy_state_buf);
3387 *(yy_state_ptr)++ = yy_current_state;
3389 for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp )
3391 register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
3392 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
3394 yy_current_state = (int) yy_def[yy_current_state];
3395 if ( yy_current_state >= 706 )
3396 yy_c = yy_meta[(unsigned int) yy_c];
3398 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
3399 *(yy_state_ptr)++ = yy_current_state;
3402 return yy_current_state;
3405 /* yy_try_NUL_trans - try to make a transition on the NUL character
3408 * next_state = yy_try_NUL_trans( current_state );
3410 static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state )
3412 register int yy_is_jam;
3414 register YY_CHAR yy_c = 1;
3415 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
3417 yy_current_state = (int) yy_def[yy_current_state];
3418 if ( yy_current_state >= 706 )
3419 yy_c = yy_meta[(unsigned int) yy_c];
3421 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
3422 yy_is_jam = (yy_current_state == 705);
3424 *(yy_state_ptr)++ = yy_current_state;
3426 return yy_is_jam ? 0 : yy_current_state;
3429 static void yyunput (int c, register char * yy_bp )
3431 register char *yy_cp;
3433 yy_cp = (yy_c_buf_p);
3435 /* undo effects of setting up yytext */
3436 *yy_cp = (yy_hold_char);
3438 if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
3439 { /* need to shift things up to make room */
3440 /* +2 for EOB chars. */
3441 register int number_to_move = (yy_n_chars) + 2;
3442 register char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[
3443 YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2];
3444 register char *source =
3445 &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move];
3447 while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
3448 *--dest = *--source;
3450 yy_cp += (int) (dest - source);
3451 yy_bp += (int) (dest - source);
3452 YY_CURRENT_BUFFER_LVALUE->yy_n_chars =
3453 (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_buf_size;
3455 if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
3456 YY_FATAL_ERROR( "flex scanner push-back overflow" );
3459 *--yy_cp = (char) c;
3461 (yytext_ptr) = yy_bp;
3462 (yy_hold_char) = *yy_cp;
3463 (yy_c_buf_p) = yy_cp;
3468 static int yyinput (void)
3470 static int input (void)
3476 *(yy_c_buf_p) = (yy_hold_char);
3478 if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR )
3480 /* yy_c_buf_p now points to the character we want to return.
3481 * If this occurs *before* the EOB characters, then it's a
3482 * valid NUL; if not, then we've hit the end of the buffer.
3484 if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )
3485 /* This was really a NUL. */
3486 *(yy_c_buf_p) = '\0';
3489 { /* need more input */
3490 int offset = (yy_c_buf_p) - (yytext_ptr);
3493 switch ( yy_get_next_buffer( ) )
3495 case EOB_ACT_LAST_MATCH:
3496 /* This happens because yy_g_n_b()
3497 * sees that we've accumulated a
3498 * token and flags that we need to
3499 * try matching the token before
3500 * proceeding. But for input(),
3501 * there's no matching to consider.
3502 * So convert the EOB_ACT_LAST_MATCH
3503 * to EOB_ACT_END_OF_FILE.
3506 /* Reset buffer status. */
3511 case EOB_ACT_END_OF_FILE:
3516 if ( ! (yy_did_buffer_switch_on_eof) )
3525 case EOB_ACT_CONTINUE_SCAN:
3526 (yy_c_buf_p) = (yytext_ptr) + offset;
3532 c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */
3533 *(yy_c_buf_p) = '\0'; /* preserve yytext */
3534 (yy_hold_char) = *++(yy_c_buf_p);
3536 YY_CURRENT_BUFFER_LVALUE->yy_at_bol = (c == '\n');
3540 #endif /* ifndef YY_NO_INPUT */
3542 /** Immediately switch to a different input stream.
3543 * @param input_file A readable stream.
3545 * @note This function does not reset the start condition to @c INITIAL .
3547 void yyrestart (FILE * input_file )
3550 if ( ! YY_CURRENT_BUFFER ){
3551 yyensure_buffer_stack ();
3552 YY_CURRENT_BUFFER_LVALUE =
3553 yy_create_buffer(yyin,YY_BUF_SIZE );
3556 yy_init_buffer(YY_CURRENT_BUFFER,input_file );
3557 yy_load_buffer_state( );
3560 /** Switch to a different input buffer.
3561 * @param new_buffer The new input buffer.
3564 void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer )
3567 /* TODO. We should be able to replace this entire function body
3569 * yypop_buffer_state();
3570 * yypush_buffer_state(new_buffer);
3572 yyensure_buffer_stack ();
3573 if ( YY_CURRENT_BUFFER == new_buffer )
3576 if ( YY_CURRENT_BUFFER )
3578 /* Flush out information for old buffer. */
3579 *(yy_c_buf_p) = (yy_hold_char);
3580 YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);
3581 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
3584 YY_CURRENT_BUFFER_LVALUE = new_buffer;
3585 yy_load_buffer_state( );
3587 /* We don't actually know whether we did this switch during
3588 * EOF (yywrap()) processing, but the only time this flag
3589 * is looked at is after yywrap() is called, so it's safe
3590 * to go ahead and always set it.
3592 (yy_did_buffer_switch_on_eof) = 1;
3595 static void yy_load_buffer_state (void)
3597 (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
3598 (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
3599 yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
3600 (yy_hold_char) = *(yy_c_buf_p);
3603 /** Allocate and initialize an input buffer state.
3604 * @param file A readable stream.
3605 * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
3607 * @return the allocated buffer state.
3609 YY_BUFFER_STATE yy_create_buffer (FILE * file, int size )
3613 b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) );
3615 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
3617 b->yy_buf_size = size;
3619 /* yy_ch_buf has to be 2 characters longer than the size given because
3620 * we need to put in 2 end-of-buffer characters.
3622 b->yy_ch_buf = (char *) yyalloc(b->yy_buf_size + 2 );
3623 if ( ! b->yy_ch_buf )
3624 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
3626 b->yy_is_our_buffer = 1;
3628 yy_init_buffer(b,file );
3633 /** Destroy the buffer.
3634 * @param b a buffer created with yy_create_buffer()
3637 void yy_delete_buffer (YY_BUFFER_STATE b )
3643 if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
3644 YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
3646 if ( b->yy_is_our_buffer )
3647 yyfree((void *) b->yy_ch_buf );
3649 yyfree((void *) b );
3653 extern int isatty (int );
3654 #endif /* __cplusplus */
3656 /* Initializes or reinitializes a buffer.
3657 * This function is sometimes called more than once on the same buffer,
3658 * such as during a yyrestart() or at EOF.
3660 static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file )
3665 yy_flush_buffer(b );
3667 b->yy_input_file = file;
3668 b->yy_fill_buffer = 1;
3670 /* If b is the current buffer, then yy_init_buffer was _probably_
3671 * called from yyrestart() or through yy_get_next_buffer.
3672 * In that case, we don't want to reset the lineno or column.
3674 if (b != YY_CURRENT_BUFFER){
3675 b->yy_bs_lineno = 1;
3676 b->yy_bs_column = 0;
3679 b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
3684 /** Discard all buffered characters. On the next scan, YY_INPUT will be called.
3685 * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
3688 void yy_flush_buffer (YY_BUFFER_STATE b )
3695 /* We always need two end-of-buffer characters. The first causes
3696 * a transition to the end-of-buffer state. The second causes
3697 * a jam in that state.
3699 b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
3700 b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
3702 b->yy_buf_pos = &b->yy_ch_buf[0];
3705 b->yy_buffer_status = YY_BUFFER_NEW;
3707 if ( b == YY_CURRENT_BUFFER )
3708 yy_load_buffer_state( );
3711 /** Pushes the new state onto the stack. The new state becomes
3712 * the current state. This function will allocate the stack
3714 * @param new_buffer The new state.
3717 void yypush_buffer_state (YY_BUFFER_STATE new_buffer )
3719 if (new_buffer == NULL)
3722 yyensure_buffer_stack();
3724 /* This block is copied from yy_switch_to_buffer. */
3725 if ( YY_CURRENT_BUFFER )
3727 /* Flush out information for old buffer. */
3728 *(yy_c_buf_p) = (yy_hold_char);
3729 YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);
3730 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
3733 /* Only push if top exists. Otherwise, replace top. */
3734 if (YY_CURRENT_BUFFER)
3735 (yy_buffer_stack_top)++;
3736 YY_CURRENT_BUFFER_LVALUE = new_buffer;
3738 /* copied from yy_switch_to_buffer. */
3739 yy_load_buffer_state( );
3740 (yy_did_buffer_switch_on_eof) = 1;
3743 /** Removes and deletes the top of the stack, if present.
3744 * The next element becomes the new top.
3747 void yypop_buffer_state (void)
3749 if (!YY_CURRENT_BUFFER)
3752 yy_delete_buffer(YY_CURRENT_BUFFER );
3753 YY_CURRENT_BUFFER_LVALUE = NULL;
3754 if ((yy_buffer_stack_top) > 0)
3755 --(yy_buffer_stack_top);
3757 if (YY_CURRENT_BUFFER) {
3758 yy_load_buffer_state( );
3759 (yy_did_buffer_switch_on_eof) = 1;
3763 /* Allocates the stack if it does not exist.
3764 * Guarantees space for at least one push.
3766 static void yyensure_buffer_stack (void)
3770 if (!(yy_buffer_stack)) {
3772 /* First allocation is just for 2 elements, since we don't know if this
3773 * scanner will even need a stack. We use 2 instead of 1 to avoid an
3774 * immediate realloc on the next call.
3777 (yy_buffer_stack) = (struct yy_buffer_state**)yyalloc
3778 (num_to_alloc * sizeof(struct yy_buffer_state*)
3780 if ( ! (yy_buffer_stack) )
3781 YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
3783 memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*));
3785 (yy_buffer_stack_max) = num_to_alloc;
3786 (yy_buffer_stack_top) = 0;
3790 if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){
3792 /* Increase the buffer to prepare for a possible push. */
3793 int grow_size = 8 /* arbitrary grow size */;
3795 num_to_alloc = (yy_buffer_stack_max) + grow_size;
3796 (yy_buffer_stack) = (struct yy_buffer_state**)yyrealloc
3798 num_to_alloc * sizeof(struct yy_buffer_state*)
3800 if ( ! (yy_buffer_stack) )
3801 YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
3803 /* zero only the new slots.*/
3804 memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*));
3805 (yy_buffer_stack_max) = num_to_alloc;
3809 /** Setup the input buffer state to scan directly from a user-specified character buffer.
3810 * @param base the character buffer
3811 * @param size the size in bytes of the character buffer
3813 * @return the newly allocated buffer state object.
3815 YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size )
3820 base[size-2] != YY_END_OF_BUFFER_CHAR ||
3821 base[size-1] != YY_END_OF_BUFFER_CHAR )
3822 /* They forgot to leave room for the EOB's. */
3825 b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) );
3827 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
3829 b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
3830 b->yy_buf_pos = b->yy_ch_buf = base;
3831 b->yy_is_our_buffer = 0;
3832 b->yy_input_file = 0;
3833 b->yy_n_chars = b->yy_buf_size;
3834 b->yy_is_interactive = 0;
3836 b->yy_fill_buffer = 0;
3837 b->yy_buffer_status = YY_BUFFER_NEW;
3839 yy_switch_to_buffer(b );
3844 /** Setup the input buffer state to scan a string. The next call to yylex() will
3845 * scan from a @e copy of @a str.
3846 * @param yystr a NUL-terminated string to scan
3848 * @return the newly allocated buffer state object.
3849 * @note If you want to scan bytes that may contain NUL values, then use
3850 * yy_scan_bytes() instead.
3852 YY_BUFFER_STATE yy_scan_string (yyconst char * yystr )
3855 return yy_scan_bytes(yystr,strlen(yystr) );
3858 /** Setup the input buffer state to scan the given bytes. The next call to yylex() will
3859 * scan from a @e copy of @a bytes.
3860 * @param bytes the byte buffer to scan
3861 * @param len the number of bytes in the buffer pointed to by @a bytes.
3863 * @return the newly allocated buffer state object.
3865 YY_BUFFER_STATE yy_scan_bytes (yyconst char * yybytes, int _yybytes_len )
3872 /* Get memory for full buffer, including space for trailing EOB's. */
3873 n = _yybytes_len + 2;
3874 buf = (char *) yyalloc(n );
3876 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
3878 for ( i = 0; i < _yybytes_len; ++i )
3879 buf[i] = yybytes[i];
3881 buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
3883 b = yy_scan_buffer(buf,n );
3885 YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
3887 /* It's okay to grow etc. this buffer, and we should throw it
3888 * away when we're done.
3890 b->yy_is_our_buffer = 1;
3895 #ifndef YY_EXIT_FAILURE
3896 #define YY_EXIT_FAILURE 2
3899 static void yy_fatal_error (yyconst char* msg )
3901 (void) fprintf( stderr, "%s\n", msg );
3902 exit( YY_EXIT_FAILURE );
3905 /* Redefine yyless() so it works in section 3 code. */
3911 /* Undo effects of setting up yytext. */ \
3912 int yyless_macro_arg = (n); \
3913 YY_LESS_LINENO(yyless_macro_arg);\
3914 yytext[yyleng] = (yy_hold_char); \
3915 (yy_c_buf_p) = yytext + yyless_macro_arg; \
3916 (yy_hold_char) = *(yy_c_buf_p); \
3917 *(yy_c_buf_p) = '\0'; \
3918 yyleng = yyless_macro_arg; \
3922 /* Accessor methods (get/set functions) to struct members. */
3924 /** Get the current line number.
3927 int yyget_lineno (void)
3933 /** Get the input stream.
3936 FILE *yyget_in (void)
3941 /** Get the output stream.
3944 FILE *yyget_out (void)
3949 /** Get the length of the current token.
3952 int yyget_leng (void)
3957 /** Get the current token.
3961 char *yyget_text (void)
3966 /** Set the current line number.
3967 * @param line_number
3970 void yyset_lineno (int line_number )
3973 yylineno = line_number;
3976 /** Set the input stream. This does not discard the current
3978 * @param in_str A readable stream.
3980 * @see yy_switch_to_buffer
3982 void yyset_in (FILE * in_str )
3987 void yyset_out (FILE * out_str )
3992 int yyget_debug (void)
3994 return yy_flex_debug;
3997 void yyset_debug (int bdebug )
3999 yy_flex_debug = bdebug ;
4002 static int yy_init_globals (void)
4004 /* Initialization is the same as for the non-reentrant scanner.
4005 * This function is called from yylex_destroy(), so don't allocate here.
4008 (yy_buffer_stack) = 0;
4009 (yy_buffer_stack_top) = 0;
4010 (yy_buffer_stack_max) = 0;
4011 (yy_c_buf_p) = (char *) 0;
4017 (yy_full_match) = 0;
4020 /* Defined in main.c */
4029 /* For future reference: Set errno on error, since we are called by
4035 /* yylex_destroy is for both reentrant and non-reentrant scanners. */
4036 int yylex_destroy (void)
4039 /* Pop the buffer stack, destroying each element. */
4040 while(YY_CURRENT_BUFFER){
4041 yy_delete_buffer(YY_CURRENT_BUFFER );
4042 YY_CURRENT_BUFFER_LVALUE = NULL;
4043 yypop_buffer_state();
4046 /* Destroy the stack itself. */
4047 yyfree((yy_buffer_stack) );
4048 (yy_buffer_stack) = NULL;
4050 yyfree ( (yy_state_buf) );
4051 (yy_state_buf) = NULL;
4053 /* Reset the globals. This is important in a non-reentrant scanner so the next time
4054 * yylex() is called, initialization will occur. */
4061 * Internal utility routines.
4065 static void yy_flex_strncpy (char* s1, yyconst char * s2, int n )
4068 for ( i = 0; i < n; ++i )
4073 #ifdef YY_NEED_STRLEN
4074 static int yy_flex_strlen (yyconst char * s )
4077 for ( n = 0; s[n]; ++n )
4084 void *yyalloc (yy_size_t size )
4086 return (void *) malloc( size );
4089 void *yyrealloc (void * ptr, yy_size_t size )
4091 /* The cast to (char *) in the following accommodates both
4092 * implementations that use char* generic pointers, and those
4093 * that use void* generic pointers. It works with the latter
4094 * because both ANSI C and C++ allow castless assignment from
4095 * any pointer type to void*, and deal with argument conversions
4096 * as though doing an assignment.
4098 return (void *) realloc( (char *) ptr, size );
4101 void yyfree (void * ptr )
4103 free( (char *) ptr ); /* see yyrealloc() for (char *) cast */
4106 #define YYTABLES_NAME "yytables"
4108 #line 993 "parser.l"
4113 static char *StringToLex;
4115 #ifndef FLEX_SCANNER
4122 if (StringToLex != NULL) {
4124 if (ret == NULLCHAR)
4128 } else if (unputCount > 0) {
4129 ret = unputBuffer[--unputCount];
4141 * Return offset of next pattern within current file
4145 int offset = ftell(lexFP) - unputCount;
4153 static void output(ch)
4156 if(appData.debugMode) fprintf(debugFP, "PARSER BUG: unmatched character '%c' (0%o)\n",
4160 static void unput(ch)
4163 if (ch == 0) return;
4164 if (StringToLex != NULL) {
4167 if (unputCount >= UNPUT_BUF_SIZE)
4168 if(appData.debugMode) fprintf(debugFP, "PARSER BUG: unput buffer overflow '%c' (0%o)\n",
4170 unputBuffer[unputCount++] = ch;
4174 /* Get ready to lex from a new file. Kludge below sticks
4175 an artificial newline at the front of the file, which the
4176 above grammar ignores, but which makes ^ at start of pattern
4177 match at the real start of the file.
4185 unput('\n'); /* kludge */
4188 /* Get ready to lex from a string. ^ at start of pattern WON'T
4189 match at the start of the string!
4198 #endif /*!FLEX_SCANNER*/
4201 void my_yy_input(buf, result, max_size)
4208 if (StringToLex != NULL) {
4210 while (*StringToLex != NULLCHAR) {
4211 *buf++ = *StringToLex++;
4217 count = fread(buf, 1, max_size, yyin);
4227 static YY_BUFFER_STATE my_file_buffer = NULL;
4230 Return offset of next pattern in the current file.
4234 int pos = yy_c_buf_p - YY_CURRENT_BUFFER->yy_ch_buf;
4236 return(ftell(YY_CURRENT_BUFFER->yy_input_file) -
4244 if (my_file_buffer != NULL)
4245 yy_delete_buffer(my_file_buffer);
4247 my_file_buffer = yy_create_buffer(stdin,YY_BUF_SIZE);
4248 yy_switch_to_buffer(my_file_buffer);
4254 if (my_file_buffer != NULL)
4255 yy_delete_buffer(my_file_buffer);
4257 my_file_buffer = yy_create_buffer(f,YY_BUF_SIZE);
4258 yy_switch_to_buffer(my_file_buffer);
4260 #endif /*FLEX_SCANNER*/
4267 /* Parse a move from the given string s */
4268 /* ^ at start of pattern WON'T work here unless using flex */
4269 ChessMove yylexstr(boardIndex, s, text, len)
4270 int boardIndex, len;
4274 char *oldStringToLex;
4276 YY_BUFFER_STATE buffer, oldBuffer;
4279 yyboardindex = boardIndex;
4280 oldStringToLex = StringToLex;
4283 buffer = yy_create_buffer(stdin,YY_BUF_SIZE);
4284 oldBuffer = YY_CURRENT_BUFFER;
4285 yy_switch_to_buffer(buffer);
4286 #endif /*FLEX_SCANNER*/
4288 ret = (ChessMove) yylex();
4289 strncpy(text, yy_text, len-1); // [HGM] vari: yy_text is not available to caller after buffer switch ?!?
4290 text[len-1] = NULLCHAR;
4293 if (oldBuffer != NULL)
4294 yy_switch_to_buffer(oldBuffer);
4295 yy_delete_buffer(buffer);
4296 #endif /*FLEX_SCANNER*/
4297 StringToLex = oldStringToLex;