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