]> git.draconx.ca Git - gob-dx.git/blob - src/lexer.c
Release 1.0.0
[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 88
288 #define YY_END_OF_BUFFER 89
289 static yyconst short int yy_acclist[399] =
290     {   0,
291        89,   86,   88,   85,   86,   88,    1,   87,   88,   86,
292        87,   88,   86,   88,   86,   88,   85,   86,   88,   86,
293        88,   86,   88,   26,   86,   88,    1,   27,   87,   88,
294        26,   86,   87,   88,   26,   86,   88,   26,   86,   88,
295        49,   86,   88,    1,   50,   87,   88,   49,   86,   87,
296        88,   42,   49,   86,   88,   49,   86,   88,   49,   86,
297        88,   49,   86,   88,   47,   49,   86,   88,   48,   49,
298        86,   88,   49,   86,   88,   49,   86,   88,   45,   86,
299        88,    1,   46,   87,   88,   45,   86,   87,   88,   44,
300        45,   86,   88,   45,   86,   88,   86,   88,   86,   88,
301
302        80,   86,   88,   80,   86,   88,   80,   86,   88,   80,
303        86,   88,   82,   86,   88,   86,   88,   86,   88,   77,
304        86,   88,   77,   86,   88,   86,   88,   80,   86,   88,
305        80,   86,   88,   80,   86,   88,   80,   86,   88,   80,
306        86,   88,   80,   86,   88,   80,   86,   88,   80,   86,
307        88,   80,   86,   88,   80,   86,   88,   80,   86,   88,
308        80,   86,   88,   83,   86,   88,   84,   86,   88,    9,
309        86,   88,    9,   86,   87,   88,    9,   86,   88,    9,
310        86,   88,    9,   86,   88,   14,   86,   88,   14,   86,
311        87,   88,   14,   86,   88,   14,   86,   88,   14,   86,
312
313        88,   17,   86,   88,   17,   86,   87,   88,   17,   86,
314        88,   21,   33,   25,   22,   41,   34,   43,   23,   79,
315        80,   78,   80,   80,   80,   77,   24,   77,   77,   81,
316        80,   80,   80,   80,   80,   80,   80,   80,   80,   80,
317        80,   80,   80,   80,   80,   80,   80,   80,    8,    6,
318        13,   10,   12,   11,   13,   16,   15,    3,   28,   32,
319        39,   35,   37,   18,   19,   79,   79,   78,   80,   80,
320        80,   68,   77,   20,   77,   77,   80,   80,   80,   80,
321        80,   80,   80,   63,   80,   80,   80,   80,   80,   80,
322        80,   80,   80,   80,   80,   80,   80,   11,   29,   30,
323
324        31,   40,   36,   38,   79,   80,   54,   80,   53,   80,
325         5,   80,   66,   80,   80,   80,   80,   58,   80,   80,
326        61,   80,   80,   80,   80,   80,   80,   80,   80,   80,
327        80,   80,   55,   80,    7,   51,   80,   53,   80,   67,
328        80,   80,   64,   80,   80,   80,   80,   80,   62,   80,
329        80,   80,   80,   57,   80,   80,   80,   80,   80,   65,
330        80,   80,   80,   80,   69,   80,   75,   80,   59,   80,
331        56,   80,   80,   80,   80,   80,   80,   70,   80,   80,
332        80,   74,   80,   73,   80,   80,   76,   80,   80,   60,
333        80,   72,   80,   71,   80,    2,    4,   52
334
335     } ;
336
337 static yyconst short int yy_accept[358] =
338     {   0,
339         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
340         1,    1,    1,    1,    1,    1,    1,    1,    1,    2,
341         4,    7,   10,   13,   15,   17,   20,   22,   24,   27,
342        31,   35,   38,   41,   44,   48,   52,   56,   59,   62,
343        65,   69,   73,   76,   79,   82,   86,   90,   94,   97,
344        99,  101,  104,  107,  110,  113,  116,  118,  120,  123,
345       126,  128,  131,  134,  137,  140,  143,  146,  149,  152,
346       155,  158,  161,  164,  167,  170,  173,  177,  180,  183,
347       186,  189,  193,  196,  199,  202,  205,  209,  212,  213,
348       213,  213,  213,  213,  213,  213,  213,  214,  214,  215,
349
350       215,  215,  215,  215,  215,  216,  216,  217,  217,  217,
351       218,  219,  220,  220,  221,  222,  223,  224,  225,  226,
352       226,  227,  228,  228,  228,  229,  229,  229,  230,  230,
353       230,  231,  232,  233,  234,  235,  236,  237,  238,  239,
354       240,  241,  242,  243,  244,  245,  246,  247,  248,  249,
355       250,  250,  250,  250,  251,  251,  252,  252,  252,  252,
356       253,  254,  254,  256,  257,  258,  258,  259,  259,  259,
357       259,  260,  260,  260,  261,  261,  261,  261,  261,  262,
358       262,  262,  262,  263,  264,  264,  265,  265,  265,  266,
359       267,  268,  269,  270,  271,  272,  273,  274,  274,  274,
360
361       275,  276,  277,  277,  277,  278,  279,  280,  281,  282,
362       283,  284,  286,  287,  288,  289,  290,  291,  292,  293,
363       294,  295,  296,  297,  298,  298,  299,  299,  299,  300,
364       300,  301,  302,  302,  302,  302,  303,  304,  305,  305,
365       306,  307,  309,  311,  311,  312,  313,  315,  316,  317,
366       318,  320,  321,  323,  324,  325,  326,  327,  328,  329,
367       330,  331,  332,  333,  335,  335,  336,  336,  336,  337,
368       337,  337,  337,  337,  337,  337,  338,  340,  342,  343,
369       345,  346,  347,  348,  349,  351,  352,  353,  354,  356,
370       357,  358,  358,  358,  358,  358,  358,  358,  359,  360,
371
372       362,  363,  364,  365,  367,  369,  371,  373,  374,  375,
373       375,  375,  375,  375,  375,  376,  377,  378,  380,  381,
374       382,  384,  384,  384,  384,  384,  384,  386,  387,  389,
375       390,  392,  392,  392,  392,  392,  392,  392,  394,  396,
376       396,  396,  396,  397,  397,  397,  397,  397,  398,  398,
377       398,  398,  398,  398,  398,  399,  399
378     } ;
379
380 static yyconst int yy_ec[256] =
381     {   0,
382         1,    1,    1,    1,    1,    1,    1,    1,    2,    3,
383         1,    1,    4,    1,    1,    1,    1,    1,    1,    1,
384         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
385         1,    5,    1,    6,    7,    1,    8,    1,    9,   10,
386        11,   12,    1,    1,    1,   13,   14,   15,   16,   17,
387        17,   17,   17,   17,   17,   18,   18,   19,    1,   20,
388         1,   21,    1,    1,   22,   22,   22,   22,   23,   22,
389        24,   24,   25,   24,   24,   24,   24,   24,   24,   24,
390        24,   26,   27,   24,   24,   24,   24,   24,   24,   24,
391        28,   29,   30,    1,   24,    1,   31,   32,   33,   34,
392
393        35,   36,   37,   38,   39,   24,   24,   40,   41,   42,
394        43,   44,   45,   46,   47,   48,   49,   50,   51,   52,
395        24,   24,   53,    1,   54,    1,    1,    1,    1,    1,
396         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
397         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
398         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
399         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
400         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
401         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
402         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
403
404         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
405         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
406         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
407         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
408         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
409         1,    1,    1,    1,    1
410     } ;
411
412 static yyconst int yy_meta[55] =
413     {   0,
414         1,    2,    3,    1,    2,    1,    1,    1,    1,    1,
415         1,    1,    1,    1,    4,    4,    4,    4,    5,    1,
416         1,    6,    6,    7,    7,    7,    7,    1,    1,    8,
417         6,    6,    6,    6,    6,    6,    7,    7,    7,    7,
418         7,    7,    7,    7,    7,    7,    7,    7,    7,    7,
419         7,    7,    1,    1
420     } ;
421
422 static yyconst short int yy_base[383] =
423     {   0,
424         0,    4,    7,   13,   17,   69,   24,   36,  123,    0,
425       165,    0,   31,   52,   48,   77,   55,   81,  848,  849,
426       849,  849,  849,    1,  807,   42,   56,  811,  849,  849,
427       849,  831,  817,  849,  849,  849,  849,   57,   10,    0,
428       849,  849,   27,  789,  849,  849,  849,  849,    0,   78,
429         0,  823,   22,   49,   77,  849,   86,   93,  171,  101,
430       209,  171,  173,   26,   55,   72,  178,  187,  172,  183,
431       202,  191,  209,  849,  849,  849,  849,  827,  232,  233,
432       849,  849,  826,  241,  252,  836,  835,  228,  849,  834,
433       805,  254,  800,  220,  210,   75,  849,  789,  849,    0,
434
435       824,  243,  823,  822,  849,  827,  849,  260,  787,  849,
436       849,  849,  825,  808,  807,  806,   17,  232,  242,  811,
437       254,  811,  819,  261,  267,  273,    0,  288,  277,  791,
438       792,  166,   30,   89,  268,  279,  283,  290,  289,  292,
439       294,  296,  175,  293,  301,  295,  303,  297,  305,  849,
440       343,  316,  344,  849,  349,  849,  351,  355,  359,  849,
441       363,  805,  849,  849,  849,  815,  849,  770,  776,  762,
442       849,  783,  760,  849,  759,  772,  761,  783,  849,  799,
443       798,  797,  849,  849,  802,  849,  771,  800,  849,  783,
444       782,  781,  312,  351,  352,  849,  357,  374,  796,  849,
445
446       365,    0,  768,  370,  359,  365,  370,  371,  298,  372,
447       374,  778,  375,  376,  377,  378,  379,  382,  383,  384,
448       387,  385,  388,  306,  418,  849,  749,  361,  849,  761,
449       849,  849,  744,  754,  767,  849,  849,  849,  751,  771,
450       391,  770,  769,  429,  849,  410,  768,  396,  397,  416,
451       767,  420,  766,  421,  422,  423,  425,  427,  428,  429,
452       430,  433,  431,  765,  452,  849,  471,  476,  849,  740,
453       747,  750,  734,    0,  730,  442,  441,  759,  447,  758,
454       446,  450,  464,  467,  757,  465,  468,  469,  756,  452,
455       470,  730,  727,  724,  736,  742,  723,  472,  474,  723,
456
457       476,  477,  480,  722,  716,  713,  674,  484,  485,  458,
458       644,  619,  648,  560,  488,  489,  496,  575,  497,  490,
459       574,  549,  553,  321,  504,  524,  570,  499,  566,  508,
460       555,  520,  527,  528,  522,  536,  529,  531,  308,  243,
461       542,  550,  849,  535,  233,  554,  542,  849,  160,  560,
462        60,  564,  581,  585,  849,  849,  599,  607,  615,  623,
463       631,  639,  647,  655,  663,  666,  670,  674,  682,  690,
464       698,  706,  711,  715,  722,  727,  730,  737,  741,  747,
465       754,  762
466     } ;
467
468 static yyconst short int yy_def[383] =
469     {   0,
470       357,  357,  358,  358,  359,  359,  360,  360,  356,    9,
471         9,   11,  361,  361,  362,  362,  363,  363,  356,  356,
472       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
473       356,  356,  356,  356,  356,  356,  356,  356,  356,  364,
474       356,  356,  356,  356,  356,  356,  356,  356,  365,  356,
475       366,  367,  367,  367,  367,  356,  356,  356,  356,  356,
476       368,  367,  367,  367,  367,  367,  367,  367,  367,  367,
477       367,  367,  367,  356,  356,  356,  356,  356,  356,  356,
478       356,  356,  356,  356,  356,  356,  356,  356,  356,  369,
479       356,  356,  356,  356,  356,  356,  356,  356,  356,  370,
480
481       356,  356,  356,  356,  356,  371,  356,  356,  356,  356,
482       356,  356,  372,  373,  367,  374,  367,  367,  367,  356,
483       356,  356,  375,  356,  356,  356,  376,  356,  356,  377,
484       356,  367,  367,  367,  367,  367,  367,  367,  367,  367,
485       367,  367,  367,  367,  367,  367,  367,  367,  367,  356,
486       356,  356,  356,  356,  378,  356,  356,  356,  356,  356,
487       356,  356,  356,  356,  356,  369,  356,  356,  356,  356,
488       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
489       356,  356,  356,  356,  371,  356,  356,  372,  356,  373,
490       379,  374,  367,  367,  367,  356,  356,  356,  375,  356,
491
492       356,  376,  377,  368,  367,  367,  367,  367,  367,  367,
493       367,  367,  367,  367,  367,  367,  367,  367,  367,  367,
494       367,  367,  367,  367,  380,  356,  356,  356,  356,  356,
495       356,  356,  356,  356,  356,  356,  356,  356,  356,  379,
496       367,  367,  367,  356,  356,  367,  367,  367,  367,  367,
497       367,  367,  367,  367,  367,  367,  367,  367,  367,  367,
498       367,  367,  367,  367,  356,  356,  380,  356,  356,  356,
499       356,  356,  356,  381,  356,  367,  367,  367,  367,  367,
500       367,  367,  367,  367,  367,  367,  367,  367,  367,  367,
501       367,  356,  356,  356,  356,  356,  356,  367,  367,  367,
502
503       367,  367,  367,  367,  367,  367,  367,  367,  367,  356,
504       356,  356,  356,  356,  367,  367,  367,  367,  367,  367,
505       367,  356,  356,  356,  356,  356,  367,  367,  367,  367,
506       367,  356,  356,  356,  356,  356,  356,  367,  367,  356,
507       356,  356,  356,  382,  356,  356,  382,  356,  356,  356,
508       356,  356,  356,  356,  356,    0,  356,  356,  356,  356,
509       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
510       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
511       356,  356
512     } ;
513
514 static yyconst short int yy_nxt[904] =
515     {   0,
516       356,   21,   22,   23,   21,   26,   22,   23,   26,   30,
517        31,   27,   89,   24,   90,   30,   31,   24,   32,   35,
518        36,  105,   37,  106,   32,   38,   46,   47,  108,   48,
519        39,  108,   25,   22,   77,  116,   25,   33,   46,   47,
520       116,   48,   78,   92,  116,   40,   92,  193,  116,   28,
521        22,   82,   49,   79,   22,   77,   79,   22,   87,   83,
522       206,  117,  101,   80,   49,  109,   88,  116,  136,   41,
523        42,   35,   36,  116,   37,   43,   44,   38,   84,   22,
524        82,   84,   39,   22,   87,  102,   94,   93,   85,  112,
525       116,  113,   88,   95,  118,  116,  137,   40,  120,   96,
526
527       121,  121,  121,  121,  122,  175,  123,  116,   97,  103,
528       104,  138,  175,  124,  119,  128,  128,  128,  128,  207,
529       176,   41,   42,   20,   21,   22,   23,   21,   20,   20,
530        20,   20,   20,   20,   20,   20,   50,   20,   20,   20,
531        20,   51,   20,   20,   52,   52,   52,   52,   52,   52,
532        20,   20,   20,   52,   52,   53,   52,   52,   54,   52,
533        52,   52,   52,   52,   52,   52,   52,   52,   52,   52,
534        55,   52,   52,   52,   52,   56,   20,   57,   58,   59,
535        60,   60,   60,  124,  116,  125,  125,  125,  126,  116,
536       116,  116,   61,  116,  351,   62,  116,   63,   64,   65,
537
538        66,  116,  205,   67,   68,  116,  217,   69,   70,  116,
539       133,   71,  134,   72,   73,  135,  132,   74,   75,  139,
540       116,  141,  127,  129,  129,  129,  129,  116,  142,  140,
541       164,  143,  147,  151,  153,  154,  151,  155,  131,  144,
542       145,  165,  157,  152,  172,  157,  150,  148,  180,  146,
543       116,  149,  158,  159,  160,   92,  161,  173,   92,  169,
544       116,  108,  174,  162,  108,  163,  349,  170,  197,  197,
545       197,  197,  171,  345,  194,  201,  201,  201,  201,  124,
546       195,  125,  125,  125,  126,  124,  116,  126,  126,  126,
547       126,  129,  129,  129,  129,  181,  182,  116,  109,   93,
548
549       124,  116,  128,  128,  128,  128,  131,  116,  116,  208,
550       116,  116,  116,  116,  116,  116,  116,  153,  154,  116,
551       155,  116,  334,  116,  116,  334,  116,  209,  214,  250,
552       116,  210,  211,  213,  215,  218,  212,  219,  216,  264,
553       220,  221,  223,  224,  151,  153,  154,  151,  153,  222,
554       153,  154,  157,  153,  152,  157,  159,  160,  241,  161,
555       159,  160,  158,  159,  159,  160,  162,  159,  226,  116,
556       116,  197,  197,  197,  197,  244,  245,  116,  244,  201,
557       201,  201,  201,  116,  129,  129,  129,  129,  116,  116,
558       116,  242,  116,  116,  116,  116,  116,  116,  243,  131,
559
560       116,  116,  116,  116,  252,  116,  116,  246,  270,  116,
561       247,  253,  251,  171,  116,  116,  248,  249,  257,  265,
562       266,  254,  265,  262,  259,  256,  255,  258,  116,  261,
563       244,  245,  260,  244,  116,  263,  268,  243,  116,  116,
564       116,  116,  277,  116,  278,  116,  116,  116,  116,  116,
565       276,  116,  282,  265,  266,  279,  265,  283,  286,  116,
566       116,  288,  287,  284,  116,  116,  281,  280,  116,  290,
567       116,  289,  265,  266,  285,  265,  298,  265,  266,  291,
568       265,  300,  116,  116,  301,  116,  116,  116,  116,  268,
569       116,  299,  116,  308,  116,  116,  303,  302,  116,  304,
570
571       309,  306,  116,  116,  305,  322,  116,  116,  116,  317,
572       174,  318,  316,  315,  116,  116,  307,  116,  320,  335,
573       336,  336,  328,  331,  321,  337,  116,  319,  337,  334,
574       329,  330,  334,  338,  344,  327,  342,  342,  342,  342,
575       348,  339,  341,  341,  341,  341,  343,  348,  344,  116,
576       342,  342,  342,  342,  346,  348,  341,  341,  341,  341,
577       343,  340,  348,  173,  342,  342,  342,  342,  350,  350,
578       350,  350,  352,  116,  350,  350,  350,  350,  353,  353,
579       353,  353,  354,  355,  116,  354,  354,  355,  116,  354,
580       333,  332,  116,  116,  326,  353,  353,  353,  353,   20,
581
582        20,   20,   20,   20,   20,   20,   20,   29,   29,   29,
583        29,   29,   29,   29,   29,   34,   34,   34,   34,   34,
584        34,   34,   34,   45,   45,   45,   45,   45,   45,   45,
585        45,   76,   76,   76,   76,   76,   76,   76,   76,   81,
586        81,   81,   81,   81,   81,   81,   81,   86,   86,   86,
587        86,   86,   86,   86,   86,  107,  107,  325,  107,  107,
588       107,  107,  107,  111,  111,  324,  111,  111,  111,  111,
589       111,  114,  114,  115,  115,  115,  115,  130,  323,  130,
590       130,  130,  166,  166,  166,  166,  166,  166,  166,  166,
591       178,  178,  116,  178,  178,  178,  178,  178,  185,  185,
592
593       185,  185,  185,  185,  185,  185,  188,  188,  188,  188,
594       188,  188,  188,  188,  190,  190,  190,  190,  192,  192,
595       192,  192,  199,  199,  199,  199,  199,  199,  199,  199,
596       202,  116,  202,  203,  116,  203,  203,  203,  225,  225,
597       116,  116,  225,  225,  240,  240,  240,  240,  267,  267,
598       267,  267,  267,  267,  296,  296,  314,  296,  296,  296,
599       296,  296,  347,  347,  313,  347,  347,  347,  347,  347,
600       312,  311,  310,  170,  116,  116,  116,  116,  297,  295,
601       294,  293,  292,  116,  116,  116,  116,  116,  116,  191,
602       275,  274,  273,  272,  271,  269,  116,  131,  200,  116,
603
604       191,  191,  189,  239,  186,  238,  237,  236,  235,  234,
605       233,  232,  231,  230,  229,  228,  227,  167,  226,  204,
606       131,  200,  198,  196,  116,  116,  191,  189,  187,  186,
607       184,  183,  179,  177,   98,  168,  167,  164,  164,  156,
608       150,  116,  110,  100,   99,   98,   91,  356,   19,  356,
609       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
610       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
611       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
612       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
613       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
614
615       356,  356,  356
616     } ;
617
618 static yyconst short int yy_chk[904] =
619     {   0,
620         0,    1,    1,    1,    1,    2,    2,    2,    2,    3,
621         3,    2,   24,    1,   24,    4,    4,    2,    3,    5,
622         5,   39,    5,   39,    4,    5,    7,    7,   43,    7,
623         5,   43,    1,   13,   13,  117,    2,    4,    8,    8,
624        53,    8,   13,   26,   64,    5,   26,  117,  133,    2,
625        15,   15,    7,   14,   14,   14,   14,   17,   17,   15,
626       133,   53,   38,   14,    8,   43,   17,   54,   64,    5,
627         5,    6,    6,   65,    6,    6,    6,    6,   16,   16,
628        16,   16,    6,   18,   18,   38,   27,   26,   16,   50,
629        66,   50,   18,   27,   54,   55,   65,    6,   57,   27,
630
631        57,   57,   57,   57,   58,  351,   58,  134,   27,   38,
632        38,   66,   96,   60,   55,   60,   60,   60,   60,  134,
633        96,    6,    6,    9,    9,    9,    9,    9,    9,    9,
634         9,    9,    9,    9,    9,    9,    9,    9,    9,    9,
635         9,    9,    9,    9,    9,    9,    9,    9,    9,    9,
636         9,    9,    9,    9,    9,    9,    9,    9,    9,    9,
637         9,    9,    9,    9,    9,    9,    9,    9,    9,    9,
638         9,    9,    9,    9,    9,    9,    9,   11,   11,   11,
639        11,   11,   11,   59,  132,   59,   59,   59,   59,   62,
640        69,   63,   11,  143,  349,   11,   67,   11,   11,   11,
641
642        11,   70,  132,   11,   11,   68,  143,   11,   11,   72,
643        63,   11,   63,   11,   11,   63,   62,   11,   11,   67,
644        71,   69,   59,   61,   61,   61,   61,   73,   70,   68,
645        88,   70,   72,   79,   80,   80,   79,   80,   61,   71,
646        71,   88,   84,   79,   95,   84,   80,   73,  102,   71,
647       118,   73,   84,   85,   85,   92,   85,   95,   92,   94,
648       119,  108,   95,   85,  108,   85,  345,   94,  121,  121,
649       121,  121,   94,  340,  118,  124,  124,  124,  124,  125,
650       119,  125,  125,  125,  125,  126,  135,  126,  126,  126,
651       126,  129,  129,  129,  129,  102,  102,  136,  108,   92,
652
653       128,  137,  128,  128,  128,  128,  129,  139,  138,  135,
654       140,  144,  141,  146,  142,  148,  209,  152,  152,  145,
655       152,  147,  324,  149,  224,  324,  339,  136,  141,  209,
656       193,  137,  138,  140,  142,  144,  139,  145,  142,  224,
657       146,  147,  148,  149,  151,  153,  153,  151,  153,  147,
658       155,  155,  157,  155,  151,  157,  158,  158,  193,  158,
659       159,  159,  157,  159,  161,  161,  158,  161,  158,  194,
660       195,  197,  197,  197,  197,  198,  198,  205,  198,  201,
661       201,  201,  201,  206,  204,  204,  204,  204,  207,  208,
662       210,  194,  211,  213,  214,  215,  216,  217,  195,  204,
663
664       218,  219,  220,  222,  211,  221,  223,  205,  228,  241,
665       206,  213,  210,  228,  248,  249,  207,  208,  217,  225,
666       225,  214,  225,  222,  219,  216,  215,  218,  246,  221,
667       244,  244,  220,  244,  250,  223,  225,  241,  252,  254,
668       255,  256,  248,  257,  249,  258,  259,  260,  261,  263,
669       246,  262,  255,  265,  265,  250,  265,  256,  259,  277,
670       276,  260,  259,  257,  281,  279,  254,  252,  282,  262,
671       290,  261,  267,  267,  258,  267,  276,  268,  268,  263,
672       268,  279,  283,  286,  281,  284,  287,  288,  291,  267,
673       298,  277,  299,  290,  301,  302,  283,  282,  303,  284,
674
675       291,  287,  308,  309,  286,  310,  315,  316,  320,  301,
676       310,  302,  299,  298,  317,  319,  288,  328,  308,  325,
677       325,  325,  316,  320,  309,  326,  330,  303,  326,  334,
678       317,  319,  334,  328,  337,  315,  335,  335,  335,  335,
679       344,  330,  334,  334,  334,  334,  336,  347,  337,  338,
680       336,  336,  336,  336,  341,  344,  341,  341,  341,  341,
681       342,  333,  347,  332,  342,  342,  342,  342,  346,  346,
682       346,  346,  350,  331,  350,  350,  350,  350,  352,  352,
683       352,  352,  353,  353,  329,  353,  354,  354,  327,  354,
684       323,  322,  321,  318,  314,  353,  353,  353,  353,  357,
685
686       357,  357,  357,  357,  357,  357,  357,  358,  358,  358,
687       358,  358,  358,  358,  358,  359,  359,  359,  359,  359,
688       359,  359,  359,  360,  360,  360,  360,  360,  360,  360,
689       360,  361,  361,  361,  361,  361,  361,  361,  361,  362,
690       362,  362,  362,  362,  362,  362,  362,  363,  363,  363,
691       363,  363,  363,  363,  363,  364,  364,  313,  364,  364,
692       364,  364,  364,  365,  365,  312,  365,  365,  365,  365,
693       365,  366,  366,  367,  367,  367,  367,  368,  311,  368,
694       368,  368,  369,  369,  369,  369,  369,  369,  369,  369,
695       370,  370,  307,  370,  370,  370,  370,  370,  371,  371,
696
697       371,  371,  371,  371,  371,  371,  372,  372,  372,  372,
698       372,  372,  372,  372,  373,  373,  373,  373,  374,  374,
699       374,  374,  375,  375,  375,  375,  375,  375,  375,  375,
700       376,  306,  376,  377,  305,  377,  377,  377,  378,  378,
701       304,  300,  378,  378,  379,  379,  379,  379,  380,  380,
702       380,  380,  380,  380,  381,  381,  297,  381,  381,  381,
703       381,  381,  382,  382,  296,  382,  382,  382,  382,  382,
704       295,  294,  293,  292,  289,  285,  280,  278,  275,  273,
705       272,  271,  270,  264,  253,  251,  247,  243,  242,  240,
706       239,  235,  234,  233,  230,  227,  212,  203,  199,  192,
707
708       191,  190,  188,  187,  185,  182,  181,  180,  178,  177,
709       176,  175,  173,  172,  170,  169,  168,  166,  162,  131,
710       130,  123,  122,  120,  116,  115,  114,  113,  109,  106,
711       104,  103,  101,   98,   93,   91,   90,   87,   86,   83,
712        78,   52,   44,   33,   32,   28,   25,   19,  356,  356,
713       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
714       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
715       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
716       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
717       356,  356,  356,  356,  356,  356,  356,  356,  356,  356,
718
719       356,  356,  356
720     } ;
721
722 static yy_state_type yy_state_buf[YY_BUF_SIZE + 2], *yy_state_ptr;
723 static char *yy_full_match;
724 static int yy_lp;
725 #define REJECT \
726 { \
727 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */ \
728 yy_cp = yy_full_match; /* restore poss. backed-over text */ \
729 ++yy_lp; \
730 goto find_rule; \
731 }
732 #define yymore() yymore_used_but_not_detected
733 #define YY_MORE_ADJ 0
734 #define YY_RESTORE_YY_MORE_OFFSET
735 char *yytext;
736 #line 1 "lexer.l"
737 #define INITIAL 0
738 /* GOB C Preprocessor
739  * Copyright (C) 1999 the Free Software Foundation.
740  *
741  * Author: George Lebl
742  *
743  * This program is free software; you can redistribute it and/or modify
744  * it under the terms of the GNU General Public License as published by
745  * the Free Software Foundation; either version 2 of the License, or
746  * (at your option) any later version.
747  *
748  * This program is distributed in the hope that it will be useful,
749  * but WITHOUT ANY WARRANTY; without even the implied warranty of
750  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
751  * GNU General Public License for more details.
752  *
753  * You should have received a copy of the GNU General Public License
754  * along with this program; if not, write to the  Free Software
755  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
756  * USA.
757  */
758 #line 22 "lexer.l"
759
760 #include "config.h"
761 #include <glib.h>
762 #include <string.h>
763
764 #include "treefuncs.h"
765 #include "parse.h"
766 #include "main.h"
767 #include "util.h"
768
769 static int parenth_depth = 0;
770 static int before_comment = INITIAL;
771 static gboolean class_after_c = FALSE;
772 static int code_type = CCODE;
773
774 /* GTK+ doc stuff */
775 static char *gtk_doc_func = NULL; /* current gtk-doc func */
776 GHashTable *gtk_doc_hash = NULL;
777
778 static GString *cbuf = NULL;
779 int ccode_line = 1;
780
781 GList *include_files = NULL;
782 /* 0 no, 1 means yes, 2+ means don't even start looking anymore */
783 static int look_for_includes = 0;
784
785 int line_no = 1;
786
787 static void
788 clear_cbuf(void)
789 {
790         if(!cbuf) {
791                 cbuf = g_string_new(NULL);
792         } else {
793                 cbuf = g_string_assign(cbuf, "");
794         }
795 }
796
797 static void
798 add_to_cbuf(char *s)
799 {
800         if(!cbuf) {
801                 cbuf = g_string_new(s);
802         } else {
803                 cbuf = g_string_append(cbuf,s);
804         }
805 }
806
807 static void
808 add_gtk_doc_func(void)
809 {
810         if(!gtk_doc_func)
811                 return;
812
813         if(!gtk_doc_hash)
814                 gtk_doc_hash = g_hash_table_new(g_str_hash, g_str_equal);
815         g_hash_table_insert(gtk_doc_hash, gtk_doc_func, g_strdup(cbuf->str));
816         clear_cbuf();
817
818         gtk_doc_func = NULL;
819 }
820
821
822 #define COMMENT 1
823
824 #define C_CODE 2
825
826 #define C_CODE_STRING 3
827
828 #define CLASS_CODE 4
829
830 #define CLASS_CODE_I 5
831
832 #define GTK_DOC_BEFORE_NAME 6
833
834 #define GTK_DOC 7
835
836 #define GTK_DOC_LINE 8
837
838 #line 839 "lex.yy.c"
839
840 /* Macros after this point can all be overridden by user definitions in
841  * section 1.
842  */
843
844 #ifndef YY_SKIP_YYWRAP
845 #ifdef __cplusplus
846 extern "C" int yywrap YY_PROTO(( void ));
847 #else
848 extern int yywrap YY_PROTO(( void ));
849 #endif
850 #endif
851
852 #ifndef YY_NO_UNPUT
853 static void yyunput YY_PROTO(( int c, char *buf_ptr ));
854 #endif
855
856 #ifndef yytext_ptr
857 static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));
858 #endif
859
860 #ifdef YY_NEED_STRLEN
861 static int yy_flex_strlen YY_PROTO(( yyconst char * ));
862 #endif
863
864 #ifndef YY_NO_INPUT
865 #ifdef __cplusplus
866 static int yyinput YY_PROTO(( void ));
867 #else
868 static int input YY_PROTO(( void ));
869 #endif
870 #endif
871
872 #if YY_STACK_USED
873 static int yy_start_stack_ptr = 0;
874 static int yy_start_stack_depth = 0;
875 static int *yy_start_stack = 0;
876 #ifndef YY_NO_PUSH_STATE
877 static void yy_push_state YY_PROTO(( int new_state ));
878 #endif
879 #ifndef YY_NO_POP_STATE
880 static void yy_pop_state YY_PROTO(( void ));
881 #endif
882 #ifndef YY_NO_TOP_STATE
883 static int yy_top_state YY_PROTO(( void ));
884 #endif
885
886 #else
887 #define YY_NO_PUSH_STATE 1
888 #define YY_NO_POP_STATE 1
889 #define YY_NO_TOP_STATE 1
890 #endif
891
892 #ifdef YY_MALLOC_DECL
893 YY_MALLOC_DECL
894 #else
895 #if __STDC__
896 #ifndef __cplusplus
897 #include <stdlib.h>
898 #endif
899 #else
900 /* Just try to get by without declaring the routines.  This will fail
901  * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int)
902  * or sizeof(void*) != sizeof(int).
903  */
904 #endif
905 #endif
906
907 /* Amount of stuff to slurp up with each read. */
908 #ifndef YY_READ_BUF_SIZE
909 #define YY_READ_BUF_SIZE 8192
910 #endif
911
912 /* Copy whatever the last rule matched to the standard output. */
913
914 #ifndef ECHO
915 /* This used to be an fputs(), but since the string might contain NUL's,
916  * we now use fwrite().
917  */
918 #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
919 #endif
920
921 /* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
922  * is returned in "result".
923  */
924 #ifndef YY_INPUT
925 #define YY_INPUT(buf,result,max_size) \
926         if ( yy_current_buffer->yy_is_interactive ) \
927                 { \
928                 int c = '*', n; \
929                 for ( n = 0; n < max_size && \
930                              (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
931                         buf[n] = (char) c; \
932                 if ( c == '\n' ) \
933                         buf[n++] = (char) c; \
934                 if ( c == EOF && ferror( yyin ) ) \
935                         YY_FATAL_ERROR( "input in flex scanner failed" ); \
936                 result = n; \
937                 } \
938         else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
939                   && ferror( yyin ) ) \
940                 YY_FATAL_ERROR( "input in flex scanner failed" );
941 #endif
942
943 /* No semi-colon after return; correct usage is to write "yyterminate();" -
944  * we don't want an extra ';' after the "return" because that will cause
945  * some compilers to complain about unreachable statements.
946  */
947 #ifndef yyterminate
948 #define yyterminate() return YY_NULL
949 #endif
950
951 /* Number of entries by which start-condition stack grows. */
952 #ifndef YY_START_STACK_INCR
953 #define YY_START_STACK_INCR 25
954 #endif
955
956 /* Report a fatal error. */
957 #ifndef YY_FATAL_ERROR
958 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
959 #endif
960
961 /* Default declaration of generated scanner - a define so the user can
962  * easily add parameters.
963  */
964 #ifndef YY_DECL
965 #define YY_DECL int yylex YY_PROTO(( void ))
966 #endif
967
968 /* Code executed at the beginning of each rule, after yytext and yyleng
969  * have been set up.
970  */
971 #ifndef YY_USER_ACTION
972 #define YY_USER_ACTION
973 #endif
974
975 /* Code executed at the end of each rule. */
976 #ifndef YY_BREAK
977 #define YY_BREAK break;
978 #endif
979
980 #define YY_RULE_SETUP \
981         if ( yyleng > 0 ) \
982                 yy_current_buffer->yy_at_bol = \
983                                 (yytext[yyleng - 1] == '\n'); \
984         YY_USER_ACTION
985
986 YY_DECL
987         {
988         register yy_state_type yy_current_state;
989         register char *yy_cp = NULL, *yy_bp = NULL;
990         register int yy_act;
991
992 #line 98 "lexer.l"
993
994
995 #line 996 "lex.yy.c"
996
997         if ( yy_init )
998                 {
999                 yy_init = 0;
1000
1001 #ifdef YY_USER_INIT
1002                 YY_USER_INIT;
1003 #endif
1004
1005                 if ( ! yy_start )
1006                         yy_start = 1;   /* first start state */
1007
1008                 if ( ! yyin )
1009                         yyin = stdin;
1010
1011                 if ( ! yyout )
1012                         yyout = stdout;
1013
1014                 if ( ! yy_current_buffer )
1015                         yy_current_buffer =
1016                                 yy_create_buffer( yyin, YY_BUF_SIZE );
1017
1018                 yy_load_buffer_state();
1019                 }
1020
1021         while ( 1 )             /* loops until end-of-file is reached */
1022                 {
1023                 yy_cp = yy_c_buf_p;
1024
1025                 /* Support of yytext. */
1026                 *yy_cp = yy_hold_char;
1027
1028                 /* yy_bp points to the position in yy_ch_buf of the start of
1029                  * the current run.
1030                  */
1031                 yy_bp = yy_cp;
1032
1033                 yy_current_state = yy_start;
1034                 yy_current_state += YY_AT_BOL();
1035                 yy_state_ptr = yy_state_buf;
1036                 *yy_state_ptr++ = yy_current_state;
1037 yy_match:
1038                 do
1039                         {
1040                         register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
1041                         while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
1042                                 {
1043                                 yy_current_state = (int) yy_def[yy_current_state];
1044                                 if ( yy_current_state >= 357 )
1045                                         yy_c = yy_meta[(unsigned int) yy_c];
1046                                 }
1047                         yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
1048                         *yy_state_ptr++ = yy_current_state;
1049                         ++yy_cp;
1050                         }
1051                 while ( yy_base[yy_current_state] != 849 );
1052
1053 yy_find_action:
1054                 yy_current_state = *--yy_state_ptr;
1055                 yy_lp = yy_accept[yy_current_state];
1056 find_rule: /* we branch to this label when backing up */
1057                 for ( ; ; ) /* until we find what rule we matched */
1058                         {
1059                         if ( yy_lp && yy_lp < yy_accept[yy_current_state + 1] )
1060                                 {
1061                                 yy_act = yy_acclist[yy_lp];
1062                                         {
1063                                         yy_full_match = yy_cp;
1064                                         break;
1065                                         }
1066                                 }
1067                         --yy_cp;
1068                         yy_current_state = *--yy_state_ptr;
1069                         yy_lp = yy_accept[yy_current_state];
1070                         }
1071
1072                 YY_DO_BEFORE_ACTION;
1073
1074
1075 do_action:      /* This label is used only to access EOF actions. */
1076
1077
1078                 switch ( yy_act )
1079         { /* beginning of action switch */
1080 case 1:
1081 YY_RULE_SETUP
1082 #line 100 "lexer.l"
1083 { line_no++; REJECT; }
1084         YY_BREAK
1085 case 2:
1086 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
1087 yy_c_buf_p = yy_cp -= 1;
1088 YY_DO_BEFORE_ACTION; /* set up yytext again */
1089 YY_RULE_SETUP
1090 #line 102 "lexer.l"
1091 {
1092 /* Thy evil easter egg */
1093 #define QQ(x) long x
1094 #define KK(x) =atoi(__(&,,x,))
1095 #define MM(x,a) {QQ(i);for(i=2;i<x;i++){a}}
1096 #define PP(Q) (P%Q)==0
1097 #define ___(x,y,z) if(x z y)
1098 #define __(a,x,y,z) a(yytext[y] x z)
1099 #define O__O(a,b) fprintf(stderr,"%s is %s!\n",a,b)
1100 QQ(m)=1;___(__(,==,2,'P'),__(,==,5,'M'),&&
1101 ){QQ(P)KK(8);MM(P,___(PP(i),,)m=0;)}__(,=,
1102 7,0);___(,,m){O__O(__( &,,8,),__(&,,2,));}
1103 #undef QQ
1104 #undef KK
1105 #undef MM
1106 #undef PP
1107 #undef ___
1108 #undef __
1109 #undef O__O
1110 REJECT;
1111 }
1112         YY_BREAK
1113 case 3:
1114 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
1115 yy_c_buf_p = yy_cp -= 1;
1116 YY_DO_BEFORE_ACTION; /* set up yytext again */
1117 YY_RULE_SETUP
1118 #line 124 "lexer.l"
1119 { ; /*comment, ignore*/ }
1120         YY_BREAK
1121 case 4:
1122 YY_RULE_SETUP
1123 #line 125 "lexer.l"
1124 {
1125         if(look_for_includes==1) {
1126                 char *p;
1127                 char *file;
1128                 char *str = g_strdup(yytext);
1129                 file = strchr(str,'"');
1130                 if(!file) file = strchr(str,'<');
1131                 file++;
1132                 p = strchr(file,'"');
1133                 if(!p) p = strchr(file,'>');
1134                 *p = '\0';
1135                 include_files = g_list_prepend(include_files,g_strdup(file));
1136                 g_free(str);
1137         }
1138         REJECT;
1139 }
1140         YY_BREAK
1141 case 5:
1142 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
1143 yy_c_buf_p = yy_cp -= 1;
1144 YY_DO_BEFORE_ACTION; /* set up yytext again */
1145 YY_RULE_SETUP
1146 #line 142 "lexer.l"
1147 {
1148                         /* eat out gtk doc stuff */
1149                         BEGIN(GTK_DOC_BEFORE_NAME);
1150                         clear_cbuf();
1151                 }
1152         YY_BREAK
1153 case 6:
1154 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
1155 yy_c_buf_p = yy_cp -= 1;
1156 YY_DO_BEFORE_ACTION; /* set up yytext again */
1157 YY_RULE_SETUP
1158 #line 147 "lexer.l"
1159 {
1160                         /* empty doc lines */
1161                         ;
1162                 }       
1163         YY_BREAK
1164 case 7:
1165 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
1166 yy_c_buf_p = yy_cp -= 1;
1167 YY_DO_BEFORE_ACTION; /* set up yytext again */
1168 YY_RULE_SETUP
1169 #line 151 "lexer.l"
1170 {
1171                         char *p;
1172                         BEGIN(GTK_DOC);
1173                         p = strchr(yytext, '*');
1174                         g_free(gtk_doc_func);
1175                         gtk_doc_func = g_strdup(p+2);
1176                         p = strchr(gtk_doc_func, ':');
1177                         if(p) *p='\0';
1178                         g_strstrip(gtk_doc_func);
1179                 }
1180         YY_BREAK
1181 case 8:
1182 YY_RULE_SETUP
1183 #line 161 "lexer.l"
1184 {
1185                         BEGIN(CLASS_CODE_I);
1186                 }
1187         YY_BREAK
1188 case 9:
1189 YY_RULE_SETUP
1190 #line 164 "lexer.l"
1191 {
1192                         BEGIN(COMMENT);
1193                         before_comment = CLASS_CODE_I;
1194                 }
1195         YY_BREAK
1196 case 10:
1197 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
1198 yy_c_buf_p = yy_cp -= 1;
1199 YY_DO_BEFORE_ACTION; /* set up yytext again */
1200 YY_RULE_SETUP
1201 #line 168 "lexer.l"
1202 {
1203                         /* empty doc lines */
1204                         add_to_cbuf(" *\n");
1205                 }       
1206         YY_BREAK
1207 case 11:
1208 YY_RULE_SETUP
1209 #line 172 "lexer.l"
1210 {
1211                         BEGIN(CLASS_CODE_I);
1212                         add_gtk_doc_func();
1213                 }
1214         YY_BREAK
1215 case 12:
1216 YY_RULE_SETUP
1217 #line 176 "lexer.l"
1218 {
1219                         fflush(stdout);
1220                         add_to_cbuf(" * ");
1221                         BEGIN(GTK_DOC_LINE);
1222                 }
1223         YY_BREAK
1224 case 13:
1225 YY_RULE_SETUP
1226 #line 181 "lexer.l"
1227 {
1228                         BEGIN(CLASS_CODE_I);
1229                 }
1230         YY_BREAK
1231 case 14:
1232 YY_RULE_SETUP
1233 #line 184 "lexer.l"
1234 {
1235                         BEGIN(COMMENT);
1236                         before_comment = CLASS_CODE_I;
1237                 }
1238         YY_BREAK
1239 case 15:
1240 YY_RULE_SETUP
1241 #line 188 "lexer.l"
1242 {
1243                         BEGIN(CLASS_CODE_I);
1244                         add_to_cbuf("\n");
1245                         add_gtk_doc_func();
1246                 }
1247         YY_BREAK
1248 case 16:
1249 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
1250 yy_c_buf_p = yy_cp -= 1;
1251 YY_DO_BEFORE_ACTION; /* set up yytext again */
1252 YY_RULE_SETUP
1253 #line 193 "lexer.l"
1254 {
1255                         BEGIN(GTK_DOC);
1256                         add_to_cbuf(yytext);
1257                         add_to_cbuf("\n");
1258                 }
1259         YY_BREAK
1260 case 17:
1261 YY_RULE_SETUP
1262 #line 198 "lexer.l"
1263 {
1264                         fflush(stdout);
1265                         add_to_cbuf(yytext);
1266                 }
1267         YY_BREAK
1268 case 18:
1269 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
1270 yy_c_buf_p = yy_cp -= 1;
1271 YY_DO_BEFORE_ACTION; /* set up yytext again */
1272 YY_RULE_SETUP
1273 #line 203 "lexer.l"
1274 { add_to_cbuf(yytext); /*comment, ignore*/ }
1275         YY_BREAK
1276 case 19:
1277 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
1278 yy_c_buf_p = yy_cp -= 1;
1279 YY_DO_BEFORE_ACTION; /* set up yytext again */
1280 YY_RULE_SETUP
1281 #line 204 "lexer.l"
1282 { ; /*comment, ignore*/ }
1283         YY_BREAK
1284 case 20:
1285 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
1286 yy_c_buf_p = yy_cp -= 1;
1287 YY_DO_BEFORE_ACTION; /* set up yytext again */
1288 YY_RULE_SETUP
1289 #line 205 "lexer.l"
1290 { ; /*comment, ignore*/ }
1291         YY_BREAK
1292 case 21:
1293 YY_RULE_SETUP
1294 #line 206 "lexer.l"
1295 {BEGIN(COMMENT); before_comment = INITIAL; }
1296         YY_BREAK
1297 case 22:
1298 YY_RULE_SETUP
1299 #line 207 "lexer.l"
1300 {
1301         add_to_cbuf(yytext);
1302         BEGIN(COMMENT);
1303         before_comment = C_CODE;
1304 }
1305         YY_BREAK
1306 case 23:
1307 YY_RULE_SETUP
1308 #line 212 "lexer.l"
1309 {BEGIN(COMMENT); before_comment = CLASS_CODE; }
1310         YY_BREAK
1311 case 24:
1312 YY_RULE_SETUP
1313 #line 213 "lexer.l"
1314 {BEGIN(COMMENT); before_comment = CLASS_CODE_I; }
1315         YY_BREAK
1316 case 25:
1317 YY_RULE_SETUP
1318 #line 214 "lexer.l"
1319 {
1320         if(before_comment == C_CODE) add_to_cbuf(yytext);
1321         BEGIN(before_comment);
1322                 }
1323         YY_BREAK
1324 case 26:
1325 YY_RULE_SETUP
1326 #line 218 "lexer.l"
1327 {
1328         /* comment, ignore */
1329         if(before_comment == C_CODE) add_to_cbuf(yytext);
1330                 }
1331         YY_BREAK
1332 case 27:
1333 YY_RULE_SETUP
1334 #line 222 "lexer.l"
1335 {
1336         /* comment, ignore */
1337         if(before_comment == C_CODE) add_to_cbuf(yytext);
1338                 }
1339         YY_BREAK
1340 case 28:
1341 YY_RULE_SETUP
1342 #line 227 "lexer.l"
1343 {
1344                         BEGIN(C_CODE);
1345                         parenth_depth = 1;
1346                         class_after_c = FALSE;
1347                         code_type = ACODE;
1348                         clear_cbuf();
1349                         ccode_line = line_no;
1350                 }
1351         YY_BREAK
1352 case 29:
1353 YY_RULE_SETUP
1354 #line 235 "lexer.l"
1355 {
1356                         BEGIN(C_CODE);
1357                         parenth_depth = 1;
1358                         class_after_c = FALSE;
1359                         code_type = ATCODE;
1360                         clear_cbuf();
1361                         ccode_line = line_no;
1362                 }
1363         YY_BREAK
1364 case 30:
1365 YY_RULE_SETUP
1366 #line 244 "lexer.l"
1367 {
1368                         BEGIN(C_CODE);
1369                         parenth_depth = 1;
1370                         class_after_c = FALSE;
1371                         code_type = HTCODE;
1372                         clear_cbuf();
1373                         ccode_line = line_no;
1374                 }
1375         YY_BREAK
1376 case 31:
1377 YY_RULE_SETUP
1378 #line 252 "lexer.l"
1379 {
1380                         BEGIN(C_CODE);
1381                         parenth_depth = 1;
1382                         class_after_c = FALSE;
1383                         code_type = PHCODE;
1384                         clear_cbuf();
1385                         ccode_line = line_no;
1386                 }
1387         YY_BREAK
1388 case 32:
1389 YY_RULE_SETUP
1390 #line 260 "lexer.l"
1391 {
1392                         BEGIN(C_CODE);
1393                         parenth_depth = 1;
1394                         class_after_c = FALSE;
1395                         code_type = HCODE;
1396                         clear_cbuf();
1397                         ccode_line = line_no;
1398                 }
1399         YY_BREAK
1400 case 33:
1401 YY_RULE_SETUP
1402 #line 268 "lexer.l"
1403 {
1404                         BEGIN(C_CODE);
1405                         parenth_depth = 1;
1406                         class_after_c = FALSE;
1407                         code_type = CCODE;
1408                         clear_cbuf();
1409                         ccode_line = line_no;
1410                         if(look_for_includes==0)
1411                                 look_for_includes=1;
1412                 }
1413         YY_BREAK
1414 case 34:
1415 YY_RULE_SETUP
1416 #line 278 "lexer.l"
1417 {
1418                         BEGIN(INITIAL);
1419                         yylval.cbuf = cbuf;
1420                         cbuf = NULL;
1421                         if(look_for_includes==1)
1422                                 look_for_includes=0;
1423                         return code_type;
1424                 }
1425         YY_BREAK
1426 case 35:
1427 YY_RULE_SETUP
1428 #line 287 "lexer.l"
1429 { add_to_cbuf(yytext); }
1430         YY_BREAK
1431 case 36:
1432 YY_RULE_SETUP
1433 #line 288 "lexer.l"
1434 { add_to_cbuf(yytext); }
1435         YY_BREAK
1436 case 37:
1437 YY_RULE_SETUP
1438 #line 289 "lexer.l"
1439 { add_to_cbuf(yytext); }
1440         YY_BREAK
1441 case 38:
1442 YY_RULE_SETUP
1443 #line 290 "lexer.l"
1444 { add_to_cbuf(yytext); }
1445         YY_BREAK
1446 case 39:
1447 YY_RULE_SETUP
1448 #line 291 "lexer.l"
1449 { add_to_cbuf(yytext); }
1450         YY_BREAK
1451 case 40:
1452 YY_RULE_SETUP
1453 #line 292 "lexer.l"
1454 { add_to_cbuf(yytext); }
1455         YY_BREAK
1456 case 41:
1457 YY_RULE_SETUP
1458 #line 294 "lexer.l"
1459 { add_to_cbuf(yytext); }
1460         YY_BREAK
1461 case 42:
1462 YY_RULE_SETUP
1463 #line 295 "lexer.l"
1464 {
1465                         BEGIN(C_CODE_STRING);
1466                         add_to_cbuf(yytext);
1467                 }
1468         YY_BREAK
1469 case 43:
1470 YY_RULE_SETUP
1471 #line 299 "lexer.l"
1472 { add_to_cbuf(yytext); }
1473         YY_BREAK
1474 case 44:
1475 YY_RULE_SETUP
1476 #line 300 "lexer.l"
1477 {
1478                                 BEGIN(C_CODE);
1479                                 add_to_cbuf(yytext);
1480                         }
1481         YY_BREAK
1482 case 45:
1483 YY_RULE_SETUP
1484 #line 304 "lexer.l"
1485 { add_to_cbuf(yytext); }
1486         YY_BREAK
1487 case 46:
1488 YY_RULE_SETUP
1489 #line 305 "lexer.l"
1490 { add_to_cbuf(yytext); }
1491         YY_BREAK
1492 case 47:
1493 YY_RULE_SETUP
1494 #line 307 "lexer.l"
1495 {
1496                         parenth_depth++;
1497                         add_to_cbuf(yytext);
1498                 }
1499         YY_BREAK
1500 case 48:
1501 YY_RULE_SETUP
1502 #line 311 "lexer.l"
1503 {
1504                         parenth_depth--;
1505                         if(parenth_depth<0) {
1506                                 REJECT;
1507                         } else if(parenth_depth==0 && class_after_c) {
1508                                 BEGIN(CLASS_CODE_I);
1509                                 yylval.cbuf = cbuf;
1510                                 cbuf = NULL;
1511                                 return CCODE;
1512                         }
1513                         add_to_cbuf(yytext);
1514                 }
1515         YY_BREAK
1516 case 49:
1517 YY_RULE_SETUP
1518 #line 324 "lexer.l"
1519 { add_to_cbuf(yytext); }
1520         YY_BREAK
1521 case 50:
1522 YY_RULE_SETUP
1523 #line 325 "lexer.l"
1524 { add_to_cbuf(yytext); }
1525         YY_BREAK
1526 case 51:
1527 YY_RULE_SETUP
1528 #line 327 "lexer.l"
1529 {
1530                         static int found_classes = 0;
1531                         look_for_includes = 2;
1532                         BEGIN(CLASS_CODE);
1533
1534                         if(++found_classes > 1) {
1535                                 print_error(FALSE, 
1536                                             "Only one class per file allowed",
1537                                             line_no);
1538                         }
1539
1540                         return CLASS;
1541                 }
1542         YY_BREAK
1543 case 52:
1544 *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
1545 yy_c_buf_p = yy_cp -= 1;
1546 YY_DO_BEFORE_ACTION; /* set up yytext again */
1547 YY_RULE_SETUP
1548 #line 341 "lexer.l"
1549 {
1550                         int maj = 0,min = 0,pl = 0;
1551                         int rmaj = 0,rmin = 0,rpl = 0;
1552                         char *p;
1553                         
1554                         sscanf(VERSION,"%d.%d.%d",&rmaj,&rmin,&rpl);
1555                         p = strchr(yytext,'r');
1556                         g_assert(p); /* we MUST have found it */
1557                         sscanf(p,"requires %d.%d.%d",&maj,&min,&pl);
1558                         if(rmaj < maj ||
1559                            (rmaj == maj && rmin < min) ||
1560                            (rmaj == maj && rmin == min && rpl < pl)) {
1561                                 char *s;
1562                                 s = g_strdup_printf(
1563                                     "GOB version %d.%d.%d required "
1564                                     "(this is %s)\n"
1565                                     "To upgrade your gob, see: "
1566                                     "http://www.5z.com/jirka/gob.html",
1567                                     maj,min,pl,VERSION);
1568                                 print_error(FALSE, s, line_no);
1569                                 g_free(s);
1570                         }
1571                 }
1572         YY_BREAK
1573 case 53:
1574 YY_RULE_SETUP
1575 #line 365 "lexer.l"
1576 {
1577                         if(for_cpp) {
1578                                 char *s;
1579                                 s = g_strdup_printf("'%s' keyword should not "
1580                                                     "be used when generating "
1581                                                     "C++ code", yytext);
1582                                 print_error(TRUE, s, line_no);
1583                                 g_free(s);
1584                         }
1585                         REJECT;
1586                 }
1587         YY_BREAK
1588 case 54:
1589 YY_RULE_SETUP
1590 #line 377 "lexer.l"
1591 {return FROM;}
1592         YY_BREAK
1593 case 55:
1594 YY_RULE_SETUP
1595 #line 379 "lexer.l"
1596 {return VOID;}
1597         YY_BREAK
1598 case 56:
1599 YY_RULE_SETUP
1600 #line 380 "lexer.l"
1601 {return STRUCT;}
1602         YY_BREAK
1603 case 57:
1604 YY_RULE_SETUP
1605 #line 381 "lexer.l"
1606 {return UNION;}
1607         YY_BREAK
1608 case 58:
1609 YY_RULE_SETUP
1610 #line 382 "lexer.l"
1611 {return ENUM;}
1612         YY_BREAK
1613 case 59:
1614 YY_RULE_SETUP
1615 #line 383 "lexer.l"
1616 {return SIGNED;}
1617         YY_BREAK
1618 case 60:
1619 YY_RULE_SETUP
1620 #line 384 "lexer.l"
1621 {return UNSIGNED;}
1622         YY_BREAK
1623 case 61:
1624 YY_RULE_SETUP
1625 #line 385 "lexer.l"
1626 {return LONG;}
1627         YY_BREAK
1628 case 62:
1629 YY_RULE_SETUP
1630 #line 386 "lexer.l"
1631 {return SHORT;}
1632         YY_BREAK
1633 case 63:
1634 YY_RULE_SETUP
1635 #line 387 "lexer.l"
1636 {return INT;}
1637         YY_BREAK
1638 case 64:
1639 YY_RULE_SETUP
1640 #line 388 "lexer.l"
1641 {return FLOAT;}
1642         YY_BREAK
1643 case 65:
1644 YY_RULE_SETUP
1645 #line 389 "lexer.l"
1646 {return DOUBLE;}
1647         YY_BREAK
1648 case 66:
1649 YY_RULE_SETUP
1650 #line 390 "lexer.l"
1651 {return CHAR;}
1652         YY_BREAK
1653 case 67:
1654 YY_RULE_SETUP
1655 #line 391 "lexer.l"
1656 {return CONST;}
1657         YY_BREAK
1658 case 68:
1659 YY_RULE_SETUP
1660 #line 393 "lexer.l"
1661 {return THREEDOTS;}
1662         YY_BREAK
1663 case 69:
1664 YY_RULE_SETUP
1665 #line 395 "lexer.l"
1666 {yylval.line = line_no; return PUBLIC;}
1667         YY_BREAK
1668 case 70:
1669 YY_RULE_SETUP
1670 #line 396 "lexer.l"
1671 {yylval.line = line_no; return PRIVATE;}
1672         YY_BREAK
1673 case 71:
1674 YY_RULE_SETUP
1675 #line 397 "lexer.l"
1676 {yylval.line = line_no; return PROTECTED;}
1677         YY_BREAK
1678 case 72:
1679 YY_RULE_SETUP
1680 #line 398 "lexer.l"
1681 {yylval.line = line_no; return CLASSWIDE;}
1682         YY_BREAK
1683 case 73:
1684 YY_RULE_SETUP
1685 #line 399 "lexer.l"
1686 {yylval.line = line_no; return ARGUMENT;}
1687         YY_BREAK
1688 case 74:
1689 YY_RULE_SETUP
1690 #line 400 "lexer.l"
1691 {yylval.line = line_no; return VIRTUAL;}
1692         YY_BREAK
1693 case 75:
1694 YY_RULE_SETUP
1695 #line 401 "lexer.l"
1696 {yylval.line = line_no; return SIGNAL;}
1697         YY_BREAK
1698 case 76:
1699 YY_RULE_SETUP
1700 #line 402 "lexer.l"
1701 {yylval.line = line_no; return OVERRIDE;}
1702         YY_BREAK
1703 case 77:
1704 YY_RULE_SETUP
1705 #line 403 "lexer.l"
1706 {
1707                         yylval.id = g_strdup(yytext);
1708                         return NUMBER;
1709                 }
1710         YY_BREAK
1711 case 78:
1712 YY_RULE_SETUP
1713 #line 407 "lexer.l"
1714 {
1715                         /* this one is for a classname with a namespace */
1716                         yylval.id = g_strdup(yytext);
1717                         return TYPETOKEN;
1718                 }
1719         YY_BREAK
1720 case 79:
1721 YY_RULE_SETUP
1722 #line 412 "lexer.l"
1723 {
1724                         /* this is for a classname with an empty namespace */
1725                         yylval.id = g_strdup(yytext);
1726                         return TYPETOKEN;
1727                 }
1728         YY_BREAK
1729 case 80:
1730 YY_RULE_SETUP
1731 #line 417 "lexer.l"
1732 {
1733                         yylval.id = g_strdup(yytext);
1734                         return TOKEN;
1735                 }
1736         YY_BREAK
1737 case 81:
1738 YY_RULE_SETUP
1739 #line 422 "lexer.l"
1740 {
1741                         yylval.id = g_strdup(yytext);
1742                         return ARRAY_DIM;
1743                 }
1744         YY_BREAK
1745 case 82:
1746 YY_RULE_SETUP
1747 #line 427 "lexer.l"
1748 {
1749                         BEGIN(CLASS_CODE_I);
1750                         return '{';
1751                 }
1752         YY_BREAK
1753 case 83:
1754 YY_RULE_SETUP
1755 #line 431 "lexer.l"
1756 {
1757                         BEGIN(C_CODE);
1758                         parenth_depth=1;
1759                         class_after_c = TRUE;
1760                         yylval.line = line_no;
1761                         clear_cbuf();
1762                         ccode_line = line_no;
1763                         return '{';
1764                 }
1765         YY_BREAK
1766 case 84:
1767 YY_RULE_SETUP
1768 #line 440 "lexer.l"
1769 {
1770                                 BEGIN(INITIAL);
1771                                 return '}';
1772                         }
1773         YY_BREAK
1774 case 85:
1775 YY_RULE_SETUP
1776 #line 445 "lexer.l"
1777 ;  /*ignore*/
1778         YY_BREAK
1779 case 86:
1780 YY_RULE_SETUP
1781 #line 447 "lexer.l"
1782 {
1783                         yylval.line = line_no;
1784                         return yytext[0];
1785                 }
1786         YY_BREAK
1787 case 87:
1788 YY_RULE_SETUP
1789 #line 452 "lexer.l"
1790 ;  /*ignore*/
1791         YY_BREAK
1792 case 88:
1793 YY_RULE_SETUP
1794 #line 453 "lexer.l"
1795 ECHO;
1796         YY_BREAK
1797 #line 1798 "lex.yy.c"
1798                         case YY_STATE_EOF(INITIAL):
1799                         case YY_STATE_EOF(COMMENT):
1800                         case YY_STATE_EOF(C_CODE):
1801                         case YY_STATE_EOF(C_CODE_STRING):
1802                         case YY_STATE_EOF(CLASS_CODE):
1803                         case YY_STATE_EOF(CLASS_CODE_I):
1804                         case YY_STATE_EOF(GTK_DOC_BEFORE_NAME):
1805                         case YY_STATE_EOF(GTK_DOC):
1806                         case YY_STATE_EOF(GTK_DOC_LINE):
1807                                 yyterminate();
1808
1809         case YY_END_OF_BUFFER:
1810                 {
1811                 /* Amount of text matched not including the EOB char. */
1812                 int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1;
1813
1814                 /* Undo the effects of YY_DO_BEFORE_ACTION. */
1815                 *yy_cp = yy_hold_char;
1816                 YY_RESTORE_YY_MORE_OFFSET
1817
1818                 if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW )
1819                         {
1820                         /* We're scanning a new file or input source.  It's
1821                          * possible that this happened because the user
1822                          * just pointed yyin at a new source and called
1823                          * yylex().  If so, then we have to assure
1824                          * consistency between yy_current_buffer and our
1825                          * globals.  Here is the right place to do so, because
1826                          * this is the first action (other than possibly a
1827                          * back-up) that will match for the new input source.
1828                          */
1829                         yy_n_chars = yy_current_buffer->yy_n_chars;
1830                         yy_current_buffer->yy_input_file = yyin;
1831                         yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL;
1832                         }
1833
1834                 /* Note that here we test for yy_c_buf_p "<=" to the position
1835                  * of the first EOB in the buffer, since yy_c_buf_p will
1836                  * already have been incremented past the NUL character
1837                  * (since all states make transitions on EOB to the
1838                  * end-of-buffer state).  Contrast this with the test
1839                  * in input().
1840                  */
1841                 if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
1842                         { /* This was really a NUL. */
1843                         yy_state_type yy_next_state;
1844
1845                         yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text;
1846
1847                         yy_current_state = yy_get_previous_state();
1848
1849                         /* Okay, we're now positioned to make the NUL
1850                          * transition.  We couldn't have
1851                          * yy_get_previous_state() go ahead and do it
1852                          * for us because it doesn't know how to deal
1853                          * with the possibility of jamming (and we don't
1854                          * want to build jamming into it because then it
1855                          * will run more slowly).
1856                          */
1857
1858                         yy_next_state = yy_try_NUL_trans( yy_current_state );
1859
1860                         yy_bp = yytext_ptr + YY_MORE_ADJ;
1861
1862                         if ( yy_next_state )
1863                                 {
1864                                 /* Consume the NUL. */
1865                                 yy_cp = ++yy_c_buf_p;
1866                                 yy_current_state = yy_next_state;
1867                                 goto yy_match;
1868                                 }
1869
1870                         else
1871                                 {
1872                                 yy_cp = yy_c_buf_p;
1873                                 goto yy_find_action;
1874                                 }
1875                         }
1876
1877                 else switch ( yy_get_next_buffer() )
1878                         {
1879                         case EOB_ACT_END_OF_FILE:
1880                                 {
1881                                 yy_did_buffer_switch_on_eof = 0;
1882
1883                                 if ( yywrap() )
1884                                         {
1885                                         /* Note: because we've taken care in
1886                                          * yy_get_next_buffer() to have set up
1887                                          * yytext, we can now set up
1888                                          * yy_c_buf_p so that if some total
1889                                          * hoser (like flex itself) wants to
1890                                          * call the scanner after we return the
1891                                          * YY_NULL, it'll still work - another
1892                                          * YY_NULL will get returned.
1893                                          */
1894                                         yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
1895
1896                                         yy_act = YY_STATE_EOF(YY_START);
1897                                         goto do_action;
1898                                         }
1899
1900                                 else
1901                                         {
1902                                         if ( ! yy_did_buffer_switch_on_eof )
1903                                                 YY_NEW_FILE;
1904                                         }
1905                                 break;
1906                                 }
1907
1908                         case EOB_ACT_CONTINUE_SCAN:
1909                                 yy_c_buf_p =
1910                                         yytext_ptr + yy_amount_of_matched_text;
1911
1912                                 yy_current_state = yy_get_previous_state();
1913
1914                                 yy_cp = yy_c_buf_p;
1915                                 yy_bp = yytext_ptr + YY_MORE_ADJ;
1916                                 goto yy_match;
1917
1918                         case EOB_ACT_LAST_MATCH:
1919                                 yy_c_buf_p =
1920                                 &yy_current_buffer->yy_ch_buf[yy_n_chars];
1921
1922                                 yy_current_state = yy_get_previous_state();
1923
1924                                 yy_cp = yy_c_buf_p;
1925                                 yy_bp = yytext_ptr + YY_MORE_ADJ;
1926                                 goto yy_find_action;
1927                         }
1928                 break;
1929                 }
1930
1931         default:
1932                 YY_FATAL_ERROR(
1933                         "fatal flex scanner internal error--no action found" );
1934         } /* end of action switch */
1935                 } /* end of scanning one token */
1936         } /* end of yylex */
1937
1938
1939 /* yy_get_next_buffer - try to read in a new buffer
1940  *
1941  * Returns a code representing an action:
1942  *      EOB_ACT_LAST_MATCH -
1943  *      EOB_ACT_CONTINUE_SCAN - continue scanning from current position
1944  *      EOB_ACT_END_OF_FILE - end of file
1945  */
1946
1947 static int yy_get_next_buffer()
1948         {
1949         register char *dest = yy_current_buffer->yy_ch_buf;
1950         register char *source = yytext_ptr;
1951         register int number_to_move, i;
1952         int ret_val;
1953
1954         if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
1955                 YY_FATAL_ERROR(
1956                 "fatal flex scanner internal error--end of buffer missed" );
1957
1958         if ( yy_current_buffer->yy_fill_buffer == 0 )
1959                 { /* Don't try to fill the buffer, so this is an EOF. */
1960                 if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 )
1961                         {
1962                         /* We matched a single character, the EOB, so
1963                          * treat this as a final EOF.
1964                          */
1965                         return EOB_ACT_END_OF_FILE;
1966                         }
1967
1968                 else
1969                         {
1970                         /* We matched some text prior to the EOB, first
1971                          * process it.
1972                          */
1973                         return EOB_ACT_LAST_MATCH;
1974                         }
1975                 }
1976
1977         /* Try to read more data. */
1978
1979         /* First move last chars to start of buffer. */
1980         number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1;
1981
1982         for ( i = 0; i < number_to_move; ++i )
1983                 *(dest++) = *(source++);
1984
1985         if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING )
1986                 /* don't do the read, it's not guaranteed to return an EOF,
1987                  * just force an EOF
1988                  */
1989                 yy_current_buffer->yy_n_chars = yy_n_chars = 0;
1990
1991         else
1992                 {
1993                 int num_to_read =
1994                         yy_current_buffer->yy_buf_size - number_to_move - 1;
1995
1996                 while ( num_to_read <= 0 )
1997                         { /* Not enough room in the buffer - grow it. */
1998 #ifdef YY_USES_REJECT
1999                         YY_FATAL_ERROR(
2000 "input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
2001 #else
2002
2003                         /* just a shorter name for the current buffer */
2004                         YY_BUFFER_STATE b = yy_current_buffer;
2005
2006                         int yy_c_buf_p_offset =
2007                                 (int) (yy_c_buf_p - b->yy_ch_buf);
2008
2009                         if ( b->yy_is_our_buffer )
2010                                 {
2011                                 int new_size = b->yy_buf_size * 2;
2012
2013                                 if ( new_size <= 0 )
2014                                         b->yy_buf_size += b->yy_buf_size / 8;
2015                                 else
2016                                         b->yy_buf_size *= 2;
2017
2018                                 b->yy_ch_buf = (char *)
2019                                         /* Include room in for 2 EOB chars. */
2020                                         yy_flex_realloc( (void *) b->yy_ch_buf,
2021                                                          b->yy_buf_size + 2 );
2022                                 }
2023                         else
2024                                 /* Can't grow it, we don't own it. */
2025                                 b->yy_ch_buf = 0;
2026
2027                         if ( ! b->yy_ch_buf )
2028                                 YY_FATAL_ERROR(
2029                                 "fatal error - scanner input buffer overflow" );
2030
2031                         yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
2032
2033                         num_to_read = yy_current_buffer->yy_buf_size -
2034                                                 number_to_move - 1;
2035 #endif
2036                         }
2037
2038                 if ( num_to_read > YY_READ_BUF_SIZE )
2039                         num_to_read = YY_READ_BUF_SIZE;
2040
2041                 /* Read in more data. */
2042                 YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
2043                         yy_n_chars, num_to_read );
2044
2045                 yy_current_buffer->yy_n_chars = yy_n_chars;
2046                 }
2047
2048         if ( yy_n_chars == 0 )
2049                 {
2050                 if ( number_to_move == YY_MORE_ADJ )
2051                         {
2052                         ret_val = EOB_ACT_END_OF_FILE;
2053                         yyrestart( yyin );
2054                         }
2055
2056                 else
2057                         {
2058                         ret_val = EOB_ACT_LAST_MATCH;
2059                         yy_current_buffer->yy_buffer_status =
2060                                 YY_BUFFER_EOF_PENDING;
2061                         }
2062                 }
2063
2064         else
2065                 ret_val = EOB_ACT_CONTINUE_SCAN;
2066
2067         yy_n_chars += number_to_move;
2068         yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
2069         yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
2070
2071         yytext_ptr = &yy_current_buffer->yy_ch_buf[0];
2072
2073         return ret_val;
2074         }
2075
2076
2077 /* yy_get_previous_state - get the state just before the EOB char was reached */
2078
2079 static yy_state_type yy_get_previous_state()
2080         {
2081         register yy_state_type yy_current_state;
2082         register char *yy_cp;
2083
2084         yy_current_state = yy_start;
2085         yy_current_state += YY_AT_BOL();
2086         yy_state_ptr = yy_state_buf;
2087         *yy_state_ptr++ = yy_current_state;
2088
2089         for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
2090                 {
2091                 register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
2092                 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
2093                         {
2094                         yy_current_state = (int) yy_def[yy_current_state];
2095                         if ( yy_current_state >= 357 )
2096                                 yy_c = yy_meta[(unsigned int) yy_c];
2097                         }
2098                 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
2099                 *yy_state_ptr++ = yy_current_state;
2100                 }
2101
2102         return yy_current_state;
2103         }
2104
2105
2106 /* yy_try_NUL_trans - try to make a transition on the NUL character
2107  *
2108  * synopsis
2109  *      next_state = yy_try_NUL_trans( current_state );
2110  */
2111
2112 #ifdef YY_USE_PROTOS
2113 static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state )
2114 #else
2115 static yy_state_type yy_try_NUL_trans( yy_current_state )
2116 yy_state_type yy_current_state;
2117 #endif
2118         {
2119         register int yy_is_jam;
2120
2121         register YY_CHAR yy_c = 1;
2122         while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
2123                 {
2124                 yy_current_state = (int) yy_def[yy_current_state];
2125                 if ( yy_current_state >= 357 )
2126                         yy_c = yy_meta[(unsigned int) yy_c];
2127                 }
2128         yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
2129         yy_is_jam = (yy_current_state == 356);
2130         if ( ! yy_is_jam )
2131                 *yy_state_ptr++ = yy_current_state;
2132
2133         return yy_is_jam ? 0 : yy_current_state;
2134         }
2135
2136
2137 #ifndef YY_NO_UNPUT
2138 #ifdef YY_USE_PROTOS
2139 static void yyunput( int c, register char *yy_bp )
2140 #else
2141 static void yyunput( c, yy_bp )
2142 int c;
2143 register char *yy_bp;
2144 #endif
2145         {
2146         register char *yy_cp = yy_c_buf_p;
2147
2148         /* undo effects of setting up yytext */
2149         *yy_cp = yy_hold_char;
2150
2151         if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
2152                 { /* need to shift things up to make room */
2153                 /* +2 for EOB chars. */
2154                 register int number_to_move = yy_n_chars + 2;
2155                 register char *dest = &yy_current_buffer->yy_ch_buf[
2156                                         yy_current_buffer->yy_buf_size + 2];
2157                 register char *source =
2158                                 &yy_current_buffer->yy_ch_buf[number_to_move];
2159
2160                 while ( source > yy_current_buffer->yy_ch_buf )
2161                         *--dest = *--source;
2162
2163                 yy_cp += (int) (dest - source);
2164                 yy_bp += (int) (dest - source);
2165                 yy_current_buffer->yy_n_chars =
2166                         yy_n_chars = yy_current_buffer->yy_buf_size;
2167
2168                 if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
2169                         YY_FATAL_ERROR( "flex scanner push-back overflow" );
2170                 }
2171
2172         *--yy_cp = (char) c;
2173
2174
2175         yytext_ptr = yy_bp;
2176         yy_hold_char = *yy_cp;
2177         yy_c_buf_p = yy_cp;
2178         }
2179 #endif  /* ifndef YY_NO_UNPUT */
2180
2181
2182 #ifdef __cplusplus
2183 static int yyinput()
2184 #else
2185 static int input()
2186 #endif
2187         {
2188         int c;
2189
2190         *yy_c_buf_p = yy_hold_char;
2191
2192         if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
2193                 {
2194                 /* yy_c_buf_p now points to the character we want to return.
2195                  * If this occurs *before* the EOB characters, then it's a
2196                  * valid NUL; if not, then we've hit the end of the buffer.
2197                  */
2198                 if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
2199                         /* This was really a NUL. */
2200                         *yy_c_buf_p = '\0';
2201
2202                 else
2203                         { /* need more input */
2204                         int offset = yy_c_buf_p - yytext_ptr;
2205                         ++yy_c_buf_p;
2206
2207                         switch ( yy_get_next_buffer() )
2208                                 {
2209                                 case EOB_ACT_LAST_MATCH:
2210                                         /* This happens because yy_g_n_b()
2211                                          * sees that we've accumulated a
2212                                          * token and flags that we need to
2213                                          * try matching the token before
2214                                          * proceeding.  But for input(),
2215                                          * there's no matching to consider.
2216                                          * So convert the EOB_ACT_LAST_MATCH
2217                                          * to EOB_ACT_END_OF_FILE.
2218                                          */
2219
2220                                         /* Reset buffer status. */
2221                                         yyrestart( yyin );
2222
2223                                         /* fall through */
2224
2225                                 case EOB_ACT_END_OF_FILE:
2226                                         {
2227                                         if ( yywrap() )
2228                                                 return EOF;
2229
2230                                         if ( ! yy_did_buffer_switch_on_eof )
2231                                                 YY_NEW_FILE;
2232 #ifdef __cplusplus
2233                                         return yyinput();
2234 #else
2235                                         return input();
2236 #endif
2237                                         }
2238
2239                                 case EOB_ACT_CONTINUE_SCAN:
2240                                         yy_c_buf_p = yytext_ptr + offset;
2241                                         break;
2242                                 }
2243                         }
2244                 }
2245
2246         c = *(unsigned char *) yy_c_buf_p;      /* cast for 8-bit char's */
2247         *yy_c_buf_p = '\0';     /* preserve yytext */
2248         yy_hold_char = *++yy_c_buf_p;
2249
2250         yy_current_buffer->yy_at_bol = (c == '\n');
2251
2252         return c;
2253         }
2254
2255
2256 #ifdef YY_USE_PROTOS
2257 void yyrestart( FILE *input_file )
2258 #else
2259 void yyrestart( input_file )
2260 FILE *input_file;
2261 #endif
2262         {
2263         if ( ! yy_current_buffer )
2264                 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );
2265
2266         yy_init_buffer( yy_current_buffer, input_file );
2267         yy_load_buffer_state();
2268         }
2269
2270
2271 #ifdef YY_USE_PROTOS
2272 void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
2273 #else
2274 void yy_switch_to_buffer( new_buffer )
2275 YY_BUFFER_STATE new_buffer;
2276 #endif
2277         {
2278         if ( yy_current_buffer == new_buffer )
2279                 return;
2280
2281         if ( yy_current_buffer )
2282                 {
2283                 /* Flush out information for old buffer. */
2284                 *yy_c_buf_p = yy_hold_char;
2285                 yy_current_buffer->yy_buf_pos = yy_c_buf_p;
2286                 yy_current_buffer->yy_n_chars = yy_n_chars;
2287                 }
2288
2289         yy_current_buffer = new_buffer;
2290         yy_load_buffer_state();
2291
2292         /* We don't actually know whether we did this switch during
2293          * EOF (yywrap()) processing, but the only time this flag
2294          * is looked at is after yywrap() is called, so it's safe
2295          * to go ahead and always set it.
2296          */
2297         yy_did_buffer_switch_on_eof = 1;
2298         }
2299
2300
2301 #ifdef YY_USE_PROTOS
2302 void yy_load_buffer_state( void )
2303 #else
2304 void yy_load_buffer_state()
2305 #endif
2306         {
2307         yy_n_chars = yy_current_buffer->yy_n_chars;
2308         yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
2309         yyin = yy_current_buffer->yy_input_file;
2310         yy_hold_char = *yy_c_buf_p;
2311         }
2312
2313
2314 #ifdef YY_USE_PROTOS
2315 YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
2316 #else
2317 YY_BUFFER_STATE yy_create_buffer( file, size )
2318 FILE *file;
2319 int size;
2320 #endif
2321         {
2322         YY_BUFFER_STATE b;
2323
2324         b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
2325         if ( ! b )
2326                 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
2327
2328         b->yy_buf_size = size;
2329
2330         /* yy_ch_buf has to be 2 characters longer than the size given because
2331          * we need to put in 2 end-of-buffer characters.
2332          */
2333         b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 );
2334         if ( ! b->yy_ch_buf )
2335                 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
2336
2337         b->yy_is_our_buffer = 1;
2338
2339         yy_init_buffer( b, file );
2340
2341         return b;
2342         }
2343
2344
2345 #ifdef YY_USE_PROTOS
2346 void yy_delete_buffer( YY_BUFFER_STATE b )
2347 #else
2348 void yy_delete_buffer( b )
2349 YY_BUFFER_STATE b;
2350 #endif
2351         {
2352         if ( ! b )
2353                 return;
2354
2355         if ( b == yy_current_buffer )
2356                 yy_current_buffer = (YY_BUFFER_STATE) 0;
2357
2358         if ( b->yy_is_our_buffer )
2359                 yy_flex_free( (void *) b->yy_ch_buf );
2360
2361         yy_flex_free( (void *) b );
2362         }
2363
2364
2365 #ifndef YY_ALWAYS_INTERACTIVE
2366 #ifndef YY_NEVER_INTERACTIVE
2367 extern int isatty YY_PROTO(( int ));
2368 #endif
2369 #endif
2370
2371 #ifdef YY_USE_PROTOS
2372 void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
2373 #else
2374 void yy_init_buffer( b, file )
2375 YY_BUFFER_STATE b;
2376 FILE *file;
2377 #endif
2378
2379
2380         {
2381         yy_flush_buffer( b );
2382
2383         b->yy_input_file = file;
2384         b->yy_fill_buffer = 1;
2385
2386 #if YY_ALWAYS_INTERACTIVE
2387         b->yy_is_interactive = 1;
2388 #else
2389 #if YY_NEVER_INTERACTIVE
2390         b->yy_is_interactive = 0;
2391 #else
2392         b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
2393 #endif
2394 #endif
2395         }
2396
2397
2398 #ifdef YY_USE_PROTOS
2399 void yy_flush_buffer( YY_BUFFER_STATE b )
2400 #else
2401 void yy_flush_buffer( b )
2402 YY_BUFFER_STATE b;
2403 #endif
2404
2405         {
2406         if ( ! b )
2407                 return;
2408
2409         b->yy_n_chars = 0;
2410
2411         /* We always need two end-of-buffer characters.  The first causes
2412          * a transition to the end-of-buffer state.  The second causes
2413          * a jam in that state.
2414          */
2415         b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
2416         b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
2417
2418         b->yy_buf_pos = &b->yy_ch_buf[0];
2419
2420         b->yy_at_bol = 1;
2421         b->yy_buffer_status = YY_BUFFER_NEW;
2422
2423         if ( b == yy_current_buffer )
2424                 yy_load_buffer_state();
2425         }
2426
2427
2428 #ifndef YY_NO_SCAN_BUFFER
2429 #ifdef YY_USE_PROTOS
2430 YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size )
2431 #else
2432 YY_BUFFER_STATE yy_scan_buffer( base, size )
2433 char *base;
2434 yy_size_t size;
2435 #endif
2436         {
2437         YY_BUFFER_STATE b;
2438
2439         if ( size < 2 ||
2440              base[size-2] != YY_END_OF_BUFFER_CHAR ||
2441              base[size-1] != YY_END_OF_BUFFER_CHAR )
2442                 /* They forgot to leave room for the EOB's. */
2443                 return 0;
2444
2445         b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
2446         if ( ! b )
2447                 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
2448
2449         b->yy_buf_size = size - 2;      /* "- 2" to take care of EOB's */
2450         b->yy_buf_pos = b->yy_ch_buf = base;
2451         b->yy_is_our_buffer = 0;
2452         b->yy_input_file = 0;
2453         b->yy_n_chars = b->yy_buf_size;
2454         b->yy_is_interactive = 0;
2455         b->yy_at_bol = 1;
2456         b->yy_fill_buffer = 0;
2457         b->yy_buffer_status = YY_BUFFER_NEW;
2458
2459         yy_switch_to_buffer( b );
2460
2461         return b;
2462         }
2463 #endif
2464
2465
2466 #ifndef YY_NO_SCAN_STRING
2467 #ifdef YY_USE_PROTOS
2468 YY_BUFFER_STATE yy_scan_string( yyconst char *yy_str )
2469 #else
2470 YY_BUFFER_STATE yy_scan_string( yy_str )
2471 yyconst char *yy_str;
2472 #endif
2473         {
2474         int len;
2475         for ( len = 0; yy_str[len]; ++len )
2476                 ;
2477
2478         return yy_scan_bytes( yy_str, len );
2479         }
2480 #endif
2481
2482
2483 #ifndef YY_NO_SCAN_BYTES
2484 #ifdef YY_USE_PROTOS
2485 YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len )
2486 #else
2487 YY_BUFFER_STATE yy_scan_bytes( bytes, len )
2488 yyconst char *bytes;
2489 int len;
2490 #endif
2491         {
2492         YY_BUFFER_STATE b;
2493         char *buf;
2494         yy_size_t n;
2495         int i;
2496
2497         /* Get memory for full buffer, including space for trailing EOB's. */
2498         n = len + 2;
2499         buf = (char *) yy_flex_alloc( n );
2500         if ( ! buf )
2501                 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
2502
2503         for ( i = 0; i < len; ++i )
2504                 buf[i] = bytes[i];
2505
2506         buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR;
2507
2508         b = yy_scan_buffer( buf, n );
2509         if ( ! b )
2510                 YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
2511
2512         /* It's okay to grow etc. this buffer, and we should throw it
2513          * away when we're done.
2514          */
2515         b->yy_is_our_buffer = 1;
2516
2517         return b;
2518         }
2519 #endif
2520
2521
2522 #ifndef YY_NO_PUSH_STATE
2523 #ifdef YY_USE_PROTOS
2524 static void yy_push_state( int new_state )
2525 #else
2526 static void yy_push_state( new_state )
2527 int new_state;
2528 #endif
2529         {
2530         if ( yy_start_stack_ptr >= yy_start_stack_depth )
2531                 {
2532                 yy_size_t new_size;
2533
2534                 yy_start_stack_depth += YY_START_STACK_INCR;
2535                 new_size = yy_start_stack_depth * sizeof( int );
2536
2537                 if ( ! yy_start_stack )
2538                         yy_start_stack = (int *) yy_flex_alloc( new_size );
2539
2540                 else
2541                         yy_start_stack = (int *) yy_flex_realloc(
2542                                         (void *) yy_start_stack, new_size );
2543
2544                 if ( ! yy_start_stack )
2545                         YY_FATAL_ERROR(
2546                         "out of memory expanding start-condition stack" );
2547                 }
2548
2549         yy_start_stack[yy_start_stack_ptr++] = YY_START;
2550
2551         BEGIN(new_state);
2552         }
2553 #endif
2554
2555
2556 #ifndef YY_NO_POP_STATE
2557 static void yy_pop_state()
2558         {
2559         if ( --yy_start_stack_ptr < 0 )
2560                 YY_FATAL_ERROR( "start-condition stack underflow" );
2561
2562         BEGIN(yy_start_stack[yy_start_stack_ptr]);
2563         }
2564 #endif
2565
2566
2567 #ifndef YY_NO_TOP_STATE
2568 static int yy_top_state()
2569         {
2570         return yy_start_stack[yy_start_stack_ptr - 1];
2571         }
2572 #endif
2573
2574 #ifndef YY_EXIT_FAILURE
2575 #define YY_EXIT_FAILURE 2
2576 #endif
2577
2578 #ifdef YY_USE_PROTOS
2579 static void yy_fatal_error( yyconst char msg[] )
2580 #else
2581 static void yy_fatal_error( msg )
2582 char msg[];
2583 #endif
2584         {
2585         (void) fprintf( stderr, "%s\n", msg );
2586         exit( YY_EXIT_FAILURE );
2587         }
2588
2589
2590
2591 /* Redefine yyless() so it works in section 3 code. */
2592
2593 #undef yyless
2594 #define yyless(n) \
2595         do \
2596                 { \
2597                 /* Undo effects of setting up yytext. */ \
2598                 yytext[yyleng] = yy_hold_char; \
2599                 yy_c_buf_p = yytext + n; \
2600                 yy_hold_char = *yy_c_buf_p; \
2601                 *yy_c_buf_p = '\0'; \
2602                 yyleng = n; \
2603                 } \
2604         while ( 0 )
2605
2606
2607 /* Internal utility routines. */
2608
2609 #ifndef yytext_ptr
2610 #ifdef YY_USE_PROTOS
2611 static void yy_flex_strncpy( char *s1, yyconst char *s2, int n )
2612 #else
2613 static void yy_flex_strncpy( s1, s2, n )
2614 char *s1;
2615 yyconst char *s2;
2616 int n;
2617 #endif
2618         {
2619         register int i;
2620         for ( i = 0; i < n; ++i )
2621                 s1[i] = s2[i];
2622         }
2623 #endif
2624
2625 #ifdef YY_NEED_STRLEN
2626 #ifdef YY_USE_PROTOS
2627 static int yy_flex_strlen( yyconst char *s )
2628 #else
2629 static int yy_flex_strlen( s )
2630 yyconst char *s;
2631 #endif
2632         {
2633         register int n;
2634         for ( n = 0; s[n]; ++n )
2635                 ;
2636
2637         return n;
2638         }
2639 #endif
2640
2641
2642 #ifdef YY_USE_PROTOS
2643 static void *yy_flex_alloc( yy_size_t size )
2644 #else
2645 static void *yy_flex_alloc( size )
2646 yy_size_t size;
2647 #endif
2648         {
2649         return (void *) malloc( size );
2650         }
2651
2652 #ifdef YY_USE_PROTOS
2653 static void *yy_flex_realloc( void *ptr, yy_size_t size )
2654 #else
2655 static void *yy_flex_realloc( ptr, size )
2656 void *ptr;
2657 yy_size_t size;
2658 #endif
2659         {
2660         /* The cast to (char *) in the following accommodates both
2661          * implementations that use char* generic pointers, and those
2662          * that use void* generic pointers.  It works with the latter
2663          * because both ANSI C and C++ allow castless assignment from
2664          * any pointer type to void*, and deal with argument conversions
2665          * as though doing an assignment.
2666          */
2667         return (void *) realloc( (char *) ptr, size );
2668         }
2669
2670 #ifdef YY_USE_PROTOS
2671 static void yy_flex_free( void *ptr )
2672 #else
2673 static void yy_flex_free( ptr )
2674 void *ptr;
2675 #endif
2676         {
2677         free( ptr );
2678         }
2679
2680 #if YY_MAIN
2681 int main()
2682         {
2683         yylex();
2684         return 0;
2685         }
2686 #endif
2687 #line 453 "lexer.l"