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