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