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 35
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
;
57 /* Limits of integral types. */
59 #define INT8_MIN (-128)
62 #define INT16_MIN (-32767-1)
65 #define INT32_MIN (-2147483647-1)
68 #define INT8_MAX (127)
71 #define INT16_MAX (32767)
74 #define INT32_MAX (2147483647)
77 #define UINT8_MAX (255U)
80 #define UINT16_MAX (65535U)
83 #define UINT32_MAX (4294967295U)
88 #endif /* ! FLEXINT_H */
92 /* The "const" storage-class-modifier is valid. */
95 #else /* ! __cplusplus */
97 /* C99 requires __STDC__ to be defined as 1. */
98 #if defined (__STDC__)
102 #endif /* defined (__STDC__) */
103 #endif /* ! __cplusplus */
106 #define yyconst const
111 /* Returned upon end-of-file. */
114 /* Promotes a possibly negative, possibly signed char to an unsigned
115 * integer for use as an array index. If the signed char is negative,
116 * we want to instead treat it as an 8-bit unsigned char, hence the
119 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
121 /* An opaque pointer. */
122 #ifndef YY_TYPEDEF_YY_SCANNER_T
123 #define YY_TYPEDEF_YY_SCANNER_T
124 typedef void* yyscan_t
;
127 /* For convenience, these vars (plus the bison vars far below)
128 are macros in the reentrant scanner. */
129 #define yyin yyg->yyin_r
130 #define yyout yyg->yyout_r
131 #define yyextra yyg->yyextra_r
132 #define yyleng yyg->yyleng_r
133 #define yytext yyg->yytext_r
134 #define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
135 #define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
136 #define yy_flex_debug yyg->yy_flex_debug_r
138 /* Enter a start condition. This macro really ought to take a parameter,
139 * but we do it the disgusting crufty way forced on us by the ()-less
140 * definition of BEGIN.
142 #define BEGIN yyg->yy_start = 1 + 2 *
144 /* Translate the current start state into a value that can be later handed
145 * to BEGIN to return to the state. The YYSTATE alias is for lex
148 #define YY_START ((yyg->yy_start - 1) / 2)
149 #define YYSTATE YY_START
151 /* Action number for EOF rule of a given start state. */
152 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
154 /* Special action meaning "start processing a new file". */
155 #define YY_NEW_FILE yyrestart(yyin ,yyscanner )
157 #define YY_END_OF_BUFFER_CHAR 0
159 /* Size of default input buffer. */
162 /* On IA-64, the buffer size is 16k, not 8k.
163 * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
164 * Ditto for the __ia64__ case accordingly.
166 #define YY_BUF_SIZE 32768
168 #define YY_BUF_SIZE 16384
169 #endif /* __ia64__ */
172 /* The state buf must be large enough to hold one state per character in the main buffer.
174 #define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
176 #ifndef YY_TYPEDEF_YY_BUFFER_STATE
177 #define YY_TYPEDEF_YY_BUFFER_STATE
178 typedef struct yy_buffer_state
*YY_BUFFER_STATE
;
181 #define EOB_ACT_CONTINUE_SCAN 0
182 #define EOB_ACT_END_OF_FILE 1
183 #define EOB_ACT_LAST_MATCH 2
185 #define YY_LESS_LINENO(n)
187 /* Return all but the first "n" matched characters back to the input stream. */
191 /* Undo effects of setting up yytext. */ \
192 int yyless_macro_arg = (n); \
193 YY_LESS_LINENO(yyless_macro_arg);\
194 *yy_cp = yyg->yy_hold_char; \
195 YY_RESTORE_YY_MORE_OFFSET \
196 yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
197 YY_DO_BEFORE_ACTION; /* set up yytext again */ \
201 #define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
203 #ifndef YY_TYPEDEF_YY_SIZE_T
204 #define YY_TYPEDEF_YY_SIZE_T
205 typedef size_t yy_size_t
;
208 #ifndef YY_STRUCT_YY_BUFFER_STATE
209 #define YY_STRUCT_YY_BUFFER_STATE
210 struct yy_buffer_state
214 char *yy_ch_buf
; /* input buffer */
215 char *yy_buf_pos
; /* current position in input buffer */
217 /* Size of input buffer in bytes, not including room for EOB
220 yy_size_t yy_buf_size
;
222 /* Number of characters read into yy_ch_buf, not including EOB
227 /* Whether we "own" the buffer - i.e., we know we created it,
228 * and can realloc() it to grow it, and should free() it to
231 int yy_is_our_buffer
;
233 /* Whether this is an "interactive" input source; if so, and
234 * if we're using stdio for input, then we want to use getc()
235 * instead of fread(), to make sure we stop fetching input after
238 int yy_is_interactive
;
240 /* Whether we're considered to be at the beginning of a line.
241 * If so, '^' rules will be active on the next match, otherwise
246 int yy_bs_lineno
; /**< The line count. */
247 int yy_bs_column
; /**< The column count. */
249 /* Whether to try to fill the input buffer when we reach the
254 int yy_buffer_status
;
256 #define YY_BUFFER_NEW 0
257 #define YY_BUFFER_NORMAL 1
258 /* When an EOF's been seen but there's still some text to process
259 * then we mark the buffer as YY_EOF_PENDING, to indicate that we
260 * shouldn't try reading from the input source any more. We might
261 * still have a bunch of tokens to match, though, because of
262 * possible backing-up.
264 * When we actually see the EOF, we change the status to "new"
265 * (via yyrestart()), so that the user can continue scanning by
266 * just pointing yyin at a new input file.
268 #define YY_BUFFER_EOF_PENDING 2
271 #endif /* !YY_STRUCT_YY_BUFFER_STATE */
273 /* We provide macros for accessing buffer states in case in the
274 * future we want to put the buffer states in a more general
277 * Returns the top of the stack, or NULL.
279 #define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \
280 ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \
283 /* Same as previous macro, but useful when we know that the buffer stack is not
284 * NULL or when we need an lvalue. For internal use only.
286 #define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
288 void yyrestart (FILE *input_file
,yyscan_t yyscanner
);
289 void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer
,yyscan_t yyscanner
);
290 YY_BUFFER_STATE
yy_create_buffer (FILE *file
,int size
,yyscan_t yyscanner
);
291 void yy_delete_buffer (YY_BUFFER_STATE b
,yyscan_t yyscanner
);
292 void yy_flush_buffer (YY_BUFFER_STATE b
,yyscan_t yyscanner
);
293 void yypush_buffer_state (YY_BUFFER_STATE new_buffer
,yyscan_t yyscanner
);
294 void yypop_buffer_state (yyscan_t yyscanner
);
296 static void yyensure_buffer_stack (yyscan_t yyscanner
);
297 static void yy_load_buffer_state (yyscan_t yyscanner
);
298 static void yy_init_buffer (YY_BUFFER_STATE b
,FILE *file
,yyscan_t yyscanner
);
300 #define YY_FLUSH_BUFFER yy_flush_buffer(YY_CURRENT_BUFFER ,yyscanner)
302 YY_BUFFER_STATE
yy_scan_buffer (char *base
,yy_size_t size
,yyscan_t yyscanner
);
303 YY_BUFFER_STATE
yy_scan_string (yyconst
char *yy_str
,yyscan_t yyscanner
);
304 YY_BUFFER_STATE
yy_scan_bytes (yyconst
char *bytes
,int len
,yyscan_t yyscanner
);
306 void *yyalloc (yy_size_t
,yyscan_t yyscanner
);
307 void *yyrealloc (void *,yy_size_t
,yyscan_t yyscanner
);
308 void yyfree (void * ,yyscan_t yyscanner
);
310 #define yy_new_buffer yy_create_buffer
312 #define yy_set_interactive(is_interactive) \
314 if ( ! YY_CURRENT_BUFFER ){ \
315 yyensure_buffer_stack (yyscanner); \
316 YY_CURRENT_BUFFER_LVALUE = \
317 yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
319 YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
322 #define yy_set_bol(at_bol) \
324 if ( ! YY_CURRENT_BUFFER ){\
325 yyensure_buffer_stack (yyscanner); \
326 YY_CURRENT_BUFFER_LVALUE = \
327 yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
329 YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
332 #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
334 /* Begin user sect3 */
337 #define YY_SKIP_YYWRAP
339 typedef unsigned char YY_CHAR
;
341 typedef int yy_state_type
;
343 #define yytext_ptr yytext_r
345 static yy_state_type
yy_get_previous_state (yyscan_t yyscanner
);
346 static yy_state_type
yy_try_NUL_trans (yy_state_type current_state
,yyscan_t yyscanner
);
347 static int yy_get_next_buffer (yyscan_t yyscanner
);
348 static void yy_fatal_error (yyconst
char msg
[] ,yyscan_t yyscanner
);
350 /* Done after the current pattern has been matched and before the
351 * corresponding action - sets up yytext.
353 #define YY_DO_BEFORE_ACTION \
354 yyg->yytext_ptr = yy_bp; \
355 yyleng = (size_t) (yy_cp - yy_bp); \
356 yyg->yy_hold_char = *yy_cp; \
358 yyg->yy_c_buf_p = yy_cp;
360 #define YY_NUM_RULES 176
361 #define YY_END_OF_BUFFER 177
362 /* This struct is not used in this scanner,
363 but its presence is necessary. */
366 flex_int32_t yy_verify
;
369 static yyconst flex_int16_t yy_accept
[645] =
371 0, 0, 177, 175, 173, 172, 175, 175, 145, 171,
372 147, 147, 147, 147, 145, 145, 145, 145, 145, 145,
373 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
374 145, 145, 145, 145, 173, 0, 0, 174, 145, 0,
375 146, 148, 168, 168, 0, 0, 0, 0, 168, 0,
376 0, 0, 0, 0, 0, 0, 132, 169, 133, 134,
377 159, 159, 159, 159, 0, 147, 0, 140, 141, 142,
378 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
379 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
380 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
382 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
383 145, 145, 145, 145, 145, 0, 0, 0, 0, 0,
384 0, 0, 0, 0, 167, 0, 0, 0, 0, 0,
385 0, 0, 0, 0, 166, 166, 0, 0, 0, 0,
386 0, 0, 0, 0, 0, 0, 0, 0, 0, 165,
387 165, 165, 0, 0, 0, 0, 0, 0, 0, 0,
388 0, 0, 156, 156, 156, 157, 157, 158, 149, 148,
389 149, 0, 150, 11, 13, 145, 15, 145, 16, 18,
390 145, 20, 22, 24, 26, 6, 28, 30, 31, 33,
391 35, 38, 36, 40, 41, 43, 45, 47, 49, 51,
393 145, 145, 145, 53, 55, 145, 57, 59, 61, 63,
394 65, 67, 69, 145, 71, 73, 75, 77, 145, 145,
395 145, 145, 145, 145, 0, 0, 0, 0, 148, 0,
396 0, 0, 0, 0, 0, 0, 0, 0, 0, 93,
397 94, 96, 0, 164, 0, 0, 0, 0, 0, 0,
398 110, 0, 0, 0, 0, 0, 0, 0, 0, 0,
399 0, 163, 162, 162, 122, 0, 0, 0, 0, 0,
400 0, 0, 0, 0, 0, 153, 153, 154, 155, 0,
401 151, 145, 145, 145, 145, 145, 145, 145, 143, 145,
402 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
404 145, 145, 145, 145, 145, 145, 145, 145, 145, 144,
405 145, 145, 145, 145, 145, 145, 145, 10, 145, 145,
406 145, 145, 145, 145, 145, 145, 145, 145, 0, 170,
407 0, 0, 0, 86, 87, 0, 0, 0, 0, 0,
408 0, 0, 98, 0, 0, 0, 0, 0, 0, 0,
409 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
410 0, 161, 0, 0, 0, 126, 0, 128, 0, 0,
411 0, 0, 0, 0, 160, 152, 145, 145, 145, 4,
412 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
413 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
415 9, 145, 145, 145, 145, 145, 145, 145, 145, 145,
416 145, 145, 145, 145, 145, 145, 145, 82, 145, 145,
417 0, 0, 0, 0, 0, 88, 89, 0, 0, 0,
418 0, 97, 0, 0, 101, 104, 0, 0, 0, 0,
419 0, 0, 0, 115, 116, 0, 0, 0, 0, 121,
420 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
421 145, 145, 145, 5, 145, 145, 145, 145, 145, 145,
422 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
423 145, 7, 8, 145, 145, 145, 145, 145, 145, 145,
424 145, 145, 145, 145, 145, 145, 145, 145, 83, 145,
426 79, 0, 0, 0, 0, 137, 0, 0, 0, 0,
427 0, 0, 0, 0, 0, 107, 0, 111, 112, 0,
428 114, 0, 0, 0, 0, 0, 0, 0, 0, 0,
429 0, 130, 131, 0, 0, 138, 12, 3, 14, 17,
430 19, 21, 23, 25, 27, 29, 32, 34, 39, 37,
431 42, 44, 46, 48, 50, 52, 54, 56, 58, 60,
432 62, 64, 66, 68, 70, 72, 74, 76, 78, 145,
433 81, 139, 0, 0, 84, 0, 90, 0, 0, 0,
434 99, 0, 0, 0, 0, 0, 0, 113, 0, 0,
435 119, 106, 0, 0, 0, 0, 0, 0, 135, 0,
437 80, 0, 0, 0, 0, 92, 95, 100, 0, 0,
438 105, 0, 0, 0, 118, 0, 0, 0, 0, 127,
439 129, 0, 2, 1, 0, 91, 0, 103, 0, 109,
440 117, 0, 0, 124, 125, 136, 0, 102, 0, 120,
444 static yyconst flex_int32_t yy_ec
[256] =
446 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
447 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
448 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
449 1, 2, 4, 1, 5, 6, 1, 1, 1, 1,
450 1, 1, 7, 1, 7, 8, 1, 9, 10, 11,
451 12, 13, 14, 14, 14, 14, 14, 1, 1, 1,
452 1, 1, 1, 1, 15, 16, 17, 18, 19, 20,
453 21, 22, 23, 6, 24, 25, 26, 27, 28, 29,
454 30, 31, 32, 33, 34, 35, 36, 37, 6, 38,
455 1, 1, 1, 1, 39, 1, 40, 41, 42, 43,
457 44, 45, 46, 47, 48, 49, 50, 51, 52, 53,
458 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
459 64, 65, 1, 1, 1, 1, 1, 1, 1, 1,
460 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
461 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
462 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
463 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
464 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
465 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
466 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
468 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
469 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
470 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
471 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
472 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
476 static yyconst flex_int32_t yy_meta
[66] =
478 1, 1, 1, 1, 1, 2, 1, 3, 4, 4,
479 4, 4, 4, 4, 2, 2, 2, 4, 4, 2,
480 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
481 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
482 2, 2, 2, 4, 2, 2, 2, 2, 2, 2,
483 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
487 static yyconst flex_int16_t yy_base
[649] =
489 0, 0, 904, 905, 901, 905, 898, 898, 0, 64,
490 80, 95, 117, 882, 115, 53, 38, 58, 55, 876,
491 121, 122, 67, 54, 115, 134, 65, 869, 840, 839,
492 851, 835, 849, 848, 889, 875, 886, 905, 0, 169,
493 905, 153, 133, 136, 17, 110, 131, 43, 148, 848,
494 834, 121, 146, 832, 844, 147, 905, 189, 190, 86,
495 189, 177, 185, 193, 250, 262, 273, 905, 905, 905,
496 852, 865, 859, 856, 847, 850, 846, 861, 255, 843,
497 857, 149, 843, 856, 847, 860, 837, 848, 839, 162,
498 840, 831, 840, 831, 830, 831, 825, 831, 842, 828,
500 825, 837, 828, 821, 837, 814, 165, 190, 833, 810,
501 795, 790, 807, 783, 788, 813, 144, 803, 225, 798,
502 286, 261, 800, 781, 263, 791, 787, 782, 96, 788,
503 774, 790, 787, 778, 270, 273, 780, 769, 783, 786,
504 768, 783, 770, 767, 774, 264, 782, 160, 269, 285,
505 288, 295, 759, 776, 777, 770, 752, 234, 753, 775,
506 766, 227, 284, 291, 295, 299, 303, 307, 905, 364,
507 375, 381, 387, 774, 205, 797, 0, 780, 771, 770,
508 789, 768, 767, 766, 765, 0, 764, 0, 763, 762,
509 0, 761, 760, 0, 759, 758, 757, 756, 755, 754,
511 769, 762, 775, 750, 749, 754, 747, 746, 745, 744,
512 743, 742, 741, 750, 739, 738, 737, 736, 728, 727,
513 712, 712, 711, 710, 752, 725, 713, 393, 400, 375,
514 717, 280, 714, 708, 708, 702, 715, 715, 700, 905,
515 905, 715, 703, 377, 710, 39, 707, 713, 376, 708,
516 905, 699, 706, 705, 708, 694, 693, 697, 692, 294,
517 697, 384, 396, 398, 905, 689, 687, 687, 695, 696,
518 678, 401, 683, 689, 364, 386, 394, 399, 403, 460,
519 466, 702, 714, 700, 699, 707, 697, 696, 0, 695,
520 694, 693, 692, 691, 690, 689, 688, 687, 686, 685,
522 684, 683, 682, 681, 684, 677, 684, 677, 676, 0,
523 675, 674, 673, 672, 671, 670, 669, 0, 668, 667,
524 666, 665, 644, 638, 643, 649, 632, 647, 374, 905,
525 646, 636, 640, 905, 905, 630, 639, 625, 642, 625,
526 628, 622, 905, 623, 622, 619, 626, 619, 627, 623,
527 633, 630, 612, 618, 625, 609, 608, 626, 608, 620,
528 619, 905, 618, 608, 612, 905, 599, 905, 604, 604,
529 612, 595, 596, 606, 905, 905, 637, 619, 635, 0,
530 633, 633, 632, 631, 630, 629, 628, 627, 626, 625,
531 624, 623, 622, 621, 620, 619, 618, 617, 604, 597,
533 0, 614, 613, 612, 611, 610, 609, 608, 607, 606,
534 605, 604, 603, 602, 572, 575, 555, 0, 556, 549,
535 556, 555, 556, 548, 566, 905, 905, 548, 546, 556,
536 549, 905, 544, 561, 429, 905, 552, 536, 537, 546,
537 537, 536, 536, 905, 535, 544, 534, 550, 547, 905,
538 546, 544, 533, 534, 530, 522, 529, 524, 525, 520,
539 545, 545, 543, 0, 542, 541, 540, 539, 538, 537,
540 536, 535, 534, 533, 532, 531, 530, 529, 528, 527,
541 526, 0, 0, 525, 524, 523, 522, 521, 520, 519,
542 518, 517, 516, 515, 514, 513, 492, 492, 0, 499,
544 0, 532, 531, 481, 499, 905, 494, 489, 482, 478,
545 490, 480, 478, 474, 490, 481, 480, 905, 905, 483,
546 905, 478, 471, 460, 471, 463, 467, 480, 475, 478,
547 460, 905, 905, 472, 461, 905, 0, 0, 0, 0,
548 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
549 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
550 0, 0, 0, 0, 0, 0, 0, 0, 0, 455,
551 0, 0, 505, 504, 905, 452, 905, 456, 456, 465,
552 905, 449, 463, 451, 453, 450, 458, 905, 436, 447,
553 905, 905, 451, 447, 439, 432, 426, 439, 905, 396,
555 0, 443, 437, 392, 378, 905, 905, 905, 378, 338,
556 905, 337, 317, 307, 905, 296, 290, 275, 275, 905,
557 905, 288, 905, 905, 268, 905, 261, 905, 264, 905,
558 905, 213, 158, 905, 905, 905, 128, 905, 75, 905,
559 905, 905, 905, 905, 484, 487, 489, 493
562 static yyconst flex_int16_t yy_def
[649] =
564 644, 1, 644, 644, 644, 644, 644, 645, 646, 644,
565 644, 647, 647, 13, 646, 646, 646, 646, 646, 646,
566 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
567 646, 646, 646, 646, 644, 644, 645, 644, 646, 644,
568 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
569 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
570 644, 644, 644, 644, 648, 644, 644, 644, 644, 644,
571 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
572 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
573 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
575 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
576 646, 646, 646, 646, 646, 644, 644, 644, 644, 644,
577 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
578 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
579 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
580 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
581 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
582 644, 644, 644, 646, 646, 646, 646, 646, 646, 646,
583 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
584 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
586 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
587 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
588 646, 646, 646, 646, 644, 644, 644, 644, 644, 644,
589 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
590 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
591 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
592 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
593 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
594 644, 646, 646, 646, 646, 646, 646, 646, 646, 646,
595 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
597 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
598 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
599 646, 646, 646, 646, 646, 646, 646, 646, 644, 644,
600 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
601 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
602 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
603 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
604 644, 644, 644, 644, 644, 644, 646, 646, 646, 646,
605 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
606 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
608 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
609 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
610 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
611 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
612 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
613 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
614 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
615 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
616 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
617 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
619 646, 644, 644, 644, 644, 644, 644, 644, 644, 644,
620 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
621 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
622 644, 644, 644, 644, 644, 644, 646, 646, 646, 646,
623 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
624 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
625 646, 646, 646, 646, 646, 646, 646, 646, 646, 646,
626 646, 646, 644, 644, 644, 644, 644, 644, 644, 644,
627 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
628 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
630 646, 644, 644, 644, 644, 644, 644, 644, 644, 644,
631 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
632 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
633 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
634 644, 644, 644, 0, 644, 644, 644, 644
637 static yyconst flex_int16_t yy_nxt
[971] =
639 4, 5, 6, 7, 8, 9, 4, 10, 11, 12,
640 13, 14, 11, 11, 15, 9, 16, 17, 18, 19,
641 9, 9, 9, 20, 21, 22, 9, 23, 24, 9,
642 25, 26, 27, 9, 9, 9, 28, 9, 9, 9,
643 9, 9, 9, 9, 29, 9, 9, 9, 9, 9,
644 9, 9, 9, 9, 30, 9, 31, 32, 33, 9,
645 34, 9, 9, 9, 9, 40, 79, 126, 96, 80,
646 127, 41, 42, 42, 42, 42, 42, 42, 76, 83,
647 77, 97, 344, 107, 81, 84, 78, 65, 66, 66,
648 66, 66, 66, 66, 82, 94, 133, 345, 67, 134,
650 95, 108, 65, 43, 44, 45, 46, 47, 48, 49,
651 50, 51, 68, 67, 52, 53, 54, 55, 56, 57,
652 58, 59, 60, 67, 65, 61, 62, 63, 64, 159,
653 71, 98, 72, 99, 69, 67, 90, 643, 67, 73,
654 237, 86, 160, 87, 91, 74, 100, 75, 88, 92,
655 101, 89, 238, 128, 102, 93, 103, 129, 104, 187,
656 67, 42, 42, 42, 42, 42, 42, 105, 139, 106,
657 40, 121, 122, 122, 140, 125, 122, 188, 122, 196,
658 642, 122, 130, 131, 123, 141, 146, 135, 136, 122,
659 214, 124, 122, 122, 132, 123, 121, 147, 197, 142,
661 148, 215, 124, 149, 122, 216, 143, 257, 117, 118,
662 45, 46, 47, 48, 641, 50, 51, 258, 217, 52,
663 53, 54, 55, 56, 57, 119, 59, 60, 150, 151,
664 120, 154, 161, 155, 152, 283, 156, 157, 163, 162,
665 164, 165, 153, 284, 158, 122, 166, 162, 162, 167,
666 162, 162, 162, 162, 168, 162, 162, 162, 170, 170,
667 170, 170, 170, 170, 227, 640, 182, 183, 171, 65,
668 66, 66, 66, 66, 66, 66, 184, 270, 153, 172,
669 67, 173, 173, 173, 173, 173, 173, 271, 275, 275,
670 275, 275, 228, 171, 229, 229, 229, 229, 229, 229,
672 230, 230, 230, 230, 233, 67, 230, 639, 230, 230,
673 230, 638, 244, 230, 254, 230, 259, 230, 230, 230,
674 255, 637, 260, 332, 230, 230, 230, 262, 230, 230,
675 230, 636, 635, 230, 263, 264, 333, 261, 634, 359,
676 230, 230, 360, 633, 230, 275, 275, 275, 275, 632,
677 631, 230, 276, 275, 275, 277, 278, 275, 275, 275,
678 275, 275, 275, 275, 279, 275, 275, 275, 275, 275,
679 275, 275, 42, 42, 42, 42, 42, 42, 630, 629,
680 628, 280, 121, 281, 281, 281, 281, 281, 281, 173,
681 173, 173, 173, 173, 173, 173, 173, 173, 173, 173,
683 173, 229, 229, 229, 229, 229, 229, 121, 229, 229,
684 229, 229, 229, 229, 330, 330, 330, 330, 421, 348,
685 330, 627, 330, 330, 330, 375, 375, 375, 375, 330,
686 626, 330, 349, 330, 422, 330, 330, 362, 330, 625,
687 330, 330, 369, 330, 370, 624, 371, 375, 375, 375,
688 375, 623, 330, 622, 330, 376, 375, 375, 375, 372,
689 375, 375, 375, 375, 375, 375, 375, 375, 281, 281,
690 281, 281, 281, 281, 281, 281, 281, 281, 281, 281,
691 513, 621, 620, 514, 37, 37, 37, 37, 39, 619,
692 39, 66, 66, 169, 169, 618, 169, 617, 616, 615,
694 614, 613, 612, 611, 610, 609, 608, 607, 606, 605,
695 604, 603, 602, 601, 600, 599, 598, 597, 596, 595,
696 594, 593, 592, 591, 590, 589, 588, 587, 586, 585,
697 584, 583, 582, 581, 580, 579, 578, 577, 576, 575,
698 574, 573, 572, 571, 570, 569, 568, 567, 566, 565,
699 564, 563, 562, 561, 560, 559, 558, 557, 556, 555,
700 554, 553, 552, 551, 550, 549, 548, 547, 546, 545,
701 544, 543, 542, 541, 540, 539, 538, 537, 536, 535,
702 534, 533, 532, 531, 530, 529, 528, 527, 526, 525,
703 524, 523, 522, 521, 520, 519, 518, 517, 516, 515,
705 512, 511, 510, 509, 508, 507, 506, 505, 504, 503,
706 502, 501, 500, 499, 498, 497, 496, 495, 494, 493,
707 492, 491, 490, 489, 488, 487, 486, 485, 484, 483,
708 482, 481, 480, 479, 478, 477, 476, 475, 474, 473,
709 472, 471, 470, 469, 468, 467, 466, 465, 464, 463,
710 462, 461, 460, 459, 458, 457, 456, 455, 454, 453,
711 452, 451, 450, 449, 448, 447, 446, 445, 444, 443,
712 442, 441, 440, 439, 438, 437, 436, 435, 434, 433,
713 432, 431, 430, 429, 428, 427, 426, 425, 424, 423,
714 420, 419, 418, 417, 416, 415, 414, 413, 412, 411,
716 410, 409, 408, 407, 406, 405, 404, 403, 402, 401,
717 400, 399, 398, 397, 396, 395, 394, 393, 392, 391,
718 390, 389, 388, 387, 386, 385, 384, 383, 382, 381,
719 380, 379, 378, 377, 374, 373, 368, 367, 366, 365,
720 364, 363, 361, 358, 357, 356, 355, 354, 353, 352,
721 351, 350, 347, 346, 343, 342, 341, 340, 339, 338,
722 337, 336, 335, 334, 331, 261, 233, 329, 328, 327,
723 326, 325, 324, 323, 322, 321, 320, 319, 318, 317,
724 316, 315, 314, 313, 312, 311, 310, 309, 308, 307,
725 306, 305, 304, 303, 302, 301, 300, 299, 298, 297,
727 296, 295, 294, 293, 292, 291, 290, 289, 288, 287,
728 286, 285, 282, 274, 273, 272, 269, 268, 267, 266,
729 265, 256, 253, 252, 251, 250, 249, 248, 247, 246,
730 245, 243, 242, 241, 240, 239, 236, 235, 234, 232,
731 231, 161, 226, 225, 224, 223, 222, 221, 220, 219,
732 218, 213, 212, 211, 210, 209, 208, 207, 206, 205,
733 204, 203, 202, 201, 200, 199, 198, 195, 194, 193,
734 192, 191, 190, 189, 186, 185, 181, 180, 179, 178,
735 177, 176, 175, 174, 145, 144, 138, 137, 38, 116,
736 35, 115, 114, 113, 112, 111, 110, 109, 85, 70,
738 38, 36, 35, 644, 3, 644, 644, 644, 644, 644,
739 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
740 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
741 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
742 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
743 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
744 644, 644, 644, 644, 644, 644, 644, 644, 644, 644
747 static yyconst flex_int16_t yy_chk
[971] =
749 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
750 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
751 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
752 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
753 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
754 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
755 1, 1, 1, 1, 1, 10, 17, 45, 24, 17,
756 45, 10, 10, 10, 10, 10, 10, 10, 16, 19,
757 16, 24, 246, 27, 18, 19, 16, 11, 11, 11,
758 11, 11, 11, 11, 18, 23, 48, 246, 11, 48,
760 23, 27, 12, 10, 10, 10, 10, 10, 10, 10,
761 10, 10, 12, 12, 10, 10, 10, 10, 10, 10,
762 10, 10, 10, 11, 13, 10, 10, 10, 10, 60,
763 15, 25, 15, 25, 13, 13, 22, 639, 12, 15,
764 129, 21, 60, 21, 22, 15, 25, 15, 21, 22,
765 26, 21, 129, 46, 26, 22, 26, 46, 26, 82,
766 13, 42, 42, 42, 42, 42, 42, 26, 52, 26,
767 40, 42, 43, 43, 52, 44, 44, 82, 43, 90,
768 637, 44, 47, 47, 43, 53, 56, 49, 49, 43,
769 107, 43, 44, 49, 47, 117, 42, 56, 90, 53,
771 56, 107, 117, 56, 49, 108, 53, 148, 40, 40,
772 40, 40, 40, 40, 633, 40, 40, 148, 108, 40,
773 40, 40, 40, 40, 40, 40, 40, 40, 58, 58,
774 40, 59, 61, 59, 58, 175, 59, 59, 62, 62,
775 62, 62, 58, 175, 59, 58, 63, 63, 63, 63,
776 61, 61, 61, 61, 64, 64, 64, 64, 65, 65,
777 65, 65, 65, 65, 119, 632, 79, 79, 65, 66,
778 66, 66, 66, 66, 66, 66, 79, 158, 119, 67,
779 66, 67, 67, 67, 67, 67, 67, 158, 162, 162,
780 162, 162, 121, 65, 121, 121, 121, 121, 121, 121,
782 122, 122, 125, 125, 125, 66, 122, 629, 125, 135,
783 135, 627, 136, 136, 146, 135, 149, 122, 136, 125,
784 146, 625, 149, 232, 150, 150, 135, 151, 151, 136,
785 150, 622, 619, 151, 152, 152, 232, 150, 618, 260,
786 152, 150, 260, 617, 151, 163, 163, 163, 163, 616,
787 614, 152, 164, 164, 164, 164, 165, 165, 165, 165,
788 166, 166, 166, 166, 167, 167, 167, 167, 168, 168,
789 168, 168, 170, 170, 170, 170, 170, 170, 613, 612,
790 610, 171, 170, 171, 171, 171, 171, 171, 171, 172,
791 172, 172, 172, 172, 172, 173, 173, 173, 173, 173,
793 173, 228, 228, 228, 228, 228, 228, 170, 229, 229,
794 229, 229, 229, 229, 230, 230, 244, 244, 329, 249,
795 230, 609, 244, 262, 262, 275, 275, 275, 275, 262,
796 605, 230, 249, 244, 329, 263, 263, 264, 264, 604,
797 262, 263, 272, 264, 272, 603, 272, 276, 276, 276,
798 276, 602, 263, 600, 264, 277, 277, 277, 277, 272,
799 278, 278, 278, 278, 279, 279, 279, 279, 280, 280,
800 280, 280, 280, 280, 281, 281, 281, 281, 281, 281,
801 435, 598, 597, 435, 645, 645, 645, 645, 646, 596,
802 646, 647, 647, 648, 648, 595, 648, 594, 593, 590,
804 589, 587, 586, 585, 584, 583, 582, 580, 579, 578,
805 576, 574, 573, 570, 535, 534, 531, 530, 529, 528,
806 527, 526, 525, 524, 523, 522, 520, 517, 516, 515,
807 514, 513, 512, 511, 510, 509, 508, 507, 505, 504,
808 503, 502, 500, 498, 497, 496, 495, 494, 493, 492,
809 491, 490, 489, 488, 487, 486, 485, 484, 481, 480,
810 479, 478, 477, 476, 475, 474, 473, 472, 471, 470,
811 469, 468, 467, 466, 465, 463, 462, 461, 460, 459,
812 458, 457, 456, 455, 454, 453, 452, 451, 449, 448,
813 447, 446, 445, 443, 442, 441, 440, 439, 438, 437,
815 434, 433, 431, 430, 429, 428, 425, 424, 423, 422,
816 421, 420, 419, 417, 416, 415, 414, 413, 412, 411,
817 410, 409, 408, 407, 406, 405, 404, 403, 402, 400,
818 399, 398, 397, 396, 395, 394, 393, 392, 391, 390,
819 389, 388, 387, 386, 385, 384, 383, 382, 381, 379,
820 378, 377, 374, 373, 372, 371, 370, 369, 367, 365,
821 364, 363, 361, 360, 359, 358, 357, 356, 355, 354,
822 353, 352, 351, 350, 349, 348, 347, 346, 345, 344,
823 342, 341, 340, 339, 338, 337, 336, 333, 332, 331,
824 328, 327, 326, 325, 324, 323, 322, 321, 320, 319,
826 317, 316, 315, 314, 313, 312, 311, 309, 308, 307,
827 306, 305, 304, 303, 302, 301, 300, 299, 298, 297,
828 296, 295, 294, 293, 292, 291, 290, 288, 287, 286,
829 285, 284, 283, 282, 274, 273, 271, 270, 269, 268,
830 267, 266, 261, 259, 258, 257, 256, 255, 254, 253,
831 252, 250, 248, 247, 245, 243, 242, 239, 238, 237,
832 236, 235, 234, 233, 231, 227, 226, 225, 224, 223,
833 222, 221, 220, 219, 218, 217, 216, 215, 214, 213,
834 212, 211, 210, 209, 208, 207, 206, 205, 204, 203,
835 202, 201, 200, 199, 198, 197, 196, 195, 193, 192,
837 190, 189, 187, 185, 184, 183, 182, 181, 180, 179,
838 178, 176, 174, 161, 160, 159, 157, 156, 155, 154,
839 153, 147, 145, 144, 143, 142, 141, 140, 139, 138,
840 137, 134, 133, 132, 131, 130, 128, 127, 126, 124,
841 123, 120, 118, 116, 115, 114, 113, 112, 111, 110,
842 109, 106, 105, 104, 103, 102, 101, 100, 99, 98,
843 97, 96, 95, 94, 93, 92, 91, 89, 88, 87,
844 86, 85, 84, 83, 81, 80, 78, 77, 76, 75,
845 74, 73, 72, 71, 55, 54, 51, 50, 37, 36,
846 35, 34, 33, 32, 31, 30, 29, 28, 20, 14,
848 8, 7, 5, 3, 644, 644, 644, 644, 644, 644,
849 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
850 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
851 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
852 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
853 644, 644, 644, 644, 644, 644, 644, 644, 644, 644,
854 644, 644, 644, 644, 644, 644, 644, 644, 644, 644
857 /* The intent behind this definition is that it'll catch
858 * any uses of REJECT which flex missed.
860 #define REJECT reject_used_but_not_detected
861 #define yymore() yymore_used_but_not_detected
862 #define YY_MORE_ADJ 0
863 #define YY_RESTORE_YY_MORE_OFFSET
864 #line 1 "program_lexer.l"
865 #line 2 "program_lexer.l"
867 * Copyright © 2009 Intel Corporation
869 * Permission is hereby granted, free of charge, to any person obtaining a
870 * copy of this software and associated documentation files (the "Software"),
871 * to deal in the Software without restriction, including without limitation
872 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
873 * and/or sell copies of the Software, and to permit persons to whom the
874 * Software is furnished to do so, subject to the following conditions:
876 * The above copyright notice and this permission notice (including the next
877 * paragraph) shall be included in all copies or substantial portions of the
880 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
881 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
882 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
883 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
884 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
885 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
886 * DEALINGS IN THE SOFTWARE.
888 #include "main/glheader.h"
889 #include "prog_instruction.h"
891 #include "program_parser.h"
892 #include "program_parse.tab.h"
894 #define require_ARB_vp (yyextra->mode == ARB_vertex)
895 #define require_ARB_fp (yyextra->mode == ARB_fragment)
897 #define return_token_or_IDENTIFIER(condition, token) \
902 yylval->string = strdup(yytext); \
907 #define return_token_or_DOT(condition, token) \
918 #define return_opcode(condition, token, opcode, sat) \
921 yylval->temp_inst.Opcode = OPCODE_ ## opcode; \
922 yylval->temp_inst.SaturateMode = SATURATE_ ## sat; \
925 yylval->string = strdup(yytext); \
930 #define SWIZZLE_INVAL MAKE_SWIZZLE4(SWIZZLE_NIL, SWIZZLE_NIL, \
931 SWIZZLE_NIL, SWIZZLE_NIL)
934 mask_from_char(char c
)
955 swiz_from_char(char c
)
975 #define YY_USER_ACTION \
977 yylloc->first_column = yylloc->last_column; \
978 yylloc->last_column += yyleng; \
979 if ((yylloc->first_line == 1) \
980 && (yylloc->first_column == 1)) { \
981 yylloc->position = 1; \
983 yylloc->position += yylloc->last_column - yylloc->first_column; \
987 #define YY_EXTRA_TYPE struct asm_parser_state *
992 #ifndef YY_NO_UNISTD_H
993 /* Special case for "unistd.h", since it is non-ANSI. We include it way
994 * down here because we want the user's section 1 to have been scanned first.
995 * The user has a chance to override it with an option.
1000 #ifndef YY_EXTRA_TYPE
1001 #define YY_EXTRA_TYPE void *
1004 /* Holds the entire state of the reentrant scanner. */
1008 /* User-defined. Not touched by flex. */
1009 YY_EXTRA_TYPE yyextra_r
;
1011 /* The rest are the same as the globals declared in the non-reentrant scanner. */
1012 FILE *yyin_r
, *yyout_r
;
1013 size_t yy_buffer_stack_top
; /**< index of top of stack. */
1014 size_t yy_buffer_stack_max
; /**< capacity of stack. */
1015 YY_BUFFER_STATE
* yy_buffer_stack
; /**< Stack as an array. */
1022 int yy_did_buffer_switch_on_eof
;
1023 int yy_start_stack_ptr
;
1024 int yy_start_stack_depth
;
1025 int *yy_start_stack
;
1026 yy_state_type yy_last_accepting_state
;
1027 char* yy_last_accepting_cpos
;
1030 int yy_flex_debug_r
;
1040 }; /* end struct yyguts_t */
1042 static int yy_init_globals (yyscan_t yyscanner
);
1044 /* This must go here because YYSTYPE and YYLTYPE are included
1045 * from bison output in section 1.*/
1046 # define yylval yyg->yylval_r
1048 # define yylloc yyg->yylloc_r
1050 int yylex_init (yyscan_t
* scanner
);
1052 int yylex_init_extra (YY_EXTRA_TYPE user_defined
,yyscan_t
* scanner
);
1054 /* Accessor methods to globals.
1055 These are made visible to non-reentrant scanners for convenience. */
1057 int yylex_destroy (yyscan_t yyscanner
);
1059 int yyget_debug (yyscan_t yyscanner
);
1061 void yyset_debug (int debug_flag
,yyscan_t yyscanner
);
1063 YY_EXTRA_TYPE
yyget_extra (yyscan_t yyscanner
);
1065 void yyset_extra (YY_EXTRA_TYPE user_defined
,yyscan_t yyscanner
);
1067 FILE *yyget_in (yyscan_t yyscanner
);
1069 void yyset_in (FILE * in_str
,yyscan_t yyscanner
);
1071 FILE *yyget_out (yyscan_t yyscanner
);
1073 void yyset_out (FILE * out_str
,yyscan_t yyscanner
);
1075 int yyget_leng (yyscan_t yyscanner
);
1077 char *yyget_text (yyscan_t yyscanner
);
1079 int yyget_lineno (yyscan_t yyscanner
);
1081 void yyset_lineno (int line_number
,yyscan_t yyscanner
);
1083 YYSTYPE
* yyget_lval (yyscan_t yyscanner
);
1085 void yyset_lval (YYSTYPE
* yylval_param
,yyscan_t yyscanner
);
1087 YYLTYPE
*yyget_lloc (yyscan_t yyscanner
);
1089 void yyset_lloc (YYLTYPE
* yylloc_param
,yyscan_t yyscanner
);
1091 /* Macros after this point can all be overridden by user definitions in
1095 #ifndef YY_SKIP_YYWRAP
1097 extern "C" int yywrap (yyscan_t yyscanner
);
1099 extern int yywrap (yyscan_t yyscanner
);
1103 static void yyunput (int c
,char *buf_ptr
,yyscan_t yyscanner
);
1106 static void yy_flex_strncpy (char *,yyconst
char *,int ,yyscan_t yyscanner
);
1109 #ifdef YY_NEED_STRLEN
1110 static int yy_flex_strlen (yyconst
char * ,yyscan_t yyscanner
);
1116 static int yyinput (yyscan_t yyscanner
);
1118 static int input (yyscan_t yyscanner
);
1123 /* Amount of stuff to slurp up with each read. */
1124 #ifndef YY_READ_BUF_SIZE
1126 /* On IA-64, the buffer size is 16k, not 8k */
1127 #define YY_READ_BUF_SIZE 16384
1129 #define YY_READ_BUF_SIZE 8192
1130 #endif /* __ia64__ */
1133 /* Copy whatever the last rule matched to the standard output. */
1135 /* This used to be an fputs(), but since the string might contain NUL's,
1136 * we now use fwrite().
1138 #define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0)
1141 /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
1142 * is returned in "result".
1145 #define YY_INPUT(buf,result,max_size) \
1146 if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
1150 for ( n = 0; n < max_size && \
1151 (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
1152 buf[n] = (char) c; \
1154 buf[n++] = (char) c; \
1155 if ( c == EOF && ferror( yyin ) ) \
1156 YY_FATAL_ERROR( "input in flex scanner failed" ); \
1162 while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \
1164 if( errno != EINTR) \
1166 YY_FATAL_ERROR( "input in flex scanner failed" ); \
1177 /* No semi-colon after return; correct usage is to write "yyterminate();" -
1178 * we don't want an extra ';' after the "return" because that will cause
1179 * some compilers to complain about unreachable statements.
1182 #define yyterminate() return YY_NULL
1185 /* Number of entries by which start-condition stack grows. */
1186 #ifndef YY_START_STACK_INCR
1187 #define YY_START_STACK_INCR 25
1190 /* Report a fatal error. */
1191 #ifndef YY_FATAL_ERROR
1192 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner)
1195 /* end tables serialization structures and prototypes */
1197 /* Default declaration of generated scanner - a define so the user can
1198 * easily add parameters.
1201 #define YY_DECL_IS_OURS 1
1204 (YYSTYPE
* yylval_param
,YYLTYPE
* yylloc_param
,yyscan_t yyscanner
);
1206 #define YY_DECL int yylex \
1207 (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner)
1208 #endif /* !YY_DECL */
1210 /* Code executed at the beginning of each rule, after yytext and yyleng
1213 #ifndef YY_USER_ACTION
1214 #define YY_USER_ACTION
1217 /* Code executed at the end of each rule. */
1219 #define YY_BREAK break;
1222 #define YY_RULE_SETUP \
1225 /** The main scanner function which does all the work.
1229 register yy_state_type yy_current_state
;
1230 register char *yy_cp
, *yy_bp
;
1231 register int yy_act
;
1232 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
1234 #line 132 "program_lexer.l"
1237 #line 1238 "lex.yy.c"
1239 yylval
= yylval_param
;
1241 yylloc
= yylloc_param
;
1243 if ( !yyg
->yy_init
)
1251 if ( ! yyg
->yy_start
)
1252 yyg
->yy_start
= 1; /* first start state */
1260 if ( ! YY_CURRENT_BUFFER
) {
1261 yyensure_buffer_stack (yyscanner
);
1262 YY_CURRENT_BUFFER_LVALUE
=
1263 yy_create_buffer(yyin
,YY_BUF_SIZE
,yyscanner
);
1266 yy_load_buffer_state(yyscanner
);
1269 while ( 1 ) /* loops until end-of-file is reached */
1271 yy_cp
= yyg
->yy_c_buf_p
;
1273 /* Support of yytext. */
1274 *yy_cp
= yyg
->yy_hold_char
;
1276 /* yy_bp points to the position in yy_ch_buf of the start of
1281 yy_current_state
= yyg
->yy_start
;
1285 register YY_CHAR yy_c
= yy_ec
[YY_SC_TO_UI(*yy_cp
)];
1286 if ( yy_accept
[yy_current_state
] )
1288 yyg
->yy_last_accepting_state
= yy_current_state
;
1289 yyg
->yy_last_accepting_cpos
= yy_cp
;
1291 while ( yy_chk
[yy_base
[yy_current_state
] + yy_c
] != yy_current_state
)
1293 yy_current_state
= (int) yy_def
[yy_current_state
];
1294 if ( yy_current_state
>= 645 )
1295 yy_c
= yy_meta
[(unsigned int) yy_c
];
1297 yy_current_state
= yy_nxt
[yy_base
[yy_current_state
] + (unsigned int) yy_c
];
1300 while ( yy_base
[yy_current_state
] != 905 );
1303 yy_act
= yy_accept
[yy_current_state
];
1305 { /* have to back up */
1306 yy_cp
= yyg
->yy_last_accepting_cpos
;
1307 yy_current_state
= yyg
->yy_last_accepting_state
;
1308 yy_act
= yy_accept
[yy_current_state
];
1311 YY_DO_BEFORE_ACTION
;
1313 do_action
: /* This label is used only to access EOF actions. */
1316 { /* beginning of action switch */
1317 case 0: /* must back up */
1318 /* undo the effects of YY_DO_BEFORE_ACTION */
1319 *yy_cp
= yyg
->yy_hold_char
;
1320 yy_cp
= yyg
->yy_last_accepting_cpos
;
1321 yy_current_state
= yyg
->yy_last_accepting_state
;
1322 goto yy_find_action
;
1326 #line 134 "program_lexer.l"
1327 { return ARBvp_10
; }
1331 #line 135 "program_lexer.l"
1332 { return ARBfp_10
; }
1336 #line 136 "program_lexer.l"
1338 yylval
->integer
= at_address
;
1339 return_token_or_IDENTIFIER(require_ARB_vp
, ADDRESS
);
1344 #line 140 "program_lexer.l"
1349 #line 141 "program_lexer.l"
1354 #line 142 "program_lexer.l"
1359 #line 143 "program_lexer.l"
1364 #line 144 "program_lexer.l"
1369 #line 145 "program_lexer.l"
1374 #line 146 "program_lexer.l"
1375 { yylval
->integer
= at_temp
; return TEMP
; }
1379 #line 148 "program_lexer.l"
1380 { return_opcode( 1, VECTOR_OP
, ABS
, OFF
); }
1384 #line 149 "program_lexer.l"
1385 { return_opcode(require_ARB_fp
, VECTOR_OP
, ABS
, ZERO_ONE
); }
1389 #line 150 "program_lexer.l"
1390 { return_opcode( 1, BIN_OP
, ADD
, OFF
); }
1394 #line 151 "program_lexer.l"
1395 { return_opcode(require_ARB_fp
, BIN_OP
, ADD
, ZERO_ONE
); }
1399 #line 152 "program_lexer.l"
1400 { return_opcode(require_ARB_vp
, ARL
, ARL
, OFF
); }
1404 #line 154 "program_lexer.l"
1405 { return_opcode(require_ARB_fp
, TRI_OP
, CMP
, OFF
); }
1409 #line 155 "program_lexer.l"
1410 { return_opcode(require_ARB_fp
, TRI_OP
, CMP
, ZERO_ONE
); }
1414 #line 156 "program_lexer.l"
1415 { return_opcode(require_ARB_fp
, SCALAR_OP
, COS
, OFF
); }
1419 #line 157 "program_lexer.l"
1420 { return_opcode(require_ARB_fp
, SCALAR_OP
, COS
, ZERO_ONE
); }
1424 #line 159 "program_lexer.l"
1425 { return_opcode( 1, BIN_OP
, DP3
, OFF
); }
1429 #line 160 "program_lexer.l"
1430 { return_opcode(require_ARB_fp
, BIN_OP
, DP3
, ZERO_ONE
); }
1434 #line 161 "program_lexer.l"
1435 { return_opcode( 1, BIN_OP
, DP4
, OFF
); }
1439 #line 162 "program_lexer.l"
1440 { return_opcode(require_ARB_fp
, BIN_OP
, DP4
, ZERO_ONE
); }
1444 #line 163 "program_lexer.l"
1445 { return_opcode( 1, BIN_OP
, DPH
, OFF
); }
1449 #line 164 "program_lexer.l"
1450 { return_opcode(require_ARB_fp
, BIN_OP
, DPH
, ZERO_ONE
); }
1454 #line 165 "program_lexer.l"
1455 { return_opcode( 1, BIN_OP
, DST
, OFF
); }
1459 #line 166 "program_lexer.l"
1460 { return_opcode(require_ARB_fp
, BIN_OP
, DST
, ZERO_ONE
); }
1464 #line 168 "program_lexer.l"
1465 { return_opcode( 1, SCALAR_OP
, EX2
, OFF
); }
1469 #line 169 "program_lexer.l"
1470 { return_opcode(require_ARB_fp
, SCALAR_OP
, EX2
, ZERO_ONE
); }
1474 #line 170 "program_lexer.l"
1475 { return_opcode(require_ARB_vp
, SCALAR_OP
, EXP
, OFF
); }
1479 #line 172 "program_lexer.l"
1480 { return_opcode( 1, VECTOR_OP
, FLR
, OFF
); }
1484 #line 173 "program_lexer.l"
1485 { return_opcode(require_ARB_fp
, VECTOR_OP
, FLR
, ZERO_ONE
); }
1489 #line 174 "program_lexer.l"
1490 { return_opcode( 1, VECTOR_OP
, FRC
, OFF
); }
1494 #line 175 "program_lexer.l"
1495 { return_opcode(require_ARB_fp
, VECTOR_OP
, FRC
, ZERO_ONE
); }
1499 #line 177 "program_lexer.l"
1500 { return_opcode(require_ARB_fp
, KIL
, KIL
, OFF
); }
1504 #line 179 "program_lexer.l"
1505 { return_opcode( 1, VECTOR_OP
, LIT
, OFF
); }
1509 #line 180 "program_lexer.l"
1510 { return_opcode(require_ARB_fp
, VECTOR_OP
, LIT
, ZERO_ONE
); }
1514 #line 181 "program_lexer.l"
1515 { return_opcode( 1, SCALAR_OP
, LG2
, OFF
); }
1519 #line 182 "program_lexer.l"
1520 { return_opcode(require_ARB_fp
, SCALAR_OP
, LG2
, ZERO_ONE
); }
1524 #line 183 "program_lexer.l"
1525 { return_opcode(require_ARB_vp
, SCALAR_OP
, LOG
, OFF
); }
1529 #line 184 "program_lexer.l"
1530 { return_opcode(require_ARB_fp
, TRI_OP
, LRP
, OFF
); }
1534 #line 185 "program_lexer.l"
1535 { return_opcode(require_ARB_fp
, TRI_OP
, LRP
, ZERO_ONE
); }
1539 #line 187 "program_lexer.l"
1540 { return_opcode( 1, TRI_OP
, MAD
, OFF
); }
1544 #line 188 "program_lexer.l"
1545 { return_opcode(require_ARB_fp
, TRI_OP
, MAD
, ZERO_ONE
); }
1549 #line 189 "program_lexer.l"
1550 { return_opcode( 1, BIN_OP
, MAX
, OFF
); }
1554 #line 190 "program_lexer.l"
1555 { return_opcode(require_ARB_fp
, BIN_OP
, MAX
, ZERO_ONE
); }
1559 #line 191 "program_lexer.l"
1560 { return_opcode( 1, BIN_OP
, MIN
, OFF
); }
1564 #line 192 "program_lexer.l"
1565 { return_opcode(require_ARB_fp
, BIN_OP
, MIN
, ZERO_ONE
); }
1569 #line 193 "program_lexer.l"
1570 { return_opcode( 1, VECTOR_OP
, MOV
, OFF
); }
1574 #line 194 "program_lexer.l"
1575 { return_opcode(require_ARB_fp
, VECTOR_OP
, MOV
, ZERO_ONE
); }
1579 #line 195 "program_lexer.l"
1580 { return_opcode( 1, BIN_OP
, MUL
, OFF
); }
1584 #line 196 "program_lexer.l"
1585 { return_opcode(require_ARB_fp
, BIN_OP
, MUL
, ZERO_ONE
); }
1589 #line 198 "program_lexer.l"
1590 { return_opcode( 1, BINSC_OP
, POW
, OFF
); }
1594 #line 199 "program_lexer.l"
1595 { return_opcode(require_ARB_fp
, BINSC_OP
, POW
, ZERO_ONE
); }
1599 #line 201 "program_lexer.l"
1600 { return_opcode( 1, SCALAR_OP
, RCP
, OFF
); }
1604 #line 202 "program_lexer.l"
1605 { return_opcode(require_ARB_fp
, SCALAR_OP
, RCP
, ZERO_ONE
); }
1609 #line 203 "program_lexer.l"
1610 { return_opcode( 1, SCALAR_OP
, RSQ
, OFF
); }
1614 #line 204 "program_lexer.l"
1615 { return_opcode(require_ARB_fp
, SCALAR_OP
, RSQ
, ZERO_ONE
); }
1619 #line 206 "program_lexer.l"
1620 { return_opcode(require_ARB_fp
, SCALAR_OP
, SCS
, OFF
); }
1624 #line 207 "program_lexer.l"
1625 { return_opcode(require_ARB_fp
, SCALAR_OP
, SCS
, ZERO_ONE
); }
1629 #line 208 "program_lexer.l"
1630 { return_opcode( 1, BIN_OP
, SGE
, OFF
); }
1634 #line 209 "program_lexer.l"
1635 { return_opcode(require_ARB_fp
, BIN_OP
, SGE
, ZERO_ONE
); }
1639 #line 210 "program_lexer.l"
1640 { return_opcode(require_ARB_fp
, SCALAR_OP
, SIN
, OFF
); }
1644 #line 211 "program_lexer.l"
1645 { return_opcode(require_ARB_fp
, SCALAR_OP
, SIN
, ZERO_ONE
); }
1649 #line 212 "program_lexer.l"
1650 { return_opcode( 1, BIN_OP
, SLT
, OFF
); }
1654 #line 213 "program_lexer.l"
1655 { return_opcode(require_ARB_fp
, BIN_OP
, SLT
, ZERO_ONE
); }
1659 #line 214 "program_lexer.l"
1660 { return_opcode( 1, BIN_OP
, SUB
, OFF
); }
1664 #line 215 "program_lexer.l"
1665 { return_opcode(require_ARB_fp
, BIN_OP
, SUB
, ZERO_ONE
); }
1669 #line 216 "program_lexer.l"
1670 { return_opcode( 1, SWZ
, SWZ
, OFF
); }
1674 #line 217 "program_lexer.l"
1675 { return_opcode(require_ARB_fp
, SWZ
, SWZ
, ZERO_ONE
); }
1679 #line 219 "program_lexer.l"
1680 { return_opcode(require_ARB_fp
, SAMPLE_OP
, TEX
, OFF
); }
1684 #line 220 "program_lexer.l"
1685 { return_opcode(require_ARB_fp
, SAMPLE_OP
, TEX
, ZERO_ONE
); }
1689 #line 221 "program_lexer.l"
1690 { return_opcode(require_ARB_fp
, SAMPLE_OP
, TXB
, OFF
); }
1694 #line 222 "program_lexer.l"
1695 { return_opcode(require_ARB_fp
, SAMPLE_OP
, TXB
, ZERO_ONE
); }
1699 #line 223 "program_lexer.l"
1700 { return_opcode(require_ARB_fp
, SAMPLE_OP
, TXP
, OFF
); }
1704 #line 224 "program_lexer.l"
1705 { return_opcode(require_ARB_fp
, SAMPLE_OP
, TXP
, ZERO_ONE
); }
1709 #line 226 "program_lexer.l"
1710 { return_opcode( 1, BIN_OP
, XPD
, OFF
); }
1714 #line 227 "program_lexer.l"
1715 { return_opcode(require_ARB_fp
, BIN_OP
, XPD
, ZERO_ONE
); }
1719 #line 229 "program_lexer.l"
1720 { return_token_or_IDENTIFIER(require_ARB_vp
, VERTEX
); }
1724 #line 230 "program_lexer.l"
1725 { return_token_or_IDENTIFIER(require_ARB_fp
, FRAGMENT
); }
1729 #line 231 "program_lexer.l"
1734 #line 232 "program_lexer.l"
1739 #line 233 "program_lexer.l"
1744 #line 235 "program_lexer.l"
1749 #line 236 "program_lexer.l"
1750 { return_token_or_DOT(require_ARB_vp
, ATTENUATION
); }
1754 #line 237 "program_lexer.l"
1759 #line 238 "program_lexer.l"
1760 { return_token_or_DOT(require_ARB_vp
, CLIP
); }
1764 #line 239 "program_lexer.l"
1769 #line 240 "program_lexer.l"
1770 { return_token_or_DOT(require_ARB_fp
, DEPTH
); }
1774 #line 241 "program_lexer.l"
1779 #line 242 "program_lexer.l"
1780 { return DIRECTION
; }
1784 #line 243 "program_lexer.l"
1785 { return EMISSION
; }
1789 #line 244 "program_lexer.l"
1794 #line 245 "program_lexer.l"
1799 #line 246 "program_lexer.l"
1800 { return FOGCOORD
; }
1804 #line 247 "program_lexer.l"
1809 #line 248 "program_lexer.l"
1814 #line 249 "program_lexer.l"
1819 #line 250 "program_lexer.l"
1824 #line 251 "program_lexer.l"
1825 { return INVTRANS
; }
1829 #line 252 "program_lexer.l"
1834 #line 253 "program_lexer.l"
1835 { return LIGHTMODEL
; }
1839 #line 254 "program_lexer.l"
1840 { return LIGHTPROD
; }
1844 #line 255 "program_lexer.l"
1849 #line 256 "program_lexer.l"
1850 { return MATERIAL
; }
1854 #line 257 "program_lexer.l"
1855 { return MAT_PROGRAM
; }
1859 #line 258 "program_lexer.l"
1864 #line 259 "program_lexer.l"
1865 { return_token_or_DOT(require_ARB_vp
, MATRIXINDEX
); }
1869 #line 260 "program_lexer.l"
1870 { return MODELVIEW
; }
1874 #line 261 "program_lexer.l"
1879 #line 262 "program_lexer.l"
1880 { return_token_or_DOT(require_ARB_vp
, NORMAL
); }
1884 #line 263 "program_lexer.l"
1889 #line 264 "program_lexer.l"
1894 #line 265 "program_lexer.l"
1899 #line 266 "program_lexer.l"
1904 #line 267 "program_lexer.l"
1905 { return_token_or_DOT(require_ARB_vp
, POINT
); }
1909 #line 268 "program_lexer.l"
1910 { return_token_or_DOT(require_ARB_vp
, POINTSIZE
); }
1914 #line 269 "program_lexer.l"
1915 { return POSITION
; }
1919 #line 270 "program_lexer.l"
1924 #line 271 "program_lexer.l"
1925 { return PROJECTION
; }
1929 #line 272 "program_lexer.l"
1930 { return_token_or_DOT(require_ARB_fp
, RANGE
); }
1934 #line 273 "program_lexer.l"
1939 #line 274 "program_lexer.l"
1940 { return SCENECOLOR
; }
1944 #line 275 "program_lexer.l"
1945 { return SECONDARY
; }
1949 #line 276 "program_lexer.l"
1950 { return SHININESS
; }
1954 #line 277 "program_lexer.l"
1955 { return_token_or_DOT(require_ARB_vp
, SIZE
); }
1959 #line 278 "program_lexer.l"
1960 { return SPECULAR
; }
1964 #line 279 "program_lexer.l"
1969 #line 280 "program_lexer.l"
1970 { return TEXCOORD
; }
1974 #line 281 "program_lexer.l"
1975 { return_token_or_DOT(require_ARB_fp
, TEXENV
); }
1979 #line 282 "program_lexer.l"
1980 { return_token_or_DOT(require_ARB_vp
, TEXGEN
); }
1984 #line 283 "program_lexer.l"
1985 { return_token_or_DOT(require_ARB_vp
, TEXGEN_Q
); }
1989 #line 284 "program_lexer.l"
1990 { return_token_or_DOT(require_ARB_vp
, TEXGEN_S
); }
1994 #line 285 "program_lexer.l"
1995 { return_token_or_DOT(require_ARB_vp
, TEXGEN_T
); }
1999 #line 286 "program_lexer.l"
2004 #line 287 "program_lexer.l"
2005 { return TRANSPOSE
; }
2009 #line 288 "program_lexer.l"
2010 { return_token_or_DOT(require_ARB_vp
, VTXATTRIB
); }
2014 #line 289 "program_lexer.l"
2015 { return_token_or_DOT(require_ARB_vp
, WEIGHT
); }
2019 #line 291 "program_lexer.l"
2020 { return_token_or_IDENTIFIER(require_ARB_fp
, TEXTURE_UNIT
); }
2024 #line 292 "program_lexer.l"
2025 { return_token_or_IDENTIFIER(require_ARB_fp
, TEX_1D
); }
2029 #line 293 "program_lexer.l"
2030 { return_token_or_IDENTIFIER(require_ARB_fp
, TEX_2D
); }
2034 #line 294 "program_lexer.l"
2035 { return_token_or_IDENTIFIER(require_ARB_fp
, TEX_3D
); }
2039 #line 295 "program_lexer.l"
2040 { return_token_or_IDENTIFIER(require_ARB_fp
, TEX_CUBE
); }
2044 #line 296 "program_lexer.l"
2045 { return_token_or_IDENTIFIER(require_ARB_fp
, TEX_RECT
); }
2049 #line 298 "program_lexer.l"
2051 yylval
->string
= strdup(yytext
);
2057 #line 303 "program_lexer.l"
2062 #line 305 "program_lexer.l"
2064 yylval
->integer
= strtol(yytext
, NULL
, 10);
2070 #line 309 "program_lexer.l"
2072 yylval
->real
= strtod(yytext
, NULL
);
2077 /* rule 149 can match eol */
2078 *yy_cp
= yyg
->yy_hold_char
; /* undo effects of setting up yytext */
2079 yyg
->yy_c_buf_p
= yy_cp
-= 1;
2080 YY_DO_BEFORE_ACTION
; /* set up yytext again */
2082 #line 313 "program_lexer.l"
2084 yylval
->real
= strtod(yytext
, NULL
);
2090 #line 317 "program_lexer.l"
2092 yylval
->real
= strtod(yytext
, NULL
);
2098 #line 321 "program_lexer.l"
2100 yylval
->real
= strtod(yytext
, NULL
);
2106 #line 326 "program_lexer.l"
2108 yylval
->swiz_mask
.swizzle
= SWIZZLE_NOOP
;
2109 yylval
->swiz_mask
.mask
= WRITEMASK_XYZW
;
2115 #line 332 "program_lexer.l"
2117 yylval
->swiz_mask
.swizzle
= SWIZZLE_INVAL
;
2118 yylval
->swiz_mask
.mask
= WRITEMASK_XY
2119 | mask_from_char(yytext
[3]);
2125 #line 338 "program_lexer.l"
2127 yylval
->swiz_mask
.swizzle
= SWIZZLE_INVAL
;
2128 yylval
->swiz_mask
.mask
= WRITEMASK_XZW
;
2134 #line 343 "program_lexer.l"
2136 yylval
->swiz_mask
.swizzle
= SWIZZLE_INVAL
;
2137 yylval
->swiz_mask
.mask
= WRITEMASK_YZW
;
2143 #line 349 "program_lexer.l"
2145 yylval
->swiz_mask
.swizzle
= SWIZZLE_INVAL
;
2146 yylval
->swiz_mask
.mask
= WRITEMASK_X
2147 | mask_from_char(yytext
[2]);
2153 #line 355 "program_lexer.l"
2155 yylval
->swiz_mask
.swizzle
= SWIZZLE_INVAL
;
2156 yylval
->swiz_mask
.mask
= WRITEMASK_Y
2157 | mask_from_char(yytext
[2]);
2163 #line 361 "program_lexer.l"
2165 yylval
->swiz_mask
.swizzle
= SWIZZLE_INVAL
;
2166 yylval
->swiz_mask
.mask
= WRITEMASK_ZW
;
2172 #line 367 "program_lexer.l"
2174 const unsigned s
= swiz_from_char(yytext
[1]);
2175 yylval
->swiz_mask
.swizzle
= MAKE_SWIZZLE4(s
, s
, s
, s
);
2176 yylval
->swiz_mask
.mask
= mask_from_char(yytext
[1]);
2182 #line 374 "program_lexer.l"
2184 yylval
->swiz_mask
.swizzle
= MAKE_SWIZZLE4(swiz_from_char(yytext
[1]),
2185 swiz_from_char(yytext
[2]),
2186 swiz_from_char(yytext
[3]),
2187 swiz_from_char(yytext
[4]));
2188 yylval
->swiz_mask
.mask
= 0;
2194 #line 383 "program_lexer.l"
2196 yylval
->swiz_mask
.swizzle
= SWIZZLE_NOOP
;
2197 yylval
->swiz_mask
.mask
= WRITEMASK_XYZW
;
2198 return_token_or_DOT(require_ARB_fp
, MASK4
);
2203 #line 389 "program_lexer.l"
2205 yylval
->swiz_mask
.swizzle
= SWIZZLE_INVAL
;
2206 yylval
->swiz_mask
.mask
= WRITEMASK_XY
2207 | mask_from_char(yytext
[3]);
2208 return_token_or_DOT(require_ARB_fp
, MASK3
);
2213 #line 395 "program_lexer.l"
2215 yylval
->swiz_mask
.swizzle
= SWIZZLE_INVAL
;
2216 yylval
->swiz_mask
.mask
= WRITEMASK_XZW
;
2217 return_token_or_DOT(require_ARB_fp
, MASK3
);
2222 #line 400 "program_lexer.l"
2224 yylval
->swiz_mask
.swizzle
= SWIZZLE_INVAL
;
2225 yylval
->swiz_mask
.mask
= WRITEMASK_YZW
;
2226 return_token_or_DOT(require_ARB_fp
, MASK3
);
2231 #line 406 "program_lexer.l"
2233 yylval
->swiz_mask
.swizzle
= SWIZZLE_INVAL
;
2234 yylval
->swiz_mask
.mask
= WRITEMASK_X
2235 | mask_from_char(yytext
[2]);
2236 return_token_or_DOT(require_ARB_fp
, MASK2
);
2241 #line 412 "program_lexer.l"
2243 yylval
->swiz_mask
.swizzle
= SWIZZLE_INVAL
;
2244 yylval
->swiz_mask
.mask
= WRITEMASK_Y
2245 | mask_from_char(yytext
[2]);
2246 return_token_or_DOT(require_ARB_fp
, MASK2
);
2251 #line 418 "program_lexer.l"
2253 yylval
->swiz_mask
.swizzle
= SWIZZLE_INVAL
;
2254 yylval
->swiz_mask
.mask
= WRITEMASK_ZW
;
2255 return_token_or_DOT(require_ARB_fp
, MASK2
);
2260 #line 424 "program_lexer.l"
2262 const unsigned s
= swiz_from_char(yytext
[1]);
2263 yylval
->swiz_mask
.swizzle
= MAKE_SWIZZLE4(s
, s
, s
, s
);
2264 yylval
->swiz_mask
.mask
= mask_from_char(yytext
[1]);
2265 return_token_or_DOT(require_ARB_fp
, MASK1
);
2270 #line 432 "program_lexer.l"
2272 if (require_ARB_vp
) {
2275 yylval
->swiz_mask
.swizzle
= MAKE_SWIZZLE4(SWIZZLE_X
, SWIZZLE_X
,
2276 SWIZZLE_X
, SWIZZLE_X
);
2277 yylval
->swiz_mask
.mask
= WRITEMASK_X
;
2284 #line 443 "program_lexer.l"
2286 yylval
->swiz_mask
.swizzle
= MAKE_SWIZZLE4(swiz_from_char(yytext
[1]),
2287 swiz_from_char(yytext
[2]),
2288 swiz_from_char(yytext
[3]),
2289 swiz_from_char(yytext
[4]));
2290 yylval
->swiz_mask
.mask
= 0;
2291 return_token_or_DOT(require_ARB_fp
, SWIZZLE
);
2296 #line 452 "program_lexer.l"
2300 /* rule 172 can match eol */
2302 #line 454 "program_lexer.l"
2304 yylloc
->first_line
++;
2305 yylloc
->first_column
= 1;
2306 yylloc
->last_line
++;
2307 yylloc
->last_column
= 1;
2313 #line 461 "program_lexer.l"
2314 /* eat whitespace */ ;
2317 *yy_cp
= yyg
->yy_hold_char
; /* undo effects of setting up yytext */
2318 yyg
->yy_c_buf_p
= yy_cp
-= 1;
2319 YY_DO_BEFORE_ACTION
; /* set up yytext again */
2321 #line 462 "program_lexer.l"
2322 /* eat comments */ ;
2326 #line 463 "program_lexer.l"
2327 { return yytext
[0]; }
2331 #line 464 "program_lexer.l"
2334 #line 2335 "lex.yy.c"
2335 case YY_STATE_EOF(INITIAL
):
2338 case YY_END_OF_BUFFER
:
2340 /* Amount of text matched not including the EOB char. */
2341 int yy_amount_of_matched_text
= (int) (yy_cp
- yyg
->yytext_ptr
) - 1;
2343 /* Undo the effects of YY_DO_BEFORE_ACTION. */
2344 *yy_cp
= yyg
->yy_hold_char
;
2345 YY_RESTORE_YY_MORE_OFFSET
2347 if ( YY_CURRENT_BUFFER_LVALUE
->yy_buffer_status
== YY_BUFFER_NEW
)
2349 /* We're scanning a new file or input source. It's
2350 * possible that this happened because the user
2351 * just pointed yyin at a new source and called
2352 * yylex(). If so, then we have to assure
2353 * consistency between YY_CURRENT_BUFFER and our
2354 * globals. Here is the right place to do so, because
2355 * this is the first action (other than possibly a
2356 * back-up) that will match for the new input source.
2358 yyg
->yy_n_chars
= YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
;
2359 YY_CURRENT_BUFFER_LVALUE
->yy_input_file
= yyin
;
2360 YY_CURRENT_BUFFER_LVALUE
->yy_buffer_status
= YY_BUFFER_NORMAL
;
2363 /* Note that here we test for yy_c_buf_p "<=" to the position
2364 * of the first EOB in the buffer, since yy_c_buf_p will
2365 * already have been incremented past the NUL character
2366 * (since all states make transitions on EOB to the
2367 * end-of-buffer state). Contrast this with the test
2370 if ( yyg
->yy_c_buf_p
<= &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[yyg
->yy_n_chars
] )
2371 { /* This was really a NUL. */
2372 yy_state_type yy_next_state
;
2374 yyg
->yy_c_buf_p
= yyg
->yytext_ptr
+ yy_amount_of_matched_text
;
2376 yy_current_state
= yy_get_previous_state( yyscanner
);
2378 /* Okay, we're now positioned to make the NUL
2379 * transition. We couldn't have
2380 * yy_get_previous_state() go ahead and do it
2381 * for us because it doesn't know how to deal
2382 * with the possibility of jamming (and we don't
2383 * want to build jamming into it because then it
2384 * will run more slowly).
2387 yy_next_state
= yy_try_NUL_trans( yy_current_state
, yyscanner
);
2389 yy_bp
= yyg
->yytext_ptr
+ YY_MORE_ADJ
;
2391 if ( yy_next_state
)
2393 /* Consume the NUL. */
2394 yy_cp
= ++yyg
->yy_c_buf_p
;
2395 yy_current_state
= yy_next_state
;
2401 yy_cp
= yyg
->yy_c_buf_p
;
2402 goto yy_find_action
;
2406 else switch ( yy_get_next_buffer( yyscanner
) )
2408 case EOB_ACT_END_OF_FILE
:
2410 yyg
->yy_did_buffer_switch_on_eof
= 0;
2412 if ( yywrap(yyscanner
) )
2414 /* Note: because we've taken care in
2415 * yy_get_next_buffer() to have set up
2416 * yytext, we can now set up
2417 * yy_c_buf_p so that if some total
2418 * hoser (like flex itself) wants to
2419 * call the scanner after we return the
2420 * YY_NULL, it'll still work - another
2421 * YY_NULL will get returned.
2423 yyg
->yy_c_buf_p
= yyg
->yytext_ptr
+ YY_MORE_ADJ
;
2425 yy_act
= YY_STATE_EOF(YY_START
);
2431 if ( ! yyg
->yy_did_buffer_switch_on_eof
)
2437 case EOB_ACT_CONTINUE_SCAN
:
2439 yyg
->yytext_ptr
+ yy_amount_of_matched_text
;
2441 yy_current_state
= yy_get_previous_state( yyscanner
);
2443 yy_cp
= yyg
->yy_c_buf_p
;
2444 yy_bp
= yyg
->yytext_ptr
+ YY_MORE_ADJ
;
2447 case EOB_ACT_LAST_MATCH
:
2449 &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[yyg
->yy_n_chars
];
2451 yy_current_state
= yy_get_previous_state( yyscanner
);
2453 yy_cp
= yyg
->yy_c_buf_p
;
2454 yy_bp
= yyg
->yytext_ptr
+ YY_MORE_ADJ
;
2455 goto yy_find_action
;
2462 "fatal flex scanner internal error--no action found" );
2463 } /* end of action switch */
2464 } /* end of scanning one token */
2465 } /* end of yylex */
2467 /* yy_get_next_buffer - try to read in a new buffer
2469 * Returns a code representing an action:
2470 * EOB_ACT_LAST_MATCH -
2471 * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
2472 * EOB_ACT_END_OF_FILE - end of file
2474 static int yy_get_next_buffer (yyscan_t yyscanner
)
2476 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2477 register char *dest
= YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
;
2478 register char *source
= yyg
->yytext_ptr
;
2479 register int number_to_move
, i
;
2482 if ( yyg
->yy_c_buf_p
> &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[yyg
->yy_n_chars
+ 1] )
2484 "fatal flex scanner internal error--end of buffer missed" );
2486 if ( YY_CURRENT_BUFFER_LVALUE
->yy_fill_buffer
== 0 )
2487 { /* Don't try to fill the buffer, so this is an EOF. */
2488 if ( yyg
->yy_c_buf_p
- yyg
->yytext_ptr
- YY_MORE_ADJ
== 1 )
2490 /* We matched a single character, the EOB, so
2491 * treat this as a final EOF.
2493 return EOB_ACT_END_OF_FILE
;
2498 /* We matched some text prior to the EOB, first
2501 return EOB_ACT_LAST_MATCH
;
2505 /* Try to read more data. */
2507 /* First move last chars to start of buffer. */
2508 number_to_move
= (int) (yyg
->yy_c_buf_p
- yyg
->yytext_ptr
) - 1;
2510 for ( i
= 0; i
< number_to_move
; ++i
)
2511 *(dest
++) = *(source
++);
2513 if ( YY_CURRENT_BUFFER_LVALUE
->yy_buffer_status
== YY_BUFFER_EOF_PENDING
)
2514 /* don't do the read, it's not guaranteed to return an EOF,
2517 YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
= yyg
->yy_n_chars
= 0;
2522 YY_CURRENT_BUFFER_LVALUE
->yy_buf_size
- number_to_move
- 1;
2524 while ( num_to_read
<= 0 )
2525 { /* Not enough room in the buffer - grow it. */
2527 /* just a shorter name for the current buffer */
2528 YY_BUFFER_STATE b
= YY_CURRENT_BUFFER
;
2530 int yy_c_buf_p_offset
=
2531 (int) (yyg
->yy_c_buf_p
- b
->yy_ch_buf
);
2533 if ( b
->yy_is_our_buffer
)
2535 int new_size
= b
->yy_buf_size
* 2;
2537 if ( new_size
<= 0 )
2538 b
->yy_buf_size
+= b
->yy_buf_size
/ 8;
2540 b
->yy_buf_size
*= 2;
2542 b
->yy_ch_buf
= (char *)
2543 /* Include room in for 2 EOB chars. */
2544 yyrealloc((void *) b
->yy_ch_buf
,b
->yy_buf_size
+ 2 ,yyscanner
);
2547 /* Can't grow it, we don't own it. */
2550 if ( ! b
->yy_ch_buf
)
2552 "fatal error - scanner input buffer overflow" );
2554 yyg
->yy_c_buf_p
= &b
->yy_ch_buf
[yy_c_buf_p_offset
];
2556 num_to_read
= YY_CURRENT_BUFFER_LVALUE
->yy_buf_size
-
2561 if ( num_to_read
> YY_READ_BUF_SIZE
)
2562 num_to_read
= YY_READ_BUF_SIZE
;
2564 /* Read in more data. */
2565 YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[number_to_move
]),
2566 yyg
->yy_n_chars
, (size_t) num_to_read
);
2568 YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
= yyg
->yy_n_chars
;
2571 if ( yyg
->yy_n_chars
== 0 )
2573 if ( number_to_move
== YY_MORE_ADJ
)
2575 ret_val
= EOB_ACT_END_OF_FILE
;
2576 yyrestart(yyin
,yyscanner
);
2581 ret_val
= EOB_ACT_LAST_MATCH
;
2582 YY_CURRENT_BUFFER_LVALUE
->yy_buffer_status
=
2583 YY_BUFFER_EOF_PENDING
;
2588 ret_val
= EOB_ACT_CONTINUE_SCAN
;
2590 if ((yy_size_t
) (yyg
->yy_n_chars
+ number_to_move
) > YY_CURRENT_BUFFER_LVALUE
->yy_buf_size
) {
2591 /* Extend the array by 50%, plus the number we really need. */
2592 yy_size_t new_size
= yyg
->yy_n_chars
+ number_to_move
+ (yyg
->yy_n_chars
>> 1);
2593 YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
= (char *) yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
,new_size
,yyscanner
);
2594 if ( ! YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
)
2595 YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
2598 yyg
->yy_n_chars
+= number_to_move
;
2599 YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[yyg
->yy_n_chars
] = YY_END_OF_BUFFER_CHAR
;
2600 YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[yyg
->yy_n_chars
+ 1] = YY_END_OF_BUFFER_CHAR
;
2602 yyg
->yytext_ptr
= &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[0];
2607 /* yy_get_previous_state - get the state just before the EOB char was reached */
2609 static yy_state_type
yy_get_previous_state (yyscan_t yyscanner
)
2611 register yy_state_type yy_current_state
;
2612 register char *yy_cp
;
2613 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2615 yy_current_state
= yyg
->yy_start
;
2617 for ( yy_cp
= yyg
->yytext_ptr
+ YY_MORE_ADJ
; yy_cp
< yyg
->yy_c_buf_p
; ++yy_cp
)
2619 register YY_CHAR yy_c
= (*yy_cp
? yy_ec
[YY_SC_TO_UI(*yy_cp
)] : 1);
2620 if ( yy_accept
[yy_current_state
] )
2622 yyg
->yy_last_accepting_state
= yy_current_state
;
2623 yyg
->yy_last_accepting_cpos
= yy_cp
;
2625 while ( yy_chk
[yy_base
[yy_current_state
] + yy_c
] != yy_current_state
)
2627 yy_current_state
= (int) yy_def
[yy_current_state
];
2628 if ( yy_current_state
>= 645 )
2629 yy_c
= yy_meta
[(unsigned int) yy_c
];
2631 yy_current_state
= yy_nxt
[yy_base
[yy_current_state
] + (unsigned int) yy_c
];
2634 return yy_current_state
;
2637 /* yy_try_NUL_trans - try to make a transition on the NUL character
2640 * next_state = yy_try_NUL_trans( current_state );
2642 static yy_state_type
yy_try_NUL_trans (yy_state_type yy_current_state
, yyscan_t yyscanner
)
2644 register int yy_is_jam
;
2645 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
; /* This var may be unused depending upon options. */
2646 register char *yy_cp
= yyg
->yy_c_buf_p
;
2648 register YY_CHAR yy_c
= 1;
2649 if ( yy_accept
[yy_current_state
] )
2651 yyg
->yy_last_accepting_state
= yy_current_state
;
2652 yyg
->yy_last_accepting_cpos
= yy_cp
;
2654 while ( yy_chk
[yy_base
[yy_current_state
] + yy_c
] != yy_current_state
)
2656 yy_current_state
= (int) yy_def
[yy_current_state
];
2657 if ( yy_current_state
>= 645 )
2658 yy_c
= yy_meta
[(unsigned int) yy_c
];
2660 yy_current_state
= yy_nxt
[yy_base
[yy_current_state
] + (unsigned int) yy_c
];
2661 yy_is_jam
= (yy_current_state
== 644);
2663 return yy_is_jam
? 0 : yy_current_state
;
2666 static void yyunput (int c
, register char * yy_bp
, yyscan_t yyscanner
)
2668 register char *yy_cp
;
2669 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2671 yy_cp
= yyg
->yy_c_buf_p
;
2673 /* undo effects of setting up yytext */
2674 *yy_cp
= yyg
->yy_hold_char
;
2676 if ( yy_cp
< YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
+ 2 )
2677 { /* need to shift things up to make room */
2678 /* +2 for EOB chars. */
2679 register int number_to_move
= yyg
->yy_n_chars
+ 2;
2680 register char *dest
= &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[
2681 YY_CURRENT_BUFFER_LVALUE
->yy_buf_size
+ 2];
2682 register char *source
=
2683 &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[number_to_move
];
2685 while ( source
> YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
)
2686 *--dest
= *--source
;
2688 yy_cp
+= (int) (dest
- source
);
2689 yy_bp
+= (int) (dest
- source
);
2690 YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
=
2691 yyg
->yy_n_chars
= YY_CURRENT_BUFFER_LVALUE
->yy_buf_size
;
2693 if ( yy_cp
< YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
+ 2 )
2694 YY_FATAL_ERROR( "flex scanner push-back overflow" );
2697 *--yy_cp
= (char) c
;
2699 yyg
->yytext_ptr
= yy_bp
;
2700 yyg
->yy_hold_char
= *yy_cp
;
2701 yyg
->yy_c_buf_p
= yy_cp
;
2706 static int yyinput (yyscan_t yyscanner
)
2708 static int input (yyscan_t yyscanner
)
2713 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2715 *yyg
->yy_c_buf_p
= yyg
->yy_hold_char
;
2717 if ( *yyg
->yy_c_buf_p
== YY_END_OF_BUFFER_CHAR
)
2719 /* yy_c_buf_p now points to the character we want to return.
2720 * If this occurs *before* the EOB characters, then it's a
2721 * valid NUL; if not, then we've hit the end of the buffer.
2723 if ( yyg
->yy_c_buf_p
< &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[yyg
->yy_n_chars
] )
2724 /* This was really a NUL. */
2725 *yyg
->yy_c_buf_p
= '\0';
2728 { /* need more input */
2729 int offset
= yyg
->yy_c_buf_p
- yyg
->yytext_ptr
;
2732 switch ( yy_get_next_buffer( yyscanner
) )
2734 case EOB_ACT_LAST_MATCH
:
2735 /* This happens because yy_g_n_b()
2736 * sees that we've accumulated a
2737 * token and flags that we need to
2738 * try matching the token before
2739 * proceeding. But for input(),
2740 * there's no matching to consider.
2741 * So convert the EOB_ACT_LAST_MATCH
2742 * to EOB_ACT_END_OF_FILE.
2745 /* Reset buffer status. */
2746 yyrestart(yyin
,yyscanner
);
2750 case EOB_ACT_END_OF_FILE
:
2752 if ( yywrap(yyscanner
) )
2755 if ( ! yyg
->yy_did_buffer_switch_on_eof
)
2758 return yyinput(yyscanner
);
2760 return input(yyscanner
);
2764 case EOB_ACT_CONTINUE_SCAN
:
2765 yyg
->yy_c_buf_p
= yyg
->yytext_ptr
+ offset
;
2771 c
= *(unsigned char *) yyg
->yy_c_buf_p
; /* cast for 8-bit char's */
2772 *yyg
->yy_c_buf_p
= '\0'; /* preserve yytext */
2773 yyg
->yy_hold_char
= *++yyg
->yy_c_buf_p
;
2777 #endif /* ifndef YY_NO_INPUT */
2779 /** Immediately switch to a different input stream.
2780 * @param input_file A readable stream.
2781 * @param yyscanner The scanner object.
2782 * @note This function does not reset the start condition to @c INITIAL .
2784 void yyrestart (FILE * input_file
, yyscan_t yyscanner
)
2786 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2788 if ( ! YY_CURRENT_BUFFER
){
2789 yyensure_buffer_stack (yyscanner
);
2790 YY_CURRENT_BUFFER_LVALUE
=
2791 yy_create_buffer(yyin
,YY_BUF_SIZE
,yyscanner
);
2794 yy_init_buffer(YY_CURRENT_BUFFER
,input_file
,yyscanner
);
2795 yy_load_buffer_state(yyscanner
);
2798 /** Switch to a different input buffer.
2799 * @param new_buffer The new input buffer.
2800 * @param yyscanner The scanner object.
2802 void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer
, yyscan_t yyscanner
)
2804 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2806 /* TODO. We should be able to replace this entire function body
2808 * yypop_buffer_state();
2809 * yypush_buffer_state(new_buffer);
2811 yyensure_buffer_stack (yyscanner
);
2812 if ( YY_CURRENT_BUFFER
== new_buffer
)
2815 if ( YY_CURRENT_BUFFER
)
2817 /* Flush out information for old buffer. */
2818 *yyg
->yy_c_buf_p
= yyg
->yy_hold_char
;
2819 YY_CURRENT_BUFFER_LVALUE
->yy_buf_pos
= yyg
->yy_c_buf_p
;
2820 YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
= yyg
->yy_n_chars
;
2823 YY_CURRENT_BUFFER_LVALUE
= new_buffer
;
2824 yy_load_buffer_state(yyscanner
);
2826 /* We don't actually know whether we did this switch during
2827 * EOF (yywrap()) processing, but the only time this flag
2828 * is looked at is after yywrap() is called, so it's safe
2829 * to go ahead and always set it.
2831 yyg
->yy_did_buffer_switch_on_eof
= 1;
2834 static void yy_load_buffer_state (yyscan_t yyscanner
)
2836 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2837 yyg
->yy_n_chars
= YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
;
2838 yyg
->yytext_ptr
= yyg
->yy_c_buf_p
= YY_CURRENT_BUFFER_LVALUE
->yy_buf_pos
;
2839 yyin
= YY_CURRENT_BUFFER_LVALUE
->yy_input_file
;
2840 yyg
->yy_hold_char
= *yyg
->yy_c_buf_p
;
2843 /** Allocate and initialize an input buffer state.
2844 * @param file A readable stream.
2845 * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
2846 * @param yyscanner The scanner object.
2847 * @return the allocated buffer state.
2849 YY_BUFFER_STATE
yy_create_buffer (FILE * file
, int size
, yyscan_t yyscanner
)
2853 b
= (YY_BUFFER_STATE
) yyalloc(sizeof( struct yy_buffer_state
) ,yyscanner
);
2855 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
2857 b
->yy_buf_size
= size
;
2859 /* yy_ch_buf has to be 2 characters longer than the size given because
2860 * we need to put in 2 end-of-buffer characters.
2862 b
->yy_ch_buf
= (char *) yyalloc(b
->yy_buf_size
+ 2 ,yyscanner
);
2863 if ( ! b
->yy_ch_buf
)
2864 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
2866 b
->yy_is_our_buffer
= 1;
2868 yy_init_buffer(b
,file
,yyscanner
);
2873 /** Destroy the buffer.
2874 * @param b a buffer created with yy_create_buffer()
2875 * @param yyscanner The scanner object.
2877 void yy_delete_buffer (YY_BUFFER_STATE b
, yyscan_t yyscanner
)
2879 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2884 if ( b
== YY_CURRENT_BUFFER
) /* Not sure if we should pop here. */
2885 YY_CURRENT_BUFFER_LVALUE
= (YY_BUFFER_STATE
) 0;
2887 if ( b
->yy_is_our_buffer
)
2888 yyfree((void *) b
->yy_ch_buf
,yyscanner
);
2890 yyfree((void *) b
,yyscanner
);
2893 /* Initializes or reinitializes a buffer.
2894 * This function is sometimes called more than once on the same buffer,
2895 * such as during a yyrestart() or at EOF.
2897 static void yy_init_buffer (YY_BUFFER_STATE b
, FILE * file
, yyscan_t yyscanner
)
2901 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2903 yy_flush_buffer(b
,yyscanner
);
2905 b
->yy_input_file
= file
;
2906 b
->yy_fill_buffer
= 1;
2908 /* If b is the current buffer, then yy_init_buffer was _probably_
2909 * called from yyrestart() or through yy_get_next_buffer.
2910 * In that case, we don't want to reset the lineno or column.
2912 if (b
!= YY_CURRENT_BUFFER
){
2913 b
->yy_bs_lineno
= 1;
2914 b
->yy_bs_column
= 0;
2917 b
->yy_is_interactive
= 0;
2922 /** Discard all buffered characters. On the next scan, YY_INPUT will be called.
2923 * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
2924 * @param yyscanner The scanner object.
2926 void yy_flush_buffer (YY_BUFFER_STATE b
, yyscan_t yyscanner
)
2928 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2934 /* We always need two end-of-buffer characters. The first causes
2935 * a transition to the end-of-buffer state. The second causes
2936 * a jam in that state.
2938 b
->yy_ch_buf
[0] = YY_END_OF_BUFFER_CHAR
;
2939 b
->yy_ch_buf
[1] = YY_END_OF_BUFFER_CHAR
;
2941 b
->yy_buf_pos
= &b
->yy_ch_buf
[0];
2944 b
->yy_buffer_status
= YY_BUFFER_NEW
;
2946 if ( b
== YY_CURRENT_BUFFER
)
2947 yy_load_buffer_state(yyscanner
);
2950 /** Pushes the new state onto the stack. The new state becomes
2951 * the current state. This function will allocate the stack
2953 * @param new_buffer The new state.
2954 * @param yyscanner The scanner object.
2956 void yypush_buffer_state (YY_BUFFER_STATE new_buffer
, yyscan_t yyscanner
)
2958 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2959 if (new_buffer
== NULL
)
2962 yyensure_buffer_stack(yyscanner
);
2964 /* This block is copied from yy_switch_to_buffer. */
2965 if ( YY_CURRENT_BUFFER
)
2967 /* Flush out information for old buffer. */
2968 *yyg
->yy_c_buf_p
= yyg
->yy_hold_char
;
2969 YY_CURRENT_BUFFER_LVALUE
->yy_buf_pos
= yyg
->yy_c_buf_p
;
2970 YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
= yyg
->yy_n_chars
;
2973 /* Only push if top exists. Otherwise, replace top. */
2974 if (YY_CURRENT_BUFFER
)
2975 yyg
->yy_buffer_stack_top
++;
2976 YY_CURRENT_BUFFER_LVALUE
= new_buffer
;
2978 /* copied from yy_switch_to_buffer. */
2979 yy_load_buffer_state(yyscanner
);
2980 yyg
->yy_did_buffer_switch_on_eof
= 1;
2983 /** Removes and deletes the top of the stack, if present.
2984 * The next element becomes the new top.
2985 * @param yyscanner The scanner object.
2987 void yypop_buffer_state (yyscan_t yyscanner
)
2989 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2990 if (!YY_CURRENT_BUFFER
)
2993 yy_delete_buffer(YY_CURRENT_BUFFER
,yyscanner
);
2994 YY_CURRENT_BUFFER_LVALUE
= NULL
;
2995 if (yyg
->yy_buffer_stack_top
> 0)
2996 --yyg
->yy_buffer_stack_top
;
2998 if (YY_CURRENT_BUFFER
) {
2999 yy_load_buffer_state(yyscanner
);
3000 yyg
->yy_did_buffer_switch_on_eof
= 1;
3004 /* Allocates the stack if it does not exist.
3005 * Guarantees space for at least one push.
3007 static void yyensure_buffer_stack (yyscan_t yyscanner
)
3010 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3012 if (!yyg
->yy_buffer_stack
) {
3014 /* First allocation is just for 2 elements, since we don't know if this
3015 * scanner will even need a stack. We use 2 instead of 1 to avoid an
3016 * immediate realloc on the next call.
3019 yyg
->yy_buffer_stack
= (struct yy_buffer_state
**)yyalloc
3020 (num_to_alloc
* sizeof(struct yy_buffer_state
*)
3022 if ( ! yyg
->yy_buffer_stack
)
3023 YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
3025 memset(yyg
->yy_buffer_stack
, 0, num_to_alloc
* sizeof(struct yy_buffer_state
*));
3027 yyg
->yy_buffer_stack_max
= num_to_alloc
;
3028 yyg
->yy_buffer_stack_top
= 0;
3032 if (yyg
->yy_buffer_stack_top
>= (yyg
->yy_buffer_stack_max
) - 1){
3034 /* Increase the buffer to prepare for a possible push. */
3035 int grow_size
= 8 /* arbitrary grow size */;
3037 num_to_alloc
= yyg
->yy_buffer_stack_max
+ grow_size
;
3038 yyg
->yy_buffer_stack
= (struct yy_buffer_state
**)yyrealloc
3039 (yyg
->yy_buffer_stack
,
3040 num_to_alloc
* sizeof(struct yy_buffer_state
*)
3042 if ( ! yyg
->yy_buffer_stack
)
3043 YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
3045 /* zero only the new slots.*/
3046 memset(yyg
->yy_buffer_stack
+ yyg
->yy_buffer_stack_max
, 0, grow_size
* sizeof(struct yy_buffer_state
*));
3047 yyg
->yy_buffer_stack_max
= num_to_alloc
;
3051 /** Setup the input buffer state to scan directly from a user-specified character buffer.
3052 * @param base the character buffer
3053 * @param size the size in bytes of the character buffer
3054 * @param yyscanner The scanner object.
3055 * @return the newly allocated buffer state object.
3057 YY_BUFFER_STATE
yy_scan_buffer (char * base
, yy_size_t size
, yyscan_t yyscanner
)
3062 base
[size
-2] != YY_END_OF_BUFFER_CHAR
||
3063 base
[size
-1] != YY_END_OF_BUFFER_CHAR
)
3064 /* They forgot to leave room for the EOB's. */
3067 b
= (YY_BUFFER_STATE
) yyalloc(sizeof( struct yy_buffer_state
) ,yyscanner
);
3069 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
3071 b
->yy_buf_size
= size
- 2; /* "- 2" to take care of EOB's */
3072 b
->yy_buf_pos
= b
->yy_ch_buf
= base
;
3073 b
->yy_is_our_buffer
= 0;
3074 b
->yy_input_file
= 0;
3075 b
->yy_n_chars
= b
->yy_buf_size
;
3076 b
->yy_is_interactive
= 0;
3078 b
->yy_fill_buffer
= 0;
3079 b
->yy_buffer_status
= YY_BUFFER_NEW
;
3081 yy_switch_to_buffer(b
,yyscanner
);
3086 /** Setup the input buffer state to scan a string. The next call to yylex() will
3087 * scan from a @e copy of @a str.
3088 * @param yystr a NUL-terminated string to scan
3089 * @param yyscanner The scanner object.
3090 * @return the newly allocated buffer state object.
3091 * @note If you want to scan bytes that may contain NUL values, then use
3092 * yy_scan_bytes() instead.
3094 YY_BUFFER_STATE
yy_scan_string (yyconst
char * yystr
, yyscan_t yyscanner
)
3097 return yy_scan_bytes(yystr
,strlen(yystr
) ,yyscanner
);
3100 /** Setup the input buffer state to scan the given bytes. The next call to yylex() will
3101 * scan from a @e copy of @a bytes.
3102 * @param yybytes the byte buffer to scan
3103 * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
3104 * @param yyscanner The scanner object.
3105 * @return the newly allocated buffer state object.
3107 YY_BUFFER_STATE
yy_scan_bytes (yyconst
char * yybytes
, int _yybytes_len
, yyscan_t yyscanner
)
3114 /* Get memory for full buffer, including space for trailing EOB's. */
3115 n
= _yybytes_len
+ 2;
3116 buf
= (char *) yyalloc(n
,yyscanner
);
3118 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
3120 for ( i
= 0; i
< _yybytes_len
; ++i
)
3121 buf
[i
] = yybytes
[i
];
3123 buf
[_yybytes_len
] = buf
[_yybytes_len
+1] = YY_END_OF_BUFFER_CHAR
;
3125 b
= yy_scan_buffer(buf
,n
,yyscanner
);
3127 YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
3129 /* It's okay to grow etc. this buffer, and we should throw it
3130 * away when we're done.
3132 b
->yy_is_our_buffer
= 1;
3137 #ifndef YY_EXIT_FAILURE
3138 #define YY_EXIT_FAILURE 2
3141 static void yy_fatal_error (yyconst
char* msg
, yyscan_t yyscanner
)
3143 (void) fprintf( stderr
, "%s\n", msg
);
3144 exit( YY_EXIT_FAILURE
);
3147 /* Redefine yyless() so it works in section 3 code. */
3153 /* Undo effects of setting up yytext. */ \
3154 int yyless_macro_arg = (n); \
3155 YY_LESS_LINENO(yyless_macro_arg);\
3156 yytext[yyleng] = yyg->yy_hold_char; \
3157 yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
3158 yyg->yy_hold_char = *yyg->yy_c_buf_p; \
3159 *yyg->yy_c_buf_p = '\0'; \
3160 yyleng = yyless_macro_arg; \
3164 /* Accessor methods (get/set functions) to struct members. */
3166 /** Get the user-defined data for this scanner.
3167 * @param yyscanner The scanner object.
3169 YY_EXTRA_TYPE
yyget_extra (yyscan_t yyscanner
)
3171 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3175 /** Get the current line number.
3176 * @param yyscanner The scanner object.
3178 int yyget_lineno (yyscan_t yyscanner
)
3180 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3182 if (! YY_CURRENT_BUFFER
)
3188 /** Get the current column number.
3189 * @param yyscanner The scanner object.
3191 int yyget_column (yyscan_t yyscanner
)
3193 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3195 if (! YY_CURRENT_BUFFER
)
3201 /** Get the input stream.
3202 * @param yyscanner The scanner object.
3204 FILE *yyget_in (yyscan_t yyscanner
)
3206 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3210 /** Get the output stream.
3211 * @param yyscanner The scanner object.
3213 FILE *yyget_out (yyscan_t yyscanner
)
3215 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3219 /** Get the length of the current token.
3220 * @param yyscanner The scanner object.
3222 int yyget_leng (yyscan_t yyscanner
)
3224 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3228 /** Get the current token.
3229 * @param yyscanner The scanner object.
3232 char *yyget_text (yyscan_t yyscanner
)
3234 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3238 /** Set the user-defined data. This data is never touched by the scanner.
3239 * @param user_defined The data to be associated with this scanner.
3240 * @param yyscanner The scanner object.
3242 void yyset_extra (YY_EXTRA_TYPE user_defined
, yyscan_t yyscanner
)
3244 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3245 yyextra
= user_defined
;
3248 /** Set the current line number.
3249 * @param line_number
3250 * @param yyscanner The scanner object.
3252 void yyset_lineno (int line_number
, yyscan_t yyscanner
)
3254 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3256 /* lineno is only valid if an input buffer exists. */
3257 if (! YY_CURRENT_BUFFER
)
3258 yy_fatal_error( "yyset_lineno called with no buffer" , yyscanner
);
3260 yylineno
= line_number
;
3263 /** Set the current column.
3264 * @param line_number
3265 * @param yyscanner The scanner object.
3267 void yyset_column (int column_no
, yyscan_t yyscanner
)
3269 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3271 /* column is only valid if an input buffer exists. */
3272 if (! YY_CURRENT_BUFFER
)
3273 yy_fatal_error( "yyset_column called with no buffer" , yyscanner
);
3275 yycolumn
= column_no
;
3278 /** Set the input stream. This does not discard the current
3280 * @param in_str A readable stream.
3281 * @param yyscanner The scanner object.
3282 * @see yy_switch_to_buffer
3284 void yyset_in (FILE * in_str
, yyscan_t yyscanner
)
3286 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3290 void yyset_out (FILE * out_str
, yyscan_t yyscanner
)
3292 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3296 int yyget_debug (yyscan_t yyscanner
)
3298 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3299 return yy_flex_debug
;
3302 void yyset_debug (int bdebug
, yyscan_t yyscanner
)
3304 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3305 yy_flex_debug
= bdebug
;
3308 /* Accessor methods for yylval and yylloc */
3310 YYSTYPE
* yyget_lval (yyscan_t yyscanner
)
3312 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3316 void yyset_lval (YYSTYPE
* yylval_param
, yyscan_t yyscanner
)
3318 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3319 yylval
= yylval_param
;
3322 YYLTYPE
*yyget_lloc (yyscan_t yyscanner
)
3324 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3328 void yyset_lloc (YYLTYPE
* yylloc_param
, yyscan_t yyscanner
)
3330 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3331 yylloc
= yylloc_param
;
3334 /* User-visible API */
3336 /* yylex_init is special because it creates the scanner itself, so it is
3337 * the ONLY reentrant function that doesn't take the scanner as the last argument.
3338 * That's why we explicitly handle the declaration, instead of using our macros.
3341 int yylex_init(yyscan_t
* ptr_yy_globals
)
3344 if (ptr_yy_globals
== NULL
){
3349 *ptr_yy_globals
= (yyscan_t
) yyalloc ( sizeof( struct yyguts_t
), NULL
);
3351 if (*ptr_yy_globals
== NULL
){
3356 /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */
3357 memset(*ptr_yy_globals
,0x00,sizeof(struct yyguts_t
));
3359 return yy_init_globals ( *ptr_yy_globals
);
3362 /* yylex_init_extra has the same functionality as yylex_init, but follows the
3363 * convention of taking the scanner as the last argument. Note however, that
3364 * this is a *pointer* to a scanner, as it will be allocated by this call (and
3365 * is the reason, too, why this function also must handle its own declaration).
3366 * The user defined value in the first argument will be available to yyalloc in
3367 * the yyextra field.
3370 int yylex_init_extra(YY_EXTRA_TYPE yy_user_defined
,yyscan_t
* ptr_yy_globals
)
3373 struct yyguts_t dummy_yyguts
;
3375 yyset_extra (yy_user_defined
, &dummy_yyguts
);
3377 if (ptr_yy_globals
== NULL
){
3382 *ptr_yy_globals
= (yyscan_t
) yyalloc ( sizeof( struct yyguts_t
), &dummy_yyguts
);
3384 if (*ptr_yy_globals
== NULL
){
3389 /* By setting to 0xAA, we expose bugs in
3390 yy_init_globals. Leave at 0x00 for releases. */
3391 memset(*ptr_yy_globals
,0x00,sizeof(struct yyguts_t
));
3393 yyset_extra (yy_user_defined
, *ptr_yy_globals
);
3395 return yy_init_globals ( *ptr_yy_globals
);
3398 static int yy_init_globals (yyscan_t yyscanner
)
3400 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3401 /* Initialization is the same as for the non-reentrant scanner.
3402 * This function is called from yylex_destroy(), so don't allocate here.
3405 yyg
->yy_buffer_stack
= 0;
3406 yyg
->yy_buffer_stack_top
= 0;
3407 yyg
->yy_buffer_stack_max
= 0;
3408 yyg
->yy_c_buf_p
= (char *) 0;
3412 yyg
->yy_start_stack_ptr
= 0;
3413 yyg
->yy_start_stack_depth
= 0;
3414 yyg
->yy_start_stack
= NULL
;
3416 /* Defined in main.c */
3425 /* For future reference: Set errno on error, since we are called by
3431 /* yylex_destroy is for both reentrant and non-reentrant scanners. */
3432 int yylex_destroy (yyscan_t yyscanner
)
3434 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3436 /* Pop the buffer stack, destroying each element. */
3437 while(YY_CURRENT_BUFFER
){
3438 yy_delete_buffer(YY_CURRENT_BUFFER
,yyscanner
);
3439 YY_CURRENT_BUFFER_LVALUE
= NULL
;
3440 yypop_buffer_state(yyscanner
);
3443 /* Destroy the stack itself. */
3444 yyfree(yyg
->yy_buffer_stack
,yyscanner
);
3445 yyg
->yy_buffer_stack
= NULL
;
3447 /* Destroy the start condition stack. */
3448 yyfree(yyg
->yy_start_stack
,yyscanner
);
3449 yyg
->yy_start_stack
= NULL
;
3451 /* Reset the globals. This is important in a non-reentrant scanner so the next time
3452 * yylex() is called, initialization will occur. */
3453 yy_init_globals( yyscanner
);
3455 /* Destroy the main struct (reentrant only). */
3456 yyfree ( yyscanner
, yyscanner
);
3462 * Internal utility routines.
3466 static void yy_flex_strncpy (char* s1
, yyconst
char * s2
, int n
, yyscan_t yyscanner
)
3469 for ( i
= 0; i
< n
; ++i
)
3474 #ifdef YY_NEED_STRLEN
3475 static int yy_flex_strlen (yyconst
char * s
, yyscan_t yyscanner
)
3478 for ( n
= 0; s
[n
]; ++n
)
3485 void *yyalloc (yy_size_t size
, yyscan_t yyscanner
)
3487 return (void *) malloc( size
);
3490 void *yyrealloc (void * ptr
, yy_size_t size
, yyscan_t yyscanner
)
3492 /* The cast to (char *) in the following accommodates both
3493 * implementations that use char* generic pointers, and those
3494 * that use void* generic pointers. It works with the latter
3495 * because both ANSI C and C++ allow castless assignment from
3496 * any pointer type to void*, and deal with argument conversions
3497 * as though doing an assignment.
3499 return (void *) realloc( (char *) ptr
, size
);
3502 void yyfree (void * ptr
, yyscan_t yyscanner
)
3504 free( (char *) ptr
); /* see yyrealloc() for (char *) cast */
3507 #define YYTABLES_NAME "yytables"
3509 #line 464 "program_lexer.l"
3514 _mesa_program_lexer_ctor(void **scanner
, struct asm_parser_state
*state
,
3515 const char *string
, size_t len
)
3517 yylex_init_extra(state
,scanner
);
3518 yy_scan_bytes(string
,len
,*scanner
);
3522 _mesa_program_lexer_dtor(void *scanner
)
3524 /* FINISHME: It's not clear to me whether or not the buffer state returned
3525 * FINISHME: by yy_scan_bytes in _mesa_program_lexer_ctor needs to be
3526 * FINISHME: explicitly destroyed here or not.
3528 yylex_destroy(scanner
);