]> git.draconx.ca Git - gob-dx.git/blob - src/lexer.c
Release 0.0.3
[gob-dx.git] / src / lexer.c
1 /* A lexical scanner generated by flex */
2
3 /* Scanner skeleton version:
4  * $Header: /home/daffy/u0/vern/flex/RCS/flex.skl,v 2.91 96/09/10 16:58:48 vern Exp $
5  */
6
7 #define FLEX_SCANNER
8 #define YY_FLEX_MAJOR_VERSION 2
9 #define YY_FLEX_MINOR_VERSION 5
10
11 #include <stdio.h>
12
13
14 /* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */
15 #ifdef c_plusplus
16 #ifndef __cplusplus
17 #define __cplusplus
18 #endif
19 #endif
20
21
22 #ifdef __cplusplus
23
24 #include <stdlib.h>
25 #include <unistd.h>
26
27 /* Use prototypes in function declarations. */
28 #define YY_USE_PROTOS
29
30 /* The "const" storage-class-modifier is valid. */
31 #define YY_USE_CONST
32
33 #else   /* ! __cplusplus */
34
35 #if __STDC__
36
37 #define YY_USE_PROTOS
38 #define YY_USE_CONST
39
40 #endif  /* __STDC__ */
41 #endif  /* ! __cplusplus */
42
43 #ifdef __TURBOC__
44  #pragma warn -rch
45  #pragma warn -use
46 #include <io.h>
47 #include <stdlib.h>
48 #define YY_USE_CONST
49 #define YY_USE_PROTOS
50 #endif
51
52 #ifdef YY_USE_CONST
53 #define yyconst const
54 #else
55 #define yyconst
56 #endif
57
58
59 #ifdef YY_USE_PROTOS
60 #define YY_PROTO(proto) proto
61 #else
62 #define YY_PROTO(proto) ()
63 #endif
64
65 /* Returned upon end-of-file. */
66 #define YY_NULL 0
67
68 /* Promotes a possibly negative, possibly signed char to an unsigned
69  * integer for use as an array index.  If the signed char is negative,
70  * we want to instead treat it as an 8-bit unsigned char, hence the
71  * double cast.
72  */
73 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
74
75 /* Enter a start condition.  This macro really ought to take a parameter,
76  * but we do it the disgusting crufty way forced on us by the ()-less
77  * definition of BEGIN.
78  */
79 #define BEGIN yy_start = 1 + 2 *
80
81 /* Translate the current start state into a value that can be later handed
82  * to BEGIN to return to the state.  The YYSTATE alias is for lex
83  * compatibility.
84  */
85 #define YY_START ((yy_start - 1) / 2)
86 #define YYSTATE YY_START
87
88 /* Action number for EOF rule of a given start state. */
89 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
90
91 /* Special action meaning "start processing a new file". */
92 #define YY_NEW_FILE yyrestart( yyin )
93
94 #define YY_END_OF_BUFFER_CHAR 0
95
96 /* Size of default input buffer. */
97 #define YY_BUF_SIZE 16384
98
99 typedef struct yy_buffer_state *YY_BUFFER_STATE;
100
101 extern int yyleng;
102 extern FILE *yyin, *yyout;
103
104 #define EOB_ACT_CONTINUE_SCAN 0
105 #define EOB_ACT_END_OF_FILE 1
106 #define EOB_ACT_LAST_MATCH 2
107
108 /* The funky do-while in the following #define is used to turn the definition
109  * int a single C statement (which needs a semi-colon terminator).  This
110  * avoids problems with code like:
111  *
112  *      if ( condition_holds )
113  *              yyless( 5 );
114  *      else
115  *              do_something_else();
116  *
117  * Prior to using the do-while the compiler would get upset at the
118  * "else" because it interpreted the "if" statement as being all
119  * done when it reached the ';' after the yyless() call.
120  */
121
122 /* Return all but the first 'n' matched characters back to the input stream. */
123
124 #define yyless(n) \
125         do \
126                 { \
127                 /* Undo effects of setting up yytext. */ \
128                 *yy_cp = yy_hold_char; \
129                 YY_RESTORE_YY_MORE_OFFSET \
130                 yy_c_buf_p = yy_cp = yy_bp + n - YY_MORE_ADJ; \
131                 YY_DO_BEFORE_ACTION; /* set up yytext again */ \
132                 } \
133         while ( 0 )
134
135 #define unput(c) yyunput( c, yytext_ptr )
136
137 /* The following is because we cannot portably get our hands on size_t
138  * (without autoconf's help, which isn't available because we want
139  * flex-generated scanners to compile on their own).
140  */
141 typedef unsigned int yy_size_t;
142
143
144 struct yy_buffer_state
145         {
146         FILE *yy_input_file;
147
148         char *yy_ch_buf;                /* input buffer */
149         char *yy_buf_pos;               /* current position in input buffer */
150
151         /* Size of input buffer in bytes, not including room for EOB
152          * characters.
153          */
154         yy_size_t yy_buf_size;
155
156         /* Number of characters read into yy_ch_buf, not including EOB
157          * characters.
158          */
159         int yy_n_chars;
160
161         /* Whether we "own" the buffer - i.e., we know we created it,
162          * and can realloc() it to grow it, and should free() it to
163          * delete it.
164          */
165         int yy_is_our_buffer;
166
167         /* Whether this is an "interactive" input source; if so, and
168          * if we're using stdio for input, then we want to use getc()
169          * instead of fread(), to make sure we stop fetching input after
170          * each newline.
171          */
172         int yy_is_interactive;
173
174         /* Whether we're considered to be at the beginning of a line.
175          * If so, '^' rules will be active on the next match, otherwise
176          * not.
177          */
178         int yy_at_bol;
179
180         /* Whether to try to fill the input buffer when we reach the
181          * end of it.
182          */
183         int yy_fill_buffer;
184
185         int yy_buffer_status;
186 #define YY_BUFFER_NEW 0
187 #define YY_BUFFER_NORMAL 1
188         /* When an EOF's been seen but there's still some text to process
189          * then we mark the buffer as YY_EOF_PENDING, to indicate that we
190          * shouldn't try reading from the input source any more.  We might
191          * still have a bunch of tokens to match, though, because of
192          * possible backing-up.
193          *
194          * When we actually see the EOF, we change the status to "new"
195          * (via yyrestart()), so that the user can continue scanning by
196          * just pointing yyin at a new input file.
197          */
198 #define YY_BUFFER_EOF_PENDING 2
199         };
200
201 static YY_BUFFER_STATE yy_current_buffer = 0;
202
203 /* We provide macros for accessing buffer states in case in the
204  * future we want to put the buffer states in a more general
205  * "scanner state".
206  */
207 #define YY_CURRENT_BUFFER yy_current_buffer
208
209
210 /* yy_hold_char holds the character lost when yytext is formed. */
211 static char yy_hold_char;
212
213 static int yy_n_chars;          /* number of characters read into yy_ch_buf */
214
215
216 int yyleng;
217
218 /* Points to current character in buffer. */
219 static char *yy_c_buf_p = (char *) 0;
220 static int yy_init = 1;         /* whether we need to initialize */
221 static int yy_start = 0;        /* start state number */
222
223 /* Flag which is used to allow yywrap()'s to do buffer switches
224  * instead of setting up a fresh yyin.  A bit of a hack ...
225  */
226 static int yy_did_buffer_switch_on_eof;
227
228 void yyrestart YY_PROTO(( FILE *input_file ));
229
230 void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
231 void yy_load_buffer_state YY_PROTO(( void ));
232 YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
233 void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
234 void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));
235 void yy_flush_buffer YY_PROTO(( YY_BUFFER_STATE b ));
236 #define YY_FLUSH_BUFFER yy_flush_buffer( yy_current_buffer )
237
238 YY_BUFFER_STATE yy_scan_buffer YY_PROTO(( char *base, yy_size_t size ));
239 YY_BUFFER_STATE yy_scan_string YY_PROTO(( yyconst char *yy_str ));
240 YY_BUFFER_STATE yy_scan_bytes YY_PROTO(( yyconst char *bytes, int len ));
241
242 static void *yy_flex_alloc YY_PROTO(( yy_size_t ));
243 static void *yy_flex_realloc YY_PROTO(( void *, yy_size_t ));
244 static void yy_flex_free YY_PROTO(( void * ));
245
246 #define yy_new_buffer yy_create_buffer
247
248 #define yy_set_interactive(is_interactive) \
249         { \
250         if ( ! yy_current_buffer ) \
251                 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
252         yy_current_buffer->yy_is_interactive = is_interactive; \
253         }
254
255 #define yy_set_bol(at_bol) \
256         { \
257         if ( ! yy_current_buffer ) \
258                 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
259         yy_current_buffer->yy_at_bol = at_bol; \
260         }
261
262 #define YY_AT_BOL() (yy_current_buffer->yy_at_bol)
263
264
265 #define YY_USES_REJECT
266 typedef unsigned char YY_CHAR;
267 FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
268 typedef int yy_state_type;
269 extern char *yytext;
270 #define yytext_ptr yytext
271
272 static yy_state_type yy_get_previous_state YY_PROTO(( void ));
273 static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
274 static int yy_get_next_buffer YY_PROTO(( void ));
275 static void yy_fatal_error YY_PROTO(( yyconst char msg[] ));
276
277 /* Done after the current pattern has been matched and before the
278  * corresponding action - sets up yytext.
279  */
280 #define YY_DO_BEFORE_ACTION \
281         yytext_ptr = yy_bp; \
282         yyleng = (int) (yy_cp - yy_bp); \
283         yy_hold_char = *yy_cp; \
284         *yy_cp = '\0'; \
285         yy_c_buf_p = yy_cp;
286
287 #define YY_NUM_RULES 58
288 #define YY_END_OF_BUFFER 59
289 static yyconst short int yy_acclist[269] =
290     {   0,
291        59,   57,   58,   56,   57,   58,    1,   56,   58,   57,
292        58,   57,   58,   57,   58,   11,   57,   58,    1,   12,
293        58,   11,   57,   58,   27,   57,   58,    1,   28,   58,
294        21,   27,   57,   58,   27,   57,   58,   27,   57,   58,
295        27,   57,   58,   25,   27,   57,   58,   26,   27,   57,
296        58,   27,   57,   58,   24,   57,   58,    1,   58,   23,
297        24,   57,   58,   24,   57,   58,   57,   58,   57,   58,
298        52,   57,   58,   52,   57,   58,   53,   57,   58,   57,
299        58,   57,   58,   50,   57,   58,   50,   57,   58,   52,
300        57,   58,   52,   57,   58,   52,   57,   58,   52,   57,
301
302        58,   52,   57,   58,   52,   57,   58,   52,   57,   58,
303        52,   57,   58,   52,   57,   58,   52,   57,   58,   52,
304        57,   58,   52,   57,   58,   54,   57,   58,   55,   57,
305        58,    6,   14,   10,    7,   20,   15,   22,    8,   52,
306        51,   52,   50,    9,   50,   50,   52,   52,   52,   52,
307        52,   52,   52,   52,   52,   52,   52,   52,   52,   52,
308        52,   52,   52,    2,   13,   16,   18,    3,    4,   51,
309        52,   50,    5,   50,   50,   52,   52,   52,   52,   52,
310        39,   52,   52,   52,   52,   52,   52,   52,   52,   52,
311        52,   52,   52,   52,   17,   19,   30,   52,   52,   42,
312
313        52,   52,   34,   52,   52,   37,   52,   52,   52,   52,
314        52,   52,   52,   52,   52,   52,   52,   31,   52,   29,
315        52,   52,   40,   52,   52,   52,   52,   52,   38,   52,
316        52,   52,   52,   33,   52,   52,   52,   52,   41,   52,
317        52,   52,   52,   43,   52,   47,   52,   35,   52,   32,
318        52,   52,   52,   52,   49,   52,   52,   44,   52,   52,
319        46,   52,   45,   52,   48,   52,   36,   52
320     } ;
321
322 static yyconst short int yy_accept[200] =
323     {   0,
324         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
325         1,    1,    1,    2,    4,    7,   10,   12,   14,   16,
326        19,   22,   25,   28,   31,   35,   38,   41,   44,   48,
327        52,   55,   58,   60,   64,   67,   69,   71,   74,   77,
328        80,   82,   84,   87,   90,   93,   96,   99,  102,  105,
329       108,  111,  114,  117,  120,  123,  126,  129,  132,  133,
330       133,  133,  133,  134,  135,  135,  135,  135,  136,  136,
331       137,  138,  139,  140,  140,  140,  141,  142,  143,  144,
332       145,  145,  145,  146,  146,  146,  147,  148,  149,  150,
333       151,  152,  153,  154,  155,  156,  157,  158,  159,  160,
334
335       161,  162,  163,  164,  164,  165,  165,  166,  166,  166,
336       167,  168,  168,  169,  169,  170,  170,  171,  172,  173,
337       173,  174,  175,  176,  177,  178,  179,  180,  181,  183,
338       184,  185,  186,  187,  188,  189,  190,  191,  192,  193,
339       194,  195,  195,  196,  197,  199,  200,  202,  203,  205,
340       206,  208,  209,  210,  211,  212,  213,  214,  215,  216,
341       217,  218,  220,  221,  222,  223,  225,  226,  227,  228,
342       229,  231,  232,  233,  234,  236,  237,  238,  239,  241,
343       242,  243,  244,  246,  248,  250,  252,  253,  254,  255,
344       257,  258,  260,  261,  263,  265,  267,  269,  269
345
346     } ;
347
348 static yyconst int yy_ec[256] =
349     {   0,
350         1,    1,    1,    1,    1,    1,    1,    1,    2,    3,
351         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
352         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
353         1,    2,    1,    4,    1,    1,    5,    1,    6,    1,
354         1,    7,    1,    1,    1,    8,    9,   10,   11,   11,
355        11,   11,   11,   11,   11,   12,   12,   13,    1,    1,
356         1,    1,    1,    1,   14,   14,   14,   14,   14,   14,
357        15,   15,   15,   15,   15,   15,   15,   15,   15,   15,
358        15,   15,   15,   15,   15,   15,   15,   15,   15,   15,
359         1,   16,    1,    1,   15,    1,   17,   18,   19,   20,
360
361        21,   22,   23,   24,   25,   15,   15,   26,   27,   28,
362        29,   30,   15,   31,   32,   33,   34,   35,   15,   36,
363        15,   15,   37,    1,   38,    1,    1,    1,    1,    1,
364         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
365         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
366         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
367         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
368         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
369         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
370         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
371
372         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
373         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
374         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
375         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
376         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
377         1,    1,    1,    1,    1
378     } ;
379
380 static yyconst int yy_meta[39] =
381     {   0,
382         1,    1,    2,    1,    1,    1,    1,    1,    1,    3,
383         3,    3,    4,    5,    6,    1,    5,    5,    5,    5,
384         5,    5,    6,    6,    6,    6,    6,    6,    6,    6,
385         6,    6,    6,    6,    6,    6,    1,    1
386     } ;
387
388 static yyconst short int yy_base[214] =
389     {   0,
390         0,    2,    3,    5,   19,   55,   10,   13,   93,    0,
391       124,    0,  434,  435,  435,  435,   11,  407,    0,  435,
392       435,  423,  435,  435,  435,   11,   23,    0,  435,  435,
393       393,  435,  435,  435,    0,   24,    0,  417,   21,  435,
394        28,   34,   34,   43,   34,   49,   37,   50,   54,   55,
395        56,  129,  134,  127,   59,   61,  435,  435,  435,  426,
396       411,  390,  435,  435,   38,  420,  419,  435,  421,  435,
397       435,  435,  435,  420,  409,  408,  407,  126,  159,  435,
398       416,  162,  167,  172,    0,  177,   66,   64,    2,  163,
399       173,  168,  135,  177,  178,  179,  182,  180,  183,  181,
400
401       190,  192,  194,  415,  435,  385,  435,  410,  409,  435,
402       435,  411,  435,  410,  435,  399,  398,  197,  206,  407,
403       435,  215,    0,  195,  200,  215,  207,   71,  395,  198,
404       201,  217,  222,  223,  224,  225,  226,  227,  229,  228,
405       230,  332,  435,  435,  345,  231,  318,  233,  317,  232,
406       316,  238,  239,  249,  250,  234,  251,  258,  260,  261,
407       263,  315,  435,  265,  266,  314,  267,  268,  269,  270,
408       313,  272,  279,  277,  312,  278,  287,  281,  311,  282,
409       288,  290,  308,  307,  306,  304,  294,  292,  299,  154,
410       301,  153,  303,  125,  124,   78,   69,  435,  332,  338,
411
412       344,  350,  356,  362,  364,  368,  374,  380,  386,  390,
413       394,  400,  404
414     } ;
415
416 static yyconst short int yy_def[214] =
417     {   0,
418       199,  199,  200,  200,  201,  201,  202,  202,  198,    9,
419         9,   11,  198,  198,  198,  198,  198,  198,  198,  198,
420       198,  198,  198,  198,  198,  198,  198,  203,  198,  198,
421       198,  198,  198,  198,  204,  198,  205,  206,  206,  198,
422       198,  198,  198,  198,  206,  206,  206,  206,  206,  206,
423       206,  206,  206,  206,  206,  206,  198,  198,  198,  207,
424       198,  198,  198,  198,  198,  198,  198,  198,  208,  198,
425       198,  198,  198,  209,  210,  206,  211,  206,  198,  198,
426       212,  198,  198,  198,  213,  198,  206,  206,  206,  206,
427       206,  206,  206,  206,  206,  206,  206,  206,  206,  206,
428
429       206,  206,  206,  207,  198,  198,  198,  198,  198,  198,
430       198,  208,  198,  209,  198,  210,  211,  206,  198,  212,
431       198,  198,  213,  206,  206,  206,  206,  206,  206,  206,
432       206,  206,  206,  206,  206,  206,  206,  206,  206,  206,
433       206,  198,  198,  198,  206,  206,  206,  206,  206,  206,
434       206,  206,  206,  206,  206,  206,  206,  206,  206,  206,
435       206,  206,  198,  206,  206,  206,  206,  206,  206,  206,
436       206,  206,  206,  206,  206,  206,  206,  206,  206,  206,
437       206,  206,  206,  206,  206,  206,  206,  206,  206,  206,
438       206,  206,  206,  206,  206,  206,  206,    0,  198,  198,
439
440       198,  198,  198,  198,  198,  198,  198,  198,  198,  198,
441       198,  198,  198
442     } ;
443
444 static yyconst short int yy_nxt[474] =
445     {   0,
446       198,   15,   16,   15,   16,   21,   19,   21,   17,   22,
447        17,   22,   33,   34,   77,   33,   34,   59,   18,   60,
448        18,   24,   25,   62,   26,   35,   65,   27,   35,   68,
449        73,   69,   74,   77,   28,  126,   63,   79,   79,   79,
450        80,   82,   81,   83,   83,   84,   77,   66,   67,   77,
451        82,   78,   86,   86,   86,   29,   30,   24,   25,   31,
452        26,   77,   77,   27,   87,   89,   77,   77,   77,   85,
453        28,   77,   88,   77,  108,  109,   77,   90,   77,   91,
454       125,   77,   92,   77,   93,  102,  101,  150,  124,  103,
455        77,   29,   30,   14,   15,   16,   14,   14,   14,   14,
456
457        14,   36,   14,   14,   14,   37,   38,   38,   14,   38,
458        38,   38,   38,   38,   39,   38,   38,   38,   38,   38,
459        38,   38,   38,   38,   38,   38,   38,   38,   38,   40,
460        14,   41,   42,   43,   44,   44,   77,   77,   77,   77,
461        45,   77,   46,   47,   48,   49,   77,   77,   50,   51,
462        98,   99,   52,   53,  118,   54,   94,   55,   56,  100,
463        57,   58,  130,   95,   96,   77,   77,   97,  119,  119,
464       119,  122,  122,  122,   82,   77,   83,   83,   84,   82,
465        77,   84,   84,   84,   82,   77,   86,   86,   86,   77,
466        77,   77,   77,   77,   77,   77,  127,  131,  132,  134,
467
468       129,  128,   77,  133,   77,  136,   77,   77,  135,   77,
469        77,  137,   77,   77,  138,  119,  119,  119,  141,   77,
470       151,  139,  140,  145,  122,  122,  122,   77,  146,   77,
471       147,  152,  148,  149,   77,   77,   77,   77,   77,   77,
472        77,   77,   77,   77,   77,   77,   77,  153,  155,  162,
473        77,   77,  157,  160,  156,  159,  154,  164,  165,  158,
474       161,   77,   77,   77,  166,  169,  171,  172,  167,  168,
475        77,  173,   77,   77,  170,   77,  174,   77,   77,   77,
476        77,   77,   77,  176,   77,  178,  179,  175,  183,   77,
477        77,   77,  181,   77,   77,  180,  177,  184,  185,   77,
478
479        77,  182,   77,  188,   77,  187,   77,  191,  189,  186,
480       192,   77,  190,   77,  193,   77,   77,  194,   77,   77,
481        77,  196,  197,   77,   77,   77,   77,   77,   77,   77,
482        77,  195,   14,   14,   14,   14,   14,   14,   20,   20,
483        20,   20,   20,   20,   23,   23,   23,   23,   23,   23,
484        32,   32,   32,   32,   32,   32,   70,   77,   70,   70,
485        70,   70,   72,  163,   72,   72,   72,   72,   75,   75,
486        76,   76,   76,   76,  104,  104,  104,  104,  104,  104,
487       112,  112,  112,  112,  112,  112,  114,  114,  114,  114,
488       114,  114,  116,  116,  116,  116,  117,  117,  117,  117,
489
490       120,  120,  120,  120,  120,  120,  123,   77,  123,  121,
491        77,   77,  115,  113,  144,  143,  142,  105,  121,   77,
492        77,   77,  115,  113,  111,  110,  107,  106,  105,   77,
493        71,   64,   61,  198,   13,  198,  198,  198,  198,  198,
494       198,  198,  198,  198,  198,  198,  198,  198,  198,  198,
495       198,  198,  198,  198,  198,  198,  198,  198,  198,  198,
496       198,  198,  198,  198,  198,  198,  198,  198,  198,  198,
497       198,  198,  198
498     } ;
499
500 static yyconst short int yy_chk[474] =
501     {   0,
502         0,    1,    1,    2,    2,    3,    2,    4,    1,    3,
503         2,    4,    7,    7,   89,    8,    8,   17,    1,   17,
504         2,    5,    5,   19,    5,    7,   26,    5,    8,   27,
505        36,   27,   36,   39,    5,   89,   19,   41,   41,   41,
506        42,   43,   42,   43,   43,   43,   45,   26,   26,   47,
507        44,   39,   44,   44,   44,    5,    5,    6,    6,    6,
508         6,   46,   48,    6,   45,   47,   49,   50,   51,   43,
509         6,   55,   46,   56,   65,   65,   88,   48,   87,   49,
510        88,  197,   50,  128,   51,   56,   55,  128,   87,   56,
511       196,    6,    6,    9,    9,    9,    9,    9,    9,    9,
512
513         9,    9,    9,    9,    9,    9,    9,    9,    9,    9,
514         9,    9,    9,    9,    9,    9,    9,    9,    9,    9,
515         9,    9,    9,    9,    9,    9,    9,    9,    9,    9,
516         9,   11,   11,   11,   11,   11,  195,  194,   78,   54,
517        11,   52,   11,   11,   11,   11,   53,   93,   11,   11,
518        54,   54,   11,   11,   78,   11,   52,   11,   11,   54,
519        11,   11,   93,   52,   53,  192,  190,   53,   79,   79,
520        79,   82,   82,   82,   83,   90,   83,   83,   83,   84,
521        92,   84,   84,   84,   86,   91,   86,   86,   86,   94,
522        95,   96,   98,  100,   97,   99,   90,   94,   95,   97,
523
524        92,   91,  101,   96,  102,   99,  103,  124,   98,  118,
525       130,  100,  125,  131,  101,  119,  119,  119,  103,  127,
526       130,  101,  102,  118,  122,  122,  122,  126,  124,  132,
527       125,  131,  126,  127,  133,  134,  135,  136,  137,  138,
528       140,  139,  141,  146,  150,  148,  156,  132,  134,  141,
529       152,  153,  136,  139,  135,  138,  133,  146,  148,  137,
530       140,  154,  155,  157,  150,  154,  156,  157,  152,  153,
531       158,  157,  159,  160,  155,  161,  158,  164,  165,  167,
532       168,  169,  170,  160,  172,  164,  165,  159,  170,  174,
533       176,  173,  168,  178,  180,  167,  161,  172,  173,  177,
534
535       181,  169,  182,  177,  188,  176,  187,  181,  178,  174,
536       182,  189,  180,  191,  187,  193,  186,  188,  185,  184,
537       183,  191,  193,  179,  175,  171,  166,  162,  151,  149,
538       147,  189,  199,  199,  199,  199,  199,  199,  200,  200,
539       200,  200,  200,  200,  201,  201,  201,  201,  201,  201,
540       202,  202,  202,  202,  202,  202,  203,  145,  203,  203,
541       203,  203,  204,  142,  204,  204,  204,  204,  205,  205,
542       206,  206,  206,  206,  207,  207,  207,  207,  207,  207,
543       208,  208,  208,  208,  208,  208,  209,  209,  209,  209,
544       209,  209,  210,  210,  210,  210,  211,  211,  211,  211,
545
546       212,  212,  212,  212,  212,  212,  213,  129,  213,  120,
547       117,  116,  114,  112,  109,  108,  106,  104,   81,   77,
548        76,   75,   74,   69,   67,   66,   62,   61,   60,   38,
549        31,   22,   18,   13,  198,  198,  198,  198,  198,  198,
550       198,  198,  198,  198,  198,  198,  198,  198,  198,  198,
551       198,  198,  198,  198,  198,  198,  198,  198,  198,  198,
552       198,  198,  198,  198,  198,  198,  198,  198,  198,  198,
553       198,  198,  198
554     } ;
555
556 static yy_state_type yy_state_buf[YY_BUF_SIZE + 2], *yy_state_ptr;
557 static char *yy_full_match;
558 static int yy_lp;
559 #define REJECT \
560 { \
561 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */ \
562 yy_cp = yy_full_match; /* restore poss. backed-over text */ \
563 ++yy_lp; \
564 goto find_rule; \
565 }
566 #define yymore() yymore_used_but_not_detected
567 #define YY_MORE_ADJ 0
568 #define YY_RESTORE_YY_MORE_OFFSET
569 char *yytext;
570 #line 1 "lexer.l"
571 #define INITIAL 0
572 /* GOB C Preprocessor
573  * Copyright (C) 1999 the Free Software Foundation.
574  *
575  * Author: George Lebl
576  *
577  * This program is free software; you can redistribute it and/or modify
578  * it under the terms of the GNU General Public License as published by
579  * the Free Software Foundation; either version 2 of the License, or
580  * (at your option) any later version.
581  *
582  * This program is distributed in the hope that it will be useful,
583  * but WITHOUT ANY WARRANTY; without even the implied warranty of
584  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
585  * GNU General Public License for more details.
586  *
587  * You should have received a copy of the GNU General Public License
588  * along with this program; if not, write to the  Free Software
589  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
590  * USA.
591  */
592 #line 22 "lexer.l"
593
594 #include "config.h"
595 #include <glib.h>
596
597 #include "parse.h"
598
599 static int parenth_depth = 0;
600 static int before_comment = INITIAL;
601 static int class_after_c = FALSE;
602 static int header_c = FALSE;
603
604 static GString *cbuf = NULL;
605 int ccode_line = 1;
606
607 int line_no = 1;
608
609 static void
610 clear_cbuf(void)
611 {
612         if(!cbuf) {
613                 cbuf = g_string_new("");
614         } else {
615                 cbuf = g_string_assign(cbuf,"");
616         }
617 }
618
619 static void
620 add_to_cbuf(char *s)
621 {
622         if(!cbuf) {
623                 cbuf = g_string_new(s);
624         } else {
625                 cbuf = g_string_append(cbuf,s);
626         }
627 }
628
629 #define COMMENT 1
630
631 #define C_CODE 2
632
633 #define C_CODE_STRING 3
634
635 #define CLASS_CODE 4
636
637 #define CLASS_CODE_I 5
638
639 #line 640 "lex.yy.c"
640
641 /* Macros after this point can all be overridden by user definitions in
642  * section 1.
643  */
644
645 #ifndef YY_SKIP_YYWRAP
646 #ifdef __cplusplus
647 extern "C" int yywrap YY_PROTO(( void ));
648 #else
649 extern int yywrap YY_PROTO(( void ));
650 #endif
651 #endif
652
653 #ifndef YY_NO_UNPUT
654 static void yyunput YY_PROTO(( int c, char *buf_ptr ));
655 #endif
656
657 #ifndef yytext_ptr
658 static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));
659 #endif
660
661 #ifdef YY_NEED_STRLEN
662 static int yy_flex_strlen YY_PROTO(( yyconst char * ));
663 #endif
664
665 #ifndef YY_NO_INPUT
666 #ifdef __cplusplus
667 static int yyinput YY_PROTO(( void ));
668 #else
669 static int input YY_PROTO(( void ));
670 #endif
671 #endif
672
673 #if YY_STACK_USED
674 static int yy_start_stack_ptr = 0;
675 static int yy_start_stack_depth = 0;
676 static int *yy_start_stack = 0;
677 #ifndef YY_NO_PUSH_STATE
678 static void yy_push_state YY_PROTO(( int new_state ));
679 #endif
680 #ifndef YY_NO_POP_STATE
681 static void yy_pop_state YY_PROTO(( void ));
682 #endif
683 #ifndef YY_NO_TOP_STATE
684 static int yy_top_state YY_PROTO(( void ));
685 #endif
686
687 #else
688 #define YY_NO_PUSH_STATE 1
689 #define YY_NO_POP_STATE 1
690 #define YY_NO_TOP_STATE 1
691 #endif
692
693 #ifdef YY_MALLOC_DECL
694 YY_MALLOC_DECL
695 #else
696 #if __STDC__
697 #ifndef __cplusplus
698 #include <stdlib.h>
699 #endif
700 #else
701 /* Just try to get by without declaring the routines.  This will fail
702  * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int)
703  * or sizeof(void*) != sizeof(int).
704  */
705 #endif
706 #endif
707
708 /* Amount of stuff to slurp up with each read. */
709 #ifndef YY_READ_BUF_SIZE
710 #define YY_READ_BUF_SIZE 8192
711 #endif
712
713 /* Copy whatever the last rule matched to the standard output. */
714
715 #ifndef ECHO
716 /* This used to be an fputs(), but since the string might contain NUL's,
717  * we now use fwrite().
718  */
719 #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
720 #endif
721
722 /* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
723  * is returned in "result".
724  */
725 #ifndef YY_INPUT
726 #define YY_INPUT(buf,result,max_size) \
727         if ( yy_current_buffer->yy_is_interactive ) \
728                 { \
729                 int c = '*', n; \
730                 for ( n = 0; n < max_size && \
731                              (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
732                         buf[n] = (char) c; \
733                 if ( c == '\n' ) \
734                         buf[n++] = (char) c; \
735                 if ( c == EOF && ferror( yyin ) ) \
736                         YY_FATAL_ERROR( "input in flex scanner failed" ); \
737                 result = n; \
738                 } \
739         else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
740                   && ferror( yyin ) ) \
741                 YY_FATAL_ERROR( "input in flex scanner failed" );
742 #endif
743
744 /* No semi-colon after return; correct usage is to write "yyterminate();" -
745  * we don't want an extra ';' after the "return" because that will cause
746  * some compilers to complain about unreachable statements.
747  */
748 #ifndef yyterminate
749 #define yyterminate() return YY_NULL
750 #endif
751
752 /* Number of entries by which start-condition stack grows. */
753 #ifndef YY_START_STACK_INCR
754 #define YY_START_STACK_INCR 25
755 #endif
756
757 /* Report a fatal error. */
758 #ifndef YY_FATAL_ERROR
759 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
760 #endif
761
762 /* Default declaration of generated scanner - a define so the user can
763  * easily add parameters.
764  */
765 #ifndef YY_DECL
766 #define YY_DECL int yylex YY_PROTO(( void ))
767 #endif
768
769 /* Code executed at the beginning of each rule, after yytext and yyleng
770  * have been set up.
771  */
772 #ifndef YY_USER_ACTION
773 #define YY_USER_ACTION
774 #endif
775
776 /* Code executed at the end of each rule. */
777 #ifndef YY_BREAK
778 #define YY_BREAK break;
779 #endif
780
781 #define YY_RULE_SETUP \
782         if ( yyleng > 0 ) \
783                 yy_current_buffer->yy_at_bol = \
784                                 (yytext[yyleng - 1] == '\n'); \
785         YY_USER_ACTION
786
787 YY_DECL
788         {
789         register yy_state_type yy_current_state;
790         register char *yy_cp, *yy_bp;
791         register int yy_act;
792
793 #line 66 "lexer.l"
794
795
796 #line 797 "lex.yy.c"
797
798         if ( yy_init )
799                 {
800                 yy_init = 0;
801
802 #ifdef YY_USER_INIT
803                 YY_USER_INIT;
804 #endif
805
806                 if ( ! yy_start )
807                         yy_start = 1;   /* first start state */
808
809                 if ( ! yyin )
810                         yyin = stdin;
811
812                 if ( ! yyout )
813                         yyout = stdout;
814
815                 if ( ! yy_current_buffer )
816                         yy_current_buffer =
817                                 yy_create_buffer( yyin, YY_BUF_SIZE );
818
819                 yy_load_buffer_state();
820                 }
821
822         while ( 1 )             /* loops until end-of-file is reached */
823                 {
824                 yy_cp = yy_c_buf_p;
825
826                 /* Support of yytext. */
827                 *yy_cp = yy_hold_char;
828
829                 /* yy_bp points to the position in yy_ch_buf of the start of
830                  * the current run.
831                  */
832                 yy_bp = yy_cp;
833
834                 yy_current_state = yy_start;
835                 yy_current_state += YY_AT_BOL();
836                 yy_state_ptr = yy_state_buf;
837                 *yy_state_ptr++ = yy_current_state;
838 yy_match:
839                 do
840                         {
841                         register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
842                         while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
843                                 {
844                                 yy_current_state = (int) yy_def[yy_current_state];
845                                 if ( yy_current_state >= 199 )
846                                         yy_c = yy_meta[(unsigned int) yy_c];
847                                 }
848                         yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
849                         *yy_state_ptr++ = yy_current_state;
850                         ++yy_cp;
851                         }
852                 while ( yy_base[yy_current_state] != 435 );
853
854 yy_find_action:
855                 yy_current_state = *--yy_state_ptr;
856                 yy_lp = yy_accept[yy_current_state];
857 find_rule: /* we branch to this label when backing up */
858                 for ( ; ; ) /* until we find what rule we matched */
859                         {
860                         if ( yy_lp && yy_lp < yy_accept[yy_current_state + 1] )
861                                 {
862                                 yy_act = yy_acclist[yy_lp];
863                                         {
864                                         yy_full_match = yy_cp;
865                                         break;
866                                         }
867                                 }
868                         --yy_cp;
869                         yy_current_state = *--yy_state_ptr;
870                         yy_lp = yy_accept[yy_current_state];
871                         }
872
873                 YY_DO_BEFORE_ACTION;
874
875
876 do_action:      /* This label is used only to access EOF actions. */
877
878
879                 switch ( yy_act )
880         { /* beginning of action switch */
881 case 1:
882 YY_RULE_SETUP
883 #line 68 "lexer.l"
884 { line_no++; REJECT; }
885         YY_BREAK
886 case 2:
887 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
888 yy_c_buf_p = yy_cp -= 1;
889 YY_DO_BEFORE_ACTION; /* set up yytext again */
890 YY_RULE_SETUP
891 #line 70 "lexer.l"
892 { ; /*comment, ignore*/ }
893         YY_BREAK
894 case 3:
895 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
896 yy_c_buf_p = yy_cp -= 1;
897 YY_DO_BEFORE_ACTION; /* set up yytext again */
898 YY_RULE_SETUP
899 #line 71 "lexer.l"
900 { ; /*comment, ignore*/ }
901         YY_BREAK
902 case 4:
903 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
904 yy_c_buf_p = yy_cp -= 1;
905 YY_DO_BEFORE_ACTION; /* set up yytext again */
906 YY_RULE_SETUP
907 #line 72 "lexer.l"
908 { ; /*comment, ignore*/ }
909         YY_BREAK
910 case 5:
911 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
912 yy_c_buf_p = yy_cp -= 1;
913 YY_DO_BEFORE_ACTION; /* set up yytext again */
914 YY_RULE_SETUP
915 #line 73 "lexer.l"
916 { ; /*comment, ignore*/ }
917         YY_BREAK
918 case 6:
919 YY_RULE_SETUP
920 #line 74 "lexer.l"
921 {BEGIN(COMMENT); before_comment = INITIAL; }
922         YY_BREAK
923 case 7:
924 YY_RULE_SETUP
925 #line 75 "lexer.l"
926 {BEGIN(COMMENT); before_comment = C_CODE; }
927         YY_BREAK
928 case 8:
929 YY_RULE_SETUP
930 #line 76 "lexer.l"
931 {BEGIN(COMMENT); before_comment = CLASS_CODE; }
932         YY_BREAK
933 case 9:
934 YY_RULE_SETUP
935 #line 77 "lexer.l"
936 {BEGIN(COMMENT); before_comment = CLASS_CODE_I; }
937         YY_BREAK
938 case 10:
939 YY_RULE_SETUP
940 #line 78 "lexer.l"
941 {BEGIN(before_comment);}
942         YY_BREAK
943 case 11:
944 YY_RULE_SETUP
945 #line 79 "lexer.l"
946 { ; /* comment, ignore */ }
947         YY_BREAK
948 case 12:
949 YY_RULE_SETUP
950 #line 80 "lexer.l"
951 { ; /* comment, ignore */ }
952         YY_BREAK
953 case 13:
954 YY_RULE_SETUP
955 #line 82 "lexer.l"
956 {
957                         BEGIN(C_CODE);
958                         parenth_depth = 1;
959                         class_after_c = FALSE;
960                         header_c = TRUE;
961                         clear_cbuf();
962                         ccode_line = line_no;
963                 }
964         YY_BREAK
965 case 14:
966 YY_RULE_SETUP
967 #line 90 "lexer.l"
968 {
969                         BEGIN(C_CODE);
970                         parenth_depth = 1;
971                         class_after_c = FALSE;
972                         header_c = FALSE;
973                         clear_cbuf();
974                         ccode_line = line_no;
975                 }
976         YY_BREAK
977 case 15:
978 YY_RULE_SETUP
979 #line 98 "lexer.l"
980 {
981                         BEGIN(INITIAL);
982                         yylval.cbuf = cbuf;
983                         cbuf = NULL;
984                         if(header_c)
985                                 return HCODE;
986                         else
987                                 return CCODE;
988                 }
989         YY_BREAK
990 case 16:
991 YY_RULE_SETUP
992 #line 108 "lexer.l"
993 { add_to_cbuf(yytext); }
994         YY_BREAK
995 case 17:
996 YY_RULE_SETUP
997 #line 109 "lexer.l"
998 { add_to_cbuf(yytext); }
999         YY_BREAK
1000 case 18:
1001 YY_RULE_SETUP
1002 #line 110 "lexer.l"
1003 { add_to_cbuf(yytext); }
1004         YY_BREAK
1005 case 19:
1006 YY_RULE_SETUP
1007 #line 111 "lexer.l"
1008 { add_to_cbuf(yytext); }
1009         YY_BREAK
1010 case 20:
1011 YY_RULE_SETUP
1012 #line 113 "lexer.l"
1013 { add_to_cbuf(yytext); }
1014         YY_BREAK
1015 case 21:
1016 YY_RULE_SETUP
1017 #line 114 "lexer.l"
1018 {
1019                         BEGIN(C_CODE_STRING);
1020                         add_to_cbuf(yytext);
1021                 }
1022         YY_BREAK
1023 case 22:
1024 YY_RULE_SETUP
1025 #line 118 "lexer.l"
1026 {
1027                                 add_to_cbuf(yytext);
1028                         }
1029         YY_BREAK
1030 case 23:
1031 YY_RULE_SETUP
1032 #line 121 "lexer.l"
1033 {
1034                                 BEGIN(C_CODE);
1035                                 add_to_cbuf(yytext);
1036                         }
1037         YY_BREAK
1038 case 24:
1039 YY_RULE_SETUP
1040 #line 125 "lexer.l"
1041 {
1042                                 add_to_cbuf(yytext);
1043                         }
1044         YY_BREAK
1045 case 25:
1046 YY_RULE_SETUP
1047 #line 129 "lexer.l"
1048 {
1049                         parenth_depth++;
1050                         add_to_cbuf(yytext);
1051                 }
1052         YY_BREAK
1053 case 26:
1054 YY_RULE_SETUP
1055 #line 133 "lexer.l"
1056 {
1057                         parenth_depth--;
1058                         if(parenth_depth<0) {
1059                                 REJECT;
1060                         } else if(parenth_depth==0 && class_after_c) {
1061                                 BEGIN(CLASS_CODE_I);
1062                                 yylval.cbuf = cbuf;
1063                                 cbuf = NULL;
1064                                 return CCODE;
1065                         }
1066                         add_to_cbuf(yytext);
1067                 }
1068         YY_BREAK
1069 case 27:
1070 YY_RULE_SETUP
1071 #line 146 "lexer.l"
1072 { add_to_cbuf(yytext); }
1073         YY_BREAK
1074 case 28:
1075 YY_RULE_SETUP
1076 #line 147 "lexer.l"
1077 { add_to_cbuf(yytext); }
1078         YY_BREAK
1079 case 29:
1080 YY_RULE_SETUP
1081 #line 149 "lexer.l"
1082 {
1083                         BEGIN(CLASS_CODE);
1084                         return CLASS;
1085                 }
1086         YY_BREAK
1087 case 30:
1088 YY_RULE_SETUP
1089 #line 154 "lexer.l"
1090 {return FROM;}
1091         YY_BREAK
1092 case 31:
1093 YY_RULE_SETUP
1094 #line 156 "lexer.l"
1095 {return VOID;}
1096         YY_BREAK
1097 case 32:
1098 YY_RULE_SETUP
1099 #line 157 "lexer.l"
1100 {return STRUCT;}
1101         YY_BREAK
1102 case 33:
1103 YY_RULE_SETUP
1104 #line 158 "lexer.l"
1105 {return UNION;}
1106         YY_BREAK
1107 case 34:
1108 YY_RULE_SETUP
1109 #line 159 "lexer.l"
1110 {return ENUM;}
1111         YY_BREAK
1112 case 35:
1113 YY_RULE_SETUP
1114 #line 160 "lexer.l"
1115 {return SIGNED;}
1116         YY_BREAK
1117 case 36:
1118 YY_RULE_SETUP
1119 #line 161 "lexer.l"
1120 {return UNSIGNED;}
1121         YY_BREAK
1122 case 37:
1123 YY_RULE_SETUP
1124 #line 162 "lexer.l"
1125 {return LONG;}
1126         YY_BREAK
1127 case 38:
1128 YY_RULE_SETUP
1129 #line 163 "lexer.l"
1130 {return SHORT;}
1131         YY_BREAK
1132 case 39:
1133 YY_RULE_SETUP
1134 #line 164 "lexer.l"
1135 {return INT;}
1136         YY_BREAK
1137 case 40:
1138 YY_RULE_SETUP
1139 #line 165 "lexer.l"
1140 {return FLOAT;}
1141         YY_BREAK
1142 case 41:
1143 YY_RULE_SETUP
1144 #line 166 "lexer.l"
1145 {return DOUBLE;}
1146         YY_BREAK
1147 case 42:
1148 YY_RULE_SETUP
1149 #line 167 "lexer.l"
1150 {return CHAR;}
1151         YY_BREAK
1152 case 43:
1153 YY_RULE_SETUP
1154 #line 169 "lexer.l"
1155 {yylval.line = line_no; return PUBLIC;}
1156         YY_BREAK
1157 case 44:
1158 YY_RULE_SETUP
1159 #line 170 "lexer.l"
1160 {yylval.line = line_no; return PRIVATE;}
1161         YY_BREAK
1162 case 45:
1163 YY_RULE_SETUP
1164 #line 171 "lexer.l"
1165 {yylval.line = line_no; return ARGUMENT;}
1166         YY_BREAK
1167 case 46:
1168 YY_RULE_SETUP
1169 #line 172 "lexer.l"
1170 {yylval.line = line_no; return VIRTUAL;}
1171         YY_BREAK
1172 case 47:
1173 YY_RULE_SETUP
1174 #line 173 "lexer.l"
1175 {yylval.line = line_no; return SIGNAL;}
1176         YY_BREAK
1177 case 48:
1178 YY_RULE_SETUP
1179 #line 174 "lexer.l"
1180 {yylval.line = line_no; return OVERRIDE;}
1181         YY_BREAK
1182 case 49:
1183 YY_RULE_SETUP
1184 #line 175 "lexer.l"
1185 {return ONERROR;}
1186         YY_BREAK
1187 case 50:
1188 YY_RULE_SETUP
1189 #line 176 "lexer.l"
1190 {
1191                         yylval.id = g_strdup(yytext);
1192                         return NUMBER;
1193                 }
1194         YY_BREAK
1195 case 51:
1196 YY_RULE_SETUP
1197 #line 180 "lexer.l"
1198 {
1199                         yylval.id = g_strdup(yytext);
1200                         return TYPETOKEN;
1201                 }
1202         YY_BREAK
1203 case 52:
1204 YY_RULE_SETUP
1205 #line 184 "lexer.l"
1206 {
1207                         yylval.id = g_strdup(yytext);
1208                         return TOKEN;
1209                 }
1210         YY_BREAK
1211 case 53:
1212 YY_RULE_SETUP
1213 #line 189 "lexer.l"
1214 {
1215                         BEGIN(CLASS_CODE_I);
1216                         return '{';
1217                 }
1218         YY_BREAK
1219 case 54:
1220 YY_RULE_SETUP
1221 #line 193 "lexer.l"
1222 {
1223                         BEGIN(C_CODE);
1224                         parenth_depth=1;
1225                         class_after_c = TRUE;
1226                         ccode_line = line_no;
1227                         yylval.line = line_no;
1228                         return '{';
1229                 }
1230         YY_BREAK
1231 case 55:
1232 YY_RULE_SETUP
1233 #line 201 "lexer.l"
1234 {
1235                                 BEGIN(INITIAL);
1236                                 return '}';
1237                         }
1238         YY_BREAK
1239 case 56:
1240 YY_RULE_SETUP
1241 #line 206 "lexer.l"
1242 ;  /*ignore*/
1243         YY_BREAK
1244 case 57:
1245 YY_RULE_SETUP
1246 #line 208 "lexer.l"
1247 {
1248                         yylval.line = line_no;
1249                         return yytext[0];
1250                 }
1251         YY_BREAK
1252 case 58:
1253 YY_RULE_SETUP
1254 #line 212 "lexer.l"
1255 ECHO;
1256         YY_BREAK
1257 #line 1258 "lex.yy.c"
1258                         case YY_STATE_EOF(INITIAL):
1259                         case YY_STATE_EOF(COMMENT):
1260                         case YY_STATE_EOF(C_CODE):
1261                         case YY_STATE_EOF(C_CODE_STRING):
1262                         case YY_STATE_EOF(CLASS_CODE):
1263                         case YY_STATE_EOF(CLASS_CODE_I):
1264                                 yyterminate();
1265
1266         case YY_END_OF_BUFFER:
1267                 {
1268                 /* Amount of text matched not including the EOB char. */
1269                 int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1;
1270
1271                 /* Undo the effects of YY_DO_BEFORE_ACTION. */
1272                 *yy_cp = yy_hold_char;
1273                 YY_RESTORE_YY_MORE_OFFSET
1274
1275                 if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW )
1276                         {
1277                         /* We're scanning a new file or input source.  It's
1278                          * possible that this happened because the user
1279                          * just pointed yyin at a new source and called
1280                          * yylex().  If so, then we have to assure
1281                          * consistency between yy_current_buffer and our
1282                          * globals.  Here is the right place to do so, because
1283                          * this is the first action (other than possibly a
1284                          * back-up) that will match for the new input source.
1285                          */
1286                         yy_n_chars = yy_current_buffer->yy_n_chars;
1287                         yy_current_buffer->yy_input_file = yyin;
1288                         yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL;
1289                         }
1290
1291                 /* Note that here we test for yy_c_buf_p "<=" to the position
1292                  * of the first EOB in the buffer, since yy_c_buf_p will
1293                  * already have been incremented past the NUL character
1294                  * (since all states make transitions on EOB to the
1295                  * end-of-buffer state).  Contrast this with the test
1296                  * in input().
1297                  */
1298                 if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
1299                         { /* This was really a NUL. */
1300                         yy_state_type yy_next_state;
1301
1302                         yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text;
1303
1304                         yy_current_state = yy_get_previous_state();
1305
1306                         /* Okay, we're now positioned to make the NUL
1307                          * transition.  We couldn't have
1308                          * yy_get_previous_state() go ahead and do it
1309                          * for us because it doesn't know how to deal
1310                          * with the possibility of jamming (and we don't
1311                          * want to build jamming into it because then it
1312                          * will run more slowly).
1313                          */
1314
1315                         yy_next_state = yy_try_NUL_trans( yy_current_state );
1316
1317                         yy_bp = yytext_ptr + YY_MORE_ADJ;
1318
1319                         if ( yy_next_state )
1320                                 {
1321                                 /* Consume the NUL. */
1322                                 yy_cp = ++yy_c_buf_p;
1323                                 yy_current_state = yy_next_state;
1324                                 goto yy_match;
1325                                 }
1326
1327                         else
1328                                 {
1329                                 yy_cp = yy_c_buf_p;
1330                                 goto yy_find_action;
1331                                 }
1332                         }
1333
1334                 else switch ( yy_get_next_buffer() )
1335                         {
1336                         case EOB_ACT_END_OF_FILE:
1337                                 {
1338                                 yy_did_buffer_switch_on_eof = 0;
1339
1340                                 if ( yywrap() )
1341                                         {
1342                                         /* Note: because we've taken care in
1343                                          * yy_get_next_buffer() to have set up
1344                                          * yytext, we can now set up
1345                                          * yy_c_buf_p so that if some total
1346                                          * hoser (like flex itself) wants to
1347                                          * call the scanner after we return the
1348                                          * YY_NULL, it'll still work - another
1349                                          * YY_NULL will get returned.
1350                                          */
1351                                         yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
1352
1353                                         yy_act = YY_STATE_EOF(YY_START);
1354                                         goto do_action;
1355                                         }
1356
1357                                 else
1358                                         {
1359                                         if ( ! yy_did_buffer_switch_on_eof )
1360                                                 YY_NEW_FILE;
1361                                         }
1362                                 break;
1363                                 }
1364
1365                         case EOB_ACT_CONTINUE_SCAN:
1366                                 yy_c_buf_p =
1367                                         yytext_ptr + yy_amount_of_matched_text;
1368
1369                                 yy_current_state = yy_get_previous_state();
1370
1371                                 yy_cp = yy_c_buf_p;
1372                                 yy_bp = yytext_ptr + YY_MORE_ADJ;
1373                                 goto yy_match;
1374
1375                         case EOB_ACT_LAST_MATCH:
1376                                 yy_c_buf_p =
1377                                 &yy_current_buffer->yy_ch_buf[yy_n_chars];
1378
1379                                 yy_current_state = yy_get_previous_state();
1380
1381                                 yy_cp = yy_c_buf_p;
1382                                 yy_bp = yytext_ptr + YY_MORE_ADJ;
1383                                 goto yy_find_action;
1384                         }
1385                 break;
1386                 }
1387
1388         default:
1389                 YY_FATAL_ERROR(
1390                         "fatal flex scanner internal error--no action found" );
1391         } /* end of action switch */
1392                 } /* end of scanning one token */
1393         } /* end of yylex */
1394
1395
1396 /* yy_get_next_buffer - try to read in a new buffer
1397  *
1398  * Returns a code representing an action:
1399  *      EOB_ACT_LAST_MATCH -
1400  *      EOB_ACT_CONTINUE_SCAN - continue scanning from current position
1401  *      EOB_ACT_END_OF_FILE - end of file
1402  */
1403
1404 static int yy_get_next_buffer()
1405         {
1406         register char *dest = yy_current_buffer->yy_ch_buf;
1407         register char *source = yytext_ptr;
1408         register int number_to_move, i;
1409         int ret_val;
1410
1411         if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
1412                 YY_FATAL_ERROR(
1413                 "fatal flex scanner internal error--end of buffer missed" );
1414
1415         if ( yy_current_buffer->yy_fill_buffer == 0 )
1416                 { /* Don't try to fill the buffer, so this is an EOF. */
1417                 if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 )
1418                         {
1419                         /* We matched a single character, the EOB, so
1420                          * treat this as a final EOF.
1421                          */
1422                         return EOB_ACT_END_OF_FILE;
1423                         }
1424
1425                 else
1426                         {
1427                         /* We matched some text prior to the EOB, first
1428                          * process it.
1429                          */
1430                         return EOB_ACT_LAST_MATCH;
1431                         }
1432                 }
1433
1434         /* Try to read more data. */
1435
1436         /* First move last chars to start of buffer. */
1437         number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1;
1438
1439         for ( i = 0; i < number_to_move; ++i )
1440                 *(dest++) = *(source++);
1441
1442         if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING )
1443                 /* don't do the read, it's not guaranteed to return an EOF,
1444                  * just force an EOF
1445                  */
1446                 yy_current_buffer->yy_n_chars = yy_n_chars = 0;
1447
1448         else
1449                 {
1450                 int num_to_read =
1451                         yy_current_buffer->yy_buf_size - number_to_move - 1;
1452
1453                 while ( num_to_read <= 0 )
1454                         { /* Not enough room in the buffer - grow it. */
1455 #ifdef YY_USES_REJECT
1456                         YY_FATAL_ERROR(
1457 "input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
1458 #else
1459
1460                         /* just a shorter name for the current buffer */
1461                         YY_BUFFER_STATE b = yy_current_buffer;
1462
1463                         int yy_c_buf_p_offset =
1464                                 (int) (yy_c_buf_p - b->yy_ch_buf);
1465
1466                         if ( b->yy_is_our_buffer )
1467                                 {
1468                                 int new_size = b->yy_buf_size * 2;
1469
1470                                 if ( new_size <= 0 )
1471                                         b->yy_buf_size += b->yy_buf_size / 8;
1472                                 else
1473                                         b->yy_buf_size *= 2;
1474
1475                                 b->yy_ch_buf = (char *)
1476                                         /* Include room in for 2 EOB chars. */
1477                                         yy_flex_realloc( (void *) b->yy_ch_buf,
1478                                                          b->yy_buf_size + 2 );
1479                                 }
1480                         else
1481                                 /* Can't grow it, we don't own it. */
1482                                 b->yy_ch_buf = 0;
1483
1484                         if ( ! b->yy_ch_buf )
1485                                 YY_FATAL_ERROR(
1486                                 "fatal error - scanner input buffer overflow" );
1487
1488                         yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
1489
1490                         num_to_read = yy_current_buffer->yy_buf_size -
1491                                                 number_to_move - 1;
1492 #endif
1493                         }
1494
1495                 if ( num_to_read > YY_READ_BUF_SIZE )
1496                         num_to_read = YY_READ_BUF_SIZE;
1497
1498                 /* Read in more data. */
1499                 YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
1500                         yy_n_chars, num_to_read );
1501
1502                 yy_current_buffer->yy_n_chars = yy_n_chars;
1503                 }
1504
1505         if ( yy_n_chars == 0 )
1506                 {
1507                 if ( number_to_move == YY_MORE_ADJ )
1508                         {
1509                         ret_val = EOB_ACT_END_OF_FILE;
1510                         yyrestart( yyin );
1511                         }
1512
1513                 else
1514                         {
1515                         ret_val = EOB_ACT_LAST_MATCH;
1516                         yy_current_buffer->yy_buffer_status =
1517                                 YY_BUFFER_EOF_PENDING;
1518                         }
1519                 }
1520
1521         else
1522                 ret_val = EOB_ACT_CONTINUE_SCAN;
1523
1524         yy_n_chars += number_to_move;
1525         yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
1526         yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
1527
1528         yytext_ptr = &yy_current_buffer->yy_ch_buf[0];
1529
1530         return ret_val;
1531         }
1532
1533
1534 /* yy_get_previous_state - get the state just before the EOB char was reached */
1535
1536 static yy_state_type yy_get_previous_state()
1537         {
1538         register yy_state_type yy_current_state;
1539         register char *yy_cp;
1540
1541         yy_current_state = yy_start;
1542         yy_current_state += YY_AT_BOL();
1543         yy_state_ptr = yy_state_buf;
1544         *yy_state_ptr++ = yy_current_state;
1545
1546         for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
1547                 {
1548                 register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
1549                 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
1550                         {
1551                         yy_current_state = (int) yy_def[yy_current_state];
1552                         if ( yy_current_state >= 199 )
1553                                 yy_c = yy_meta[(unsigned int) yy_c];
1554                         }
1555                 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
1556                 *yy_state_ptr++ = yy_current_state;
1557                 }
1558
1559         return yy_current_state;
1560         }
1561
1562
1563 /* yy_try_NUL_trans - try to make a transition on the NUL character
1564  *
1565  * synopsis
1566  *      next_state = yy_try_NUL_trans( current_state );
1567  */
1568
1569 #ifdef YY_USE_PROTOS
1570 static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state )
1571 #else
1572 static yy_state_type yy_try_NUL_trans( yy_current_state )
1573 yy_state_type yy_current_state;
1574 #endif
1575         {
1576         register int yy_is_jam;
1577
1578         register YY_CHAR yy_c = 1;
1579         while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
1580                 {
1581                 yy_current_state = (int) yy_def[yy_current_state];
1582                 if ( yy_current_state >= 199 )
1583                         yy_c = yy_meta[(unsigned int) yy_c];
1584                 }
1585         yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
1586         yy_is_jam = (yy_current_state == 198);
1587         if ( ! yy_is_jam )
1588                 *yy_state_ptr++ = yy_current_state;
1589
1590         return yy_is_jam ? 0 : yy_current_state;
1591         }
1592
1593
1594 #ifndef YY_NO_UNPUT
1595 #ifdef YY_USE_PROTOS
1596 static void yyunput( int c, register char *yy_bp )
1597 #else
1598 static void yyunput( c, yy_bp )
1599 int c;
1600 register char *yy_bp;
1601 #endif
1602         {
1603         register char *yy_cp = yy_c_buf_p;
1604
1605         /* undo effects of setting up yytext */
1606         *yy_cp = yy_hold_char;
1607
1608         if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
1609                 { /* need to shift things up to make room */
1610                 /* +2 for EOB chars. */
1611                 register int number_to_move = yy_n_chars + 2;
1612                 register char *dest = &yy_current_buffer->yy_ch_buf[
1613                                         yy_current_buffer->yy_buf_size + 2];
1614                 register char *source =
1615                                 &yy_current_buffer->yy_ch_buf[number_to_move];
1616
1617                 while ( source > yy_current_buffer->yy_ch_buf )
1618                         *--dest = *--source;
1619
1620                 yy_cp += (int) (dest - source);
1621                 yy_bp += (int) (dest - source);
1622                 yy_current_buffer->yy_n_chars =
1623                         yy_n_chars = yy_current_buffer->yy_buf_size;
1624
1625                 if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
1626                         YY_FATAL_ERROR( "flex scanner push-back overflow" );
1627                 }
1628
1629         *--yy_cp = (char) c;
1630
1631
1632         yytext_ptr = yy_bp;
1633         yy_hold_char = *yy_cp;
1634         yy_c_buf_p = yy_cp;
1635         }
1636 #endif  /* ifndef YY_NO_UNPUT */
1637
1638
1639 #ifdef __cplusplus
1640 static int yyinput()
1641 #else
1642 static int input()
1643 #endif
1644         {
1645         int c;
1646
1647         *yy_c_buf_p = yy_hold_char;
1648
1649         if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
1650                 {
1651                 /* yy_c_buf_p now points to the character we want to return.
1652                  * If this occurs *before* the EOB characters, then it's a
1653                  * valid NUL; if not, then we've hit the end of the buffer.
1654                  */
1655                 if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
1656                         /* This was really a NUL. */
1657                         *yy_c_buf_p = '\0';
1658
1659                 else
1660                         { /* need more input */
1661                         int offset = yy_c_buf_p - yytext_ptr;
1662                         ++yy_c_buf_p;
1663
1664                         switch ( yy_get_next_buffer() )
1665                                 {
1666                                 case EOB_ACT_LAST_MATCH:
1667                                         /* This happens because yy_g_n_b()
1668                                          * sees that we've accumulated a
1669                                          * token and flags that we need to
1670                                          * try matching the token before
1671                                          * proceeding.  But for input(),
1672                                          * there's no matching to consider.
1673                                          * So convert the EOB_ACT_LAST_MATCH
1674                                          * to EOB_ACT_END_OF_FILE.
1675                                          */
1676
1677                                         /* Reset buffer status. */
1678                                         yyrestart( yyin );
1679
1680                                         /* fall through */
1681
1682                                 case EOB_ACT_END_OF_FILE:
1683                                         {
1684                                         if ( yywrap() )
1685                                                 return EOF;
1686
1687                                         if ( ! yy_did_buffer_switch_on_eof )
1688                                                 YY_NEW_FILE;
1689 #ifdef __cplusplus
1690                                         return yyinput();
1691 #else
1692                                         return input();
1693 #endif
1694                                         }
1695
1696                                 case EOB_ACT_CONTINUE_SCAN:
1697                                         yy_c_buf_p = yytext_ptr + offset;
1698                                         break;
1699                                 }
1700                         }
1701                 }
1702
1703         c = *(unsigned char *) yy_c_buf_p;      /* cast for 8-bit char's */
1704         *yy_c_buf_p = '\0';     /* preserve yytext */
1705         yy_hold_char = *++yy_c_buf_p;
1706
1707         yy_current_buffer->yy_at_bol = (c == '\n');
1708
1709         return c;
1710         }
1711
1712
1713 #ifdef YY_USE_PROTOS
1714 void yyrestart( FILE *input_file )
1715 #else
1716 void yyrestart( input_file )
1717 FILE *input_file;
1718 #endif
1719         {
1720         if ( ! yy_current_buffer )
1721                 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );
1722
1723         yy_init_buffer( yy_current_buffer, input_file );
1724         yy_load_buffer_state();
1725         }
1726
1727
1728 #ifdef YY_USE_PROTOS
1729 void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
1730 #else
1731 void yy_switch_to_buffer( new_buffer )
1732 YY_BUFFER_STATE new_buffer;
1733 #endif
1734         {
1735         if ( yy_current_buffer == new_buffer )
1736                 return;
1737
1738         if ( yy_current_buffer )
1739                 {
1740                 /* Flush out information for old buffer. */
1741                 *yy_c_buf_p = yy_hold_char;
1742                 yy_current_buffer->yy_buf_pos = yy_c_buf_p;
1743                 yy_current_buffer->yy_n_chars = yy_n_chars;
1744                 }
1745
1746         yy_current_buffer = new_buffer;
1747         yy_load_buffer_state();
1748
1749         /* We don't actually know whether we did this switch during
1750          * EOF (yywrap()) processing, but the only time this flag
1751          * is looked at is after yywrap() is called, so it's safe
1752          * to go ahead and always set it.
1753          */
1754         yy_did_buffer_switch_on_eof = 1;
1755         }
1756
1757
1758 #ifdef YY_USE_PROTOS
1759 void yy_load_buffer_state( void )
1760 #else
1761 void yy_load_buffer_state()
1762 #endif
1763         {
1764         yy_n_chars = yy_current_buffer->yy_n_chars;
1765         yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
1766         yyin = yy_current_buffer->yy_input_file;
1767         yy_hold_char = *yy_c_buf_p;
1768         }
1769
1770
1771 #ifdef YY_USE_PROTOS
1772 YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
1773 #else
1774 YY_BUFFER_STATE yy_create_buffer( file, size )
1775 FILE *file;
1776 int size;
1777 #endif
1778         {
1779         YY_BUFFER_STATE b;
1780
1781         b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
1782         if ( ! b )
1783                 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
1784
1785         b->yy_buf_size = size;
1786
1787         /* yy_ch_buf has to be 2 characters longer than the size given because
1788          * we need to put in 2 end-of-buffer characters.
1789          */
1790         b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 );
1791         if ( ! b->yy_ch_buf )
1792                 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
1793
1794         b->yy_is_our_buffer = 1;
1795
1796         yy_init_buffer( b, file );
1797
1798         return b;
1799         }
1800
1801
1802 #ifdef YY_USE_PROTOS
1803 void yy_delete_buffer( YY_BUFFER_STATE b )
1804 #else
1805 void yy_delete_buffer( b )
1806 YY_BUFFER_STATE b;
1807 #endif
1808         {
1809         if ( ! b )
1810                 return;
1811
1812         if ( b == yy_current_buffer )
1813                 yy_current_buffer = (YY_BUFFER_STATE) 0;
1814
1815         if ( b->yy_is_our_buffer )
1816                 yy_flex_free( (void *) b->yy_ch_buf );
1817
1818         yy_flex_free( (void *) b );
1819         }
1820
1821
1822 #ifndef YY_ALWAYS_INTERACTIVE
1823 #ifndef YY_NEVER_INTERACTIVE
1824 extern int isatty YY_PROTO(( int ));
1825 #endif
1826 #endif
1827
1828 #ifdef YY_USE_PROTOS
1829 void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
1830 #else
1831 void yy_init_buffer( b, file )
1832 YY_BUFFER_STATE b;
1833 FILE *file;
1834 #endif
1835
1836
1837         {
1838         yy_flush_buffer( b );
1839
1840         b->yy_input_file = file;
1841         b->yy_fill_buffer = 1;
1842
1843 #if YY_ALWAYS_INTERACTIVE
1844         b->yy_is_interactive = 1;
1845 #else
1846 #if YY_NEVER_INTERACTIVE
1847         b->yy_is_interactive = 0;
1848 #else
1849         b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
1850 #endif
1851 #endif
1852         }
1853
1854
1855 #ifdef YY_USE_PROTOS
1856 void yy_flush_buffer( YY_BUFFER_STATE b )
1857 #else
1858 void yy_flush_buffer( b )
1859 YY_BUFFER_STATE b;
1860 #endif
1861
1862         {
1863         if ( ! b )
1864                 return;
1865
1866         b->yy_n_chars = 0;
1867
1868         /* We always need two end-of-buffer characters.  The first causes
1869          * a transition to the end-of-buffer state.  The second causes
1870          * a jam in that state.
1871          */
1872         b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
1873         b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
1874
1875         b->yy_buf_pos = &b->yy_ch_buf[0];
1876
1877         b->yy_at_bol = 1;
1878         b->yy_buffer_status = YY_BUFFER_NEW;
1879
1880         if ( b == yy_current_buffer )
1881                 yy_load_buffer_state();
1882         }
1883
1884
1885 #ifndef YY_NO_SCAN_BUFFER
1886 #ifdef YY_USE_PROTOS
1887 YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size )
1888 #else
1889 YY_BUFFER_STATE yy_scan_buffer( base, size )
1890 char *base;
1891 yy_size_t size;
1892 #endif
1893         {
1894         YY_BUFFER_STATE b;
1895
1896         if ( size < 2 ||
1897              base[size-2] != YY_END_OF_BUFFER_CHAR ||
1898              base[size-1] != YY_END_OF_BUFFER_CHAR )
1899                 /* They forgot to leave room for the EOB's. */
1900                 return 0;
1901
1902         b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
1903         if ( ! b )
1904                 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
1905
1906         b->yy_buf_size = size - 2;      /* "- 2" to take care of EOB's */
1907         b->yy_buf_pos = b->yy_ch_buf = base;
1908         b->yy_is_our_buffer = 0;
1909         b->yy_input_file = 0;
1910         b->yy_n_chars = b->yy_buf_size;
1911         b->yy_is_interactive = 0;
1912         b->yy_at_bol = 1;
1913         b->yy_fill_buffer = 0;
1914         b->yy_buffer_status = YY_BUFFER_NEW;
1915
1916         yy_switch_to_buffer( b );
1917
1918         return b;
1919         }
1920 #endif
1921
1922
1923 #ifndef YY_NO_SCAN_STRING
1924 #ifdef YY_USE_PROTOS
1925 YY_BUFFER_STATE yy_scan_string( yyconst char *yy_str )
1926 #else
1927 YY_BUFFER_STATE yy_scan_string( yy_str )
1928 yyconst char *yy_str;
1929 #endif
1930         {
1931         int len;
1932         for ( len = 0; yy_str[len]; ++len )
1933                 ;
1934
1935         return yy_scan_bytes( yy_str, len );
1936         }
1937 #endif
1938
1939
1940 #ifndef YY_NO_SCAN_BYTES
1941 #ifdef YY_USE_PROTOS
1942 YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len )
1943 #else
1944 YY_BUFFER_STATE yy_scan_bytes( bytes, len )
1945 yyconst char *bytes;
1946 int len;
1947 #endif
1948         {
1949         YY_BUFFER_STATE b;
1950         char *buf;
1951         yy_size_t n;
1952         int i;
1953
1954         /* Get memory for full buffer, including space for trailing EOB's. */
1955         n = len + 2;
1956         buf = (char *) yy_flex_alloc( n );
1957         if ( ! buf )
1958                 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
1959
1960         for ( i = 0; i < len; ++i )
1961                 buf[i] = bytes[i];
1962
1963         buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR;
1964
1965         b = yy_scan_buffer( buf, n );
1966         if ( ! b )
1967                 YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
1968
1969         /* It's okay to grow etc. this buffer, and we should throw it
1970          * away when we're done.
1971          */
1972         b->yy_is_our_buffer = 1;
1973
1974         return b;
1975         }
1976 #endif
1977
1978
1979 #ifndef YY_NO_PUSH_STATE
1980 #ifdef YY_USE_PROTOS
1981 static void yy_push_state( int new_state )
1982 #else
1983 static void yy_push_state( new_state )
1984 int new_state;
1985 #endif
1986         {
1987         if ( yy_start_stack_ptr >= yy_start_stack_depth )
1988                 {
1989                 yy_size_t new_size;
1990
1991                 yy_start_stack_depth += YY_START_STACK_INCR;
1992                 new_size = yy_start_stack_depth * sizeof( int );
1993
1994                 if ( ! yy_start_stack )
1995                         yy_start_stack = (int *) yy_flex_alloc( new_size );
1996
1997                 else
1998                         yy_start_stack = (int *) yy_flex_realloc(
1999                                         (void *) yy_start_stack, new_size );
2000
2001                 if ( ! yy_start_stack )
2002                         YY_FATAL_ERROR(
2003                         "out of memory expanding start-condition stack" );
2004                 }
2005
2006         yy_start_stack[yy_start_stack_ptr++] = YY_START;
2007
2008         BEGIN(new_state);
2009         }
2010 #endif
2011
2012
2013 #ifndef YY_NO_POP_STATE
2014 static void yy_pop_state()
2015         {
2016         if ( --yy_start_stack_ptr < 0 )
2017                 YY_FATAL_ERROR( "start-condition stack underflow" );
2018
2019         BEGIN(yy_start_stack[yy_start_stack_ptr]);
2020         }
2021 #endif
2022
2023
2024 #ifndef YY_NO_TOP_STATE
2025 static int yy_top_state()
2026         {
2027         return yy_start_stack[yy_start_stack_ptr - 1];
2028         }
2029 #endif
2030
2031 #ifndef YY_EXIT_FAILURE
2032 #define YY_EXIT_FAILURE 2
2033 #endif
2034
2035 #ifdef YY_USE_PROTOS
2036 static void yy_fatal_error( yyconst char msg[] )
2037 #else
2038 static void yy_fatal_error( msg )
2039 char msg[];
2040 #endif
2041         {
2042         (void) fprintf( stderr, "%s\n", msg );
2043         exit( YY_EXIT_FAILURE );
2044         }
2045
2046
2047
2048 /* Redefine yyless() so it works in section 3 code. */
2049
2050 #undef yyless
2051 #define yyless(n) \
2052         do \
2053                 { \
2054                 /* Undo effects of setting up yytext. */ \
2055                 yytext[yyleng] = yy_hold_char; \
2056                 yy_c_buf_p = yytext + n; \
2057                 yy_hold_char = *yy_c_buf_p; \
2058                 *yy_c_buf_p = '\0'; \
2059                 yyleng = n; \
2060                 } \
2061         while ( 0 )
2062
2063
2064 /* Internal utility routines. */
2065
2066 #ifndef yytext_ptr
2067 #ifdef YY_USE_PROTOS
2068 static void yy_flex_strncpy( char *s1, yyconst char *s2, int n )
2069 #else
2070 static void yy_flex_strncpy( s1, s2, n )
2071 char *s1;
2072 yyconst char *s2;
2073 int n;
2074 #endif
2075         {
2076         register int i;
2077         for ( i = 0; i < n; ++i )
2078                 s1[i] = s2[i];
2079         }
2080 #endif
2081
2082 #ifdef YY_NEED_STRLEN
2083 #ifdef YY_USE_PROTOS
2084 static int yy_flex_strlen( yyconst char *s )
2085 #else
2086 static int yy_flex_strlen( s )
2087 yyconst char *s;
2088 #endif
2089         {
2090         register int n;
2091         for ( n = 0; s[n]; ++n )
2092                 ;
2093
2094         return n;
2095         }
2096 #endif
2097
2098
2099 #ifdef YY_USE_PROTOS
2100 static void *yy_flex_alloc( yy_size_t size )
2101 #else
2102 static void *yy_flex_alloc( size )
2103 yy_size_t size;
2104 #endif
2105         {
2106         return (void *) malloc( size );
2107         }
2108
2109 #ifdef YY_USE_PROTOS
2110 static void *yy_flex_realloc( void *ptr, yy_size_t size )
2111 #else
2112 static void *yy_flex_realloc( ptr, size )
2113 void *ptr;
2114 yy_size_t size;
2115 #endif
2116         {
2117         /* The cast to (char *) in the following accommodates both
2118          * implementations that use char* generic pointers, and those
2119          * that use void* generic pointers.  It works with the latter
2120          * because both ANSI C and C++ allow castless assignment from
2121          * any pointer type to void*, and deal with argument conversions
2122          * as though doing an assignment.
2123          */
2124         return (void *) realloc( (char *) ptr, size );
2125         }
2126
2127 #ifdef YY_USE_PROTOS
2128 static void yy_flex_free( void *ptr )
2129 #else
2130 static void yy_flex_free( ptr )
2131 void *ptr;
2132 #endif
2133         {
2134         free( ptr );
2135         }
2136
2137 #if YY_MAIN
2138 int main()
2139         {
2140         yylex();
2141         return 0;
2142         }
2143 #endif
2144 #line 212 "lexer.l"