• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #line 2 "src/chromium_gensrc/mesa/lex.yy.c"
2 
3 #line 4 "src/chromium_gensrc/mesa/lex.yy.c"
4 
5 #define  YY_INT_ALIGNED short int
6 
7 /* A lexical scanner generated by flex */
8 
9 #define FLEX_SCANNER
10 #define YY_FLEX_MAJOR_VERSION 2
11 #define YY_FLEX_MINOR_VERSION 5
12 #define YY_FLEX_SUBMINOR_VERSION 35
13 #if YY_FLEX_SUBMINOR_VERSION > 0
14 #define FLEX_BETA
15 #endif
16 
17 /* First, we deal with  platform-specific or compiler-specific issues. */
18 
19 /* begin standard C headers. */
20 #include <stdio.h>
21 #include <string.h>
22 #include <errno.h>
23 #include <stdlib.h>
24 
25 /* end standard C headers. */
26 
27 /* flex integer type definitions */
28 
29 #ifndef FLEXINT_H
30 #define FLEXINT_H
31 
32 /* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
33 
34 #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
35 
36 /* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
37  * if you want the limit (max/min) macros for int types.
38  */
39 #ifndef __STDC_LIMIT_MACROS
40 #define __STDC_LIMIT_MACROS 1
41 #endif
42 
43 #include <inttypes.h>
44 typedef int8_t flex_int8_t;
45 typedef uint8_t flex_uint8_t;
46 typedef int16_t flex_int16_t;
47 typedef uint16_t flex_uint16_t;
48 typedef int32_t flex_int32_t;
49 typedef uint32_t flex_uint32_t;
50 #else
51 typedef signed char flex_int8_t;
52 typedef short int flex_int16_t;
53 typedef int flex_int32_t;
54 typedef unsigned char flex_uint8_t;
55 typedef unsigned short int flex_uint16_t;
56 typedef unsigned int flex_uint32_t;
57 
58 /* Limits of integral types. */
59 #ifndef INT8_MIN
60 #define INT8_MIN               (-128)
61 #endif
62 #ifndef INT16_MIN
63 #define INT16_MIN              (-32767-1)
64 #endif
65 #ifndef INT32_MIN
66 #define INT32_MIN              (-2147483647-1)
67 #endif
68 #ifndef INT8_MAX
69 #define INT8_MAX               (127)
70 #endif
71 #ifndef INT16_MAX
72 #define INT16_MAX              (32767)
73 #endif
74 #ifndef INT32_MAX
75 #define INT32_MAX              (2147483647)
76 #endif
77 #ifndef UINT8_MAX
78 #define UINT8_MAX              (255U)
79 #endif
80 #ifndef UINT16_MAX
81 #define UINT16_MAX             (65535U)
82 #endif
83 #ifndef UINT32_MAX
84 #define UINT32_MAX             (4294967295U)
85 #endif
86 
87 #endif /* ! C99 */
88 
89 #endif /* ! FLEXINT_H */
90 
91 #ifdef __cplusplus
92 
93 /* The "const" storage-class-modifier is valid. */
94 #define YY_USE_CONST
95 
96 #else	/* ! __cplusplus */
97 
98 /* C99 requires __STDC__ to be defined as 1. */
99 #if defined (__STDC__)
100 
101 #define YY_USE_CONST
102 
103 #endif	/* defined (__STDC__) */
104 #endif	/* ! __cplusplus */
105 
106 #ifdef YY_USE_CONST
107 #define yyconst const
108 #else
109 #define yyconst
110 #endif
111 
112 /* Returned upon end-of-file. */
113 #define YY_NULL 0
114 
115 /* Promotes a possibly negative, possibly signed char to an unsigned
116  * integer for use as an array index.  If the signed char is negative,
117  * we want to instead treat it as an 8-bit unsigned char, hence the
118  * double cast.
119  */
120 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
121 
122 /* An opaque pointer. */
123 #ifndef YY_TYPEDEF_YY_SCANNER_T
124 #define YY_TYPEDEF_YY_SCANNER_T
125 typedef void* yyscan_t;
126 #endif
127 
128 /* For convenience, these vars (plus the bison vars far below)
129    are macros in the reentrant scanner. */
130 #define yyin yyg->yyin_r
131 #define yyout yyg->yyout_r
132 #define yyextra yyg->yyextra_r
133 #define yyleng yyg->yyleng_r
134 #define yytext yyg->yytext_r
135 #define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
136 #define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
137 #define yy_flex_debug yyg->yy_flex_debug_r
138 
139 /* Enter a start condition.  This macro really ought to take a parameter,
140  * but we do it the disgusting crufty way forced on us by the ()-less
141  * definition of BEGIN.
142  */
143 #define BEGIN yyg->yy_start = 1 + 2 *
144 
145 /* Translate the current start state into a value that can be later handed
146  * to BEGIN to return to the state.  The YYSTATE alias is for lex
147  * compatibility.
148  */
149 #define YY_START ((yyg->yy_start - 1) / 2)
150 #define YYSTATE YY_START
151 
152 /* Action number for EOF rule of a given start state. */
153 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
154 
155 /* Special action meaning "start processing a new file". */
156 #define YY_NEW_FILE _mesa_program_restart(yyin ,yyscanner )
157 
158 #define YY_END_OF_BUFFER_CHAR 0
159 
160 /* Size of default input buffer. */
161 #ifndef YY_BUF_SIZE
162 #ifdef __ia64__
163 /* On IA-64, the buffer size is 16k, not 8k.
164  * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
165  * Ditto for the __ia64__ case accordingly.
166  */
167 #define YY_BUF_SIZE 32768
168 #else
169 #define YY_BUF_SIZE 16384
170 #endif /* __ia64__ */
171 #endif
172 
173 /* The state buf must be large enough to hold one state per character in the main buffer.
174  */
175 #define YY_STATE_BUF_SIZE   ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
176 
177 #ifndef YY_TYPEDEF_YY_BUFFER_STATE
178 #define YY_TYPEDEF_YY_BUFFER_STATE
179 typedef struct yy_buffer_state *YY_BUFFER_STATE;
180 #endif
181 
182 #define EOB_ACT_CONTINUE_SCAN 0
183 #define EOB_ACT_END_OF_FILE 1
184 #define EOB_ACT_LAST_MATCH 2
185 
186     #define YY_LESS_LINENO(n)
187 
188 /* Return all but the first "n" matched characters back to the input stream. */
189 #define yyless(n) \
190 	do \
191 		{ \
192 		/* Undo effects of setting up yytext. */ \
193         int yyless_macro_arg = (n); \
194         YY_LESS_LINENO(yyless_macro_arg);\
195 		*yy_cp = yyg->yy_hold_char; \
196 		YY_RESTORE_YY_MORE_OFFSET \
197 		yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
198 		YY_DO_BEFORE_ACTION; /* set up yytext again */ \
199 		} \
200 	while ( 0 )
201 
202 #define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
203 
204 #ifndef YY_TYPEDEF_YY_SIZE_T
205 #define YY_TYPEDEF_YY_SIZE_T
206 typedef size_t yy_size_t;
207 #endif
208 
209 #ifndef YY_STRUCT_YY_BUFFER_STATE
210 #define YY_STRUCT_YY_BUFFER_STATE
211 struct yy_buffer_state
212 	{
213 	FILE *yy_input_file;
214 
215 	char *yy_ch_buf;		/* input buffer */
216 	char *yy_buf_pos;		/* current position in input buffer */
217 
218 	/* Size of input buffer in bytes, not including room for EOB
219 	 * characters.
220 	 */
221 	yy_size_t yy_buf_size;
222 
223 	/* Number of characters read into yy_ch_buf, not including EOB
224 	 * characters.
225 	 */
226 	int yy_n_chars;
227 
228 	/* Whether we "own" the buffer - i.e., we know we created it,
229 	 * and can realloc() it to grow it, and should free() it to
230 	 * delete it.
231 	 */
232 	int yy_is_our_buffer;
233 
234 	/* Whether this is an "interactive" input source; if so, and
235 	 * if we're using stdio for input, then we want to use getc()
236 	 * instead of fread(), to make sure we stop fetching input after
237 	 * each newline.
238 	 */
239 	int yy_is_interactive;
240 
241 	/* Whether we're considered to be at the beginning of a line.
242 	 * If so, '^' rules will be active on the next match, otherwise
243 	 * not.
244 	 */
245 	int yy_at_bol;
246 
247     int yy_bs_lineno; /**< The line count. */
248     int yy_bs_column; /**< The column count. */
249 
250 	/* Whether to try to fill the input buffer when we reach the
251 	 * end of it.
252 	 */
253 	int yy_fill_buffer;
254 
255 	int yy_buffer_status;
256 
257 #define YY_BUFFER_NEW 0
258 #define YY_BUFFER_NORMAL 1
259 	/* When an EOF's been seen but there's still some text to process
260 	 * then we mark the buffer as YY_EOF_PENDING, to indicate that we
261 	 * shouldn't try reading from the input source any more.  We might
262 	 * still have a bunch of tokens to match, though, because of
263 	 * possible backing-up.
264 	 *
265 	 * When we actually see the EOF, we change the status to "new"
266 	 * (via _mesa_program_restart()), so that the user can continue scanning by
267 	 * just pointing yyin at a new input file.
268 	 */
269 #define YY_BUFFER_EOF_PENDING 2
270 
271 	};
272 #endif /* !YY_STRUCT_YY_BUFFER_STATE */
273 
274 /* We provide macros for accessing buffer states in case in the
275  * future we want to put the buffer states in a more general
276  * "scanner state".
277  *
278  * Returns the top of the stack, or NULL.
279  */
280 #define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \
281                           ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \
282                           : NULL)
283 
284 /* Same as previous macro, but useful when we know that the buffer stack is not
285  * NULL or when we need an lvalue. For internal use only.
286  */
287 #define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
288 
289 void _mesa_program_restart (FILE *input_file ,yyscan_t yyscanner );
290 void _mesa_program__switch_to_buffer (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
291 YY_BUFFER_STATE _mesa_program__create_buffer (FILE *file,int size ,yyscan_t yyscanner );
292 void _mesa_program__delete_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
293 void _mesa_program__flush_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
294 void _mesa_program_push_buffer_state (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
295 void _mesa_program_pop_buffer_state (yyscan_t yyscanner );
296 
297 static void _mesa_program_ensure_buffer_stack (yyscan_t yyscanner );
298 static void _mesa_program__load_buffer_state (yyscan_t yyscanner );
299 static void _mesa_program__init_buffer (YY_BUFFER_STATE b,FILE *file ,yyscan_t yyscanner );
300 
301 #define YY_FLUSH_BUFFER _mesa_program__flush_buffer(YY_CURRENT_BUFFER ,yyscanner)
302 
303 YY_BUFFER_STATE _mesa_program__scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner );
304 YY_BUFFER_STATE _mesa_program__scan_string (yyconst char *yy_str ,yyscan_t yyscanner );
305 YY_BUFFER_STATE _mesa_program__scan_bytes (yyconst char *bytes,int len ,yyscan_t yyscanner );
306 
307 void *_mesa_program_alloc (yy_size_t ,yyscan_t yyscanner );
308 void *_mesa_program_realloc (void *,yy_size_t ,yyscan_t yyscanner );
309 void _mesa_program_free (void * ,yyscan_t yyscanner );
310 
311 #define yy_new_buffer _mesa_program__create_buffer
312 
313 #define yy_set_interactive(is_interactive) \
314 	{ \
315 	if ( ! YY_CURRENT_BUFFER ){ \
316         _mesa_program_ensure_buffer_stack (yyscanner); \
317 		YY_CURRENT_BUFFER_LVALUE =    \
318             _mesa_program__create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
319 	} \
320 	YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
321 	}
322 
323 #define yy_set_bol(at_bol) \
324 	{ \
325 	if ( ! YY_CURRENT_BUFFER ){\
326         _mesa_program_ensure_buffer_stack (yyscanner); \
327 		YY_CURRENT_BUFFER_LVALUE =    \
328             _mesa_program__create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
329 	} \
330 	YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
331 	}
332 
333 #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
334 
335 /* Begin user sect3 */
336 
337 #define _mesa_program_wrap(n) 1
338 #define YY_SKIP_YYWRAP
339 
340 typedef unsigned char YY_CHAR;
341 
342 typedef int yy_state_type;
343 
344 #define yytext_ptr yytext_r
345 
346 static yy_state_type yy_get_previous_state (yyscan_t yyscanner );
347 static yy_state_type yy_try_NUL_trans (yy_state_type current_state  ,yyscan_t yyscanner);
348 static int yy_get_next_buffer (yyscan_t yyscanner );
349 static void yy_fatal_error (yyconst char msg[] ,yyscan_t yyscanner );
350 
351 /* Done after the current pattern has been matched and before the
352  * corresponding action - sets up yytext.
353  */
354 #define YY_DO_BEFORE_ACTION \
355 	yyg->yytext_ptr = yy_bp; \
356 	yyleng = (size_t) (yy_cp - yy_bp); \
357 	yyg->yy_hold_char = *yy_cp; \
358 	*yy_cp = '\0'; \
359 	yyg->yy_c_buf_p = yy_cp;
360 
361 #define YY_NUM_RULES 170
362 #define YY_END_OF_BUFFER 171
363 /* This struct is not used in this scanner,
364    but its presence is necessary. */
365 struct yy_trans_info
366 	{
367 	flex_int32_t yy_verify;
368 	flex_int32_t yy_nxt;
369 	};
370 static yyconst flex_int16_t yy_accept[850] =
371     {   0,
372         0,    0,  171,  169,  167,  166,  169,  169,  139,  165,
373       141,  141,  141,  141,  139,  139,  139,  139,  139,  139,
374       139,  139,  139,  139,  139,  139,  139,  139,  139,  139,
375       139,  139,  139,  139,  139,  167,    0,    0,  168,  139,
376         0,  140,  142,  162,  162,    0,    0,    0,    0,  162,
377         0,    0,    0,    0,    0,    0,    0,  119,  163,  120,
378       121,  153,  153,  153,  153,    0,  141,    0,  127,  128,
379       129,  139,  139,  139,  139,  139,  139,  139,  139,  139,
380       139,  139,  139,  139,  139,  139,  139,  139,  139,  139,
381       139,  139,  139,  139,  139,  139,  139,  139,  139,  139,
382 
383       139,  139,  139,  139,  139,  139,  139,  139,  139,  139,
384       139,  139,  139,  139,  139,  139,  139,  139,  139,  139,
385       139,  139,  139,  139,  139,  139,    0,    0,    0,    0,
386         0,    0,    0,    0,    0,  161,    0,    0,    0,    0,
387         0,    0,    0,    0,    0,  160,  160,    0,    0,    0,
388         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
389       159,  159,  159,    0,    0,    0,    0,    0,    0,    0,
390         0,    0,    0,  150,  150,  150,  151,  151,  152,  143,
391       142,  143,    0,  144,   11,   12,  139,   13,  139,  139,
392        14,   15,  139,   16,   17,   18,   19,   20,   21,    6,
393 
394        22,   23,   24,   25,   26,   28,   27,   29,   30,   31,
395        32,   33,   34,   35,  139,  139,  139,  139,  139,   40,
396        41,  139,   42,   43,   44,   45,   46,   47,   48,  139,
397        49,   50,   51,   52,   53,   54,   55,  139,   56,   57,
398        58,   59,  139,  139,   64,   65,  139,  139,  139,  139,
399       139,  139,    0,    0,    0,    0,  142,    0,    0,    0,
400         0,    0,    0,    0,    0,    0,    0,   80,   81,   83,
401         0,  158,    0,    0,    0,    0,    0,    0,   97,    0,
402         0,    0,    0,    0,    0,    0,    0,    0,    0,  157,
403       156,  156,  109,    0,    0,    0,    0,    0,    0,    0,
404 
405         0,    0,    0,  147,  147,  148,  149,    0,  145,   11,
406        11,  139,   12,   12,   12,  139,  139,  139,  139,  139,
407        15,   15,  139,  130,   16,   16,  139,   17,   17,  139,
408        18,   18,  139,   19,   19,  139,   20,   20,  139,   21,
409        21,  139,   22,   22,  139,   24,   24,  139,   25,   25,
410       139,   28,   28,  139,   27,   27,  139,   30,   30,  139,
411        31,   31,  139,   32,   32,  139,   33,   33,  139,   34,
412        34,  139,   35,   35,  139,  139,  139,  139,   36,  139,
413        38,  139,   40,   40,  139,   41,   41,  139,  131,   42,
414        42,  139,   43,   43,  139,  139,   45,   45,  139,   46,
415 
416        46,  139,   47,   47,  139,   48,   48,  139,  139,   49,
417        49,  139,   50,   50,  139,   51,   51,  139,   52,   52,
418       139,   53,   53,  139,   54,   54,  139,  139,   10,   56,
419       139,   57,  139,   58,  139,   59,  139,   60,  139,   62,
420       139,   64,   64,  139,  139,  139,  139,  139,  139,  139,
421       139,    0,  164,    0,    0,    0,   73,   74,    0,    0,
422         0,    0,    0,    0,    0,   85,    0,    0,    0,    0,
423         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
424         0,    0,    0,    0,  155,    0,    0,    0,  113,    0,
425       115,    0,    0,    0,    0,    0,    0,  154,  146,  139,
426 
427       139,  139,    4,  139,  139,  139,  139,  139,  139,  139,
428       139,  139,  139,  139,  139,  139,  139,  139,  139,  139,
429       139,  139,  139,  139,  139,  139,    9,   37,   39,  139,
430       139,  139,  139,  139,  139,  139,  139,  139,  139,  139,
431       139,  139,  139,  139,  139,  139,  139,  139,  139,  139,
432        60,  139,   61,   62,  139,   63,  139,  139,  139,  139,
433       139,   69,  139,  139,    0,    0,    0,    0,    0,   75,
434        76,    0,    0,    0,    0,   84,    0,    0,   88,   91,
435         0,    0,    0,    0,    0,    0,    0,  102,  103,    0,
436         0,    0,    0,  108,    0,    0,    0,    0,    0,    0,
437 
438         0,    0,    0,    0,  139,  139,  139,  139,  139,  139,
439         5,  139,  139,  139,  139,  139,  139,  139,  139,  139,
440       139,  139,  139,  139,  139,  139,  139,  139,  139,  139,
441         7,    8,  139,  139,  139,  139,  139,  139,  139,  139,
442       139,  139,  139,  139,  139,  139,  139,  139,  139,  139,
443       139,  139,  139,  139,   61,  139,  139,   63,  139,  139,
444       139,  139,  139,   70,  139,   66,    0,    0,    0,    0,
445       124,    0,    0,    0,    0,    0,    0,    0,    0,    0,
446        94,    0,   98,   99,    0,  101,    0,    0,    0,    0,
447         0,    0,    0,    0,    0,    0,  117,  118,    0,    0,
448 
449       125,   11,    3,   12,  135,  136,  139,   14,   15,   16,
450        17,   18,   19,   20,   21,   22,   24,   25,   28,   27,
451        30,   31,   32,   33,   34,   35,   40,   41,   42,   43,
452        44,   45,   46,   47,   48,  139,  139,  139,   49,   50,
453        51,   52,   53,   54,   55,   56,   57,   58,   59,  139,
454       139,  139,  139,   64,   65,  139,   68,  126,    0,    0,
455        71,    0,   77,    0,    0,    0,   86,    0,    0,    0,
456         0,    0,    0,  100,    0,    0,  106,   93,    0,    0,
457         0,    0,    0,    0,  122,    0,  139,  132,  133,  139,
458        60,  139,   62,  139,   67,    0,    0,    0,    0,   79,
459 
460        82,   87,    0,    0,   92,    0,    0,    0,  105,    0,
461         0,    0,    0,  114,  116,    0,  139,  139,   61,   63,
462         2,    1,    0,   78,    0,   90,    0,   96,  104,    0,
463         0,  111,  112,  123,  139,  134,    0,   89,    0,  107,
464       110,  139,   72,   95,  139,  139,  137,  138,    0
465     } ;
466 
467 static yyconst flex_int32_t yy_ec[256] =
468     {   0,
469         1,    1,    1,    1,    1,    1,    1,    1,    2,    3,
470         1,    1,    4,    1,    1,    1,    1,    1,    1,    1,
471         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
472         1,    2,    5,    1,    6,    7,    1,    1,    1,    1,
473         1,    1,    8,    1,    8,    9,    1,   10,   11,   12,
474        13,   14,   15,   15,   15,   15,   15,    1,    1,    1,
475         1,    1,    1,    1,   16,   17,   18,   19,   20,   21,
476        22,   23,   24,    7,   25,   26,   27,   28,   29,   30,
477        31,   32,   33,   34,   35,   36,   37,   38,   39,   40,
478         1,    1,    1,    1,   41,    1,   42,   43,   44,   45,
479 
480        46,   47,   48,   49,   50,   51,   52,   53,   54,   55,
481        56,   57,   58,   59,   60,   61,   62,   63,   64,   65,
482        66,   67,    1,    1,    1,    1,    1,    1,    1,    1,
483         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
484         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
485         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
486         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
487         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
488         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
489         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
490 
491         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
492         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
493         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
494         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
495         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
496         1,    1,    1,    1,    1
497     } ;
498 
499 static yyconst flex_int32_t yy_meta[68] =
500     {   0,
501         1,    1,    1,    1,    1,    1,    2,    1,    3,    2,
502         2,    2,    2,    2,    2,    2,    2,    2,    2,    2,
503         2,    2,    2,    2,    2,    2,    2,    2,    2,    2,
504         2,    2,    2,    2,    2,    2,    2,    2,    2,    2,
505         2,    2,    2,    2,    2,    2,    2,    2,    2,    2,
506         2,    2,    2,    2,    2,    2,    2,    2,    2,    2,
507         2,    2,    2,    2,    2,    2,    2
508     } ;
509 
510 static yyconst flex_int16_t yy_base[853] =
511     {   0,
512         0,    0, 1299, 1300,   66, 1300, 1293, 1294,    0,   69,
513        85,  128,  140,  152,  151,   58,   56,   63,   76, 1272,
514       158,  160,   39,  163,  173,  189,   52, 1265,   76, 1235,
515      1234, 1246, 1230, 1244, 1243,  105, 1272, 1284, 1300,    0,
516       225, 1300,  218,  160,  157,   20,  123,   66,  119,  192,
517      1244, 1230,   54,  162, 1228, 1240,  194, 1300,  200,  195,
518        98,  227,  196,  231,  235,  293,  305,  316, 1300, 1300,
519      1300, 1249, 1262, 1256,  223, 1245, 1248, 1244, 1259,  107,
520       298, 1241, 1255,  246, 1241, 1254, 1245, 1258, 1235, 1246,
521      1237,  182, 1238, 1229, 1238, 1229, 1228, 1229,  144, 1223,
522 
523      1229, 1240, 1231, 1225, 1222, 1223, 1227,  289, 1236, 1223,
524       302, 1230, 1217, 1231, 1207,   65,  315,  276, 1227, 1226,
525      1202, 1187, 1182, 1199, 1175, 1180, 1206,  279, 1195,  293,
526      1190,  342,  299, 1192, 1173,  317, 1183, 1179, 1174,  207,
527      1180, 1166, 1182, 1179, 1170,  320,  324, 1172, 1161, 1175,
528      1178, 1160, 1175, 1162, 1159, 1166,  284, 1174,  227,  288,
529       327,  342,  345, 1151, 1168, 1169, 1162, 1144,  318, 1145,
530      1167, 1158,  330,  341,  345,  349,  353,  357,  361, 1300,
531       419,  430,  436,  442,  440,  441, 1191,    0, 1190, 1173,
532      1163,  443, 1183,  444,  451,  468,  470,  472,  471,    0,
533 
534       496,    0,  497,  498,    0,  499,  500,    0,  524,  525,
535       526,  536,  537,  553, 1178, 1171, 1184,  354,  356,  561,
536       563, 1165,  564,  565, 1157,  580,  590,  591,  592, 1178,
537       593,  617,  618,  619,  629,  630, 1155, 1165,  330,  362,
538       419,  483,  445,  364,  646, 1153, 1145, 1144, 1129, 1129,
539      1128, 1127, 1170, 1142, 1130,  662,  669,  643, 1134,  487,
540      1131, 1125, 1125, 1119, 1132, 1132, 1117, 1300, 1300, 1132,
541      1120,  646, 1127,  135, 1124, 1130,  561, 1125, 1300, 1116,
542      1123, 1122, 1125, 1111, 1110, 1114, 1109,  448, 1114,  650,
543       653,  665, 1300, 1106, 1104, 1104, 1112, 1113, 1095,  670,
544 
545      1100, 1106,  486,  579,  655,  661,  668,  726,  732, 1112,
546       682, 1119, 1110,  688,  730, 1117, 1116, 1109, 1123, 1113,
547      1104,  712, 1111,    0, 1102,  731, 1109, 1100,  733, 1107,
548      1098,  734, 1105, 1096,  736, 1103, 1094,  737, 1101, 1092,
549       738, 1099, 1090,  739, 1097, 1088,  740, 1095, 1086,  741,
550      1093, 1084,  742, 1091, 1082,  743, 1089, 1080,  744, 1087,
551      1078,  745, 1085, 1076,  746, 1083, 1074,  747, 1081, 1072,
552       748, 1079, 1070,  749, 1077, 1080, 1073, 1080,    0, 1073,
553         0, 1088, 1063,  750, 1070, 1061,  751, 1068,    0, 1059,
554       752, 1066, 1057,  755, 1064, 1063, 1054,  758, 1061, 1052,
555 
556       776, 1059, 1050,  777, 1057, 1048,  779, 1055, 1058, 1045,
557       780, 1052, 1043,  782, 1050, 1041,  783, 1048, 1039,  784,
558      1046, 1037,  785, 1044, 1035,  786, 1042, 1041,    0, 1032,
559      1039, 1030, 1037, 1028, 1035, 1026, 1033,  787, 1032,  788,
560      1047, 1022,  789, 1029, 1028, 1006, 1000, 1005, 1011,  994,
561      1009,  424, 1300, 1008,  998, 1002, 1300, 1300,  992, 1001,
562       987, 1004,  987,  990,  984, 1300,  985,  984,  981,  988,
563       981,  989,  985,  995,  992,  974,  980,  987,  971,  970,
564       988,  970,  982,  981, 1300,  980,  970,  974, 1300,  961,
565      1300,  966,  966,  974,  957,  958,  968, 1300, 1300, 1000,
566 
567       982,  998,    0,  798,  996,  996,  995,  994,  993,  992,
568       991,  990,  989,  988,  987,  986,  985,  984,  983,  982,
569       981,  980,  979,  978,  965,  958,    0,    0,    0,  975,
570       974,  973,  972,  971,  970,  969,  968,  967,  945,  965,
571       964,  963,  962,  961,  960,  959,  958,  957,  956,  955,
572       929,  936,  793,  927,  934,  794,  950,  949,  918,  921,
573       901,    0,  902,  895,  902,  901,  902,  894,  912, 1300,
574      1300,  894,  892,  902,  895, 1300,  890,  907,  516, 1300,
575       898,  882,  883,  892,  883,  882,  882, 1300,  881,  890,
576       880,  896,  893, 1300,  892,  890,  879,  880,  876,  868,
577 
578       875,  870,  871,  866,  892,  892,  890,  904,  903,  898,
579         0,  886,  885,  884,  883,  882,  881,  880,  879,  878,
580       877,  876,  875,  874,  873,  872,  871,  870,  869,  868,
581         0,    0,  867,  866,  865,  864,  863,  862,  861,  860,
582       859,  804,  858,  857,  856,  855,  854,  853,  852,  851,
583       850,  849,  848,  865,  839,  846,  862,  836,  843,  841,
584       840,  818,  818,    0,  825,    0,  859,  858,  807,  825,
585      1300,  820,  815,  808,  804,  816,  806,  804,  800,  816,
586       807,  806, 1300, 1300,  809, 1300,  804,  797,  786,  797,
587       789,  793,  806,  801,  804,  786, 1300, 1300,  798,  787,
588 
589      1300,    0,    0,    0,    0,    0,  826,    0,    0,    0,
590         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
591         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
592         0,    0,    0,    0,    0,  814,  813,  802,    0,    0,
593         0,    0,    0,    0,    0,    0,    0,    0,    0,  785,
594       798,  779,  792,    0,    0,  656,    0,    0,  706,  702,
595      1300,  649, 1300,  648,  648,  654, 1300,  637,  645,  610,
596       612,  608,  608, 1300,  572,  583, 1300, 1300,  577,  573,
597       560,  557,  542,  555, 1300,  539,  573,    0,    0,  572,
598         0,  555,    0,  546,    0,  562,  551,  495,  479, 1300,
599 
600      1300, 1300,  481,  481, 1300,  480,  443,   31, 1300,  141,
601       166,  171,  186, 1300, 1300,  211,  236,  276,    0,    0,
602      1300, 1300,  290, 1300,  325, 1300,  346, 1300, 1300,  343,
603       341, 1300, 1300, 1300,  365,    0,  380, 1300,  371, 1300,
604      1300,  486, 1300, 1300,  451,  458,    0,    0, 1300,  836,
605       503,  839
606     } ;
607 
608 static yyconst flex_int16_t yy_def[853] =
609     {   0,
610       849,    1,  849,  849,  849,  849,  849,  850,  851,  849,
611       849,  849,  849,  849,  851,  851,  851,  851,  851,  851,
612       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
613       851,  851,  851,  851,  851,  849,  849,  850,  849,  851,
614       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
615       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
616       849,  849,  849,  849,  849,  852,  849,  849,  849,  849,
617       849,  851,  851,  851,  851,  851,  851,  851,  851,  851,
618       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
619       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
620 
621       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
622       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
623       851,  851,  851,  851,  851,  851,  849,  849,  849,  849,
624       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
625       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
626       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
627       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
628       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
629       849,  849,  849,  849,  851,  851,  851,  851,  851,  851,
630       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
631 
632       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
633       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
634       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
635       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
636       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
637       851,  851,  849,  849,  849,  849,  849,  849,  849,  849,
638       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
639       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
640       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
641       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
642 
643       849,  849,  849,  849,  849,  849,  849,  849,  849,  851,
644       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
645       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
646       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
647       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
648       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
649       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
650       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
651       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
652       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
653 
654       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
655       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
656       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
657       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
658       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
659       851,  849,  849,  849,  849,  849,  849,  849,  849,  849,
660       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
661       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
662       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
663       849,  849,  849,  849,  849,  849,  849,  849,  849,  851,
664 
665       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
666       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
667       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
668       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
669       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
670       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
671       851,  851,  851,  851,  849,  849,  849,  849,  849,  849,
672       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
673       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
674       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
675 
676       849,  849,  849,  849,  851,  851,  851,  851,  851,  851,
677       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
678       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
679       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
680       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
681       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
682       851,  851,  851,  851,  851,  851,  849,  849,  849,  849,
683       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
684       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
685       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
686 
687       849,  851,  851,  851,  851,  851,  851,  851,  851,  851,
688       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
689       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
690       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
691       851,  851,  851,  851,  851,  851,  851,  851,  851,  851,
692       851,  851,  851,  851,  851,  851,  851,  851,  849,  849,
693       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
694       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
695       849,  849,  849,  849,  849,  849,  851,  851,  851,  851,
696       851,  851,  851,  851,  851,  849,  849,  849,  849,  849,
697 
698       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
699       849,  849,  849,  849,  849,  849,  851,  851,  851,  851,
700       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
701       849,  849,  849,  849,  851,  851,  849,  849,  849,  849,
702       849,  851,  849,  849,  851,  851,  851,  851,    0,  849,
703       849,  849
704     } ;
705 
706 static yyconst flex_int16_t yy_nxt[1368] =
707     {   0,
708         4,    5,    6,    5,    7,    8,    9,    4,   10,   11,
709        12,   13,   14,   11,   11,   15,    9,   16,   17,   18,
710        19,    9,    9,    9,   20,   21,   22,    9,   23,   24,
711         9,   25,   26,   27,   28,    9,    9,   29,    9,    9,
712         9,    9,    9,    9,    9,    9,   30,    9,    9,    9,
713         9,    9,    9,    9,    9,    9,   31,    9,   32,   33,
714        34,    9,   35,    9,    9,    9,    9,   36,   96,   36,
715        41,  116,  137,   97,   80,  138,  829,   42,   43,   43,
716        43,   43,   43,   43,   77,   81,   78,  119,   82,  117,
717        83,  238,   79,   66,   67,   67,   67,   67,   67,   67,
718 
719        84,   85,  239,  150,   68,  120,   36,   86,   36,  151,
720        44,   45,   46,   47,   48,   49,   50,   51,   52,  141,
721       142,   53,   54,   55,   56,   57,   58,   59,   60,   61,
722        68,  143,   62,   63,   64,   65,   66,   67,   67,   67,
723        67,   67,   67,  170,  194,  195,   69,   68,   66,   67,
724        67,   67,   67,   67,   67,  218,  171,  219,   70,   68,
725        66,   67,   67,   67,   67,   67,   67,   72,  139,   73,
726        71,   68,  140,   68,  144,   92,   74,  145,   98,   88,
727       467,   89,   75,   93,   76,   68,   90,   99,   94,   91,
728       101,  100,  102,  103,   95,  468,  830,   68,  136,  133,
729 
730       210,  133,  133,  152,  133,  104,  105,  133,  106,  107,
731       108,  109,  110,  134,  111,  133,  112,  153,  133,  211,
732       135,  831,  113,  114,  154,  115,   41,   43,   43,   43,
733        43,   43,   43,  146,  147,  157,  832,  132,  165,  133,
734       166,  161,  162,  167,  168,  833,  158,  163,  188,  159,
735       133,  169,  160,  265,  189,  164,  834,  201,  133,  174,
736       173,  175,  176,  132,  835,  266,  128,  129,   46,   47,
737        48,   49,  172,   51,   52,  202,  285,   53,   54,   55,
738        56,   57,   58,  130,   60,   61,  286,  243,  131,  244,
739       173,  173,  173,  173,  177,  173,  173,  178,  179,  173,
740 
741       173,  173,  181,  181,  181,  181,  181,  181,  228,  836,
742       196,  197,  182,   66,   67,   67,   67,   67,   67,   67,
743       198,  232,  229,  183,   68,  184,  184,  184,  184,  184,
744       184,  240,  134,  241,  255,  233,  282,  287,  182,  135,
745       258,  258,  283,  288,  242,  837,  258,  430,  164,  256,
746        68,  257,  257,  257,  257,  257,  257,  258,  258,  258,
747       261,  258,  258,  298,  258,  272,  258,  258,  258,  258,
748       431,  258,  381,  299,  258,  258,  379,  838,  258,  432,
749       440,  289,  258,  290,  258,  258,  291,  292,  380,  258,
750       382,  839,  258,  303,  303,  303,  303,  840,  441,  841,
751 
752       258,  842,  433,  258,  303,  303,  303,  303,  304,  303,
753       303,  305,  306,  303,  303,  303,  303,  303,  303,  303,
754       307,  303,  303,  303,  303,  303,  303,  303,   43,   43,
755        43,   43,   43,   43,  843,  844,  434,  308,  132,  309,
756       309,  309,  309,  309,  309,  184,  184,  184,  184,  184,
757       184,  184,  184,  184,  184,  184,  184,  310,  313,  435,
758       321,  325,  311,  314,  132,  322,  326,  438,  328,  847,
759       565,  311,  315,  329,  322,  326,  848,  311,  314,  439,
760       312,  316,  329,  323,  327,  331,  566,  334,  340,  337,
761       332,  330,  335,  341,  338,  482,  845,  846,  483,  332,
762 
763       436,  335,  341,  338,   40,  332,  828,  335,  333,  338,
764       336,  342,  339,  343,  346,  349,  352,  355,  344,  347,
765       350,  353,  356,  437,  827,  826,  825,  344,  347,  350,
766       353,  356,  455,  824,  347,  350,  345,  348,  351,  354,
767       357,  358,  361,  364,  823,  456,  359,  362,  365,  498,
768       498,  498,  498,  367,  370,  359,  362,  365,  368,  371,
769       822,  359,  362,  365,  360,  363,  366,  368,  371,  678,
770       373,  821,  679,  368,  371,  374,  369,  372,  383,  820,
771       386,  390,  393,  384,  374,  387,  391,  394,  819,  818,
772       374,  817,  384,  375,  387,  391,  394,  397,  816,  815,
773 
774       814,  385,  398,  388,  392,  395,  471,  400,  403,  406,
775       410,  398,  401,  404,  407,  411,  813,  398,  812,  472,
776       399,  401,  404,  407,  411,  811,  810,  401,  404,  407,
777       402,  405,  408,  412,  413,  416,  419,  809,  808,  414,
778       417,  420,  498,  498,  498,  498,  422,  425,  414,  417,
779       420,  423,  426,  807,  414,  417,  420,  415,  418,  421,
780       423,  426,  806,  442,  805,  804,  423,  426,  443,  424,
781       427,  257,  257,  257,  257,  257,  257,  443,  257,  257,
782       257,  257,  257,  257,  453,  453,  444,  453,  453,  803,
783       453,  453,  453,  453,  453,  453,  802,  453,  801,  310,
784 
785       453,  453,  800,  799,  453,  313,  485,  453,  453,  798,
786       797,  453,  453,  492,  796,  493,  795,  494,  499,  498,
787       498,  498,  312,  453,  498,  498,  498,  498,  316,  321,
788       495,  498,  498,  498,  498,  309,  309,  309,  309,  309,
789       309,  309,  309,  309,  309,  309,  309,  313,  325,  501,
790       328,  331,  323,  334,  337,  340,  343,  346,  349,  352,
791       355,  358,  361,  364,  367,  370,  373,  383,  386,  390,
792       316,  327,  393,  330,  333,  397,  336,  339,  342,  345,
793       348,  351,  354,  357,  360,  363,  366,  369,  372,  375,
794       385,  388,  392,  400,  403,  395,  406,  410,  399,  413,
795 
796       416,  419,  422,  425,  551,  554,  442,  794,  608,  609,
797       655,  658,  793,  792,  736,  737,  402,  405,  791,  408,
798       412,  790,  415,  418,  421,  424,  427,  552,  555,  444,
799       610,  789,  788,  656,  659,  738,   38,   38,   38,  180,
800       180,  787,  786,  785,  784,  783,  782,  781,  780,  779,
801       778,  777,  776,  775,  774,  773,  772,  771,  770,  769,
802       768,  767,  766,  765,  764,  763,  762,  761,  760,  759,
803       758,  757,  756,  755,  754,  753,  659,  752,  751,  656,
804       750,  749,  748,  747,  746,  745,  744,  743,  742,  741,
805       740,  739,  735,  734,  733,  732,  731,  730,  729,  728,
806 
807       727,  726,  725,  724,  723,  722,  721,  720,  719,  718,
808       717,  716,  715,  714,  713,  712,  711,  710,  709,  708,
809       707,  706,  705,  704,  703,  702,  701,  700,  699,  698,
810       697,  696,  695,  694,  693,  692,  691,  690,  689,  688,
811       687,  686,  685,  684,  683,  682,  681,  680,  677,  676,
812       675,  674,  673,  672,  671,  670,  669,  668,  667,  666,
813       665,  664,  663,  662,  661,  660,  657,  555,  654,  552,
814       653,  652,  651,  650,  649,  648,  647,  646,  645,  644,
815       643,  642,  641,  640,  639,  638,  637,  636,  635,  634,
816       633,  632,  631,  630,  629,  628,  627,  626,  625,  624,
817 
818       623,  622,  621,  620,  619,  618,  617,  616,  615,  614,
819       613,  612,  611,  607,  606,  605,  604,  603,  602,  601,
820       600,  599,  598,  597,  596,  595,  594,  593,  592,  591,
821       590,  589,  588,  587,  586,  585,  584,  583,  582,  581,
822       580,  579,  578,  577,  576,  575,  574,  573,  572,  571,
823       570,  569,  568,  567,  564,  563,  562,  561,  560,  559,
824       558,  557,  444,  556,  553,  550,  437,  549,  435,  548,
825       433,  547,  431,  546,  545,  427,  544,  424,  543,  421,
826       542,  418,  541,  415,  540,  412,  539,  538,  408,  537,
827       405,  536,  402,  535,  399,  534,  533,  395,  532,  392,
828 
829       531,  388,  530,  385,  529,  528,  527,  526,  525,  524,
830       375,  523,  372,  522,  369,  521,  366,  520,  363,  519,
831       360,  518,  357,  517,  354,  516,  351,  515,  348,  514,
832       345,  513,  342,  512,  339,  511,  336,  510,  333,  509,
833       330,  508,  327,  507,  323,  506,  505,  504,  503,  502,
834       316,  500,  312,  497,  496,  491,  490,  489,  488,  487,
835       486,  484,  481,  480,  479,  478,  477,  476,  475,  474,
836       473,  470,  469,  466,  465,  464,  463,  462,  461,  460,
837       459,  458,  457,  454,  289,  261,  452,  451,  450,  449,
838       448,  447,  446,  445,  429,  428,  409,  396,  389,  378,
839 
840       377,  376,  324,  320,  319,  318,  317,  302,  301,  300,
841       297,  296,  295,  294,  293,  284,  281,  280,  279,  278,
842       277,  276,  275,  274,  273,  271,  270,  269,  268,  267,
843       264,  263,  262,  260,  259,  172,  254,  253,  252,  251,
844       250,  249,  248,  247,  246,  245,  237,  236,  235,  234,
845       231,  230,  227,  226,  225,  224,  223,  222,  221,  220,
846       217,  216,  215,  214,  213,  212,  209,  208,  207,  206,
847       205,  204,  203,  200,  199,  193,  192,  191,  190,  187,
848       186,  185,  156,  155,  149,  148,   39,  127,  126,  125,
849       124,  123,  122,  121,  118,   87,   39,   37,  849,    3,
850 
851       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
852       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
853       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
854       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
855       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
856       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
857       849,  849,  849,  849,  849,  849,  849
858     } ;
859 
860 static yyconst flex_int16_t yy_chk[1368] =
861     {   0,
862         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
863         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
864         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
865         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
866         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
867         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
868         1,    1,    1,    1,    1,    1,    1,    5,   23,    5,
869        10,   27,   46,   23,   17,   46,  808,   10,   10,   10,
870        10,   10,   10,   10,   16,   17,   16,   29,   17,   27,
871        18,  116,   16,   11,   11,   11,   11,   11,   11,   11,
872 
873        18,   19,  116,   53,   11,   29,   36,   19,   36,   53,
874        10,   10,   10,   10,   10,   10,   10,   10,   10,   48,
875        48,   10,   10,   10,   10,   10,   10,   10,   10,   10,
876        11,   48,   10,   10,   10,   10,   12,   12,   12,   12,
877        12,   12,   12,   61,   80,   80,   12,   12,   13,   13,
878        13,   13,   13,   13,   13,   99,   61,   99,   13,   13,
879        14,   14,   14,   14,   14,   14,   14,   15,   47,   15,
880        14,   14,   47,   12,   49,   22,   15,   49,   24,   21,
881       274,   21,   15,   22,   15,   13,   21,   24,   22,   21,
882        25,   24,   25,   25,   22,  274,  810,   14,   45,   45,
883 
884        92,   44,   44,   54,   45,   25,   26,   44,   26,   26,
885        26,   26,   26,   44,   26,   45,   26,   54,   44,   92,
886        44,  811,   26,   26,   54,   26,   41,   43,   43,   43,
887        43,   43,   43,   50,   50,   57,  812,   43,   60,   50,
888        60,   59,   59,   60,   60,  813,   57,   59,   75,   57,
889        50,   60,   57,  140,   75,   59,  816,   84,   59,   63,
890        63,   63,   63,   43,  817,  140,   41,   41,   41,   41,
891        41,   41,   62,   41,   41,   84,  159,   41,   41,   41,
892        41,   41,   41,   41,   41,   41,  159,  118,   41,  118,
893        62,   62,   62,   62,   64,   64,   64,   64,   65,   65,
894 
895        65,   65,   66,   66,   66,   66,   66,   66,  108,  818,
896        81,   81,   66,   67,   67,   67,   67,   67,   67,   67,
897        81,  111,  108,   68,   67,   68,   68,   68,   68,   68,
898        68,  117,  128,  117,  130,  111,  157,  160,   66,  128,
899       133,  133,  157,  160,  117,  823,  133,  239,  130,  132,
900        67,  132,  132,  132,  132,  132,  132,  133,  136,  136,
901       136,  146,  146,  169,  136,  147,  147,  146,  161,  161,
902       239,  147,  219,  169,  161,  136,  218,  825,  146,  240,
903       244,  161,  147,  162,  162,  161,  163,  163,  218,  162,
904       219,  827,  163,  173,  173,  173,  173,  830,  244,  831,
905 
906       162,  835,  240,  163,  174,  174,  174,  174,  175,  175,
907       175,  175,  176,  176,  176,  176,  177,  177,  177,  177,
908       178,  178,  178,  178,  179,  179,  179,  179,  181,  181,
909       181,  181,  181,  181,  837,  839,  241,  182,  181,  182,
910       182,  182,  182,  182,  182,  183,  183,  183,  183,  183,
911       183,  184,  184,  184,  184,  184,  184,  185,  186,  241,
912       192,  194,  185,  186,  181,  192,  194,  243,  195,  845,
913       452,  185,  186,  195,  192,  194,  846,  185,  186,  243,
914       185,  186,  195,  192,  194,  196,  452,  197,  199,  198,
915       196,  195,  197,  199,  198,  288,  842,  842,  288,  196,
916 
917       242,  197,  199,  198,  851,  196,  807,  197,  196,  198,
918       197,  199,  198,  201,  203,  204,  206,  207,  201,  203,
919       204,  206,  207,  242,  806,  804,  803,  201,  203,  204,
920       206,  207,  260,  799,  203,  204,  201,  203,  204,  206,
921       207,  209,  210,  211,  798,  260,  209,  210,  211,  303,
922       303,  303,  303,  212,  213,  209,  210,  211,  212,  213,
923       797,  209,  210,  211,  209,  210,  211,  212,  213,  579,
924       214,  796,  579,  212,  213,  214,  212,  213,  220,  794,
925       221,  223,  224,  220,  214,  221,  223,  224,  792,  790,
926       214,  787,  220,  214,  221,  223,  224,  226,  786,  784,
927 
928       783,  220,  226,  221,  223,  224,  277,  227,  228,  229,
929       231,  226,  227,  228,  229,  231,  782,  226,  781,  277,
930       226,  227,  228,  229,  231,  780,  779,  227,  228,  229,
931       227,  228,  229,  231,  232,  233,  234,  776,  775,  232,
932       233,  234,  304,  304,  304,  304,  235,  236,  232,  233,
933       234,  235,  236,  773,  232,  233,  234,  232,  233,  234,
934       235,  236,  772,  245,  771,  770,  235,  236,  245,  235,
935       236,  256,  256,  256,  256,  256,  256,  245,  257,  257,
936       257,  257,  257,  257,  258,  258,  245,  272,  272,  769,
937       258,  290,  290,  272,  291,  291,  768,  290,  766,  311,
938 
939       291,  258,  765,  764,  272,  314,  292,  292,  290,  762,
940       760,  291,  292,  300,  759,  300,  756,  300,  305,  305,
941       305,  305,  311,  292,  306,  306,  306,  306,  314,  322,
942       300,  307,  307,  307,  307,  308,  308,  308,  308,  308,
943       308,  309,  309,  309,  309,  309,  309,  315,  326,  315,
944       329,  332,  322,  335,  338,  341,  344,  347,  350,  353,
945       356,  359,  362,  365,  368,  371,  374,  384,  387,  391,
946       315,  326,  394,  329,  332,  398,  335,  338,  341,  344,
947       347,  350,  353,  356,  359,  362,  365,  368,  371,  374,
948       384,  387,  391,  401,  404,  394,  407,  411,  398,  414,
949 
950       417,  420,  423,  426,  438,  440,  443,  753,  504,  504,
951       553,  556,  752,  751,  642,  642,  401,  404,  750,  407,
952       411,  738,  414,  417,  420,  423,  426,  438,  440,  443,
953       504,  737,  736,  553,  556,  642,  850,  850,  850,  852,
954       852,  707,  700,  699,  696,  695,  694,  693,  692,  691,
955       690,  689,  688,  687,  685,  682,  681,  680,  679,  678,
956       677,  676,  675,  674,  673,  672,  670,  669,  668,  667,
957       665,  663,  662,  661,  660,  659,  658,  657,  656,  655,
958       654,  653,  652,  651,  650,  649,  648,  647,  646,  645,
959       644,  643,  641,  640,  639,  638,  637,  636,  635,  634,
960 
961       633,  630,  629,  628,  627,  626,  625,  624,  623,  622,
962       621,  620,  619,  618,  617,  616,  615,  614,  613,  612,
963       610,  609,  608,  607,  606,  605,  604,  603,  602,  601,
964       600,  599,  598,  597,  596,  595,  593,  592,  591,  590,
965       589,  587,  586,  585,  584,  583,  582,  581,  578,  577,
966       575,  574,  573,  572,  569,  568,  567,  566,  565,  564,
967       563,  561,  560,  559,  558,  557,  555,  554,  552,  551,
968       550,  549,  548,  547,  546,  545,  544,  543,  542,  541,
969       540,  539,  538,  537,  536,  535,  534,  533,  532,  531,
970       530,  526,  525,  524,  523,  522,  521,  520,  519,  518,
971 
972       517,  516,  515,  514,  513,  512,  511,  510,  509,  508,
973       507,  506,  505,  502,  501,  500,  497,  496,  495,  494,
974       493,  492,  490,  488,  487,  486,  484,  483,  482,  481,
975       480,  479,  478,  477,  476,  475,  474,  473,  472,  471,
976       470,  469,  468,  467,  465,  464,  463,  462,  461,  460,
977       459,  456,  455,  454,  451,  450,  449,  448,  447,  446,
978       445,  444,  442,  441,  439,  437,  436,  435,  434,  433,
979       432,  431,  430,  428,  427,  425,  424,  422,  421,  419,
980       418,  416,  415,  413,  412,  410,  409,  408,  406,  405,
981       403,  402,  400,  399,  397,  396,  395,  393,  392,  390,
982 
983       388,  386,  385,  383,  382,  380,  378,  377,  376,  375,
984       373,  372,  370,  369,  367,  366,  364,  363,  361,  360,
985       358,  357,  355,  354,  352,  351,  349,  348,  346,  345,
986       343,  342,  340,  339,  337,  336,  334,  333,  331,  330,
987       328,  327,  325,  323,  321,  320,  319,  318,  317,  316,
988       313,  312,  310,  302,  301,  299,  298,  297,  296,  295,
989       294,  289,  287,  286,  285,  284,  283,  282,  281,  280,
990       278,  276,  275,  273,  271,  270,  267,  266,  265,  264,
991       263,  262,  261,  259,  255,  254,  253,  252,  251,  250,
992       249,  248,  247,  246,  238,  237,  230,  225,  222,  217,
993 
994       216,  215,  193,  191,  190,  189,  187,  172,  171,  170,
995       168,  167,  166,  165,  164,  158,  156,  155,  154,  153,
996       152,  151,  150,  149,  148,  145,  144,  143,  142,  141,
997       139,  138,  137,  135,  134,  131,  129,  127,  126,  125,
998       124,  123,  122,  121,  120,  119,  115,  114,  113,  112,
999       110,  109,  107,  106,  105,  104,  103,  102,  101,  100,
1000        98,   97,   96,   95,   94,   93,   91,   90,   89,   88,
1001        87,   86,   85,   83,   82,   79,   78,   77,   76,   74,
1002        73,   72,   56,   55,   52,   51,   38,   37,   35,   34,
1003        33,   32,   31,   30,   28,   20,    8,    7,    3,  849,
1004 
1005       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
1006       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
1007       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
1008       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
1009       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
1010       849,  849,  849,  849,  849,  849,  849,  849,  849,  849,
1011       849,  849,  849,  849,  849,  849,  849
1012     } ;
1013 
1014 /* The intent behind this definition is that it'll catch
1015  * any uses of REJECT which flex missed.
1016  */
1017 #define REJECT reject_used_but_not_detected
1018 #define yymore() yymore_used_but_not_detected
1019 #define YY_MORE_ADJ 0
1020 #define YY_RESTORE_YY_MORE_OFFSET
1021 #line 1 "src/src/mesa/program/program_lexer.l"
1022 #line 2 "src/src/mesa/program/program_lexer.l"
1023 /*
1024  * Copyright © 2009 Intel Corporation
1025  *
1026  * Permission is hereby granted, free of charge, to any person obtaining a
1027  * copy of this software and associated documentation files (the "Software"),
1028  * to deal in the Software without restriction, including without limitation
1029  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
1030  * and/or sell copies of the Software, and to permit persons to whom the
1031  * Software is furnished to do so, subject to the following conditions:
1032  *
1033  * The above copyright notice and this permission notice (including the next
1034  * paragraph) shall be included in all copies or substantial portions of the
1035  * Software.
1036  *
1037  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
1038  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
1039  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
1040  * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
1041  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
1042  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
1043  * DEALINGS IN THE SOFTWARE.
1044  */
1045 #include "main/glheader.h"
1046 #include "main/imports.h"
1047 #include "program/prog_instruction.h"
1048 #include "program/prog_statevars.h"
1049 #include "program/symbol_table.h"
1050 #include "program/program_parser.h"
1051 #include "program/program_parse.tab.h"
1052 
1053 #define require_ARB_vp (yyextra->mode == ARB_vertex)
1054 #define require_ARB_fp (yyextra->mode == ARB_fragment)
1055 #define require_NV_fp  (yyextra->option.NV_fragment)
1056 #define require_shadow (yyextra->option.Shadow)
1057 #define require_rect   (yyextra->option.TexRect)
1058 #define require_texarray        (yyextra->option.TexArray)
1059 
1060 #ifndef HAVE_UNISTD_H
1061 #define YY_NO_UNISTD_H
1062 #endif
1063 
1064 #define return_token_or_IDENTIFIER(condition, token)	\
1065    do {							\
1066       if (condition) {					\
1067 	 return token;					\
1068       } else {						\
1069 	 return handle_ident(yyextra, yytext, yylval);	\
1070       }							\
1071    } while (0)
1072 
1073 #define return_token_or_DOT(condition, token)		\
1074    do {							\
1075       if (condition) {					\
1076 	 return token;					\
1077       } else {						\
1078 	 yyless(1);					\
1079 	 return DOT;					\
1080       }							\
1081    } while (0)
1082 
1083 
1084 #define return_opcode(condition, token, opcode, len)	\
1085    do {							\
1086       if (condition &&					\
1087 	  _mesa_parse_instruction_suffix(yyextra,	\
1088 					 yytext + len,	\
1089 					 & yylval->temp_inst)) {	\
1090 	 yylval->temp_inst.Opcode = OPCODE_ ## opcode;	\
1091 	 return token;					\
1092       } else {						\
1093 	 return handle_ident(yyextra, yytext, yylval);	\
1094       }							\
1095    } while (0)
1096 
1097 #define SWIZZLE_INVAL  MAKE_SWIZZLE4(SWIZZLE_NIL, SWIZZLE_NIL, \
1098 				     SWIZZLE_NIL, SWIZZLE_NIL)
1099 
1100 static unsigned
mask_from_char(char c)1101 mask_from_char(char c)
1102 {
1103    switch (c) {
1104    case 'x':
1105    case 'r':
1106       return WRITEMASK_X;
1107    case 'y':
1108    case 'g':
1109       return WRITEMASK_Y;
1110    case 'z':
1111    case 'b':
1112       return WRITEMASK_Z;
1113    case 'w':
1114    case 'a':
1115       return WRITEMASK_W;
1116    }
1117 
1118    return 0;
1119 }
1120 
1121 static unsigned
swiz_from_char(char c)1122 swiz_from_char(char c)
1123 {
1124    switch (c) {
1125    case 'x':
1126    case 'r':
1127       return SWIZZLE_X;
1128    case 'y':
1129    case 'g':
1130       return SWIZZLE_Y;
1131    case 'z':
1132    case 'b':
1133       return SWIZZLE_Z;
1134    case 'w':
1135    case 'a':
1136       return SWIZZLE_W;
1137    }
1138 
1139    return 0;
1140 }
1141 
1142 static int
handle_ident(struct asm_parser_state * state,const char * text,YYSTYPE * lval)1143 handle_ident(struct asm_parser_state *state, const char *text, YYSTYPE *lval)
1144 {
1145    lval->string = strdup(text);
1146 
1147    return (_mesa_symbol_table_find_symbol(state->st, 0, text) == NULL)
1148       ? IDENTIFIER : USED_IDENTIFIER;
1149 }
1150 
1151 #define YY_USER_ACTION							\
1152    do {									\
1153       yylloc->first_column = yylloc->last_column;			\
1154       yylloc->last_column += yyleng;					\
1155       if ((yylloc->first_line == 1)					\
1156 	  && (yylloc->first_column == 1)) {				\
1157 	 yylloc->position = 1;						\
1158       } else {								\
1159 	 yylloc->position += yylloc->last_column - yylloc->first_column; \
1160       }									\
1161    } while(0);
1162 
1163 #define YY_NO_INPUT
1164 
1165 /* Yes, this is intentionally doing nothing. We have this line of code
1166 here only to avoid the compiler complaining about an unput function
1167 that is defined, but never called. */
1168 #define YY_USER_INIT while (0) { unput(0); }
1169 
1170 #define YY_EXTRA_TYPE struct asm_parser_state *
1171 
1172 /* Flex defines a couple of functions with no declarations nor the
1173 static keyword. Declare them here to avoid a compiler warning. */
1174 int _mesa_program_get_column  (yyscan_t yyscanner);
1175 void _mesa_program_set_column (int  column_no , yyscan_t yyscanner);
1176 
1177 #line 1178 "src/chromium_gensrc/mesa/lex.yy.c"
1178 
1179 #define INITIAL 0
1180 
1181 #ifndef YY_NO_UNISTD_H
1182 /* Special case for "unistd.h", since it is non-ANSI. We include it way
1183  * down here because we want the user's section 1 to have been scanned first.
1184  * The user has a chance to override it with an option.
1185  */
1186 #include <unistd.h>
1187 #endif
1188 
1189 #ifndef YY_EXTRA_TYPE
1190 #define YY_EXTRA_TYPE void *
1191 #endif
1192 
1193 /* Holds the entire state of the reentrant scanner. */
1194 struct yyguts_t
1195     {
1196 
1197     /* User-defined. Not touched by flex. */
1198     YY_EXTRA_TYPE yyextra_r;
1199 
1200     /* The rest are the same as the globals declared in the non-reentrant scanner. */
1201     FILE *yyin_r, *yyout_r;
1202     size_t yy_buffer_stack_top; /**< index of top of stack. */
1203     size_t yy_buffer_stack_max; /**< capacity of stack. */
1204     YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */
1205     char yy_hold_char;
1206     int yy_n_chars;
1207     int yyleng_r;
1208     char *yy_c_buf_p;
1209     int yy_init;
1210     int yy_start;
1211     int yy_did_buffer_switch_on_eof;
1212     int yy_start_stack_ptr;
1213     int yy_start_stack_depth;
1214     int *yy_start_stack;
1215     yy_state_type yy_last_accepting_state;
1216     char* yy_last_accepting_cpos;
1217 
1218     int yylineno_r;
1219     int yy_flex_debug_r;
1220 
1221     char *yytext_r;
1222     int yy_more_flag;
1223     int yy_more_len;
1224 
1225     YYSTYPE * yylval_r;
1226 
1227     YYLTYPE * yylloc_r;
1228 
1229     }; /* end struct yyguts_t */
1230 
1231 static int yy_init_globals (yyscan_t yyscanner );
1232 
1233     /* This must go here because YYSTYPE and YYLTYPE are included
1234      * from bison output in section 1.*/
1235     #    define yylval yyg->yylval_r
1236 
1237     #    define yylloc yyg->yylloc_r
1238 
1239 int _mesa_program_lex_init (yyscan_t* scanner);
1240 
1241 int _mesa_program_lex_init_extra (YY_EXTRA_TYPE user_defined,yyscan_t* scanner);
1242 
1243 /* Accessor methods to globals.
1244    These are made visible to non-reentrant scanners for convenience. */
1245 
1246 int _mesa_program_lex_destroy (yyscan_t yyscanner );
1247 
1248 int _mesa_program_get_debug (yyscan_t yyscanner );
1249 
1250 void _mesa_program_set_debug (int debug_flag ,yyscan_t yyscanner );
1251 
1252 YY_EXTRA_TYPE _mesa_program_get_extra (yyscan_t yyscanner );
1253 
1254 void _mesa_program_set_extra (YY_EXTRA_TYPE user_defined ,yyscan_t yyscanner );
1255 
1256 FILE *_mesa_program_get_in (yyscan_t yyscanner );
1257 
1258 void _mesa_program_set_in  (FILE * in_str ,yyscan_t yyscanner );
1259 
1260 FILE *_mesa_program_get_out (yyscan_t yyscanner );
1261 
1262 void _mesa_program_set_out  (FILE * out_str ,yyscan_t yyscanner );
1263 
1264 int _mesa_program_get_leng (yyscan_t yyscanner );
1265 
1266 char *_mesa_program_get_text (yyscan_t yyscanner );
1267 
1268 int _mesa_program_get_lineno (yyscan_t yyscanner );
1269 
1270 void _mesa_program_set_lineno (int line_number ,yyscan_t yyscanner );
1271 
1272 YYSTYPE * _mesa_program_get_lval (yyscan_t yyscanner );
1273 
1274 void _mesa_program_set_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner );
1275 
1276        YYLTYPE *_mesa_program_get_lloc (yyscan_t yyscanner );
1277 
1278         void _mesa_program_set_lloc (YYLTYPE * yylloc_param ,yyscan_t yyscanner );
1279 
1280 /* Macros after this point can all be overridden by user definitions in
1281  * section 1.
1282  */
1283 
1284 #ifndef YY_SKIP_YYWRAP
1285 #ifdef __cplusplus
1286 extern "C" int _mesa_program_wrap (yyscan_t yyscanner );
1287 #else
1288 extern int _mesa_program_wrap (yyscan_t yyscanner );
1289 #endif
1290 #endif
1291 
1292     static void yyunput (int c,char *buf_ptr  ,yyscan_t yyscanner);
1293 
1294 #ifndef yytext_ptr
1295 static void yy_flex_strncpy (char *,yyconst char *,int ,yyscan_t yyscanner);
1296 #endif
1297 
1298 #ifdef YY_NEED_STRLEN
1299 static int yy_flex_strlen (yyconst char * ,yyscan_t yyscanner);
1300 #endif
1301 
1302 #ifndef YY_NO_INPUT
1303 
1304 #ifdef __cplusplus
1305 static int yyinput (yyscan_t yyscanner );
1306 #else
1307 static int input (yyscan_t yyscanner );
1308 #endif
1309 
1310 #endif
1311 
1312 /* Amount of stuff to slurp up with each read. */
1313 #ifndef YY_READ_BUF_SIZE
1314 #ifdef __ia64__
1315 /* On IA-64, the buffer size is 16k, not 8k */
1316 #define YY_READ_BUF_SIZE 16384
1317 #else
1318 #define YY_READ_BUF_SIZE 8192
1319 #endif /* __ia64__ */
1320 #endif
1321 
1322 /* Copy whatever the last rule matched to the standard output. */
1323 #ifndef ECHO
1324 /* This used to be an fputs(), but since the string might contain NUL's,
1325  * we now use fwrite().
1326  */
1327 #define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0)
1328 #endif
1329 
1330 /* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
1331  * is returned in "result".
1332  */
1333 #ifndef YY_INPUT
1334 #define YY_INPUT(buf,result,max_size) \
1335 	if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
1336 		{ \
1337 		int c = '*'; \
1338 		size_t n; \
1339 		for ( n = 0; n < max_size && \
1340 			     (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
1341 			buf[n] = (char) c; \
1342 		if ( c == '\n' ) \
1343 			buf[n++] = (char) c; \
1344 		if ( c == EOF && ferror( yyin ) ) \
1345 			YY_FATAL_ERROR( "input in flex scanner failed" ); \
1346 		result = n; \
1347 		} \
1348 	else \
1349 		{ \
1350 		errno=0; \
1351 		while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \
1352 			{ \
1353 			if( errno != EINTR) \
1354 				{ \
1355 				YY_FATAL_ERROR( "input in flex scanner failed" ); \
1356 				break; \
1357 				} \
1358 			errno=0; \
1359 			clearerr(yyin); \
1360 			} \
1361 		}\
1362 \
1363 
1364 #endif
1365 
1366 /* No semi-colon after return; correct usage is to write "yyterminate();" -
1367  * we don't want an extra ';' after the "return" because that will cause
1368  * some compilers to complain about unreachable statements.
1369  */
1370 #ifndef yyterminate
1371 #define yyterminate() return YY_NULL
1372 #endif
1373 
1374 /* Number of entries by which start-condition stack grows. */
1375 #ifndef YY_START_STACK_INCR
1376 #define YY_START_STACK_INCR 25
1377 #endif
1378 
1379 /* Report a fatal error. */
1380 #ifndef YY_FATAL_ERROR
1381 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner)
1382 #endif
1383 
1384 /* end tables serialization structures and prototypes */
1385 
1386 /* Default declaration of generated scanner - a define so the user can
1387  * easily add parameters.
1388  */
1389 #ifndef YY_DECL
1390 #define YY_DECL_IS_OURS 1
1391 
1392 extern int _mesa_program_lex \
1393                (YYSTYPE * yylval_param,YYLTYPE * yylloc_param ,yyscan_t yyscanner);
1394 
1395 #define YY_DECL int _mesa_program_lex \
1396                (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner)
1397 #endif /* !YY_DECL */
1398 
1399 /* Code executed at the beginning of each rule, after yytext and yyleng
1400  * have been set up.
1401  */
1402 #ifndef YY_USER_ACTION
1403 #define YY_USER_ACTION
1404 #endif
1405 
1406 /* Code executed at the end of each rule. */
1407 #ifndef YY_BREAK
1408 #define YY_BREAK break;
1409 #endif
1410 
1411 #define YY_RULE_SETUP \
1412 	YY_USER_ACTION
1413 
1414 /** The main scanner function which does all the work.
1415  */
1416 YY_DECL
1417 {
1418 	register yy_state_type yy_current_state;
1419 	register char *yy_cp, *yy_bp;
1420 	register int yy_act;
1421     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
1422 
1423 #line 170 "src/src/mesa/program/program_lexer.l"
1424 
1425 
1426 #line 1427 "src/chromium_gensrc/mesa/lex.yy.c"
1427 
1428     yylval = yylval_param;
1429 
1430     yylloc = yylloc_param;
1431 
1432 	if ( !yyg->yy_init )
1433 		{
1434 		yyg->yy_init = 1;
1435 
1436 #ifdef YY_USER_INIT
1437 		YY_USER_INIT;
1438 #endif
1439 
1440 		if ( ! yyg->yy_start )
1441 			yyg->yy_start = 1;	/* first start state */
1442 
1443 		if ( ! yyin )
1444 			yyin = stdin;
1445 
1446 		if ( ! yyout )
1447 			yyout = stdout;
1448 
1449 		if ( ! YY_CURRENT_BUFFER ) {
1450 			_mesa_program_ensure_buffer_stack (yyscanner);
1451 			YY_CURRENT_BUFFER_LVALUE =
1452 				_mesa_program__create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
1453 		}
1454 
1455 		_mesa_program__load_buffer_state(yyscanner );
1456 		}
1457 
1458 	while ( 1 )		/* loops until end-of-file is reached */
1459 		{
1460 		yy_cp = yyg->yy_c_buf_p;
1461 
1462 		/* Support of yytext. */
1463 		*yy_cp = yyg->yy_hold_char;
1464 
1465 		/* yy_bp points to the position in yy_ch_buf of the start of
1466 		 * the current run.
1467 		 */
1468 		yy_bp = yy_cp;
1469 
1470 		yy_current_state = yyg->yy_start;
1471 yy_match:
1472 		do
1473 			{
1474 			register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
1475 			if ( yy_accept[yy_current_state] )
1476 				{
1477 				yyg->yy_last_accepting_state = yy_current_state;
1478 				yyg->yy_last_accepting_cpos = yy_cp;
1479 				}
1480 			while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
1481 				{
1482 				yy_current_state = (int) yy_def[yy_current_state];
1483 				if ( yy_current_state >= 850 )
1484 					yy_c = yy_meta[(unsigned int) yy_c];
1485 				}
1486 			yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
1487 			++yy_cp;
1488 			}
1489 		while ( yy_base[yy_current_state] != 1300 );
1490 
1491 yy_find_action:
1492 		yy_act = yy_accept[yy_current_state];
1493 		if ( yy_act == 0 )
1494 			{ /* have to back up */
1495 			yy_cp = yyg->yy_last_accepting_cpos;
1496 			yy_current_state = yyg->yy_last_accepting_state;
1497 			yy_act = yy_accept[yy_current_state];
1498 			}
1499 
1500 		YY_DO_BEFORE_ACTION;
1501 
1502 do_action:	/* This label is used only to access EOF actions. */
1503 
1504 		switch ( yy_act )
1505 	{ /* beginning of action switch */
1506 			case 0: /* must back up */
1507 			/* undo the effects of YY_DO_BEFORE_ACTION */
1508 			*yy_cp = yyg->yy_hold_char;
1509 			yy_cp = yyg->yy_last_accepting_cpos;
1510 			yy_current_state = yyg->yy_last_accepting_state;
1511 			goto yy_find_action;
1512 
1513 case 1:
1514 YY_RULE_SETUP
1515 #line 172 "src/src/mesa/program/program_lexer.l"
1516 { return ARBvp_10; }
1517 	YY_BREAK
1518 case 2:
1519 YY_RULE_SETUP
1520 #line 173 "src/src/mesa/program/program_lexer.l"
1521 { return ARBfp_10; }
1522 	YY_BREAK
1523 case 3:
1524 YY_RULE_SETUP
1525 #line 174 "src/src/mesa/program/program_lexer.l"
1526 {
1527    yylval->integer = at_address;
1528    return_token_or_IDENTIFIER(require_ARB_vp, ADDRESS);
1529 }
1530 	YY_BREAK
1531 case 4:
1532 YY_RULE_SETUP
1533 #line 178 "src/src/mesa/program/program_lexer.l"
1534 { return ALIAS; }
1535 	YY_BREAK
1536 case 5:
1537 YY_RULE_SETUP
1538 #line 179 "src/src/mesa/program/program_lexer.l"
1539 { return ATTRIB; }
1540 	YY_BREAK
1541 case 6:
1542 YY_RULE_SETUP
1543 #line 180 "src/src/mesa/program/program_lexer.l"
1544 { return END; }
1545 	YY_BREAK
1546 case 7:
1547 YY_RULE_SETUP
1548 #line 181 "src/src/mesa/program/program_lexer.l"
1549 { return OPTION; }
1550 	YY_BREAK
1551 case 8:
1552 YY_RULE_SETUP
1553 #line 182 "src/src/mesa/program/program_lexer.l"
1554 { return OUTPUT; }
1555 	YY_BREAK
1556 case 9:
1557 YY_RULE_SETUP
1558 #line 183 "src/src/mesa/program/program_lexer.l"
1559 { return PARAM; }
1560 	YY_BREAK
1561 case 10:
1562 YY_RULE_SETUP
1563 #line 184 "src/src/mesa/program/program_lexer.l"
1564 { yylval->integer = at_temp; return TEMP; }
1565 	YY_BREAK
1566 case 11:
1567 YY_RULE_SETUP
1568 #line 186 "src/src/mesa/program/program_lexer.l"
1569 { return_opcode(             1, VECTOR_OP, ABS, 3); }
1570 	YY_BREAK
1571 case 12:
1572 YY_RULE_SETUP
1573 #line 187 "src/src/mesa/program/program_lexer.l"
1574 { return_opcode(             1, BIN_OP, ADD, 3); }
1575 	YY_BREAK
1576 case 13:
1577 YY_RULE_SETUP
1578 #line 188 "src/src/mesa/program/program_lexer.l"
1579 { return_opcode(require_ARB_vp, ARL, ARL, 3); }
1580 	YY_BREAK
1581 case 14:
1582 YY_RULE_SETUP
1583 #line 190 "src/src/mesa/program/program_lexer.l"
1584 { return_opcode(require_ARB_fp, TRI_OP, CMP, 3); }
1585 	YY_BREAK
1586 case 15:
1587 YY_RULE_SETUP
1588 #line 191 "src/src/mesa/program/program_lexer.l"
1589 { return_opcode(require_ARB_fp, SCALAR_OP, COS, 3); }
1590 	YY_BREAK
1591 case 16:
1592 YY_RULE_SETUP
1593 #line 193 "src/src/mesa/program/program_lexer.l"
1594 { return_opcode(require_NV_fp,  VECTOR_OP, DDX, 3); }
1595 	YY_BREAK
1596 case 17:
1597 YY_RULE_SETUP
1598 #line 194 "src/src/mesa/program/program_lexer.l"
1599 { return_opcode(require_NV_fp,  VECTOR_OP, DDY, 3); }
1600 	YY_BREAK
1601 case 18:
1602 YY_RULE_SETUP
1603 #line 195 "src/src/mesa/program/program_lexer.l"
1604 { return_opcode(             1, BIN_OP, DP3, 3); }
1605 	YY_BREAK
1606 case 19:
1607 YY_RULE_SETUP
1608 #line 196 "src/src/mesa/program/program_lexer.l"
1609 { return_opcode(             1, BIN_OP, DP4, 3); }
1610 	YY_BREAK
1611 case 20:
1612 YY_RULE_SETUP
1613 #line 197 "src/src/mesa/program/program_lexer.l"
1614 { return_opcode(             1, BIN_OP, DPH, 3); }
1615 	YY_BREAK
1616 case 21:
1617 YY_RULE_SETUP
1618 #line 198 "src/src/mesa/program/program_lexer.l"
1619 { return_opcode(             1, BIN_OP, DST, 3); }
1620 	YY_BREAK
1621 case 22:
1622 YY_RULE_SETUP
1623 #line 200 "src/src/mesa/program/program_lexer.l"
1624 { return_opcode(             1, SCALAR_OP, EX2, 3); }
1625 	YY_BREAK
1626 case 23:
1627 YY_RULE_SETUP
1628 #line 201 "src/src/mesa/program/program_lexer.l"
1629 { return_opcode(require_ARB_vp, SCALAR_OP, EXP, 3); }
1630 	YY_BREAK
1631 case 24:
1632 YY_RULE_SETUP
1633 #line 203 "src/src/mesa/program/program_lexer.l"
1634 { return_opcode(             1, VECTOR_OP, FLR, 3); }
1635 	YY_BREAK
1636 case 25:
1637 YY_RULE_SETUP
1638 #line 204 "src/src/mesa/program/program_lexer.l"
1639 { return_opcode(             1, VECTOR_OP, FRC, 3); }
1640 	YY_BREAK
1641 case 26:
1642 YY_RULE_SETUP
1643 #line 206 "src/src/mesa/program/program_lexer.l"
1644 { return_opcode(require_ARB_fp, KIL, KIL, 3); }
1645 	YY_BREAK
1646 case 27:
1647 YY_RULE_SETUP
1648 #line 208 "src/src/mesa/program/program_lexer.l"
1649 { return_opcode(             1, VECTOR_OP, LIT, 3); }
1650 	YY_BREAK
1651 case 28:
1652 YY_RULE_SETUP
1653 #line 209 "src/src/mesa/program/program_lexer.l"
1654 { return_opcode(             1, SCALAR_OP, LG2, 3); }
1655 	YY_BREAK
1656 case 29:
1657 YY_RULE_SETUP
1658 #line 210 "src/src/mesa/program/program_lexer.l"
1659 { return_opcode(require_ARB_vp, SCALAR_OP, LOG, 3); }
1660 	YY_BREAK
1661 case 30:
1662 YY_RULE_SETUP
1663 #line 211 "src/src/mesa/program/program_lexer.l"
1664 { return_opcode(require_ARB_fp, TRI_OP, LRP, 3); }
1665 	YY_BREAK
1666 case 31:
1667 YY_RULE_SETUP
1668 #line 213 "src/src/mesa/program/program_lexer.l"
1669 { return_opcode(             1, TRI_OP, MAD, 3); }
1670 	YY_BREAK
1671 case 32:
1672 YY_RULE_SETUP
1673 #line 214 "src/src/mesa/program/program_lexer.l"
1674 { return_opcode(             1, BIN_OP, MAX, 3); }
1675 	YY_BREAK
1676 case 33:
1677 YY_RULE_SETUP
1678 #line 215 "src/src/mesa/program/program_lexer.l"
1679 { return_opcode(             1, BIN_OP, MIN, 3); }
1680 	YY_BREAK
1681 case 34:
1682 YY_RULE_SETUP
1683 #line 216 "src/src/mesa/program/program_lexer.l"
1684 { return_opcode(             1, VECTOR_OP, MOV, 3); }
1685 	YY_BREAK
1686 case 35:
1687 YY_RULE_SETUP
1688 #line 217 "src/src/mesa/program/program_lexer.l"
1689 { return_opcode(             1, BIN_OP, MUL, 3); }
1690 	YY_BREAK
1691 case 36:
1692 YY_RULE_SETUP
1693 #line 219 "src/src/mesa/program/program_lexer.l"
1694 { return_opcode(require_NV_fp,  VECTOR_OP, PK2H, 4); }
1695 	YY_BREAK
1696 case 37:
1697 YY_RULE_SETUP
1698 #line 220 "src/src/mesa/program/program_lexer.l"
1699 { return_opcode(require_NV_fp,  VECTOR_OP, PK2US, 5); }
1700 	YY_BREAK
1701 case 38:
1702 YY_RULE_SETUP
1703 #line 221 "src/src/mesa/program/program_lexer.l"
1704 { return_opcode(require_NV_fp,  VECTOR_OP, PK4B, 4); }
1705 	YY_BREAK
1706 case 39:
1707 YY_RULE_SETUP
1708 #line 222 "src/src/mesa/program/program_lexer.l"
1709 { return_opcode(require_NV_fp,  VECTOR_OP, PK4UB, 5); }
1710 	YY_BREAK
1711 case 40:
1712 YY_RULE_SETUP
1713 #line 223 "src/src/mesa/program/program_lexer.l"
1714 { return_opcode(             1, BINSC_OP, POW, 3); }
1715 	YY_BREAK
1716 case 41:
1717 YY_RULE_SETUP
1718 #line 225 "src/src/mesa/program/program_lexer.l"
1719 { return_opcode(             1, SCALAR_OP, RCP, 3); }
1720 	YY_BREAK
1721 case 42:
1722 YY_RULE_SETUP
1723 #line 226 "src/src/mesa/program/program_lexer.l"
1724 { return_opcode(require_NV_fp,  BIN_OP,    RFL, 3); }
1725 	YY_BREAK
1726 case 43:
1727 YY_RULE_SETUP
1728 #line 227 "src/src/mesa/program/program_lexer.l"
1729 { return_opcode(             1, SCALAR_OP, RSQ, 3); }
1730 	YY_BREAK
1731 case 44:
1732 YY_RULE_SETUP
1733 #line 229 "src/src/mesa/program/program_lexer.l"
1734 { return_opcode(require_ARB_fp, SCALAR_OP, SCS, 3); }
1735 	YY_BREAK
1736 case 45:
1737 YY_RULE_SETUP
1738 #line 230 "src/src/mesa/program/program_lexer.l"
1739 { return_opcode(require_NV_fp,  BIN_OP, SEQ, 3); }
1740 	YY_BREAK
1741 case 46:
1742 YY_RULE_SETUP
1743 #line 231 "src/src/mesa/program/program_lexer.l"
1744 { return_opcode(require_NV_fp,  BIN_OP, SFL, 3); }
1745 	YY_BREAK
1746 case 47:
1747 YY_RULE_SETUP
1748 #line 232 "src/src/mesa/program/program_lexer.l"
1749 { return_opcode(             1, BIN_OP, SGE, 3); }
1750 	YY_BREAK
1751 case 48:
1752 YY_RULE_SETUP
1753 #line 233 "src/src/mesa/program/program_lexer.l"
1754 { return_opcode(require_NV_fp,  BIN_OP, SGT, 3); }
1755 	YY_BREAK
1756 case 49:
1757 YY_RULE_SETUP
1758 #line 234 "src/src/mesa/program/program_lexer.l"
1759 { return_opcode(require_ARB_fp, SCALAR_OP, SIN, 3); }
1760 	YY_BREAK
1761 case 50:
1762 YY_RULE_SETUP
1763 #line 235 "src/src/mesa/program/program_lexer.l"
1764 { return_opcode(require_NV_fp,  BIN_OP, SLE, 3); }
1765 	YY_BREAK
1766 case 51:
1767 YY_RULE_SETUP
1768 #line 236 "src/src/mesa/program/program_lexer.l"
1769 { return_opcode(             1, BIN_OP, SLT, 3); }
1770 	YY_BREAK
1771 case 52:
1772 YY_RULE_SETUP
1773 #line 237 "src/src/mesa/program/program_lexer.l"
1774 { return_opcode(require_NV_fp,  BIN_OP, SNE, 3); }
1775 	YY_BREAK
1776 case 53:
1777 YY_RULE_SETUP
1778 #line 238 "src/src/mesa/program/program_lexer.l"
1779 { return_opcode(require_NV_fp,  BIN_OP, STR, 3); }
1780 	YY_BREAK
1781 case 54:
1782 YY_RULE_SETUP
1783 #line 239 "src/src/mesa/program/program_lexer.l"
1784 { return_opcode(             1, BIN_OP, SUB, 3); }
1785 	YY_BREAK
1786 case 55:
1787 YY_RULE_SETUP
1788 #line 240 "src/src/mesa/program/program_lexer.l"
1789 { return_opcode(             1, SWZ, SWZ, 3); }
1790 	YY_BREAK
1791 case 56:
1792 YY_RULE_SETUP
1793 #line 242 "src/src/mesa/program/program_lexer.l"
1794 { return_opcode(require_ARB_fp, SAMPLE_OP, TEX, 3); }
1795 	YY_BREAK
1796 case 57:
1797 YY_RULE_SETUP
1798 #line 243 "src/src/mesa/program/program_lexer.l"
1799 { return_opcode(require_ARB_fp, SAMPLE_OP, TXB, 3); }
1800 	YY_BREAK
1801 case 58:
1802 YY_RULE_SETUP
1803 #line 244 "src/src/mesa/program/program_lexer.l"
1804 { return_opcode(require_NV_fp,  TXD_OP, TXD, 3); }
1805 	YY_BREAK
1806 case 59:
1807 YY_RULE_SETUP
1808 #line 245 "src/src/mesa/program/program_lexer.l"
1809 { return_opcode(require_ARB_fp, SAMPLE_OP, TXP, 3); }
1810 	YY_BREAK
1811 case 60:
1812 YY_RULE_SETUP
1813 #line 247 "src/src/mesa/program/program_lexer.l"
1814 { return_opcode(require_NV_fp,  SCALAR_OP, UP2H, 4); }
1815 	YY_BREAK
1816 case 61:
1817 YY_RULE_SETUP
1818 #line 248 "src/src/mesa/program/program_lexer.l"
1819 { return_opcode(require_NV_fp,  SCALAR_OP, UP2US, 5); }
1820 	YY_BREAK
1821 case 62:
1822 YY_RULE_SETUP
1823 #line 249 "src/src/mesa/program/program_lexer.l"
1824 { return_opcode(require_NV_fp,  SCALAR_OP, UP4B, 4); }
1825 	YY_BREAK
1826 case 63:
1827 YY_RULE_SETUP
1828 #line 250 "src/src/mesa/program/program_lexer.l"
1829 { return_opcode(require_NV_fp,  SCALAR_OP, UP4UB, 5); }
1830 	YY_BREAK
1831 case 64:
1832 YY_RULE_SETUP
1833 #line 252 "src/src/mesa/program/program_lexer.l"
1834 { return_opcode(require_NV_fp,  TRI_OP, X2D, 3); }
1835 	YY_BREAK
1836 case 65:
1837 YY_RULE_SETUP
1838 #line 253 "src/src/mesa/program/program_lexer.l"
1839 { return_opcode(             1, BIN_OP, XPD, 3); }
1840 	YY_BREAK
1841 case 66:
1842 YY_RULE_SETUP
1843 #line 255 "src/src/mesa/program/program_lexer.l"
1844 { return_token_or_IDENTIFIER(require_ARB_vp, VERTEX); }
1845 	YY_BREAK
1846 case 67:
1847 YY_RULE_SETUP
1848 #line 256 "src/src/mesa/program/program_lexer.l"
1849 { return_token_or_IDENTIFIER(require_ARB_fp, FRAGMENT); }
1850 	YY_BREAK
1851 case 68:
1852 YY_RULE_SETUP
1853 #line 257 "src/src/mesa/program/program_lexer.l"
1854 { return PROGRAM; }
1855 	YY_BREAK
1856 case 69:
1857 YY_RULE_SETUP
1858 #line 258 "src/src/mesa/program/program_lexer.l"
1859 { return STATE; }
1860 	YY_BREAK
1861 case 70:
1862 YY_RULE_SETUP
1863 #line 259 "src/src/mesa/program/program_lexer.l"
1864 { return RESULT; }
1865 	YY_BREAK
1866 case 71:
1867 YY_RULE_SETUP
1868 #line 261 "src/src/mesa/program/program_lexer.l"
1869 { return AMBIENT; }
1870 	YY_BREAK
1871 case 72:
1872 YY_RULE_SETUP
1873 #line 262 "src/src/mesa/program/program_lexer.l"
1874 { return ATTENUATION; }
1875 	YY_BREAK
1876 case 73:
1877 YY_RULE_SETUP
1878 #line 263 "src/src/mesa/program/program_lexer.l"
1879 { return BACK; }
1880 	YY_BREAK
1881 case 74:
1882 YY_RULE_SETUP
1883 #line 264 "src/src/mesa/program/program_lexer.l"
1884 { return_token_or_DOT(require_ARB_vp, CLIP); }
1885 	YY_BREAK
1886 case 75:
1887 YY_RULE_SETUP
1888 #line 265 "src/src/mesa/program/program_lexer.l"
1889 { return COLOR; }
1890 	YY_BREAK
1891 case 76:
1892 YY_RULE_SETUP
1893 #line 266 "src/src/mesa/program/program_lexer.l"
1894 { return_token_or_DOT(require_ARB_fp, DEPTH); }
1895 	YY_BREAK
1896 case 77:
1897 YY_RULE_SETUP
1898 #line 267 "src/src/mesa/program/program_lexer.l"
1899 { return DIFFUSE; }
1900 	YY_BREAK
1901 case 78:
1902 YY_RULE_SETUP
1903 #line 268 "src/src/mesa/program/program_lexer.l"
1904 { return DIRECTION; }
1905 	YY_BREAK
1906 case 79:
1907 YY_RULE_SETUP
1908 #line 269 "src/src/mesa/program/program_lexer.l"
1909 { return EMISSION; }
1910 	YY_BREAK
1911 case 80:
1912 YY_RULE_SETUP
1913 #line 270 "src/src/mesa/program/program_lexer.l"
1914 { return ENV; }
1915 	YY_BREAK
1916 case 81:
1917 YY_RULE_SETUP
1918 #line 271 "src/src/mesa/program/program_lexer.l"
1919 { return EYE; }
1920 	YY_BREAK
1921 case 82:
1922 YY_RULE_SETUP
1923 #line 272 "src/src/mesa/program/program_lexer.l"
1924 { return FOGCOORD; }
1925 	YY_BREAK
1926 case 83:
1927 YY_RULE_SETUP
1928 #line 273 "src/src/mesa/program/program_lexer.l"
1929 { return FOG; }
1930 	YY_BREAK
1931 case 84:
1932 YY_RULE_SETUP
1933 #line 274 "src/src/mesa/program/program_lexer.l"
1934 { return FRONT; }
1935 	YY_BREAK
1936 case 85:
1937 YY_RULE_SETUP
1938 #line 275 "src/src/mesa/program/program_lexer.l"
1939 { return HALF; }
1940 	YY_BREAK
1941 case 86:
1942 YY_RULE_SETUP
1943 #line 276 "src/src/mesa/program/program_lexer.l"
1944 { return INVERSE; }
1945 	YY_BREAK
1946 case 87:
1947 YY_RULE_SETUP
1948 #line 277 "src/src/mesa/program/program_lexer.l"
1949 { return INVTRANS; }
1950 	YY_BREAK
1951 case 88:
1952 YY_RULE_SETUP
1953 #line 278 "src/src/mesa/program/program_lexer.l"
1954 { return LIGHT; }
1955 	YY_BREAK
1956 case 89:
1957 YY_RULE_SETUP
1958 #line 279 "src/src/mesa/program/program_lexer.l"
1959 { return LIGHTMODEL; }
1960 	YY_BREAK
1961 case 90:
1962 YY_RULE_SETUP
1963 #line 280 "src/src/mesa/program/program_lexer.l"
1964 { return LIGHTPROD; }
1965 	YY_BREAK
1966 case 91:
1967 YY_RULE_SETUP
1968 #line 281 "src/src/mesa/program/program_lexer.l"
1969 { return LOCAL; }
1970 	YY_BREAK
1971 case 92:
1972 YY_RULE_SETUP
1973 #line 282 "src/src/mesa/program/program_lexer.l"
1974 { return MATERIAL; }
1975 	YY_BREAK
1976 case 93:
1977 YY_RULE_SETUP
1978 #line 283 "src/src/mesa/program/program_lexer.l"
1979 { return MAT_PROGRAM; }
1980 	YY_BREAK
1981 case 94:
1982 YY_RULE_SETUP
1983 #line 284 "src/src/mesa/program/program_lexer.l"
1984 { return MATRIX; }
1985 	YY_BREAK
1986 case 95:
1987 YY_RULE_SETUP
1988 #line 285 "src/src/mesa/program/program_lexer.l"
1989 { return_token_or_DOT(require_ARB_vp, MATRIXINDEX); }
1990 	YY_BREAK
1991 case 96:
1992 YY_RULE_SETUP
1993 #line 286 "src/src/mesa/program/program_lexer.l"
1994 { return MODELVIEW; }
1995 	YY_BREAK
1996 case 97:
1997 YY_RULE_SETUP
1998 #line 287 "src/src/mesa/program/program_lexer.l"
1999 { return MVP; }
2000 	YY_BREAK
2001 case 98:
2002 YY_RULE_SETUP
2003 #line 288 "src/src/mesa/program/program_lexer.l"
2004 { return_token_or_DOT(require_ARB_vp, NORMAL); }
2005 	YY_BREAK
2006 case 99:
2007 YY_RULE_SETUP
2008 #line 289 "src/src/mesa/program/program_lexer.l"
2009 { return OBJECT; }
2010 	YY_BREAK
2011 case 100:
2012 YY_RULE_SETUP
2013 #line 290 "src/src/mesa/program/program_lexer.l"
2014 { return PALETTE; }
2015 	YY_BREAK
2016 case 101:
2017 YY_RULE_SETUP
2018 #line 291 "src/src/mesa/program/program_lexer.l"
2019 { return PARAMS; }
2020 	YY_BREAK
2021 case 102:
2022 YY_RULE_SETUP
2023 #line 292 "src/src/mesa/program/program_lexer.l"
2024 { return PLANE; }
2025 	YY_BREAK
2026 case 103:
2027 YY_RULE_SETUP
2028 #line 293 "src/src/mesa/program/program_lexer.l"
2029 { return_token_or_DOT(require_ARB_vp, POINT_TOK); }
2030 	YY_BREAK
2031 case 104:
2032 YY_RULE_SETUP
2033 #line 294 "src/src/mesa/program/program_lexer.l"
2034 { return_token_or_DOT(require_ARB_vp, POINTSIZE); }
2035 	YY_BREAK
2036 case 105:
2037 YY_RULE_SETUP
2038 #line 295 "src/src/mesa/program/program_lexer.l"
2039 { return POSITION; }
2040 	YY_BREAK
2041 case 106:
2042 YY_RULE_SETUP
2043 #line 296 "src/src/mesa/program/program_lexer.l"
2044 { return PRIMARY; }
2045 	YY_BREAK
2046 case 107:
2047 YY_RULE_SETUP
2048 #line 297 "src/src/mesa/program/program_lexer.l"
2049 { return PROJECTION; }
2050 	YY_BREAK
2051 case 108:
2052 YY_RULE_SETUP
2053 #line 298 "src/src/mesa/program/program_lexer.l"
2054 { return_token_or_DOT(require_ARB_fp, RANGE); }
2055 	YY_BREAK
2056 case 109:
2057 YY_RULE_SETUP
2058 #line 299 "src/src/mesa/program/program_lexer.l"
2059 { return ROW; }
2060 	YY_BREAK
2061 case 110:
2062 YY_RULE_SETUP
2063 #line 300 "src/src/mesa/program/program_lexer.l"
2064 { return SCENECOLOR; }
2065 	YY_BREAK
2066 case 111:
2067 YY_RULE_SETUP
2068 #line 301 "src/src/mesa/program/program_lexer.l"
2069 { return SECONDARY; }
2070 	YY_BREAK
2071 case 112:
2072 YY_RULE_SETUP
2073 #line 302 "src/src/mesa/program/program_lexer.l"
2074 { return SHININESS; }
2075 	YY_BREAK
2076 case 113:
2077 YY_RULE_SETUP
2078 #line 303 "src/src/mesa/program/program_lexer.l"
2079 { return_token_or_DOT(require_ARB_vp, SIZE_TOK); }
2080 	YY_BREAK
2081 case 114:
2082 YY_RULE_SETUP
2083 #line 304 "src/src/mesa/program/program_lexer.l"
2084 { return SPECULAR; }
2085 	YY_BREAK
2086 case 115:
2087 YY_RULE_SETUP
2088 #line 305 "src/src/mesa/program/program_lexer.l"
2089 { return SPOT; }
2090 	YY_BREAK
2091 case 116:
2092 YY_RULE_SETUP
2093 #line 306 "src/src/mesa/program/program_lexer.l"
2094 { return TEXCOORD; }
2095 	YY_BREAK
2096 case 117:
2097 YY_RULE_SETUP
2098 #line 307 "src/src/mesa/program/program_lexer.l"
2099 { return_token_or_DOT(require_ARB_fp, TEXENV); }
2100 	YY_BREAK
2101 case 118:
2102 YY_RULE_SETUP
2103 #line 308 "src/src/mesa/program/program_lexer.l"
2104 { return_token_or_DOT(require_ARB_vp, TEXGEN); }
2105 	YY_BREAK
2106 case 119:
2107 YY_RULE_SETUP
2108 #line 309 "src/src/mesa/program/program_lexer.l"
2109 { return_token_or_DOT(require_ARB_vp, TEXGEN_Q); }
2110 	YY_BREAK
2111 case 120:
2112 YY_RULE_SETUP
2113 #line 310 "src/src/mesa/program/program_lexer.l"
2114 { return_token_or_DOT(require_ARB_vp, TEXGEN_S); }
2115 	YY_BREAK
2116 case 121:
2117 YY_RULE_SETUP
2118 #line 311 "src/src/mesa/program/program_lexer.l"
2119 { return_token_or_DOT(require_ARB_vp, TEXGEN_T); }
2120 	YY_BREAK
2121 case 122:
2122 YY_RULE_SETUP
2123 #line 312 "src/src/mesa/program/program_lexer.l"
2124 { return TEXTURE; }
2125 	YY_BREAK
2126 case 123:
2127 YY_RULE_SETUP
2128 #line 313 "src/src/mesa/program/program_lexer.l"
2129 { return TRANSPOSE; }
2130 	YY_BREAK
2131 case 124:
2132 YY_RULE_SETUP
2133 #line 314 "src/src/mesa/program/program_lexer.l"
2134 { return_token_or_DOT(require_ARB_vp, VTXATTRIB); }
2135 	YY_BREAK
2136 case 125:
2137 YY_RULE_SETUP
2138 #line 315 "src/src/mesa/program/program_lexer.l"
2139 { return_token_or_DOT(require_ARB_vp, WEIGHT); }
2140 	YY_BREAK
2141 case 126:
2142 YY_RULE_SETUP
2143 #line 317 "src/src/mesa/program/program_lexer.l"
2144 { return_token_or_IDENTIFIER(require_ARB_fp, TEXTURE_UNIT); }
2145 	YY_BREAK
2146 case 127:
2147 YY_RULE_SETUP
2148 #line 318 "src/src/mesa/program/program_lexer.l"
2149 { return_token_or_IDENTIFIER(require_ARB_fp, TEX_1D); }
2150 	YY_BREAK
2151 case 128:
2152 YY_RULE_SETUP
2153 #line 319 "src/src/mesa/program/program_lexer.l"
2154 { return_token_or_IDENTIFIER(require_ARB_fp, TEX_2D); }
2155 	YY_BREAK
2156 case 129:
2157 YY_RULE_SETUP
2158 #line 320 "src/src/mesa/program/program_lexer.l"
2159 { return_token_or_IDENTIFIER(require_ARB_fp, TEX_3D); }
2160 	YY_BREAK
2161 case 130:
2162 YY_RULE_SETUP
2163 #line 321 "src/src/mesa/program/program_lexer.l"
2164 { return_token_or_IDENTIFIER(require_ARB_fp, TEX_CUBE); }
2165 	YY_BREAK
2166 case 131:
2167 YY_RULE_SETUP
2168 #line 322 "src/src/mesa/program/program_lexer.l"
2169 { return_token_or_IDENTIFIER(require_ARB_fp && require_rect, TEX_RECT); }
2170 	YY_BREAK
2171 case 132:
2172 YY_RULE_SETUP
2173 #line 323 "src/src/mesa/program/program_lexer.l"
2174 { return_token_or_IDENTIFIER(require_ARB_fp && require_shadow, TEX_SHADOW1D); }
2175 	YY_BREAK
2176 case 133:
2177 YY_RULE_SETUP
2178 #line 324 "src/src/mesa/program/program_lexer.l"
2179 { return_token_or_IDENTIFIER(require_ARB_fp && require_shadow, TEX_SHADOW2D); }
2180 	YY_BREAK
2181 case 134:
2182 YY_RULE_SETUP
2183 #line 325 "src/src/mesa/program/program_lexer.l"
2184 { return_token_or_IDENTIFIER(require_ARB_fp && require_shadow && require_rect, TEX_SHADOWRECT); }
2185 	YY_BREAK
2186 case 135:
2187 YY_RULE_SETUP
2188 #line 326 "src/src/mesa/program/program_lexer.l"
2189 { return_token_or_IDENTIFIER(require_ARB_fp && require_texarray, TEX_ARRAY1D); }
2190 	YY_BREAK
2191 case 136:
2192 YY_RULE_SETUP
2193 #line 327 "src/src/mesa/program/program_lexer.l"
2194 { return_token_or_IDENTIFIER(require_ARB_fp && require_texarray, TEX_ARRAY2D); }
2195 	YY_BREAK
2196 case 137:
2197 YY_RULE_SETUP
2198 #line 328 "src/src/mesa/program/program_lexer.l"
2199 { return_token_or_IDENTIFIER(require_ARB_fp && require_shadow && require_texarray, TEX_ARRAYSHADOW1D); }
2200 	YY_BREAK
2201 case 138:
2202 YY_RULE_SETUP
2203 #line 329 "src/src/mesa/program/program_lexer.l"
2204 { return_token_or_IDENTIFIER(require_ARB_fp && require_shadow && require_texarray, TEX_ARRAYSHADOW2D); }
2205 	YY_BREAK
2206 case 139:
2207 YY_RULE_SETUP
2208 #line 331 "src/src/mesa/program/program_lexer.l"
2209 { return handle_ident(yyextra, yytext, yylval); }
2210 	YY_BREAK
2211 case 140:
2212 YY_RULE_SETUP
2213 #line 333 "src/src/mesa/program/program_lexer.l"
2214 { return DOT_DOT; }
2215 	YY_BREAK
2216 case 141:
2217 YY_RULE_SETUP
2218 #line 335 "src/src/mesa/program/program_lexer.l"
2219 {
2220    yylval->integer = strtol(yytext, NULL, 10);
2221    return INTEGER;
2222 }
2223 	YY_BREAK
2224 case 142:
2225 YY_RULE_SETUP
2226 #line 339 "src/src/mesa/program/program_lexer.l"
2227 {
2228    yylval->real = _mesa_strtof(yytext, NULL);
2229    return REAL;
2230 }
2231 	YY_BREAK
2232 case 143:
2233 /* rule 143 can match eol */
2234 *yy_cp = yyg->yy_hold_char; /* undo effects of setting up yytext */
2235 yyg->yy_c_buf_p = yy_cp -= 1;
2236 YY_DO_BEFORE_ACTION; /* set up yytext again */
2237 YY_RULE_SETUP
2238 #line 343 "src/src/mesa/program/program_lexer.l"
2239 {
2240    yylval->real = _mesa_strtof(yytext, NULL);
2241    return REAL;
2242 }
2243 	YY_BREAK
2244 case 144:
2245 YY_RULE_SETUP
2246 #line 347 "src/src/mesa/program/program_lexer.l"
2247 {
2248    yylval->real = _mesa_strtof(yytext, NULL);
2249    return REAL;
2250 }
2251 	YY_BREAK
2252 case 145:
2253 YY_RULE_SETUP
2254 #line 351 "src/src/mesa/program/program_lexer.l"
2255 {
2256    yylval->real = _mesa_strtof(yytext, NULL);
2257    return REAL;
2258 }
2259 	YY_BREAK
2260 case 146:
2261 YY_RULE_SETUP
2262 #line 356 "src/src/mesa/program/program_lexer.l"
2263 {
2264    yylval->swiz_mask.swizzle = SWIZZLE_NOOP;
2265    yylval->swiz_mask.mask = WRITEMASK_XYZW;
2266    return MASK4;
2267 }
2268 	YY_BREAK
2269 case 147:
2270 YY_RULE_SETUP
2271 #line 362 "src/src/mesa/program/program_lexer.l"
2272 {
2273    yylval->swiz_mask.swizzle = SWIZZLE_INVAL;
2274    yylval->swiz_mask.mask = WRITEMASK_XY
2275       | mask_from_char(yytext[3]);
2276    return MASK3;
2277 }
2278 	YY_BREAK
2279 case 148:
2280 YY_RULE_SETUP
2281 #line 368 "src/src/mesa/program/program_lexer.l"
2282 {
2283    yylval->swiz_mask.swizzle = SWIZZLE_INVAL;
2284    yylval->swiz_mask.mask = WRITEMASK_XZW;
2285    return MASK3;
2286 }
2287 	YY_BREAK
2288 case 149:
2289 YY_RULE_SETUP
2290 #line 373 "src/src/mesa/program/program_lexer.l"
2291 {
2292    yylval->swiz_mask.swizzle = SWIZZLE_INVAL;
2293    yylval->swiz_mask.mask = WRITEMASK_YZW;
2294    return MASK3;
2295 }
2296 	YY_BREAK
2297 case 150:
2298 YY_RULE_SETUP
2299 #line 379 "src/src/mesa/program/program_lexer.l"
2300 {
2301    yylval->swiz_mask.swizzle = SWIZZLE_INVAL;
2302    yylval->swiz_mask.mask = WRITEMASK_X
2303       | mask_from_char(yytext[2]);
2304    return MASK2;
2305 }
2306 	YY_BREAK
2307 case 151:
2308 YY_RULE_SETUP
2309 #line 385 "src/src/mesa/program/program_lexer.l"
2310 {
2311    yylval->swiz_mask.swizzle = SWIZZLE_INVAL;
2312    yylval->swiz_mask.mask = WRITEMASK_Y
2313       | mask_from_char(yytext[2]);
2314    return MASK2;
2315 }
2316 	YY_BREAK
2317 case 152:
2318 YY_RULE_SETUP
2319 #line 391 "src/src/mesa/program/program_lexer.l"
2320 {
2321    yylval->swiz_mask.swizzle = SWIZZLE_INVAL;
2322    yylval->swiz_mask.mask = WRITEMASK_ZW;
2323    return MASK2;
2324 }
2325 	YY_BREAK
2326 case 153:
2327 YY_RULE_SETUP
2328 #line 397 "src/src/mesa/program/program_lexer.l"
2329 {
2330    const unsigned s = swiz_from_char(yytext[1]);
2331    yylval->swiz_mask.swizzle = MAKE_SWIZZLE4(s, s, s, s);
2332    yylval->swiz_mask.mask = mask_from_char(yytext[1]);
2333    return MASK1;
2334 }
2335 	YY_BREAK
2336 case 154:
2337 YY_RULE_SETUP
2338 #line 404 "src/src/mesa/program/program_lexer.l"
2339 {
2340    yylval->swiz_mask.swizzle = MAKE_SWIZZLE4(swiz_from_char(yytext[1]),
2341 					    swiz_from_char(yytext[2]),
2342 					    swiz_from_char(yytext[3]),
2343 					    swiz_from_char(yytext[4]));
2344    yylval->swiz_mask.mask = 0;
2345    return SWIZZLE;
2346 }
2347 	YY_BREAK
2348 case 155:
2349 YY_RULE_SETUP
2350 #line 413 "src/src/mesa/program/program_lexer.l"
2351 {
2352    yylval->swiz_mask.swizzle = SWIZZLE_NOOP;
2353    yylval->swiz_mask.mask = WRITEMASK_XYZW;
2354    return_token_or_DOT(require_ARB_fp, MASK4);
2355 }
2356 	YY_BREAK
2357 case 156:
2358 YY_RULE_SETUP
2359 #line 419 "src/src/mesa/program/program_lexer.l"
2360 {
2361    yylval->swiz_mask.swizzle = SWIZZLE_INVAL;
2362    yylval->swiz_mask.mask = WRITEMASK_XY
2363       | mask_from_char(yytext[3]);
2364    return_token_or_DOT(require_ARB_fp, MASK3);
2365 }
2366 	YY_BREAK
2367 case 157:
2368 YY_RULE_SETUP
2369 #line 425 "src/src/mesa/program/program_lexer.l"
2370 {
2371    yylval->swiz_mask.swizzle = SWIZZLE_INVAL;
2372    yylval->swiz_mask.mask = WRITEMASK_XZW;
2373    return_token_or_DOT(require_ARB_fp, MASK3);
2374 }
2375 	YY_BREAK
2376 case 158:
2377 YY_RULE_SETUP
2378 #line 430 "src/src/mesa/program/program_lexer.l"
2379 {
2380    yylval->swiz_mask.swizzle = SWIZZLE_INVAL;
2381    yylval->swiz_mask.mask = WRITEMASK_YZW;
2382    return_token_or_DOT(require_ARB_fp, MASK3);
2383 }
2384 	YY_BREAK
2385 case 159:
2386 YY_RULE_SETUP
2387 #line 436 "src/src/mesa/program/program_lexer.l"
2388 {
2389    yylval->swiz_mask.swizzle = SWIZZLE_INVAL;
2390    yylval->swiz_mask.mask = WRITEMASK_X
2391       | mask_from_char(yytext[2]);
2392    return_token_or_DOT(require_ARB_fp, MASK2);
2393 }
2394 	YY_BREAK
2395 case 160:
2396 YY_RULE_SETUP
2397 #line 442 "src/src/mesa/program/program_lexer.l"
2398 {
2399    yylval->swiz_mask.swizzle = SWIZZLE_INVAL;
2400    yylval->swiz_mask.mask = WRITEMASK_Y
2401       | mask_from_char(yytext[2]);
2402    return_token_or_DOT(require_ARB_fp, MASK2);
2403 }
2404 	YY_BREAK
2405 case 161:
2406 YY_RULE_SETUP
2407 #line 448 "src/src/mesa/program/program_lexer.l"
2408 {
2409    yylval->swiz_mask.swizzle = SWIZZLE_INVAL;
2410    yylval->swiz_mask.mask = WRITEMASK_ZW;
2411    return_token_or_DOT(require_ARB_fp, MASK2);
2412 }
2413 	YY_BREAK
2414 case 162:
2415 YY_RULE_SETUP
2416 #line 454 "src/src/mesa/program/program_lexer.l"
2417 {
2418    const unsigned s = swiz_from_char(yytext[1]);
2419    yylval->swiz_mask.swizzle = MAKE_SWIZZLE4(s, s, s, s);
2420    yylval->swiz_mask.mask = mask_from_char(yytext[1]);
2421    return_token_or_DOT(require_ARB_fp, MASK1);
2422 }
2423 	YY_BREAK
2424 case 163:
2425 YY_RULE_SETUP
2426 #line 462 "src/src/mesa/program/program_lexer.l"
2427 {
2428    if (require_ARB_vp) {
2429       return TEXGEN_R;
2430    } else {
2431       yylval->swiz_mask.swizzle = MAKE_SWIZZLE4(SWIZZLE_X, SWIZZLE_X,
2432 						SWIZZLE_X, SWIZZLE_X);
2433       yylval->swiz_mask.mask = WRITEMASK_X;
2434       return MASK1;
2435    }
2436 }
2437 	YY_BREAK
2438 case 164:
2439 YY_RULE_SETUP
2440 #line 473 "src/src/mesa/program/program_lexer.l"
2441 {
2442    yylval->swiz_mask.swizzle = MAKE_SWIZZLE4(swiz_from_char(yytext[1]),
2443 					    swiz_from_char(yytext[2]),
2444 					    swiz_from_char(yytext[3]),
2445 					    swiz_from_char(yytext[4]));
2446    yylval->swiz_mask.mask = 0;
2447    return_token_or_DOT(require_ARB_fp, SWIZZLE);
2448 }
2449 	YY_BREAK
2450 case 165:
2451 YY_RULE_SETUP
2452 #line 482 "src/src/mesa/program/program_lexer.l"
2453 { return DOT; }
2454 	YY_BREAK
2455 case 166:
2456 /* rule 166 can match eol */
2457 YY_RULE_SETUP
2458 #line 484 "src/src/mesa/program/program_lexer.l"
2459 {
2460    yylloc->first_line++;
2461    yylloc->first_column = 1;
2462    yylloc->last_line++;
2463    yylloc->last_column = 1;
2464    yylloc->position++;
2465 }
2466 	YY_BREAK
2467 case 167:
2468 YY_RULE_SETUP
2469 #line 491 "src/src/mesa/program/program_lexer.l"
2470 /* eat whitespace */ ;
2471 	YY_BREAK
2472 case 168:
2473 *yy_cp = yyg->yy_hold_char; /* undo effects of setting up yytext */
2474 yyg->yy_c_buf_p = yy_cp -= 1;
2475 YY_DO_BEFORE_ACTION; /* set up yytext again */
2476 YY_RULE_SETUP
2477 #line 492 "src/src/mesa/program/program_lexer.l"
2478 /* eat comments */ ;
2479 	YY_BREAK
2480 case 169:
2481 YY_RULE_SETUP
2482 #line 493 "src/src/mesa/program/program_lexer.l"
2483 { return yytext[0]; }
2484 	YY_BREAK
2485 case 170:
2486 YY_RULE_SETUP
2487 #line 494 "src/src/mesa/program/program_lexer.l"
2488 ECHO;
2489 	YY_BREAK
2490 #line 2491 "src/chromium_gensrc/mesa/lex.yy.c"
2491 case YY_STATE_EOF(INITIAL):
2492 	yyterminate();
2493 
2494 	case YY_END_OF_BUFFER:
2495 		{
2496 		/* Amount of text matched not including the EOB char. */
2497 		int yy_amount_of_matched_text = (int) (yy_cp - yyg->yytext_ptr) - 1;
2498 
2499 		/* Undo the effects of YY_DO_BEFORE_ACTION. */
2500 		*yy_cp = yyg->yy_hold_char;
2501 		YY_RESTORE_YY_MORE_OFFSET
2502 
2503 		if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
2504 			{
2505 			/* We're scanning a new file or input source.  It's
2506 			 * possible that this happened because the user
2507 			 * just pointed yyin at a new source and called
2508 			 * _mesa_program_lex().  If so, then we have to assure
2509 			 * consistency between YY_CURRENT_BUFFER and our
2510 			 * globals.  Here is the right place to do so, because
2511 			 * this is the first action (other than possibly a
2512 			 * back-up) that will match for the new input source.
2513 			 */
2514 			yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
2515 			YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
2516 			YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
2517 			}
2518 
2519 		/* Note that here we test for yy_c_buf_p "<=" to the position
2520 		 * of the first EOB in the buffer, since yy_c_buf_p will
2521 		 * already have been incremented past the NUL character
2522 		 * (since all states make transitions on EOB to the
2523 		 * end-of-buffer state).  Contrast this with the test
2524 		 * in input().
2525 		 */
2526 		if ( yyg->yy_c_buf_p <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
2527 			{ /* This was really a NUL. */
2528 			yy_state_type yy_next_state;
2529 
2530 			yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text;
2531 
2532 			yy_current_state = yy_get_previous_state( yyscanner );
2533 
2534 			/* Okay, we're now positioned to make the NUL
2535 			 * transition.  We couldn't have
2536 			 * yy_get_previous_state() go ahead and do it
2537 			 * for us because it doesn't know how to deal
2538 			 * with the possibility of jamming (and we don't
2539 			 * want to build jamming into it because then it
2540 			 * will run more slowly).
2541 			 */
2542 
2543 			yy_next_state = yy_try_NUL_trans( yy_current_state , yyscanner);
2544 
2545 			yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
2546 
2547 			if ( yy_next_state )
2548 				{
2549 				/* Consume the NUL. */
2550 				yy_cp = ++yyg->yy_c_buf_p;
2551 				yy_current_state = yy_next_state;
2552 				goto yy_match;
2553 				}
2554 
2555 			else
2556 				{
2557 				yy_cp = yyg->yy_c_buf_p;
2558 				goto yy_find_action;
2559 				}
2560 			}
2561 
2562 		else switch ( yy_get_next_buffer( yyscanner ) )
2563 			{
2564 			case EOB_ACT_END_OF_FILE:
2565 				{
2566 				yyg->yy_did_buffer_switch_on_eof = 0;
2567 
2568 				if ( _mesa_program_wrap(yyscanner ) )
2569 					{
2570 					/* Note: because we've taken care in
2571 					 * yy_get_next_buffer() to have set up
2572 					 * yytext, we can now set up
2573 					 * yy_c_buf_p so that if some total
2574 					 * hoser (like flex itself) wants to
2575 					 * call the scanner after we return the
2576 					 * YY_NULL, it'll still work - another
2577 					 * YY_NULL will get returned.
2578 					 */
2579 					yyg->yy_c_buf_p = yyg->yytext_ptr + YY_MORE_ADJ;
2580 
2581 					yy_act = YY_STATE_EOF(YY_START);
2582 					goto do_action;
2583 					}
2584 
2585 				else
2586 					{
2587 					if ( ! yyg->yy_did_buffer_switch_on_eof )
2588 						YY_NEW_FILE;
2589 					}
2590 				break;
2591 				}
2592 
2593 			case EOB_ACT_CONTINUE_SCAN:
2594 				yyg->yy_c_buf_p =
2595 					yyg->yytext_ptr + yy_amount_of_matched_text;
2596 
2597 				yy_current_state = yy_get_previous_state( yyscanner );
2598 
2599 				yy_cp = yyg->yy_c_buf_p;
2600 				yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
2601 				goto yy_match;
2602 
2603 			case EOB_ACT_LAST_MATCH:
2604 				yyg->yy_c_buf_p =
2605 				&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars];
2606 
2607 				yy_current_state = yy_get_previous_state( yyscanner );
2608 
2609 				yy_cp = yyg->yy_c_buf_p;
2610 				yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
2611 				goto yy_find_action;
2612 			}
2613 		break;
2614 		}
2615 
2616 	default:
2617 		YY_FATAL_ERROR(
2618 			"fatal flex scanner internal error--no action found" );
2619 	} /* end of action switch */
2620 		} /* end of scanning one token */
2621 } /* end of _mesa_program_lex */
2622 
2623 /* yy_get_next_buffer - try to read in a new buffer
2624  *
2625  * Returns a code representing an action:
2626  *	EOB_ACT_LAST_MATCH -
2627  *	EOB_ACT_CONTINUE_SCAN - continue scanning from current position
2628  *	EOB_ACT_END_OF_FILE - end of file
2629  */
yy_get_next_buffer(yyscan_t yyscanner)2630 static int yy_get_next_buffer (yyscan_t yyscanner)
2631 {
2632     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2633 	register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
2634 	register char *source = yyg->yytext_ptr;
2635 	register int number_to_move, i;
2636 	int ret_val;
2637 
2638 	if ( yyg->yy_c_buf_p > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] )
2639 		YY_FATAL_ERROR(
2640 		"fatal flex scanner internal error--end of buffer missed" );
2641 
2642 	if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
2643 		{ /* Don't try to fill the buffer, so this is an EOF. */
2644 		if ( yyg->yy_c_buf_p - yyg->yytext_ptr - YY_MORE_ADJ == 1 )
2645 			{
2646 			/* We matched a single character, the EOB, so
2647 			 * treat this as a final EOF.
2648 			 */
2649 			return EOB_ACT_END_OF_FILE;
2650 			}
2651 
2652 		else
2653 			{
2654 			/* We matched some text prior to the EOB, first
2655 			 * process it.
2656 			 */
2657 			return EOB_ACT_LAST_MATCH;
2658 			}
2659 		}
2660 
2661 	/* Try to read more data. */
2662 
2663 	/* First move last chars to start of buffer. */
2664 	number_to_move = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr) - 1;
2665 
2666 	for ( i = 0; i < number_to_move; ++i )
2667 		*(dest++) = *(source++);
2668 
2669 	if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
2670 		/* don't do the read, it's not guaranteed to return an EOF,
2671 		 * just force an EOF
2672 		 */
2673 		YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars = 0;
2674 
2675 	else
2676 		{
2677 			int num_to_read =
2678 			YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
2679 
2680 		while ( num_to_read <= 0 )
2681 			{ /* Not enough room in the buffer - grow it. */
2682 
2683 			/* just a shorter name for the current buffer */
2684 			YY_BUFFER_STATE b = YY_CURRENT_BUFFER;
2685 
2686 			int yy_c_buf_p_offset =
2687 				(int) (yyg->yy_c_buf_p - b->yy_ch_buf);
2688 
2689 			if ( b->yy_is_our_buffer )
2690 				{
2691 				int new_size = b->yy_buf_size * 2;
2692 
2693 				if ( new_size <= 0 )
2694 					b->yy_buf_size += b->yy_buf_size / 8;
2695 				else
2696 					b->yy_buf_size *= 2;
2697 
2698 				b->yy_ch_buf = (char *)
2699 					/* Include room in for 2 EOB chars. */
2700 					_mesa_program_realloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ,yyscanner );
2701 				}
2702 			else
2703 				/* Can't grow it, we don't own it. */
2704 				b->yy_ch_buf = 0;
2705 
2706 			if ( ! b->yy_ch_buf )
2707 				YY_FATAL_ERROR(
2708 				"fatal error - scanner input buffer overflow" );
2709 
2710 			yyg->yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
2711 
2712 			num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
2713 						number_to_move - 1;
2714 
2715 			}
2716 
2717 		if ( num_to_read > YY_READ_BUF_SIZE )
2718 			num_to_read = YY_READ_BUF_SIZE;
2719 
2720 		/* Read in more data. */
2721 		YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
2722 			yyg->yy_n_chars, (size_t) num_to_read );
2723 
2724 		YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
2725 		}
2726 
2727 	if ( yyg->yy_n_chars == 0 )
2728 		{
2729 		if ( number_to_move == YY_MORE_ADJ )
2730 			{
2731 			ret_val = EOB_ACT_END_OF_FILE;
2732 			_mesa_program_restart(yyin  ,yyscanner);
2733 			}
2734 
2735 		else
2736 			{
2737 			ret_val = EOB_ACT_LAST_MATCH;
2738 			YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
2739 				YY_BUFFER_EOF_PENDING;
2740 			}
2741 		}
2742 
2743 	else
2744 		ret_val = EOB_ACT_CONTINUE_SCAN;
2745 
2746 	if ((yy_size_t) (yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
2747 		/* Extend the array by 50%, plus the number we really need. */
2748 		yy_size_t new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
2749 		YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) _mesa_program_realloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ,yyscanner );
2750 		if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
2751 			YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
2752 	}
2753 
2754 	yyg->yy_n_chars += number_to_move;
2755 	YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] = YY_END_OF_BUFFER_CHAR;
2756 	YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
2757 
2758 	yyg->yytext_ptr = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
2759 
2760 	return ret_val;
2761 }
2762 
2763 /* yy_get_previous_state - get the state just before the EOB char was reached */
2764 
yy_get_previous_state(yyscan_t yyscanner)2765     static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
2766 {
2767 	register yy_state_type yy_current_state;
2768 	register char *yy_cp;
2769     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2770 
2771 	yy_current_state = yyg->yy_start;
2772 
2773 	for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp )
2774 		{
2775 		register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
2776 		if ( yy_accept[yy_current_state] )
2777 			{
2778 			yyg->yy_last_accepting_state = yy_current_state;
2779 			yyg->yy_last_accepting_cpos = yy_cp;
2780 			}
2781 		while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
2782 			{
2783 			yy_current_state = (int) yy_def[yy_current_state];
2784 			if ( yy_current_state >= 850 )
2785 				yy_c = yy_meta[(unsigned int) yy_c];
2786 			}
2787 		yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
2788 		}
2789 
2790 	return yy_current_state;
2791 }
2792 
2793 /* yy_try_NUL_trans - try to make a transition on the NUL character
2794  *
2795  * synopsis
2796  *	next_state = yy_try_NUL_trans( current_state );
2797  */
yy_try_NUL_trans(yy_state_type yy_current_state,yyscan_t yyscanner)2798     static yy_state_type yy_try_NUL_trans  (yy_state_type yy_current_state , yyscan_t yyscanner)
2799 {
2800 	register int yy_is_jam;
2801     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* This var may be unused depending upon options. */
2802 	register char *yy_cp = yyg->yy_c_buf_p;
2803 
2804 	register YY_CHAR yy_c = 1;
2805 	if ( yy_accept[yy_current_state] )
2806 		{
2807 		yyg->yy_last_accepting_state = yy_current_state;
2808 		yyg->yy_last_accepting_cpos = yy_cp;
2809 		}
2810 	while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
2811 		{
2812 		yy_current_state = (int) yy_def[yy_current_state];
2813 		if ( yy_current_state >= 850 )
2814 			yy_c = yy_meta[(unsigned int) yy_c];
2815 		}
2816 	yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
2817 	yy_is_jam = (yy_current_state == 849);
2818 
2819 	return yy_is_jam ? 0 : yy_current_state;
2820 }
2821 
yyunput(int c,register char * yy_bp,yyscan_t yyscanner)2822     static void yyunput (int c, register char * yy_bp , yyscan_t yyscanner)
2823 {
2824 	register char *yy_cp;
2825     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2826 
2827     yy_cp = yyg->yy_c_buf_p;
2828 
2829 	/* undo effects of setting up yytext */
2830 	*yy_cp = yyg->yy_hold_char;
2831 
2832 	if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
2833 		{ /* need to shift things up to make room */
2834 		/* +2 for EOB chars. */
2835 		register int number_to_move = yyg->yy_n_chars + 2;
2836 		register char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[
2837 					YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2];
2838 		register char *source =
2839 				&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move];
2840 
2841 		while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
2842 			*--dest = *--source;
2843 
2844 		yy_cp += (int) (dest - source);
2845 		yy_bp += (int) (dest - source);
2846 		YY_CURRENT_BUFFER_LVALUE->yy_n_chars =
2847 			yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_buf_size;
2848 
2849 		if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
2850 			YY_FATAL_ERROR( "flex scanner push-back overflow" );
2851 		}
2852 
2853 	*--yy_cp = (char) c;
2854 
2855 	yyg->yytext_ptr = yy_bp;
2856 	yyg->yy_hold_char = *yy_cp;
2857 	yyg->yy_c_buf_p = yy_cp;
2858 }
2859 
2860 #ifndef YY_NO_INPUT
2861 #ifdef __cplusplus
yyinput(yyscan_t yyscanner)2862     static int yyinput (yyscan_t yyscanner)
2863 #else
2864     static int input  (yyscan_t yyscanner)
2865 #endif
2866 
2867 {
2868 	int c;
2869     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2870 
2871 	*yyg->yy_c_buf_p = yyg->yy_hold_char;
2872 
2873 	if ( *yyg->yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
2874 		{
2875 		/* yy_c_buf_p now points to the character we want to return.
2876 		 * If this occurs *before* the EOB characters, then it's a
2877 		 * valid NUL; if not, then we've hit the end of the buffer.
2878 		 */
2879 		if ( yyg->yy_c_buf_p < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
2880 			/* This was really a NUL. */
2881 			*yyg->yy_c_buf_p = '\0';
2882 
2883 		else
2884 			{ /* need more input */
2885 			int offset = yyg->yy_c_buf_p - yyg->yytext_ptr;
2886 			++yyg->yy_c_buf_p;
2887 
2888 			switch ( yy_get_next_buffer( yyscanner ) )
2889 				{
2890 				case EOB_ACT_LAST_MATCH:
2891 					/* This happens because yy_g_n_b()
2892 					 * sees that we've accumulated a
2893 					 * token and flags that we need to
2894 					 * try matching the token before
2895 					 * proceeding.  But for input(),
2896 					 * there's no matching to consider.
2897 					 * So convert the EOB_ACT_LAST_MATCH
2898 					 * to EOB_ACT_END_OF_FILE.
2899 					 */
2900 
2901 					/* Reset buffer status. */
2902 					_mesa_program_restart(yyin ,yyscanner);
2903 
2904 					/*FALLTHROUGH*/
2905 
2906 				case EOB_ACT_END_OF_FILE:
2907 					{
2908 					if ( _mesa_program_wrap(yyscanner ) )
2909 						return EOF;
2910 
2911 					if ( ! yyg->yy_did_buffer_switch_on_eof )
2912 						YY_NEW_FILE;
2913 #ifdef __cplusplus
2914 					return yyinput(yyscanner);
2915 #else
2916 					return input(yyscanner);
2917 #endif
2918 					}
2919 
2920 				case EOB_ACT_CONTINUE_SCAN:
2921 					yyg->yy_c_buf_p = yyg->yytext_ptr + offset;
2922 					break;
2923 				}
2924 			}
2925 		}
2926 
2927 	c = *(unsigned char *) yyg->yy_c_buf_p;	/* cast for 8-bit char's */
2928 	*yyg->yy_c_buf_p = '\0';	/* preserve yytext */
2929 	yyg->yy_hold_char = *++yyg->yy_c_buf_p;
2930 
2931 	return c;
2932 }
2933 #endif	/* ifndef YY_NO_INPUT */
2934 
2935 /** Immediately switch to a different input stream.
2936  * @param input_file A readable stream.
2937  * @param yyscanner The scanner object.
2938  * @note This function does not reset the start condition to @c INITIAL .
2939  */
_mesa_program_restart(FILE * input_file,yyscan_t yyscanner)2940     void _mesa_program_restart  (FILE * input_file , yyscan_t yyscanner)
2941 {
2942     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2943 
2944 	if ( ! YY_CURRENT_BUFFER ){
2945         _mesa_program_ensure_buffer_stack (yyscanner);
2946 		YY_CURRENT_BUFFER_LVALUE =
2947             _mesa_program__create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
2948 	}
2949 
2950 	_mesa_program__init_buffer(YY_CURRENT_BUFFER,input_file ,yyscanner);
2951 	_mesa_program__load_buffer_state(yyscanner );
2952 }
2953 
2954 /** Switch to a different input buffer.
2955  * @param new_buffer The new input buffer.
2956  * @param yyscanner The scanner object.
2957  */
_mesa_program__switch_to_buffer(YY_BUFFER_STATE new_buffer,yyscan_t yyscanner)2958     void _mesa_program__switch_to_buffer  (YY_BUFFER_STATE  new_buffer , yyscan_t yyscanner)
2959 {
2960     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2961 
2962 	/* TODO. We should be able to replace this entire function body
2963 	 * with
2964 	 *		_mesa_program_pop_buffer_state();
2965 	 *		_mesa_program_push_buffer_state(new_buffer);
2966      */
2967 	_mesa_program_ensure_buffer_stack (yyscanner);
2968 	if ( YY_CURRENT_BUFFER == new_buffer )
2969 		return;
2970 
2971 	if ( YY_CURRENT_BUFFER )
2972 		{
2973 		/* Flush out information for old buffer. */
2974 		*yyg->yy_c_buf_p = yyg->yy_hold_char;
2975 		YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
2976 		YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
2977 		}
2978 
2979 	YY_CURRENT_BUFFER_LVALUE = new_buffer;
2980 	_mesa_program__load_buffer_state(yyscanner );
2981 
2982 	/* We don't actually know whether we did this switch during
2983 	 * EOF (_mesa_program_wrap()) processing, but the only time this flag
2984 	 * is looked at is after _mesa_program_wrap() is called, so it's safe
2985 	 * to go ahead and always set it.
2986 	 */
2987 	yyg->yy_did_buffer_switch_on_eof = 1;
2988 }
2989 
_mesa_program__load_buffer_state(yyscan_t yyscanner)2990 static void _mesa_program__load_buffer_state  (yyscan_t yyscanner)
2991 {
2992     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2993 	yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
2994 	yyg->yytext_ptr = yyg->yy_c_buf_p = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
2995 	yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
2996 	yyg->yy_hold_char = *yyg->yy_c_buf_p;
2997 }
2998 
2999 /** Allocate and initialize an input buffer state.
3000  * @param file A readable stream.
3001  * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
3002  * @param yyscanner The scanner object.
3003  * @return the allocated buffer state.
3004  */
_mesa_program__create_buffer(FILE * file,int size,yyscan_t yyscanner)3005     YY_BUFFER_STATE _mesa_program__create_buffer  (FILE * file, int  size , yyscan_t yyscanner)
3006 {
3007 	YY_BUFFER_STATE b;
3008 
3009 	b = (YY_BUFFER_STATE) _mesa_program_alloc(sizeof( struct yy_buffer_state ) ,yyscanner );
3010 	if ( ! b )
3011 		YY_FATAL_ERROR( "out of dynamic memory in _mesa_program__create_buffer()" );
3012 
3013 	b->yy_buf_size = size;
3014 
3015 	/* yy_ch_buf has to be 2 characters longer than the size given because
3016 	 * we need to put in 2 end-of-buffer characters.
3017 	 */
3018 	b->yy_ch_buf = (char *) _mesa_program_alloc(b->yy_buf_size + 2 ,yyscanner );
3019 	if ( ! b->yy_ch_buf )
3020 		YY_FATAL_ERROR( "out of dynamic memory in _mesa_program__create_buffer()" );
3021 
3022 	b->yy_is_our_buffer = 1;
3023 
3024 	_mesa_program__init_buffer(b,file ,yyscanner);
3025 
3026 	return b;
3027 }
3028 
3029 /** Destroy the buffer.
3030  * @param b a buffer created with _mesa_program__create_buffer()
3031  * @param yyscanner The scanner object.
3032  */
_mesa_program__delete_buffer(YY_BUFFER_STATE b,yyscan_t yyscanner)3033     void _mesa_program__delete_buffer (YY_BUFFER_STATE  b , yyscan_t yyscanner)
3034 {
3035     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3036 
3037 	if ( ! b )
3038 		return;
3039 
3040 	if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
3041 		YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
3042 
3043 	if ( b->yy_is_our_buffer )
3044 		_mesa_program_free((void *) b->yy_ch_buf ,yyscanner );
3045 
3046 	_mesa_program_free((void *) b ,yyscanner );
3047 }
3048 
3049 /* Initializes or reinitializes a buffer.
3050  * This function is sometimes called more than once on the same buffer,
3051  * such as during a _mesa_program_restart() or at EOF.
3052  */
_mesa_program__init_buffer(YY_BUFFER_STATE b,FILE * file,yyscan_t yyscanner)3053     static void _mesa_program__init_buffer  (YY_BUFFER_STATE  b, FILE * file , yyscan_t yyscanner)
3054 
3055 {
3056 	int oerrno = errno;
3057     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3058 
3059 	_mesa_program__flush_buffer(b ,yyscanner);
3060 
3061 	b->yy_input_file = file;
3062 	b->yy_fill_buffer = 1;
3063 
3064     /* If b is the current buffer, then _mesa_program__init_buffer was _probably_
3065      * called from _mesa_program_restart() or through yy_get_next_buffer.
3066      * In that case, we don't want to reset the lineno or column.
3067      */
3068     if (b != YY_CURRENT_BUFFER){
3069         b->yy_bs_lineno = 1;
3070         b->yy_bs_column = 0;
3071     }
3072 
3073         b->yy_is_interactive = 0;
3074 
3075 	errno = oerrno;
3076 }
3077 
3078 /** Discard all buffered characters. On the next scan, YY_INPUT will be called.
3079  * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
3080  * @param yyscanner The scanner object.
3081  */
_mesa_program__flush_buffer(YY_BUFFER_STATE b,yyscan_t yyscanner)3082     void _mesa_program__flush_buffer (YY_BUFFER_STATE  b , yyscan_t yyscanner)
3083 {
3084     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3085 	if ( ! b )
3086 		return;
3087 
3088 	b->yy_n_chars = 0;
3089 
3090 	/* We always need two end-of-buffer characters.  The first causes
3091 	 * a transition to the end-of-buffer state.  The second causes
3092 	 * a jam in that state.
3093 	 */
3094 	b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
3095 	b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
3096 
3097 	b->yy_buf_pos = &b->yy_ch_buf[0];
3098 
3099 	b->yy_at_bol = 1;
3100 	b->yy_buffer_status = YY_BUFFER_NEW;
3101 
3102 	if ( b == YY_CURRENT_BUFFER )
3103 		_mesa_program__load_buffer_state(yyscanner );
3104 }
3105 
3106 /** Pushes the new state onto the stack. The new state becomes
3107  *  the current state. This function will allocate the stack
3108  *  if necessary.
3109  *  @param new_buffer The new state.
3110  *  @param yyscanner The scanner object.
3111  */
_mesa_program_push_buffer_state(YY_BUFFER_STATE new_buffer,yyscan_t yyscanner)3112 void _mesa_program_push_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
3113 {
3114     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3115 	if (new_buffer == NULL)
3116 		return;
3117 
3118 	_mesa_program_ensure_buffer_stack(yyscanner);
3119 
3120 	/* This block is copied from _mesa_program__switch_to_buffer. */
3121 	if ( YY_CURRENT_BUFFER )
3122 		{
3123 		/* Flush out information for old buffer. */
3124 		*yyg->yy_c_buf_p = yyg->yy_hold_char;
3125 		YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
3126 		YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
3127 		}
3128 
3129 	/* Only push if top exists. Otherwise, replace top. */
3130 	if (YY_CURRENT_BUFFER)
3131 		yyg->yy_buffer_stack_top++;
3132 	YY_CURRENT_BUFFER_LVALUE = new_buffer;
3133 
3134 	/* copied from _mesa_program__switch_to_buffer. */
3135 	_mesa_program__load_buffer_state(yyscanner );
3136 	yyg->yy_did_buffer_switch_on_eof = 1;
3137 }
3138 
3139 /** Removes and deletes the top of the stack, if present.
3140  *  The next element becomes the new top.
3141  *  @param yyscanner The scanner object.
3142  */
_mesa_program_pop_buffer_state(yyscan_t yyscanner)3143 void _mesa_program_pop_buffer_state (yyscan_t yyscanner)
3144 {
3145     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3146 	if (!YY_CURRENT_BUFFER)
3147 		return;
3148 
3149 	_mesa_program__delete_buffer(YY_CURRENT_BUFFER ,yyscanner);
3150 	YY_CURRENT_BUFFER_LVALUE = NULL;
3151 	if (yyg->yy_buffer_stack_top > 0)
3152 		--yyg->yy_buffer_stack_top;
3153 
3154 	if (YY_CURRENT_BUFFER) {
3155 		_mesa_program__load_buffer_state(yyscanner );
3156 		yyg->yy_did_buffer_switch_on_eof = 1;
3157 	}
3158 }
3159 
3160 /* Allocates the stack if it does not exist.
3161  *  Guarantees space for at least one push.
3162  */
_mesa_program_ensure_buffer_stack(yyscan_t yyscanner)3163 static void _mesa_program_ensure_buffer_stack (yyscan_t yyscanner)
3164 {
3165 	int num_to_alloc;
3166     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3167 
3168 	if (!yyg->yy_buffer_stack) {
3169 
3170 		/* First allocation is just for 2 elements, since we don't know if this
3171 		 * scanner will even need a stack. We use 2 instead of 1 to avoid an
3172 		 * immediate realloc on the next call.
3173          */
3174 		num_to_alloc = 1;
3175 		yyg->yy_buffer_stack = (struct yy_buffer_state**)_mesa_program_alloc
3176 								(num_to_alloc * sizeof(struct yy_buffer_state*)
3177 								, yyscanner);
3178 		if ( ! yyg->yy_buffer_stack )
3179 			YY_FATAL_ERROR( "out of dynamic memory in _mesa_program_ensure_buffer_stack()" );
3180 
3181 		memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*));
3182 
3183 		yyg->yy_buffer_stack_max = num_to_alloc;
3184 		yyg->yy_buffer_stack_top = 0;
3185 		return;
3186 	}
3187 
3188 	if (yyg->yy_buffer_stack_top >= (yyg->yy_buffer_stack_max) - 1){
3189 
3190 		/* Increase the buffer to prepare for a possible push. */
3191 		int grow_size = 8 /* arbitrary grow size */;
3192 
3193 		num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
3194 		yyg->yy_buffer_stack = (struct yy_buffer_state**)_mesa_program_realloc
3195 								(yyg->yy_buffer_stack,
3196 								num_to_alloc * sizeof(struct yy_buffer_state*)
3197 								, yyscanner);
3198 		if ( ! yyg->yy_buffer_stack )
3199 			YY_FATAL_ERROR( "out of dynamic memory in _mesa_program_ensure_buffer_stack()" );
3200 
3201 		/* zero only the new slots.*/
3202 		memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*));
3203 		yyg->yy_buffer_stack_max = num_to_alloc;
3204 	}
3205 }
3206 
3207 /** Setup the input buffer state to scan directly from a user-specified character buffer.
3208  * @param base the character buffer
3209  * @param size the size in bytes of the character buffer
3210  * @param yyscanner The scanner object.
3211  * @return the newly allocated buffer state object.
3212  */
_mesa_program__scan_buffer(char * base,yy_size_t size,yyscan_t yyscanner)3213 YY_BUFFER_STATE _mesa_program__scan_buffer  (char * base, yy_size_t  size , yyscan_t yyscanner)
3214 {
3215 	YY_BUFFER_STATE b;
3216 
3217 	if ( size < 2 ||
3218 	     base[size-2] != YY_END_OF_BUFFER_CHAR ||
3219 	     base[size-1] != YY_END_OF_BUFFER_CHAR )
3220 		/* They forgot to leave room for the EOB's. */
3221 		return 0;
3222 
3223 	b = (YY_BUFFER_STATE) _mesa_program_alloc(sizeof( struct yy_buffer_state ) ,yyscanner );
3224 	if ( ! b )
3225 		YY_FATAL_ERROR( "out of dynamic memory in _mesa_program__scan_buffer()" );
3226 
3227 	b->yy_buf_size = size - 2;	/* "- 2" to take care of EOB's */
3228 	b->yy_buf_pos = b->yy_ch_buf = base;
3229 	b->yy_is_our_buffer = 0;
3230 	b->yy_input_file = 0;
3231 	b->yy_n_chars = b->yy_buf_size;
3232 	b->yy_is_interactive = 0;
3233 	b->yy_at_bol = 1;
3234 	b->yy_fill_buffer = 0;
3235 	b->yy_buffer_status = YY_BUFFER_NEW;
3236 
3237 	_mesa_program__switch_to_buffer(b ,yyscanner );
3238 
3239 	return b;
3240 }
3241 
3242 /** Setup the input buffer state to scan a string. The next call to _mesa_program_lex() will
3243  * scan from a @e copy of @a str.
3244  * @param yystr a NUL-terminated string to scan
3245  * @param yyscanner The scanner object.
3246  * @return the newly allocated buffer state object.
3247  * @note If you want to scan bytes that may contain NUL values, then use
3248  *       _mesa_program__scan_bytes() instead.
3249  */
_mesa_program__scan_string(yyconst char * yystr,yyscan_t yyscanner)3250 YY_BUFFER_STATE _mesa_program__scan_string (yyconst char * yystr , yyscan_t yyscanner)
3251 {
3252 
3253 	return _mesa_program__scan_bytes(yystr,strlen(yystr) ,yyscanner);
3254 }
3255 
3256 /** Setup the input buffer state to scan the given bytes. The next call to _mesa_program_lex() will
3257  * scan from a @e copy of @a bytes.
3258  * @param yybytes the byte buffer to scan
3259  * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
3260  * @param yyscanner The scanner object.
3261  * @return the newly allocated buffer state object.
3262  */
_mesa_program__scan_bytes(yyconst char * yybytes,int _yybytes_len,yyscan_t yyscanner)3263 YY_BUFFER_STATE _mesa_program__scan_bytes  (yyconst char * yybytes, int  _yybytes_len , yyscan_t yyscanner)
3264 {
3265 	YY_BUFFER_STATE b;
3266 	char *buf;
3267 	yy_size_t n;
3268 	int i;
3269 
3270 	/* Get memory for full buffer, including space for trailing EOB's. */
3271 	n = _yybytes_len + 2;
3272 	buf = (char *) _mesa_program_alloc(n ,yyscanner );
3273 	if ( ! buf )
3274 		YY_FATAL_ERROR( "out of dynamic memory in _mesa_program__scan_bytes()" );
3275 
3276 	for ( i = 0; i < _yybytes_len; ++i )
3277 		buf[i] = yybytes[i];
3278 
3279 	buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
3280 
3281 	b = _mesa_program__scan_buffer(buf,n ,yyscanner);
3282 	if ( ! b )
3283 		YY_FATAL_ERROR( "bad buffer in _mesa_program__scan_bytes()" );
3284 
3285 	/* It's okay to grow etc. this buffer, and we should throw it
3286 	 * away when we're done.
3287 	 */
3288 	b->yy_is_our_buffer = 1;
3289 
3290 	return b;
3291 }
3292 
3293 #ifndef YY_EXIT_FAILURE
3294 #define YY_EXIT_FAILURE 2
3295 #endif
3296 
yy_fatal_error(yyconst char * msg,yyscan_t yyscanner)3297 static void yy_fatal_error (yyconst char* msg , yyscan_t yyscanner)
3298 {
3299     	(void) fprintf( stderr, "%s\n", msg );
3300 	exit( YY_EXIT_FAILURE );
3301 }
3302 
3303 /* Redefine yyless() so it works in section 3 code. */
3304 
3305 #undef yyless
3306 #define yyless(n) \
3307 	do \
3308 		{ \
3309 		/* Undo effects of setting up yytext. */ \
3310         int yyless_macro_arg = (n); \
3311         YY_LESS_LINENO(yyless_macro_arg);\
3312 		yytext[yyleng] = yyg->yy_hold_char; \
3313 		yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
3314 		yyg->yy_hold_char = *yyg->yy_c_buf_p; \
3315 		*yyg->yy_c_buf_p = '\0'; \
3316 		yyleng = yyless_macro_arg; \
3317 		} \
3318 	while ( 0 )
3319 
3320 /* Accessor  methods (get/set functions) to struct members. */
3321 
3322 /** Get the user-defined data for this scanner.
3323  * @param yyscanner The scanner object.
3324  */
_mesa_program_get_extra(yyscan_t yyscanner)3325 YY_EXTRA_TYPE _mesa_program_get_extra  (yyscan_t yyscanner)
3326 {
3327     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3328     return yyextra;
3329 }
3330 
3331 /** Get the current line number.
3332  * @param yyscanner The scanner object.
3333  */
_mesa_program_get_lineno(yyscan_t yyscanner)3334 int _mesa_program_get_lineno  (yyscan_t yyscanner)
3335 {
3336     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3337 
3338         if (! YY_CURRENT_BUFFER)
3339             return 0;
3340 
3341     return yylineno;
3342 }
3343 
3344 /** Get the current column number.
3345  * @param yyscanner The scanner object.
3346  */
_mesa_program_get_column(yyscan_t yyscanner)3347 int _mesa_program_get_column  (yyscan_t yyscanner)
3348 {
3349     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3350 
3351         if (! YY_CURRENT_BUFFER)
3352             return 0;
3353 
3354     return yycolumn;
3355 }
3356 
3357 /** Get the input stream.
3358  * @param yyscanner The scanner object.
3359  */
_mesa_program_get_in(yyscan_t yyscanner)3360 FILE *_mesa_program_get_in  (yyscan_t yyscanner)
3361 {
3362     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3363     return yyin;
3364 }
3365 
3366 /** Get the output stream.
3367  * @param yyscanner The scanner object.
3368  */
_mesa_program_get_out(yyscan_t yyscanner)3369 FILE *_mesa_program_get_out  (yyscan_t yyscanner)
3370 {
3371     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3372     return yyout;
3373 }
3374 
3375 /** Get the length of the current token.
3376  * @param yyscanner The scanner object.
3377  */
_mesa_program_get_leng(yyscan_t yyscanner)3378 int _mesa_program_get_leng  (yyscan_t yyscanner)
3379 {
3380     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3381     return yyleng;
3382 }
3383 
3384 /** Get the current token.
3385  * @param yyscanner The scanner object.
3386  */
3387 
_mesa_program_get_text(yyscan_t yyscanner)3388 char *_mesa_program_get_text  (yyscan_t yyscanner)
3389 {
3390     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3391     return yytext;
3392 }
3393 
3394 /** Set the user-defined data. This data is never touched by the scanner.
3395  * @param user_defined The data to be associated with this scanner.
3396  * @param yyscanner The scanner object.
3397  */
_mesa_program_set_extra(YY_EXTRA_TYPE user_defined,yyscan_t yyscanner)3398 void _mesa_program_set_extra (YY_EXTRA_TYPE  user_defined , yyscan_t yyscanner)
3399 {
3400     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3401     yyextra = user_defined ;
3402 }
3403 
3404 /** Set the current line number.
3405  * @param line_number
3406  * @param yyscanner The scanner object.
3407  */
_mesa_program_set_lineno(int line_number,yyscan_t yyscanner)3408 void _mesa_program_set_lineno (int  line_number , yyscan_t yyscanner)
3409 {
3410     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3411 
3412         /* lineno is only valid if an input buffer exists. */
3413         if (! YY_CURRENT_BUFFER )
3414            yy_fatal_error( "_mesa_program_set_lineno called with no buffer" , yyscanner);
3415 
3416     yylineno = line_number;
3417 }
3418 
3419 /** Set the current column.
3420  * @param line_number
3421  * @param yyscanner The scanner object.
3422  */
_mesa_program_set_column(int column_no,yyscan_t yyscanner)3423 void _mesa_program_set_column (int  column_no , yyscan_t yyscanner)
3424 {
3425     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3426 
3427         /* column is only valid if an input buffer exists. */
3428         if (! YY_CURRENT_BUFFER )
3429            yy_fatal_error( "_mesa_program_set_column called with no buffer" , yyscanner);
3430 
3431     yycolumn = column_no;
3432 }
3433 
3434 /** Set the input stream. This does not discard the current
3435  * input buffer.
3436  * @param in_str A readable stream.
3437  * @param yyscanner The scanner object.
3438  * @see _mesa_program__switch_to_buffer
3439  */
_mesa_program_set_in(FILE * in_str,yyscan_t yyscanner)3440 void _mesa_program_set_in (FILE *  in_str , yyscan_t yyscanner)
3441 {
3442     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3443     yyin = in_str ;
3444 }
3445 
_mesa_program_set_out(FILE * out_str,yyscan_t yyscanner)3446 void _mesa_program_set_out (FILE *  out_str , yyscan_t yyscanner)
3447 {
3448     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3449     yyout = out_str ;
3450 }
3451 
_mesa_program_get_debug(yyscan_t yyscanner)3452 int _mesa_program_get_debug  (yyscan_t yyscanner)
3453 {
3454     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3455     return yy_flex_debug;
3456 }
3457 
_mesa_program_set_debug(int bdebug,yyscan_t yyscanner)3458 void _mesa_program_set_debug (int  bdebug , yyscan_t yyscanner)
3459 {
3460     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3461     yy_flex_debug = bdebug ;
3462 }
3463 
3464 /* Accessor methods for yylval and yylloc */
3465 
_mesa_program_get_lval(yyscan_t yyscanner)3466 YYSTYPE * _mesa_program_get_lval  (yyscan_t yyscanner)
3467 {
3468     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3469     return yylval;
3470 }
3471 
_mesa_program_set_lval(YYSTYPE * yylval_param,yyscan_t yyscanner)3472 void _mesa_program_set_lval (YYSTYPE *  yylval_param , yyscan_t yyscanner)
3473 {
3474     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3475     yylval = yylval_param;
3476 }
3477 
_mesa_program_get_lloc(yyscan_t yyscanner)3478 YYLTYPE *_mesa_program_get_lloc  (yyscan_t yyscanner)
3479 {
3480     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3481     return yylloc;
3482 }
3483 
_mesa_program_set_lloc(YYLTYPE * yylloc_param,yyscan_t yyscanner)3484 void _mesa_program_set_lloc (YYLTYPE *  yylloc_param , yyscan_t yyscanner)
3485 {
3486     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3487     yylloc = yylloc_param;
3488 }
3489 
3490 /* User-visible API */
3491 
3492 /* _mesa_program_lex_init is special because it creates the scanner itself, so it is
3493  * the ONLY reentrant function that doesn't take the scanner as the last argument.
3494  * That's why we explicitly handle the declaration, instead of using our macros.
3495  */
3496 
_mesa_program_lex_init(yyscan_t * ptr_yy_globals)3497 int _mesa_program_lex_init(yyscan_t* ptr_yy_globals)
3498 
3499 {
3500     if (ptr_yy_globals == NULL){
3501         errno = EINVAL;
3502         return 1;
3503     }
3504 
3505     *ptr_yy_globals = (yyscan_t) _mesa_program_alloc ( sizeof( struct yyguts_t ), NULL );
3506 
3507     if (*ptr_yy_globals == NULL){
3508         errno = ENOMEM;
3509         return 1;
3510     }
3511 
3512     /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */
3513     memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
3514 
3515     return yy_init_globals ( *ptr_yy_globals );
3516 }
3517 
3518 /* _mesa_program_lex_init_extra has the same functionality as _mesa_program_lex_init, but follows the
3519  * convention of taking the scanner as the last argument. Note however, that
3520  * this is a *pointer* to a scanner, as it will be allocated by this call (and
3521  * is the reason, too, why this function also must handle its own declaration).
3522  * The user defined value in the first argument will be available to _mesa_program_alloc in
3523  * the yyextra field.
3524  */
3525 
_mesa_program_lex_init_extra(YY_EXTRA_TYPE yy_user_defined,yyscan_t * ptr_yy_globals)3526 int _mesa_program_lex_init_extra(YY_EXTRA_TYPE yy_user_defined,yyscan_t* ptr_yy_globals )
3527 
3528 {
3529     struct yyguts_t dummy_yyguts;
3530 
3531     _mesa_program_set_extra (yy_user_defined, &dummy_yyguts);
3532 
3533     if (ptr_yy_globals == NULL){
3534         errno = EINVAL;
3535         return 1;
3536     }
3537 
3538     *ptr_yy_globals = (yyscan_t) _mesa_program_alloc ( sizeof( struct yyguts_t ), &dummy_yyguts );
3539 
3540     if (*ptr_yy_globals == NULL){
3541         errno = ENOMEM;
3542         return 1;
3543     }
3544 
3545     /* By setting to 0xAA, we expose bugs in
3546     yy_init_globals. Leave at 0x00 for releases. */
3547     memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
3548 
3549     _mesa_program_set_extra (yy_user_defined, *ptr_yy_globals);
3550 
3551     return yy_init_globals ( *ptr_yy_globals );
3552 }
3553 
yy_init_globals(yyscan_t yyscanner)3554 static int yy_init_globals (yyscan_t yyscanner)
3555 {
3556     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3557     /* Initialization is the same as for the non-reentrant scanner.
3558      * This function is called from _mesa_program_lex_destroy(), so don't allocate here.
3559      */
3560 
3561     yyg->yy_buffer_stack = 0;
3562     yyg->yy_buffer_stack_top = 0;
3563     yyg->yy_buffer_stack_max = 0;
3564     yyg->yy_c_buf_p = (char *) 0;
3565     yyg->yy_init = 0;
3566     yyg->yy_start = 0;
3567 
3568     yyg->yy_start_stack_ptr = 0;
3569     yyg->yy_start_stack_depth = 0;
3570     yyg->yy_start_stack =  NULL;
3571 
3572 /* Defined in main.c */
3573 #ifdef YY_STDINIT
3574     yyin = stdin;
3575     yyout = stdout;
3576 #else
3577     yyin = (FILE *) 0;
3578     yyout = (FILE *) 0;
3579 #endif
3580 
3581     /* For future reference: Set errno on error, since we are called by
3582      * _mesa_program_lex_init()
3583      */
3584     return 0;
3585 }
3586 
3587 /* _mesa_program_lex_destroy is for both reentrant and non-reentrant scanners. */
_mesa_program_lex_destroy(yyscan_t yyscanner)3588 int _mesa_program_lex_destroy  (yyscan_t yyscanner)
3589 {
3590     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3591 
3592     /* Pop the buffer stack, destroying each element. */
3593 	while(YY_CURRENT_BUFFER){
3594 		_mesa_program__delete_buffer(YY_CURRENT_BUFFER ,yyscanner );
3595 		YY_CURRENT_BUFFER_LVALUE = NULL;
3596 		_mesa_program_pop_buffer_state(yyscanner);
3597 	}
3598 
3599 	/* Destroy the stack itself. */
3600 	_mesa_program_free(yyg->yy_buffer_stack ,yyscanner);
3601 	yyg->yy_buffer_stack = NULL;
3602 
3603     /* Destroy the start condition stack. */
3604         _mesa_program_free(yyg->yy_start_stack ,yyscanner );
3605         yyg->yy_start_stack = NULL;
3606 
3607     /* Reset the globals. This is important in a non-reentrant scanner so the next time
3608      * _mesa_program_lex() is called, initialization will occur. */
3609     yy_init_globals( yyscanner);
3610 
3611     /* Destroy the main struct (reentrant only). */
3612     _mesa_program_free ( yyscanner , yyscanner );
3613     yyscanner = NULL;
3614     return 0;
3615 }
3616 
3617 /*
3618  * Internal utility routines.
3619  */
3620 
3621 #ifndef yytext_ptr
yy_flex_strncpy(char * s1,yyconst char * s2,int n,yyscan_t yyscanner)3622 static void yy_flex_strncpy (char* s1, yyconst char * s2, int n , yyscan_t yyscanner)
3623 {
3624 	register int i;
3625 	for ( i = 0; i < n; ++i )
3626 		s1[i] = s2[i];
3627 }
3628 #endif
3629 
3630 #ifdef YY_NEED_STRLEN
yy_flex_strlen(yyconst char * s,yyscan_t yyscanner)3631 static int yy_flex_strlen (yyconst char * s , yyscan_t yyscanner)
3632 {
3633 	register int n;
3634 	for ( n = 0; s[n]; ++n )
3635 		;
3636 
3637 	return n;
3638 }
3639 #endif
3640 
_mesa_program_alloc(yy_size_t size,yyscan_t yyscanner)3641 void *_mesa_program_alloc (yy_size_t  size , yyscan_t yyscanner)
3642 {
3643 	return (void *) malloc( size );
3644 }
3645 
_mesa_program_realloc(void * ptr,yy_size_t size,yyscan_t yyscanner)3646 void *_mesa_program_realloc  (void * ptr, yy_size_t  size , yyscan_t yyscanner)
3647 {
3648 	/* The cast to (char *) in the following accommodates both
3649 	 * implementations that use char* generic pointers, and those
3650 	 * that use void* generic pointers.  It works with the latter
3651 	 * because both ANSI C and C++ allow castless assignment from
3652 	 * any pointer type to void*, and deal with argument conversions
3653 	 * as though doing an assignment.
3654 	 */
3655 	return (void *) realloc( (char *) ptr, size );
3656 }
3657 
_mesa_program_free(void * ptr,yyscan_t yyscanner)3658 void _mesa_program_free (void * ptr , yyscan_t yyscanner)
3659 {
3660 	free( (char *) ptr );	/* see _mesa_program_realloc() for (char *) cast */
3661 }
3662 
3663 #define YYTABLES_NAME "yytables"
3664 
3665 #line 494 "src/src/mesa/program/program_lexer.l"
3666 
3667 
3668 
3669 void
_mesa_program_lexer_ctor(void ** scanner,struct asm_parser_state * state,const char * string,size_t len)3670 _mesa_program_lexer_ctor(void **scanner, struct asm_parser_state *state,
3671 			 const char *string, size_t len)
3672 {
3673    _mesa_program_lex_init_extra(state,scanner);
3674    _mesa_program__scan_bytes(string,len,*scanner);
3675 }
3676 
3677 void
_mesa_program_lexer_dtor(void * scanner)3678 _mesa_program_lexer_dtor(void *scanner)
3679 {
3680    _mesa_program_lex_destroy(scanner);
3681 }
3682 
3683