Fix parsing of floating point numbers
[com/gs-lite.git] / src / ftacmp / ftalexer.cc
1 #line 2 "ftalexer.cc"
2
3 #line 4 "ftalexer.cc"
4
5 #define  YY_INT_ALIGNED short int
6
7 /* A lexical scanner generated by flex */
8
9 #define yy_create_buffer FtaParser_create_buffer
10 #define yy_delete_buffer FtaParser_delete_buffer
11 #define yy_flex_debug FtaParser_flex_debug
12 #define yy_init_buffer FtaParser_init_buffer
13 #define yy_flush_buffer FtaParser_flush_buffer
14 #define yy_load_buffer_state FtaParser_load_buffer_state
15 #define yy_switch_to_buffer FtaParser_switch_to_buffer
16 #define yyin FtaParserin
17 #define yyleng FtaParserleng
18 #define yylex FtaParserlex
19 #define yylineno FtaParserlineno
20 #define yyout FtaParserout
21 #define yyrestart FtaParserrestart
22 #define yytext FtaParsertext
23 #define yywrap FtaParserwrap
24 #define yyalloc FtaParseralloc
25 #define yyrealloc FtaParserrealloc
26 #define yyfree FtaParserfree
27
28 #define FLEX_SCANNER
29 #define YY_FLEX_MAJOR_VERSION 2
30 #define YY_FLEX_MINOR_VERSION 6
31 #define YY_FLEX_SUBMINOR_VERSION 0
32 #if YY_FLEX_SUBMINOR_VERSION > 0
33 #define FLEX_BETA
34 #endif
35
36 /* First, we deal with  platform-specific or compiler-specific issues. */
37
38 /* begin standard C headers. */
39 #include <stdio.h>
40 #include <string.h>
41 #include <errno.h>
42 #include <stdlib.h>
43
44 /* end standard C headers. */
45
46 /* flex integer type definitions */
47
48 #ifndef FLEXINT_H
49 #define FLEXINT_H
50
51 /* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
52
53 #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
54
55 /* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
56  * if you want the limit (max/min) macros for int types. 
57  */
58 #ifndef __STDC_LIMIT_MACROS
59 #define __STDC_LIMIT_MACROS 1
60 #endif
61
62 #include <inttypes.h>
63 typedef int8_t flex_int8_t;
64 typedef uint8_t flex_uint8_t;
65 typedef int16_t flex_int16_t;
66 typedef uint16_t flex_uint16_t;
67 typedef int32_t flex_int32_t;
68 typedef uint32_t flex_uint32_t;
69 #else
70 typedef signed char flex_int8_t;
71 typedef short int flex_int16_t;
72 typedef int flex_int32_t;
73 typedef unsigned char flex_uint8_t; 
74 typedef unsigned short int flex_uint16_t;
75 typedef unsigned int flex_uint32_t;
76
77 /* Limits of integral types. */
78 #ifndef INT8_MIN
79 #define INT8_MIN               (-128)
80 #endif
81 #ifndef INT16_MIN
82 #define INT16_MIN              (-32767-1)
83 #endif
84 #ifndef INT32_MIN
85 #define INT32_MIN              (-2147483647-1)
86 #endif
87 #ifndef INT8_MAX
88 #define INT8_MAX               (127)
89 #endif
90 #ifndef INT16_MAX
91 #define INT16_MAX              (32767)
92 #endif
93 #ifndef INT32_MAX
94 #define INT32_MAX              (2147483647)
95 #endif
96 #ifndef UINT8_MAX
97 #define UINT8_MAX              (255U)
98 #endif
99 #ifndef UINT16_MAX
100 #define UINT16_MAX             (65535U)
101 #endif
102 #ifndef UINT32_MAX
103 #define UINT32_MAX             (4294967295U)
104 #endif
105
106 #endif /* ! C99 */
107
108 #endif /* ! FLEXINT_H */
109
110 #ifdef __cplusplus
111
112 /* The "const" storage-class-modifier is valid. */
113 #define YY_USE_CONST
114
115 #else   /* ! __cplusplus */
116
117 /* C99 requires __STDC__ to be defined as 1. */
118 #if defined (__STDC__)
119
120 #define YY_USE_CONST
121
122 #endif  /* defined (__STDC__) */
123 #endif  /* ! __cplusplus */
124
125 #ifdef YY_USE_CONST
126 #define yyconst const
127 #else
128 #define yyconst
129 #endif
130
131 /* Returned upon end-of-file. */
132 #define YY_NULL 0
133
134 /* Promotes a possibly negative, possibly signed char to an unsigned
135  * integer for use as an array index.  If the signed char is negative,
136  * we want to instead treat it as an 8-bit unsigned char, hence the
137  * double cast.
138  */
139 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
140
141 /* Enter a start condition.  This macro really ought to take a parameter,
142  * but we do it the disgusting crufty way forced on us by the ()-less
143  * definition of BEGIN.
144  */
145 #define BEGIN (yy_start) = 1 + 2 *
146
147 /* Translate the current start state into a value that can be later handed
148  * to BEGIN to return to the state.  The YYSTATE alias is for lex
149  * compatibility.
150  */
151 #define YY_START (((yy_start) - 1) / 2)
152 #define YYSTATE YY_START
153
154 /* Action number for EOF rule of a given start state. */
155 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
156
157 /* Special action meaning "start processing a new file". */
158 #define YY_NEW_FILE FtaParserrestart(FtaParserin  )
159
160 #define YY_END_OF_BUFFER_CHAR 0
161
162 /* Size of default input buffer. */
163 #ifndef YY_BUF_SIZE
164 #ifdef __ia64__
165 /* On IA-64, the buffer size is 16k, not 8k.
166  * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
167  * Ditto for the __ia64__ case accordingly.
168  */
169 #define YY_BUF_SIZE 32768
170 #else
171 #define YY_BUF_SIZE 16384
172 #endif /* __ia64__ */
173 #endif
174
175 /* The state buf must be large enough to hold one state per character in the main buffer.
176  */
177 #define YY_STATE_BUF_SIZE   ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
178
179 #ifndef YY_TYPEDEF_YY_BUFFER_STATE
180 #define YY_TYPEDEF_YY_BUFFER_STATE
181 typedef struct yy_buffer_state *YY_BUFFER_STATE;
182 #endif
183
184 #ifndef YY_TYPEDEF_YY_SIZE_T
185 #define YY_TYPEDEF_YY_SIZE_T
186 typedef size_t yy_size_t;
187 #endif
188
189 extern yy_size_t FtaParserleng;
190
191 extern FILE *FtaParserin, *FtaParserout;
192
193 #define EOB_ACT_CONTINUE_SCAN 0
194 #define EOB_ACT_END_OF_FILE 1
195 #define EOB_ACT_LAST_MATCH 2
196
197     #define YY_LESS_LINENO(n)
198     #define YY_LINENO_REWIND_TO(ptr)
199     
200 /* Return all but the first "n" matched characters back to the input stream. */
201 #define yyless(n) \
202         do \
203                 { \
204                 /* Undo effects of setting up FtaParsertext. */ \
205         int yyless_macro_arg = (n); \
206         YY_LESS_LINENO(yyless_macro_arg);\
207                 *yy_cp = (yy_hold_char); \
208                 YY_RESTORE_YY_MORE_OFFSET \
209                 (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
210                 YY_DO_BEFORE_ACTION; /* set up FtaParsertext again */ \
211                 } \
212         while ( 0 )
213
214 #define unput(c) yyunput( c, (yytext_ptr)  )
215
216 #ifndef YY_STRUCT_YY_BUFFER_STATE
217 #define YY_STRUCT_YY_BUFFER_STATE
218 struct yy_buffer_state
219         {
220         FILE *yy_input_file;
221
222         char *yy_ch_buf;                /* input buffer */
223         char *yy_buf_pos;               /* current position in input buffer */
224
225         /* Size of input buffer in bytes, not including room for EOB
226          * characters.
227          */
228         yy_size_t yy_buf_size;
229
230         /* Number of characters read into yy_ch_buf, not including EOB
231          * characters.
232          */
233         int yy_n_chars;
234
235         /* Whether we "own" the buffer - i.e., we know we created it,
236          * and can realloc() it to grow it, and should free() it to
237          * delete it.
238          */
239         int yy_is_our_buffer;
240
241         /* Whether this is an "interactive" input source; if so, and
242          * if we're using stdio for input, then we want to use getc()
243          * instead of fread(), to make sure we stop fetching input after
244          * each newline.
245          */
246         int yy_is_interactive;
247
248         /* Whether we're considered to be at the beginning of a line.
249          * If so, '^' rules will be active on the next match, otherwise
250          * not.
251          */
252         int yy_at_bol;
253
254     int yy_bs_lineno; /**< The line count. */
255     int yy_bs_column; /**< The column count. */
256     
257         /* Whether to try to fill the input buffer when we reach the
258          * end of it.
259          */
260         int yy_fill_buffer;
261
262         int yy_buffer_status;
263
264 #define YY_BUFFER_NEW 0
265 #define YY_BUFFER_NORMAL 1
266         /* When an EOF's been seen but there's still some text to process
267          * then we mark the buffer as YY_EOF_PENDING, to indicate that we
268          * shouldn't try reading from the input source any more.  We might
269          * still have a bunch of tokens to match, though, because of
270          * possible backing-up.
271          *
272          * When we actually see the EOF, we change the status to "new"
273          * (via FtaParserrestart()), so that the user can continue scanning by
274          * just pointing FtaParserin at a new input file.
275          */
276 #define YY_BUFFER_EOF_PENDING 2
277
278         };
279 #endif /* !YY_STRUCT_YY_BUFFER_STATE */
280
281 /* Stack of input buffers. */
282 static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */
283 static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */
284 static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */
285
286 /* We provide macros for accessing buffer states in case in the
287  * future we want to put the buffer states in a more general
288  * "scanner state".
289  *
290  * Returns the top of the stack, or NULL.
291  */
292 #define YY_CURRENT_BUFFER ( (yy_buffer_stack) \
293                           ? (yy_buffer_stack)[(yy_buffer_stack_top)] \
294                           : NULL)
295
296 /* Same as previous macro, but useful when we know that the buffer stack is not
297  * NULL or when we need an lvalue. For internal use only.
298  */
299 #define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)]
300
301 /* yy_hold_char holds the character lost when FtaParsertext is formed. */
302 static char yy_hold_char;
303 static int yy_n_chars;          /* number of characters read into yy_ch_buf */
304 yy_size_t FtaParserleng;
305
306 /* Points to current character in buffer. */
307 static char *yy_c_buf_p = (char *) 0;
308 static int yy_init = 0;         /* whether we need to initialize */
309 static int yy_start = 0;        /* start state number */
310
311 /* Flag which is used to allow FtaParserwrap()'s to do buffer switches
312  * instead of setting up a fresh FtaParserin.  A bit of a hack ...
313  */
314 static int yy_did_buffer_switch_on_eof;
315
316 void FtaParserrestart (FILE *input_file  );
317 void FtaParser_switch_to_buffer (YY_BUFFER_STATE new_buffer  );
318 YY_BUFFER_STATE FtaParser_create_buffer (FILE *file,int size  );
319 void FtaParser_delete_buffer (YY_BUFFER_STATE b  );
320 void FtaParser_flush_buffer (YY_BUFFER_STATE b  );
321 void FtaParserpush_buffer_state (YY_BUFFER_STATE new_buffer  );
322 void FtaParserpop_buffer_state (void );
323
324 static void FtaParserensure_buffer_stack (void );
325 static void FtaParser_load_buffer_state (void );
326 static void FtaParser_init_buffer (YY_BUFFER_STATE b,FILE *file  );
327
328 #define YY_FLUSH_BUFFER FtaParser_flush_buffer(YY_CURRENT_BUFFER )
329
330 YY_BUFFER_STATE FtaParser_scan_buffer (char *base,yy_size_t size  );
331 YY_BUFFER_STATE FtaParser_scan_string (yyconst char *yy_str  );
332 YY_BUFFER_STATE FtaParser_scan_bytes (yyconst char *bytes,yy_size_t len  );
333
334 void *FtaParseralloc (yy_size_t  );
335 void *FtaParserrealloc (void *,yy_size_t  );
336 void FtaParserfree (void *  );
337
338 #define yy_new_buffer FtaParser_create_buffer
339
340 #define yy_set_interactive(is_interactive) \
341         { \
342         if ( ! YY_CURRENT_BUFFER ){ \
343         FtaParserensure_buffer_stack (); \
344                 YY_CURRENT_BUFFER_LVALUE =    \
345             FtaParser_create_buffer(FtaParserin,YY_BUF_SIZE ); \
346         } \
347         YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
348         }
349
350 #define yy_set_bol(at_bol) \
351         { \
352         if ( ! YY_CURRENT_BUFFER ){\
353         FtaParserensure_buffer_stack (); \
354                 YY_CURRENT_BUFFER_LVALUE =    \
355             FtaParser_create_buffer(FtaParserin,YY_BUF_SIZE ); \
356         } \
357         YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
358         }
359
360 #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
361
362 /* Begin user sect3 */
363
364 #define FtaParserwrap() (/*CONSTCOND*/1)
365 #define YY_SKIP_YYWRAP
366
367 typedef unsigned char YY_CHAR;
368
369 FILE *FtaParserin = (FILE *) 0, *FtaParserout = (FILE *) 0;
370
371 typedef int yy_state_type;
372
373 extern int FtaParserlineno;
374
375 int FtaParserlineno = 1;
376
377 extern char *FtaParsertext;
378 #ifdef yytext_ptr
379 #undef yytext_ptr
380 #endif
381 #define yytext_ptr FtaParsertext
382
383 static yy_state_type yy_get_previous_state (void );
384 static yy_state_type yy_try_NUL_trans (yy_state_type current_state  );
385 static int yy_get_next_buffer (void );
386 #if defined(__GNUC__) && __GNUC__ >= 3
387 __attribute__((__noreturn__))
388 #endif
389 static void yy_fatal_error (yyconst char msg[]  );
390
391 /* Done after the current pattern has been matched and before the
392  * corresponding action - sets up FtaParsertext.
393  */
394 #define YY_DO_BEFORE_ACTION \
395         (yytext_ptr) = yy_bp; \
396         (yytext_ptr) -= (yy_more_len); \
397         FtaParserleng = (size_t) (yy_cp - (yytext_ptr)); \
398         (yy_hold_char) = *yy_cp; \
399         *yy_cp = '\0'; \
400         (yy_c_buf_p) = yy_cp;
401
402 #define YY_NUM_RULES 87
403 #define YY_END_OF_BUFFER 88
404 /* This struct is not used in this scanner,
405    but its presence is necessary. */
406 struct yy_trans_info
407         {
408         flex_int32_t yy_verify;
409         flex_int32_t yy_nxt;
410         };
411 static yyconst flex_int16_t yy_accept[692] =
412     {   0,
413         0,    0,   88,   86,   83,   82,   68,   86,   69,   68,
414        68,   72,   59,   64,   62,   65,   71,   71,   71,   71,
415        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
416        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
417        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
418        71,   71,   47,   48,   70,   83,   82,    0,   81,   80,
419         0,   76,    0,   75,   72,    0,    0,   60,   66,   63,
420        67,   61,   71,   71,   27,   71,   71,   71,   10,   71,
421        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
422        71,   71,   71,   71,   71,   71,   71,   28,   71,   28,
423
424        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
425        71,   71,   30,   71,   30,   71,   71,   71,   71,   71,
426        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
427        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
428        71,   71,   71,   71,   71,   71,   71,   71,   71,   28,
429        71,   71,   71,   71,   71,   30,   71,   71,   71,   71,
430        71,   71,   71,   71,   71,    0,   84,    0,    0,   85,
431        75,    0,    0,   77,   73,    1,    5,    1,   71,   71,
432        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
433        71,   52,   71,   71,   71,   71,   71,   41,   71,   71,
434
435        71,   71,   71,   71,   71,   71,   71,    7,   71,    6,
436        71,   29,   71,   71,   71,   71,   71,   71,   71,   71,
437        71,   71,   71,   71,   71,   71,   71,   71,    8,   71,
438        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
439        71,   71,   71,   71,   71,    1,   71,   71,   71,   71,
440        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
441        71,   71,   71,   71,   71,   71,   71,   71,    0,   79,
442         0,   78,   74,   71,   71,   71,   71,   71,   20,   71,
443        71,   71,   71,   71,   71,   71,   11,   71,   71,   71,
444        71,   71,   71,   71,   71,   71,   71,   71,   42,   71,
445
446        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
447        71,   71,   71,   71,   71,   71,   71,   33,   71,   71,
448        71,   71,   34,   71,   38,   71,   71,   71,   71,   71,
449        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
450        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
451        71,   71,   71,   71,   71,    9,   71,   71,   71,   39,
452        71,   71,   71,   18,   18,   71,   71,   71,   71,   71,
453        71,   71,   71,   71,   35,   71,   71,   71,   71,   71,
454        46,   71,   71,   71,   71,   71,   71,   36,   71,   71,
455        71,   71,   71,   49,   71,   71,   71,   32,   71,   71,
456
457        71,   71,   71,   71,   71,   18,   71,   71,   71,   71,
458        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
459        71,   71,   71,   45,   56,   71,   71,   71,   71,   26,
460        71,   71,   43,   71,   71,   71,   71,   71,   71,   71,
461        71,   71,   71,   71,   19,   71,   31,   51,   71,   71,
462        31,   71,   71,   71,   71,   71,   71,   71,   71,   71,
463        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
464        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
465        71,   71,   71,   71,   71,   71,   71,   71,    3,   71,
466        71,   71,   71,   71,   71,   71,   71,   71,   40,   71,
467
468        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
469        71,   71,   71,   71,   71,   71,    2,   71,   71,   71,
470        71,   71,   71,   71,   71,   71,   44,   71,   71,   71,
471        54,   71,   71,   50,   71,   71,   71,   71,   71,   71,
472        71,   71,   71,    4,   71,   71,   71,   71,   71,   71,
473        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
474        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
475        71,   71,   71,   71,   71,   71,   37,   37,   71,   71,
476        71,   71,   71,   71,   71,   71,   71,   37,   71,   71,
477        71,   71,   71,   71,   71,   71,   71,   71,   12,   71,
478
479        71,   71,   13,   71,   71,   71,   57,   22,   71,   71,
480        71,   71,   71,   71,   71,   71,   71,   71,   71,   24,
481        71,   71,   71,   71,   17,   71,   71,   71,   71,   71,
482        71,   71,   71,   53,   71,   71,   71,   71,   71,   71,
483        71,   71,   71,   25,   71,   71,   71,   71,   71,   71,
484        71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
485        23,   21,   71,   71,   55,   71,   71,   71,   71,   71,
486        71,   71,   71,   71,   71,   71,   71,   71,   16,   71,
487        71,   15,   71,   71,   71,   71,   14,   71,   71,   58,
488         0
489
490     } ;
491
492 static yyconst YY_CHAR yy_ec[256] =
493     {   0,
494         1,    1,    1,    1,    1,    1,    1,    1,    2,    3,
495         1,    1,    2,    1,    1,    1,    1,    1,    1,    1,
496         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
497         1,    2,    4,    1,    4,    4,    4,    4,    5,    4,
498         4,    4,    6,    4,    7,    8,    9,   10,   10,   10,
499        10,   10,   10,   11,   10,   10,   10,    4,   12,   13,
500        14,   15,    1,    4,   16,   17,   18,   19,   20,   21,
501        22,   23,   24,   25,   26,   27,   28,   29,   30,   31,
502        32,   33,   34,   35,   36,   37,   38,   39,   40,   41,
503         4,    1,    4,    1,   42,    1,   43,   44,   45,   46,
504
505        47,   48,   49,   50,   51,   52,   41,   53,   54,   55,
506        56,   57,   41,   58,   59,   60,   61,   62,   63,   64,
507        65,   41,   66,    4,   67,   68,    1,    1,    1,    1,
508         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
509         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
510         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
511         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
512         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
513         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
514         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
515
516         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
517         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
518         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
519         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
520         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
521         1,    1,    1,    1,    1
522     } ;
523
524 static yyconst YY_CHAR yy_meta[69] =
525     {   0,
526         1,    1,    2,    1,    1,    1,    1,    1,    1,    3,
527         3,    1,    1,    1,    1,    3,    3,    3,    3,    3,
528         3,    3,    3,    3,    3,    3,    3,    3,    3,    3,
529         3,    3,    3,    3,    3,    3,    3,    3,    3,    3,
530         3,    3,    3,    3,    3,    3,    3,    3,    3,    3,
531         3,    3,    3,    3,    3,    3,    3,    3,    3,    3,
532         3,    3,    3,    3,    3,    1,    1,    1
533     } ;
534
535 static yyconst flex_uint16_t yy_base[697] =
536     {   0,
537         0,    0,  814,  815,  811,    0,  815,   66,  805,   62,
538       802,   66,  815,   65,  815,   67,   55,   30,   63,  790,
539         0,   72,   42,   78,   54,   81,  102,   73,   75,   99,
540       101,  107,  123,  780,  121,   82,   96,  743,  106,   90,
541       749,  763,  750,  757,  118,  747,  102,   84,  119,  752,
542       127,  745,  815,  815,  815,  798,    0,  169,  815,  815,
543       796,  165,  795,  168,  173,  180,  770,  815,  815,  815,
544       815,  815,    0,  777,    0,  773,  748,  744,    0,   67,
545       756,  774,  142,  729,  745,  767,  760,  172,  756,  769,
546       731,  727,  752,  725,  743,  740,  716,  748,  159,  721,
547
548       754,  754,  725,  733,  738,  741,  705,  710,  712,  731,
549       705,  744,  721,  727,  719,  700,  726,  728,  735,  729,
550       706,  701,  726,  736,  718,  177,  697,  157,  732,  732,
551       719,  710,  702,  713,  708,  722,  681,  693,  706,  680,
552       691,  687,  150,  674,  690,  680,  676,  675,  668,  674,
553       680,  663,  668,  670,  664,  681,  662,  672,  667,  666,
554       159,  675,  657,  669,  657,  711,  815,  212,  710,  815,
555       214,  220,  218,  222,  685,  669,    0,  668,  693,  674,
556       678,  686,  662,  645,  648,  655,  677,  666,  672,  663,
557       669,    0,  636,  641,  658,  632,  668,    0,  640,  670,
558
559       678,  651,  676,  639,  650,  645,  623,    0,  660,    0,
560       632,    0,  647,  663,  658,  661,  629,  659,  639,  650,
561       645,  621,  617,  649,  650,  647,  634,  642,    0,  644,
562       616,  612,  614,  633,  624,  638,  637,  596,  639,  636,
563       620,  607,  593,  608,  607,  606,  604,  587,  590,  597,
564       583,  588,  580,  589,  592,  578,  588,  593,  588,  584,
565       580,  585,  581,  583,  569,  583,  569,  584,  225,  227,
566       229,  231,  815,  609,  608,  594,  598,  586,    0,  565,
567       568,  558,  588,  596,  596,  594,    0,  566,  581,  554,
568       581,  554,  575,  565,  590,  563,  546,  561,    0,  560,
569
570       581,  553,  583,  576,  564,  547,  537,  566,  563,  557,
571       555,  530,  528,  570,  561,  570,  549,    0,  551,  538,
572       524,  561,    0,  543,    0,  561,  555,  557,  526,  528,
573       558,  557,  529,  516,  519,  509,  521,  510,  511,  507,
574       522,  516,  513,  503,  500,  498,  513,  499,  506,  508,
575       511,  531,  503,  527,  521,    0,  498,  493,  527,    0,
576       512,  512,  486,  519,  491,  519,  491,  497,  501,  510,
577       499,  493,  504,  503,    0,  497,  509,  488,  480,  486,
578         0,  509,  484,  494,  482,  466,  487,    0,  493,  500,
579       497,  458,  468,    0,  500,  489,  487,    0,  460,  490,
580
581       462,  461,  458,  453,  449,  455,  456,  462,  447,  453,
582       459,  458,  442,  438,  448,  443,  446,  472,  444,  463,
583       469,  435,  440,    0,    0,  446,  445,  457,  430,    0,
584       459,  467,    0,  466,  456,  444,  418,  448,  444,  451,
585       417,  449,  443,  442,    0,  441,  446,    0,  436,  435,
586         0,  409,  439,  423,  440,  412,  440,  412,  411,  404,
587       409,  415,  401,  403,  393,  395,  400,  395,  392,  398,
588       399,  414,  388,  423,  402,  394,  400,  416,  415,  417,
589       389,  407,  409,  408,  378,  398,  372,  398,    0,  400,
590       373,  401,  391,  365,  395,  400,  393,  366,    0,  400,
591
592       386,  360,  385,  359,  358,  366,  372,  361,  363,  355,
593       350,  353,  347,  351,  347,  347,    0,  362,  365,  360,
594       363,  370,  343,  356,  355,  372,    0,  344,  374,  346,
595       350,  367,  339,    0,  354,  328,  358,  366,  349,  323,
596       365,  347,  321,    0,  338,  316,  322,  335,  325,  328,
597       323,  313,  311,  311,  165,  347,  226,  319,  344,  316,
598       332,  331,  335,  308,  329,  303,  323,  330,  303,  337,
599       309,  313,  320,  322,  295,  322,  308,  307,  200,  298,
600       296,  287,  290,  286,  288,  295,  284,  298,  299,  315,
601       317,  271,  285,  287,  304,  277,  311,  283,    0,  287,
602
603       286,  303,    0,  293,  267,  293,    0,    0,  289,  297,
604       296,  255,  269,  271,  262,  269,   49,   62,   98,    0,
605       180,  178,  163,  162,    0,  210,  186,  222,  223,  229,
606       208,  209,  216,    0,  223,  198,  208,  201,  197,  206,
607       217,  204,  233,    0,  210,  232,  208,  238,  213,  232,
608       246,  247,  239,  250,  224,  221,  218,  222,  227,  229,
609         0,    0,  257,  231,    0,  253,  228,  262,  257,  232,
610       237,  233,  235,  262,  237,  269,  243,  276,    0,  241,
611       246,    0,  269,  244,  270,  246,    0,  264,  274,    0,
612       815,  303,  306,  302,  309,  312
613
614     } ;
615
616 static yyconst flex_int16_t yy_def[697] =
617     {   0,
618       691,    1,  691,  691,  691,  692,  691,  693,  691,  691,
619       691,  691,  691,  691,  691,  691,  694,  694,  694,  694,
620       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
621       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
622       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
623       694,  694,  691,  691,  691,  691,  692,  693,  691,  691,
624       695,  691,  696,  691,  691,  691,  691,  691,  691,  691,
625       691,  691,  694,  694,  694,  694,  694,  694,  694,  694,
626       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
627       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
628
629       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
630       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
631       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
632       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
633       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
634       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
635       694,  694,  694,  694,  694,  695,  691,  691,  696,  691,
636       691,  691,  691,  691,  691,  694,  694,  694,  694,  694,
637       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
638       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
639
640       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
641       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
642       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
643       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
644       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
645       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
646       694,  694,  694,  694,  694,  694,  694,  694,  691,  691,
647       691,  691,  691,  694,  694,  694,  694,  694,  694,  694,
648       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
649       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
650
651       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
652       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
653       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
654       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
655       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
656       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
657       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
658       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
659       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
660       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
661
662       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
663       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
664       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
665       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
666       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
667       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
668       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
669       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
670       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
671       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
672
673       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
674       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
675       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
676       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
677       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
678       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
679       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
680       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
681       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
682       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
683
684       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
685       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
686       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
687       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
688       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
689       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
690       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
691       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
692       694,  694,  694,  694,  694,  694,  694,  694,  694,  694,
693         0,  691,  691,  691,  691,  691
694
695     } ;
696
697 static yyconst flex_uint16_t yy_nxt[884] =
698     {   0,
699         4,    5,    6,    7,    8,    7,    9,   10,   11,   12,
700        12,   13,   14,   15,   16,   17,   18,   19,   20,   21,
701        22,   23,   24,   25,   21,   21,   26,   27,   28,   29,
702        30,   21,   31,   32,   33,   34,   21,   35,   36,   21,
703        21,   21,   37,   38,   39,   21,   21,   40,   41,   42,
704        43,   21,   44,   45,   46,   47,   21,   48,   49,   50,
705        21,   21,   51,   52,   21,   53,   54,   55,   59,   79,
706        60,   62,   62,   64,   93,   65,   65,   68,   69,   70,
707        71,   72,   98,   74,   99,   66,  179,   87,   75,   80,
708       640,   76,   81,   95,   79,   88,  180,   96,   82,   94,
709
710       101,   67,  110,  102,   89,  112,   90,  113,  100,   77,
711       114,  139,   66,   75,  117,   83,   78,  104,   84,  641,
712        97,  105,   91,   85,  119,  106,  123,  103,  111,   92,
713       120,  118,  115,  124,  158,  116,  135,  140,  129,  159,
714       146,  125,  126,  136,  107,  130,  131,  147,  108,  642,
715       141,  121,  109,  127,   75,  132,  122,  142,  143,  156,
716       152,  144,  157,  137,  153,  160,  145,  128,  154,  163,
717       138,   59,  133,   60,   62,   62,  164,  171,  171,  161,
718        64,  589,   65,   65,  168,  173,  173,  172,  183,  174,
719       174,  189,   66,  227,  228,  201,  247,  184,  190,  643,
720
721       202,  232,  590,  263,  229,  248,  644,  230,   67,  645,
722       229,  168,  229,  233,  172,  264,  644,  269,  269,   66,
723       203,  270,  270,  171,  171,  271,  271,  174,  174,  272,
724       272,  174,  174,  172,  270,  270,  270,  270,  272,  272,
725       272,  272,  592,  612,  646,  647,  648,  649,  650,  651,
726       652,  653,  654,  655,  656,  644,  657,  658,  659,  660,
727       172,  661,  613,  593,  661,  662,  662,  663,  664,  665,
728       666,  667,  668,  669,  670,  661,  662,  671,  672,  673,
729       674,  675,  676,  677,  678,  679,  679,  680,  681,  679,
730       682,  682,  683,  684,  685,  682,  686,  687,  687,  688,
731
732       687,  689,  690,   57,   73,   57,   58,   58,   58,  166,
733       166,  166,  169,  169,  169,  639,  625,  638,  637,  620,
734       636,  635,  634,  633,  632,  631,  630,  629,  628,  627,
735       626,  625,  625,  624,  623,  620,  622,  621,  620,  619,
736       608,  618,  603,  617,  599,  616,  615,  614,  611,  610,
737       609,  608,  608,  607,  606,  605,  604,  603,  603,  602,
738       601,  600,  599,  599,  598,  597,  596,  595,  594,  591,
739       588,  587,  586,  585,  584,  583,  582,  581,  580,  579,
740       578,  577,  576,  575,  574,  573,  572,  571,  570,  569,
741       568,  567,  566,  565,  564,  563,  562,  561,  560,  559,
742
743       558,  557,  556,  555,  544,  554,  553,  552,  551,  550,
744       549,  548,  547,  546,  545,  517,  544,  544,  543,  542,
745       541,  540,  539,  538,  537,  536,  535,  534,  533,  532,
746       531,  530,  529,  528,  527,  527,  526,  525,  524,  523,
747       522,  521,  520,  519,  518,  517,  517,  516,  515,  514,
748       513,  512,  489,  511,  510,  509,  508,  507,  506,  505,
749       504,  503,  502,  501,  500,  499,  498,  497,  496,  495,
750       494,  493,  492,  491,  489,  490,  489,  488,  487,  486,
751       485,  484,  483,  482,  481,  480,  479,  478,  477,  476,
752       475,  474,  473,  472,  471,  470,  469,  451,  445,  468,
753
754       467,  466,  465,  464,  430,  463,  462,  461,  460,  459,
755       458,  457,  456,  455,  454,  453,  452,  451,  450,  449,
756       448,  447,  445,  446,  445,  444,  443,  442,  441,  440,
757       439,  438,  437,  436,  435,  434,  433,  432,  431,  430,
758       430,  429,  428,  427,  426,  425,  424,  423,  422,  421,
759       420,  419,  418,  417,  398,  416,  415,  414,  413,  412,
760       411,  410,  375,  409,  408,  407,  406,  405,  356,  404,
761       403,  402,  401,  400,  398,  399,  398,  397,  396,  395,
762       394,  393,  392,  391,  390,  389,  388,  387,  386,  385,
763       384,  383,  382,  381,  380,  379,  378,  377,  376,  375,
764
765       375,  374,  373,  372,  371,  370,  369,  368,  367,  366,
766       365,  364,  363,  362,  361,  360,  359,  356,  358,  357,
767       356,  355,  354,  353,  352,  351,  350,  349,  323,  348,
768       318,  347,  346,  345,  344,  343,  342,  341,  340,  339,
769       338,  287,  337,  279,  336,  335,  334,  333,  332,  331,
770       330,  329,  328,  327,  326,  323,  325,  324,  323,  322,
771       321,  318,  320,  319,  318,  317,  316,  315,  314,  313,
772       312,  311,  310,  309,  308,  307,  306,  305,  304,  303,
773       302,  301,  300,  299,  298,  297,  296,  295,  294,  293,
774       292,  291,  290,  289,  287,  288,  287,  286,  285,  284,
775
776       283,  279,  282,  281,  280,  279,  278,  277,  276,  275,
777       274,  273,  170,  167,  268,  267,  266,  265,  262,  261,
778       260,  259,  258,  212,  210,  257,  208,  256,  255,  254,
779       253,  252,  251,  250,  249,  177,  246,  245,  244,  243,
780       242,  241,  240,  239,  238,  237,  236,  235,  234,  231,
781       226,  225,  224,  223,  222,  221,  220,  219,  218,  217,
782       216,  215,  214,  213,  212,  212,  210,  211,  208,  210,
783       209,  208,  207,  206,  205,  204,  200,  199,  198,  197,
784       196,  195,  194,  193,  192,  191,  188,  187,  186,  185,
785       182,  181,  177,  178,  177,  176,  175,  170,  167,   56,
786
787       165,  162,  155,  151,  150,  149,  148,   79,  134,   86,
788        63,   61,   56,  691,    3,  691,  691,  691,  691,  691,
789       691,  691,  691,  691,  691,  691,  691,  691,  691,  691,
790       691,  691,  691,  691,  691,  691,  691,  691,  691,  691,
791       691,  691,  691,  691,  691,  691,  691,  691,  691,  691,
792       691,  691,  691,  691,  691,  691,  691,  691,  691,  691,
793       691,  691,  691,  691,  691,  691,  691,  691,  691,  691,
794       691,  691,  691,  691,  691,  691,  691,  691,  691,  691,
795       691,  691,  691
796     } ;
797
798 static yyconst flex_int16_t yy_chk[884] =
799     {   0,
800         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
801         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
802         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
803         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
804         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
805         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
806         1,    1,    1,    1,    1,    1,    1,    1,    8,   18,
807         8,   10,   10,   12,   23,   12,   12,   14,   14,   14,
808        16,   16,   25,   17,   25,   12,   80,   22,   17,   19,
809       617,   17,   19,   24,   18,   22,   80,   24,   19,   23,
810
811        26,   12,   28,   26,   22,   29,   22,   29,   25,   17,
812        29,   36,   12,   17,   30,   19,   17,   27,   19,  618,
813        24,   27,   22,   19,   31,   27,   32,   26,   28,   22,
814        31,   30,   29,   32,   48,   29,   35,   36,   33,   48,
815        40,   32,   32,   35,   27,   33,   33,   40,   27,  619,
816        37,   31,   27,   32,   37,   33,   31,   37,   39,   47,
817        45,   39,   47,   35,   45,   49,   39,   32,   45,   51,
818        35,   58,   33,   58,   62,   62,   51,   64,   64,   49,
819        65,  555,   65,   65,   62,   66,   66,   64,   83,   66,
820        66,   88,   65,  126,  126,   99,  143,   83,   88,  621,
821
822        99,  128,  555,  161,  126,  143,  622,  126,   65,  623,
823       128,   62,  161,  128,   64,  161,  624,  168,  168,   65,
824        99,  168,  168,  171,  171,  172,  172,  173,  173,  172,
825       172,  174,  174,  171,  269,  269,  270,  270,  271,  271,
826       272,  272,  557,  579,  626,  627,  628,  629,  630,  631,
827       632,  633,  635,  636,  637,  638,  639,  640,  641,  642,
828       171,  643,  579,  557,  645,  646,  647,  648,  649,  650,
829       651,  652,  653,  654,  655,  656,  657,  658,  659,  660,
830       663,  664,  666,  667,  668,  669,  670,  671,  672,  673,
831       674,  675,  676,  677,  678,  680,  681,  683,  684,  685,
832
833       686,  688,  689,  692,  694,  692,  693,  693,  693,  695,
834       695,  695,  696,  696,  696,  616,  615,  614,  613,  612,
835       611,  610,  609,  606,  605,  604,  602,  601,  600,  598,
836       597,  596,  595,  594,  593,  592,  591,  590,  589,  588,
837       587,  586,  585,  584,  583,  582,  581,  580,  578,  577,
838       576,  575,  574,  573,  572,  571,  570,  569,  568,  567,
839       566,  565,  564,  563,  562,  561,  560,  559,  558,  556,
840       554,  553,  552,  551,  550,  549,  548,  547,  546,  545,
841       543,  542,  541,  540,  539,  538,  537,  536,  535,  533,
842       532,  531,  530,  529,  528,  526,  525,  524,  523,  522,
843
844       521,  520,  519,  518,  516,  515,  514,  513,  512,  511,
845       510,  509,  508,  507,  506,  505,  504,  503,  502,  501,
846       500,  498,  497,  496,  495,  494,  493,  492,  491,  490,
847       488,  487,  486,  485,  484,  483,  482,  481,  480,  479,
848       478,  477,  476,  475,  474,  473,  472,  471,  470,  469,
849       468,  467,  466,  465,  464,  463,  462,  461,  460,  459,
850       458,  457,  456,  455,  454,  453,  452,  450,  449,  447,
851       446,  444,  443,  442,  441,  440,  439,  438,  437,  436,
852       435,  434,  432,  431,  429,  428,  427,  426,  423,  422,
853       421,  420,  419,  418,  417,  416,  415,  414,  413,  412,
854
855       411,  410,  409,  408,  407,  406,  405,  404,  403,  402,
856       401,  400,  399,  397,  396,  395,  393,  392,  391,  390,
857       389,  387,  386,  385,  384,  383,  382,  380,  379,  378,
858       377,  376,  374,  373,  372,  371,  370,  369,  368,  367,
859       366,  365,  364,  363,  362,  361,  359,  358,  357,  355,
860       354,  353,  352,  351,  350,  349,  348,  347,  346,  345,
861       344,  343,  342,  341,  340,  339,  338,  337,  336,  335,
862       334,  333,  332,  331,  330,  329,  328,  327,  326,  324,
863       322,  321,  320,  319,  317,  316,  315,  314,  313,  312,
864       311,  310,  309,  308,  307,  306,  305,  304,  303,  302,
865
866       301,  300,  298,  297,  296,  295,  294,  293,  292,  291,
867       290,  289,  288,  286,  285,  284,  283,  282,  281,  280,
868       278,  277,  276,  275,  274,  268,  267,  266,  265,  264,
869       263,  262,  261,  260,  259,  258,  257,  256,  255,  254,
870       253,  252,  251,  250,  249,  248,  247,  246,  245,  244,
871       243,  242,  241,  240,  239,  238,  237,  236,  235,  234,
872       233,  232,  231,  230,  228,  227,  226,  225,  224,  223,
873       222,  221,  220,  219,  218,  217,  216,  215,  214,  213,
874       211,  209,  207,  206,  205,  204,  203,  202,  201,  200,
875       199,  197,  196,  195,  194,  193,  191,  190,  189,  188,
876
877       187,  186,  185,  184,  183,  182,  181,  180,  179,  178,
878       176,  175,  169,  166,  165,  164,  163,  162,  160,  159,
879       158,  157,  156,  155,  154,  153,  152,  151,  150,  149,
880       148,  147,  146,  145,  144,  142,  141,  140,  139,  138,
881       137,  136,  135,  134,  133,  132,  131,  130,  129,  127,
882       125,  124,  123,  122,  121,  120,  119,  118,  117,  116,
883       115,  114,  113,  112,  111,  110,  109,  108,  107,  106,
884       105,  104,  103,  102,  101,  100,   98,   97,   96,   95,
885        94,   93,   92,   91,   90,   89,   87,   86,   85,   84,
886        82,   81,   78,   77,   76,   74,   67,   63,   61,   56,
887
888        52,   50,   46,   44,   43,   42,   41,   38,   34,   20,
889        11,    9,    5,    3,  691,  691,  691,  691,  691,  691,
890       691,  691,  691,  691,  691,  691,  691,  691,  691,  691,
891       691,  691,  691,  691,  691,  691,  691,  691,  691,  691,
892       691,  691,  691,  691,  691,  691,  691,  691,  691,  691,
893       691,  691,  691,  691,  691,  691,  691,  691,  691,  691,
894       691,  691,  691,  691,  691,  691,  691,  691,  691,  691,
895       691,  691,  691,  691,  691,  691,  691,  691,  691,  691,
896       691,  691,  691
897     } ;
898
899 static yy_state_type yy_last_accepting_state;
900 static char *yy_last_accepting_cpos;
901
902 extern int FtaParser_flex_debug;
903 int FtaParser_flex_debug = 0;
904
905 /* The intent behind this definition is that it'll catch
906  * any uses of REJECT which flex missed.
907  */
908 #define REJECT reject_used_but_not_detected
909 static int yy_more_flag = 0;
910 static int yy_more_len = 0;
911 #define yymore() ((yy_more_flag) = 1)
912 #define YY_MORE_ADJ (yy_more_len)
913 #define YY_RESTORE_YY_MORE_OFFSET
914 char *FtaParsertext;
915 #line 1 "fta.l"
916 /* ------------------------------------------------
917 Copyright 2020 AT&T Intellectual Property
918    Licensed under the Apache License, Version 2.0 (the "License");
919    you may not use this file except in compliance with the License.
920    You may obtain a copy of the License at
921
922      http://www.apache.org/licenses/LICENSE-2.0
923
924    Unless required by applicable law or agreed to in writing, software
925    distributed under the License is distributed on an "AS IS" BASIS,
926    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
927    See the License for the specific language governing permissions and
928    limitations under the License.
929  ------------------------------------------- */
930 /*
931         MUST COMPILE WITH
932                 flex -PFtaParser -oftalexer.cc fta.l
933         (or equivalent).
934 */      
935 #line 24 "fta.l"
936 /*
937  * AT&T lex can't handle this lexer due to lex bugs.  It works with flex
938  * 2.3.7, pclex 2.0.5, and MKS lex 3.1a.
939  */
940
941  #include "parse_fta.h"
942  #include "parse_schema.h"
943  #include <string.h>
944
945
946
947 #include "fta.tab.cc.h"
948
949 /*
950         Some includes that flex doesn't include as standard,
951         but which are needed.
952 */
953
954 #include <stdlib.h>
955 #include <string.h>
956
957
958 //              Prevent flex from defining FtaParserwrap as extern "C" 
959
960 #define YY_SKIP_YYWRAP
961
962 /*              No lex lib, supply the FtaParserwrap fcn. that normally resides there
963 */
964
965 //int FtaParserwrap(){return(1);}
966
967 extern int FtaParserdebug;
968
969
970 /*
971                 These variables are used for error reporting:
972                 flex_fta_lineno : the line currently being parsed when the error occurs.
973                 flex_fta_ch : the character on the line where the error occurs
974                 flex_fta_linebuf : store the line for reporting.
975
976                 NOTE : 1) the fixed size flex_fta_linebuf buffer is dangerous.
977                            2) You might get pointed to a place shortly after
978                                   where the syntax error occurs.  It is close enough
979                                   for now.
980 */
981
982 int flex_fta_lineno = 1;
983 int flex_fta_ch = 0;
984 char flex_fta_linebuf[200000];
985
986 char *flex_fta_stringinput = NULL;
987 int flex_fta_stringinput_ptr = 0;
988 FILE *flex_fta_fileinput = NULL;
989 int my_FtaParser_yyinput(char *buf, int max_size);
990
991
992
993 void FtaParsererror(char *s){
994         int i;
995         fprintf(stderr,"On line %d, char %d: %s (token %s):\n%s\n",
996                                 flex_fta_lineno, flex_fta_ch, s, FtaParsertext, flex_fta_linebuf );
997     for(i=0;i<flex_fta_ch;i++){
998                 if(flex_fta_linebuf[i] == '\t'){
999                         fprintf(stderr,"\t");
1000                 }else{
1001                         fprintf(stderr," ");
1002                 }
1003         }
1004         fprintf(stderr,"^\n");
1005         //      fprintf(stderr,"%*s\n",1+flex_fta_ch,"^");
1006 }
1007
1008 #undef YY_INPUT
1009 #define YY_INPUT(b, r, ms) (r = my_FtaParser_yyinput(b,ms))
1010
1011 /* MKS needs the next line to increase the NFA table */
1012 #line 1013 "ftalexer.cc"
1013
1014 #define INITIAL 0
1015
1016 #ifndef YY_NO_UNISTD_H
1017 /* Special case for "unistd.h", since it is non-ANSI. We include it way
1018  * down here because we want the user's section 1 to have been scanned first.
1019  * The user has a chance to override it with an option.
1020  */
1021 #include <unistd.h>
1022 #endif
1023
1024 #ifndef YY_EXTRA_TYPE
1025 #define YY_EXTRA_TYPE void *
1026 #endif
1027
1028 static int yy_init_globals (void );
1029
1030 /* Accessor methods to globals.
1031    These are made visible to non-reentrant scanners for convenience. */
1032
1033 int FtaParserlex_destroy (void );
1034
1035 int FtaParserget_debug (void );
1036
1037 void FtaParserset_debug (int debug_flag  );
1038
1039 YY_EXTRA_TYPE FtaParserget_extra (void );
1040
1041 void FtaParserset_extra (YY_EXTRA_TYPE user_defined  );
1042
1043 FILE *FtaParserget_in (void );
1044
1045 void FtaParserset_in  (FILE * _in_str  );
1046
1047 FILE *FtaParserget_out (void );
1048
1049 void FtaParserset_out  (FILE * _out_str  );
1050
1051 yy_size_t FtaParserget_leng (void );
1052
1053 char *FtaParserget_text (void );
1054
1055 int FtaParserget_lineno (void );
1056
1057 void FtaParserset_lineno (int _line_number  );
1058
1059 /* Macros after this point can all be overridden by user definitions in
1060  * section 1.
1061  */
1062
1063 #ifndef YY_SKIP_YYWRAP
1064 #ifdef __cplusplus
1065 extern "C" int FtaParserwrap (void );
1066 #else
1067 extern int FtaParserwrap (void );
1068 #endif
1069 #endif
1070
1071 #ifndef YY_NO_UNPUT
1072     
1073     static void yyunput (int c,char *buf_ptr  );
1074     
1075 #endif
1076
1077 #ifndef yytext_ptr
1078 static void yy_flex_strncpy (char *,yyconst char *,int );
1079 #endif
1080
1081 #ifdef YY_NEED_STRLEN
1082 static int yy_flex_strlen (yyconst char * );
1083 #endif
1084
1085 #ifndef YY_NO_INPUT
1086
1087 #ifdef __cplusplus
1088 static int yyinput (void );
1089 #else
1090 static int input (void );
1091 #endif
1092
1093 #endif
1094
1095 /* Amount of stuff to slurp up with each read. */
1096 #ifndef YY_READ_BUF_SIZE
1097 #ifdef __ia64__
1098 /* On IA-64, the buffer size is 16k, not 8k */
1099 #define YY_READ_BUF_SIZE 16384
1100 #else
1101 #define YY_READ_BUF_SIZE 8192
1102 #endif /* __ia64__ */
1103 #endif
1104
1105 /* Copy whatever the last rule matched to the standard output. */
1106 #ifndef ECHO
1107 /* This used to be an fputs(), but since the string might contain NUL's,
1108  * we now use fwrite().
1109  */
1110 #define ECHO do { if (fwrite( FtaParsertext, FtaParserleng, 1, FtaParserout )) {} } while (0)
1111 #endif
1112
1113 /* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
1114  * is returned in "result".
1115  */
1116 #ifndef YY_INPUT
1117 #define YY_INPUT(buf,result,max_size) \
1118         if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
1119                 { \
1120                 int c = '*'; \
1121                 size_t n; \
1122                 for ( n = 0; n < max_size && \
1123                              (c = getc( FtaParserin )) != EOF && c != '\n'; ++n ) \
1124                         buf[n] = (char) c; \
1125                 if ( c == '\n' ) \
1126                         buf[n++] = (char) c; \
1127                 if ( c == EOF && ferror( FtaParserin ) ) \
1128                         YY_FATAL_ERROR( "input in flex scanner failed" ); \
1129                 result = n; \
1130                 } \
1131         else \
1132                 { \
1133                 errno=0; \
1134                 while ( (result = fread(buf, 1, max_size, FtaParserin))==0 && ferror(FtaParserin)) \
1135                         { \
1136                         if( errno != EINTR) \
1137                                 { \
1138                                 YY_FATAL_ERROR( "input in flex scanner failed" ); \
1139                                 break; \
1140                                 } \
1141                         errno=0; \
1142                         clearerr(FtaParserin); \
1143                         } \
1144                 }\
1145 \
1146
1147 #endif
1148
1149 /* No semi-colon after return; correct usage is to write "yyterminate();" -
1150  * we don't want an extra ';' after the "return" because that will cause
1151  * some compilers to complain about unreachable statements.
1152  */
1153 #ifndef yyterminate
1154 #define yyterminate() return YY_NULL
1155 #endif
1156
1157 /* Number of entries by which start-condition stack grows. */
1158 #ifndef YY_START_STACK_INCR
1159 #define YY_START_STACK_INCR 25
1160 #endif
1161
1162 /* Report a fatal error. */
1163 #ifndef YY_FATAL_ERROR
1164 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
1165 #endif
1166
1167 /* end tables serialization structures and prototypes */
1168
1169 /* Default declaration of generated scanner - a define so the user can
1170  * easily add parameters.
1171  */
1172 #ifndef YY_DECL
1173 #define YY_DECL_IS_OURS 1
1174
1175 extern int FtaParserlex (void);
1176
1177 #define YY_DECL int FtaParserlex (void)
1178 #endif /* !YY_DECL */
1179
1180 /* Code executed at the beginning of each rule, after FtaParsertext and FtaParserleng
1181  * have been set up.
1182  */
1183 #ifndef YY_USER_ACTION
1184 #define YY_USER_ACTION
1185 #endif
1186
1187 /* Code executed at the end of each rule. */
1188 #ifndef YY_BREAK
1189 #define YY_BREAK /*LINTED*/break;
1190 #endif
1191
1192 #define YY_RULE_SETUP \
1193         YY_USER_ACTION
1194
1195 /** The main scanner function which does all the work.
1196  */
1197 YY_DECL
1198 {
1199         yy_state_type yy_current_state;
1200         char *yy_cp, *yy_bp;
1201         int yy_act;
1202     
1203         if ( !(yy_init) )
1204                 {
1205                 (yy_init) = 1;
1206
1207 #ifdef YY_USER_INIT
1208                 YY_USER_INIT;
1209 #endif
1210
1211                 if ( ! (yy_start) )
1212                         (yy_start) = 1; /* first start state */
1213
1214                 if ( ! FtaParserin )
1215                         FtaParserin = stdin;
1216
1217                 if ( ! FtaParserout )
1218                         FtaParserout = stdout;
1219
1220                 if ( ! YY_CURRENT_BUFFER ) {
1221                         FtaParserensure_buffer_stack ();
1222                         YY_CURRENT_BUFFER_LVALUE =
1223                                 FtaParser_create_buffer(FtaParserin,YY_BUF_SIZE );
1224                 }
1225
1226                 FtaParser_load_buffer_state( );
1227                 }
1228
1229         {
1230 #line 104 "fta.l"
1231
1232
1233         /* literal keyword tokens */
1234
1235  /*
1236                         The actions associated with each text token are to
1237                         keep track of the current location (for syntax error reporting)
1238                         and to report any necessary info to the emf.y parse tree builder
1239
1240                         Its likely that there are a number of omissions, inconsistencies
1241                         (some keywords do not need to be in caps), and relics
1242                         (keywords such as BETWEEN, INDICATOR, etc., are not used
1243                          in emf.y)
1244                         This parser is somewhat of a work in progress.
1245  */
1246
1247  /*             Query keywords          */
1248
1249 #line 1250 "ftalexer.cc"
1250
1251         while ( /*CONSTCOND*/1 )                /* loops until end-of-file is reached */
1252                 {
1253                 (yy_more_len) = 0;
1254                 if ( (yy_more_flag) )
1255                         {
1256                         (yy_more_len) = (yy_c_buf_p) - (yytext_ptr);
1257                         (yy_more_flag) = 0;
1258                         }
1259                 yy_cp = (yy_c_buf_p);
1260
1261                 /* Support of FtaParsertext. */
1262                 *yy_cp = (yy_hold_char);
1263
1264                 /* yy_bp points to the position in yy_ch_buf of the start of
1265                  * the current run.
1266                  */
1267                 yy_bp = yy_cp;
1268
1269                 yy_current_state = (yy_start);
1270 yy_match:
1271                 do
1272                         {
1273                         YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ;
1274                         if ( yy_accept[yy_current_state] )
1275                                 {
1276                                 (yy_last_accepting_state) = yy_current_state;
1277                                 (yy_last_accepting_cpos) = yy_cp;
1278                                 }
1279                         while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
1280                                 {
1281                                 yy_current_state = (int) yy_def[yy_current_state];
1282                                 if ( yy_current_state >= 692 )
1283                                         yy_c = yy_meta[(unsigned int) yy_c];
1284                                 }
1285                         yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
1286                         ++yy_cp;
1287                         }
1288                 while ( yy_base[yy_current_state] != 815 );
1289
1290 yy_find_action:
1291                 yy_act = yy_accept[yy_current_state];
1292                 if ( yy_act == 0 )
1293                         { /* have to back up */
1294                         yy_cp = (yy_last_accepting_cpos);
1295                         yy_current_state = (yy_last_accepting_state);
1296                         yy_act = yy_accept[yy_current_state];
1297                         }
1298
1299                 YY_DO_BEFORE_ACTION;
1300
1301 do_action:      /* This label is used only to access EOF actions. */
1302
1303                 switch ( yy_act )
1304         { /* beginning of action switch */
1305                         case 0: /* must back up */
1306                         /* undo the effects of YY_DO_BEFORE_ACTION */
1307                         *yy_cp = (yy_hold_char);
1308                         yy_cp = (yy_last_accepting_cpos);
1309                         yy_current_state = (yy_last_accepting_state);
1310                         goto yy_find_action;
1311
1312 case 1:
1313 YY_RULE_SETUP
1314 #line 122 "fta.l"
1315 { flex_fta_ch+=FtaParserleng; return AND; }
1316         YY_BREAK
1317 case 2:
1318 YY_RULE_SETUP
1319 #line 123 "fta.l"
1320 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup("AND_AGGR"); return AGGR; }
1321         YY_BREAK
1322 case 3:
1323 YY_RULE_SETUP
1324 #line 124 "fta.l"
1325 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup("OR_AGGR"); return AGGR; }
1326         YY_BREAK
1327 case 4:
1328 YY_RULE_SETUP
1329 #line 125 "fta.l"
1330 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup("XOR_AGGR"); return AGGR; }
1331         YY_BREAK
1332 case 5:
1333 YY_RULE_SETUP
1334 #line 126 "fta.l"
1335 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup("AVG"); return AGGR; }
1336         YY_BREAK
1337 case 6:
1338 YY_RULE_SETUP
1339 #line 127 "fta.l"
1340 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup("MIN"); return AGGR; }
1341         YY_BREAK
1342 case 7:
1343 YY_RULE_SETUP
1344 #line 128 "fta.l"
1345 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup("MAX"); return AGGR; }
1346         YY_BREAK
1347 case 8:
1348 YY_RULE_SETUP
1349 #line 129 "fta.l"
1350 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup("SUM"); return AGGR; }
1351         YY_BREAK
1352 case 9:
1353 YY_RULE_SETUP
1354 #line 130 "fta.l"
1355 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup("COUNT"); return AGGR; }
1356         YY_BREAK
1357 case 10:
1358 YY_RULE_SETUP
1359 #line 131 "fta.l"
1360 { flex_fta_ch+=FtaParserleng; return BY; }
1361         YY_BREAK
1362 case 11:
1363 YY_RULE_SETUP
1364 #line 132 "fta.l"
1365 { flex_fta_ch+=FtaParserleng; return FROM; }
1366         YY_BREAK
1367 case 12:
1368 YY_RULE_SETUP
1369 #line 133 "fta.l"
1370 { flex_fta_ch+=FtaParserleng; return INNER_JOIN; }
1371         YY_BREAK
1372 case 13:
1373 YY_RULE_SETUP
1374 #line 134 "fta.l"
1375 { flex_fta_ch+=FtaParserleng; return OUTER_JOIN; }
1376         YY_BREAK
1377 case 14:
1378 YY_RULE_SETUP
1379 #line 135 "fta.l"
1380 { flex_fta_ch+=FtaParserleng; return RIGHT_OUTER_JOIN; }
1381         YY_BREAK
1382 case 15:
1383 YY_RULE_SETUP
1384 #line 136 "fta.l"
1385 { flex_fta_ch+=FtaParserleng; return LEFT_OUTER_JOIN; }
1386         YY_BREAK
1387 case 16:
1388 YY_RULE_SETUP
1389 #line 137 "fta.l"
1390 { flex_fta_ch+=FtaParserleng; return WATCHLIST_JOIN; }
1391         YY_BREAK
1392 case 17:
1393 YY_RULE_SETUP
1394 #line 138 "fta.l"
1395 { flex_fta_ch+=FtaParserleng; return FILTER_JOIN; }
1396         YY_BREAK
1397 case 18:
1398 YY_RULE_SETUP
1399 #line 139 "fta.l"
1400 { flex_fta_ch+=FtaParserleng; return GROUP; }
1401         YY_BREAK
1402 case 19:
1403 YY_RULE_SETUP
1404 #line 140 "fta.l"
1405 { flex_fta_ch+=FtaParserleng; return ROLLUP; }
1406         YY_BREAK
1407 case 20:
1408 YY_RULE_SETUP
1409 #line 141 "fta.l"
1410 { flex_fta_ch+=FtaParserleng; return CUBE; }
1411         YY_BREAK
1412 case 21:
1413 YY_RULE_SETUP
1414 #line 142 "fta.l"
1415 { flex_fta_ch+=FtaParserleng; return GROUPING_SETS; }
1416         YY_BREAK
1417 case 22:
1418 YY_RULE_SETUP
1419 #line 143 "fta.l"
1420 { flex_fta_ch+=FtaParserleng; return SUPERGROUP; }
1421         YY_BREAK
1422 case 23:
1423 YY_RULE_SETUP
1424 #line 144 "fta.l"
1425 { flex_fta_ch+=FtaParserleng; return CLEANING_WHEN; }
1426         YY_BREAK
1427 case 24:
1428 YY_RULE_SETUP
1429 #line 145 "fta.l"
1430 { flex_fta_ch+=FtaParserleng; return CLEANING_BY; }
1431         YY_BREAK
1432 case 25:
1433 YY_RULE_SETUP
1434 #line 146 "fta.l"
1435 { flex_fta_ch+=FtaParserleng; return CLOSING_WHEN; }
1436         YY_BREAK
1437 case 26:
1438 YY_RULE_SETUP
1439 #line 147 "fta.l"
1440 { flex_fta_ch+=FtaParserleng; return HAVING; }
1441         YY_BREAK
1442 case 27:
1443 YY_RULE_SETUP
1444 #line 148 "fta.l"
1445 { flex_fta_ch+=FtaParserleng; return AS; }
1446         YY_BREAK
1447 case 28:
1448 YY_RULE_SETUP
1449 #line 149 "fta.l"
1450 { flex_fta_ch+=FtaParserleng; return IN; }
1451         YY_BREAK
1452 case 29:
1453 YY_RULE_SETUP
1454 #line 150 "fta.l"
1455 { flex_fta_ch+=FtaParserleng; return NOT; }
1456         YY_BREAK
1457 case 30:
1458 YY_RULE_SETUP
1459 #line 151 "fta.l"
1460 { flex_fta_ch+=FtaParserleng; return OR; }
1461         YY_BREAK
1462 case 31:
1463 YY_RULE_SETUP
1464 #line 153 "fta.l"
1465 { flex_fta_ch+=FtaParserleng; return SELECT; }
1466         YY_BREAK
1467 case 32:
1468 YY_RULE_SETUP
1469 #line 154 "fta.l"
1470 { flex_fta_ch+=FtaParserleng; return WHERE; }
1471         YY_BREAK
1472 case 33:
1473 YY_RULE_SETUP
1474 #line 155 "fta.l"
1475 { flex_fta_ch+=FtaParserleng; return SUCH;}
1476         YY_BREAK
1477 case 34:
1478 YY_RULE_SETUP
1479 #line 156 "fta.l"
1480 { flex_fta_ch+=FtaParserleng; return THAT;}
1481         YY_BREAK
1482 case 35:
1483 YY_RULE_SETUP
1484 #line 157 "fta.l"
1485 {flex_fta_ch+=FtaParserleng; return MERGE;}
1486         YY_BREAK
1487 case 36:
1488 YY_RULE_SETUP
1489 #line 158 "fta.l"
1490 {flex_fta_ch+=FtaParserleng; return SLACK;}
1491         YY_BREAK
1492 case 37:
1493 YY_RULE_SETUP
1494 #line 159 "fta.l"
1495 {flex_fta_ch+=FtaParserleng; return WATCHLIST;}
1496         YY_BREAK
1497 case 38:
1498 YY_RULE_SETUP
1499 #line 161 "fta.l"
1500 { flex_fta_ch+=FtaParserleng; return TRUE_V;}
1501         YY_BREAK
1502 case 39:
1503 YY_RULE_SETUP
1504 #line 162 "fta.l"
1505 { flex_fta_ch+=FtaParserleng; return FALSE_V;}
1506         YY_BREAK
1507 case 40:
1508 YY_RULE_SETUP
1509 #line 163 "fta.l"
1510 { flex_fta_ch+=FtaParserleng; return TIMEVAL_L;}
1511         YY_BREAK
1512 case 41:
1513 YY_RULE_SETUP
1514 #line 164 "fta.l"
1515 { flex_fta_ch+=FtaParserleng; return HEX_L;}
1516         YY_BREAK
1517 case 42:
1518 YY_RULE_SETUP
1519 #line 165 "fta.l"
1520 { flex_fta_ch+=FtaParserleng; return LHEX_L;}
1521         YY_BREAK
1522 case 43:
1523 YY_RULE_SETUP
1524 #line 166 "fta.l"
1525 { flex_fta_ch+=FtaParserleng; return IP_L;}
1526         YY_BREAK
1527 case 44:
1528 YY_RULE_SETUP
1529 #line 167 "fta.l"
1530 { flex_fta_ch+=FtaParserleng; return IPV6_L;}
1531         YY_BREAK
1532 case 45:
1533 YY_RULE_SETUP
1534 #line 169 "fta.l"
1535 { flex_fta_ch+=FtaParserleng; return DEFINE_SEC;}
1536         YY_BREAK
1537 case 46:
1538 YY_RULE_SETUP
1539 #line 170 "fta.l"
1540 { flex_fta_ch+=FtaParserleng; return PARAM_SEC;}
1541         YY_BREAK
1542 case 47:
1543 YY_RULE_SETUP
1544 #line 172 "fta.l"
1545 {flex_fta_ch+=FtaParserleng; return LEFTBRACE;}
1546         YY_BREAK
1547 case 48:
1548 YY_RULE_SETUP
1549 #line 173 "fta.l"
1550 {flex_fta_ch+=FtaParserleng; return RIGHTBRACE;}
1551         YY_BREAK
1552 /*
1553                 Table definition keywords
1554  */             
1555 case 49:
1556 YY_RULE_SETUP
1557 #line 178 "fta.l"
1558 { flex_fta_ch+=FtaParserleng; return TABLE; }
1559         YY_BREAK
1560 case 50:
1561 YY_RULE_SETUP
1562 #line 179 "fta.l"
1563 { flex_fta_ch+=FtaParserleng; return PROTOCOL; }
1564         YY_BREAK
1565 case 51:
1566 YY_RULE_SETUP
1567 #line 180 "fta.l"
1568 { flex_fta_ch+=FtaParserleng; return STREAM; }
1569         YY_BREAK
1570 case 52:
1571 YY_RULE_SETUP
1572 #line 181 "fta.l"
1573 { flex_fta_ch+=FtaParserleng; return FTA; }
1574         YY_BREAK
1575 case 53:
1576 YY_RULE_SETUP
1577 #line 182 "fta.l"
1578 { flex_fta_ch+=FtaParserleng; return UNPACK_FCNS; }
1579         YY_BREAK
1580 case 54:
1581 YY_RULE_SETUP
1582 #line 184 "fta.l"
1583 { flex_fta_ch+=FtaParserleng; return OPERATOR; }
1584         YY_BREAK
1585 case 55:
1586 YY_RULE_SETUP
1587 #line 185 "fta.l"
1588 { flex_fta_ch+=FtaParserleng; return OPERATOR_VIEW; }
1589         YY_BREAK
1590 case 56:
1591 YY_RULE_SETUP
1592 #line 186 "fta.l"
1593 { flex_fta_ch+=FtaParserleng; return FIELDS; }
1594         YY_BREAK
1595 case 57:
1596 YY_RULE_SETUP
1597 #line 187 "fta.l"
1598 { flex_fta_ch+=FtaParserleng; return SUBQUERIES; }
1599         YY_BREAK
1600 case 58:
1601 YY_RULE_SETUP
1602 #line 188 "fta.l"
1603 { flex_fta_ch+=FtaParserleng; return SELECTION_PUSHDOWN; }
1604         YY_BREAK
1605 case 59:
1606 YY_RULE_SETUP
1607 #line 189 "fta.l"
1608 {flex_fta_ch+=FtaParserleng; return SEMICOLON;}
1609         YY_BREAK
1610 /* punctuation */
1611 case 60:
1612 #line 194 "fta.l"
1613 case 61:
1614 YY_RULE_SETUP
1615 #line 194 "fta.l"
1616 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup(FtaParsertext); return SHIFT_OP; }
1617         YY_BREAK
1618 case 62:
1619 #line 197 "fta.l"
1620 case 63:
1621 #line 198 "fta.l"
1622 case 64:
1623 #line 199 "fta.l"
1624 case 65:
1625 #line 200 "fta.l"
1626 case 66:
1627 #line 201 "fta.l"
1628 case 67:
1629 YY_RULE_SETUP
1630 #line 201 "fta.l"
1631 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup(FtaParsertext); return COMPARISON; }
1632         YY_BREAK
1633 case 68:
1634 YY_RULE_SETUP
1635 #line 203 "fta.l"
1636 { flex_fta_ch+=FtaParserleng; return FtaParsertext[0]; }
1637         YY_BREAK
1638 case 69:
1639 YY_RULE_SETUP
1640 #line 204 "fta.l"
1641 { flex_fta_ch+=FtaParserleng; return FtaParsertext[0]; }
1642         YY_BREAK
1643 case 70:
1644 YY_RULE_SETUP
1645 #line 205 "fta.l"
1646 { flex_fta_ch+=FtaParserleng; return FtaParsertext[0]; }
1647         YY_BREAK
1648 /* names */
1649 case 71:
1650 YY_RULE_SETUP
1651 #line 209 "fta.l"
1652 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup(FtaParsertext); return NAME; }
1653         YY_BREAK
1654 /* numbers */
1655 case 72:
1656 #line 214 "fta.l"
1657 case 73:
1658 YY_RULE_SETUP
1659 #line 214 "fta.l"
1660 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup(FtaParsertext);  return INTNUM; }
1661         YY_BREAK
1662 case 74:
1663 YY_RULE_SETUP
1664 #line 216 "fta.l"
1665 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup(FtaParsertext);  return LONGINTNUM; }
1666         YY_BREAK
1667 case 75:
1668 #line 219 "fta.l"
1669 case 76:
1670 #line 220 "fta.l"
1671 case 77:
1672 #line 221 "fta.l"
1673 case 78:
1674 #line 222 "fta.l"
1675 case 79:
1676 YY_RULE_SETUP
1677 #line 222 "fta.l"
1678 { flex_fta_ch+=FtaParserleng; FtaParserlval.strval = strdup(FtaParsertext); return APPROXNUM; }
1679         YY_BREAK
1680 /* strings */
1681 case 80:
1682 YY_RULE_SETUP
1683 #line 226 "fta.l"
1684 {
1685                 
1686                 int c;
1687                 
1688                 FtaParserlval.strval = strdup(FtaParsertext+1); 
1689
1690                 c = yyinput();
1691
1692                 unput(c);       /* just peeking */
1693                 if(c != '\'') {
1694                         flex_fta_ch+=FtaParserleng; 
1695                         FtaParserlval.strval[FtaParserleng-2] = '\0';
1696                         return STRING_TOKEN;
1697                 } else
1698                         yymore();
1699         }
1700         YY_BREAK
1701 case 81:
1702 *yy_cp = (yy_hold_char); /* undo effects of setting up FtaParsertext */
1703 (yy_c_buf_p) = yy_cp -= 1;
1704 YY_DO_BEFORE_ACTION; /* set up FtaParsertext again */
1705 YY_RULE_SETUP
1706 #line 243 "fta.l"
1707 { flex_fta_ch+=FtaParserleng; FtaParsererror("Unterminated string"); }
1708         YY_BREAK
1709 /*                                                                                                                      */
1710 /*              Newline : advance the error reporting line number       */
1711 /*              and grab the next line into flex_fta_linebuf                    */
1712 /*                                                                                                                      */
1713 case 82:
1714 /* rule 82 can match eol */
1715 YY_RULE_SETUP
1716 #line 250 "fta.l"
1717 {flex_fta_ch=0; flex_fta_lineno++;
1718                            strcpy(flex_fta_linebuf,FtaParsertext+1);
1719                            yyless(1);
1720                            }
1721         YY_BREAK
1722 case 83:
1723 YY_RULE_SETUP
1724 #line 255 "fta.l"
1725 {flex_fta_ch+=FtaParserleng; }  /* white space */
1726         YY_BREAK
1727 case 84:
1728 *yy_cp = (yy_hold_char); /* undo effects of setting up FtaParsertext */
1729 (yy_c_buf_p) = yy_cp -= 1;
1730 YY_DO_BEFORE_ACTION; /* set up FtaParsertext again */
1731 YY_RULE_SETUP
1732 #line 257 "fta.l"
1733 {flex_fta_ch+=FtaParserleng; }; /* comment */
1734         YY_BREAK
1735 case 85:
1736 *yy_cp = (yy_hold_char); /* undo effects of setting up FtaParsertext */
1737 (yy_c_buf_p) = yy_cp -= 1;
1738 YY_DO_BEFORE_ACTION; /* set up FtaParsertext again */
1739 YY_RULE_SETUP
1740 #line 258 "fta.l"
1741 {flex_fta_ch+=FtaParserleng; }; /* comment */
1742         YY_BREAK
1743 case 86:
1744 /* rule 86 can match eol */
1745 YY_RULE_SETUP
1746 #line 260 "fta.l"
1747 {flex_fta_ch+=FtaParserleng; fprintf(stderr,"Warning: unknown token (ignored)\n");  FtaParsererror(FtaParsertext);}
1748         YY_BREAK
1749 case 87:
1750 YY_RULE_SETUP
1751 #line 262 "fta.l"
1752 ECHO;
1753         YY_BREAK
1754 #line 1755 "ftalexer.cc"
1755 case YY_STATE_EOF(INITIAL):
1756         yyterminate();
1757
1758         case YY_END_OF_BUFFER:
1759                 {
1760                 /* Amount of text matched not including the EOB char. */
1761                 int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1;
1762
1763                 /* Undo the effects of YY_DO_BEFORE_ACTION. */
1764                 *yy_cp = (yy_hold_char);
1765                 YY_RESTORE_YY_MORE_OFFSET
1766
1767                 if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
1768                         {
1769                         /* We're scanning a new file or input source.  It's
1770                          * possible that this happened because the user
1771                          * just pointed FtaParserin at a new source and called
1772                          * FtaParserlex().  If so, then we have to assure
1773                          * consistency between YY_CURRENT_BUFFER and our
1774                          * globals.  Here is the right place to do so, because
1775                          * this is the first action (other than possibly a
1776                          * back-up) that will match for the new input source.
1777                          */
1778                         (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
1779                         YY_CURRENT_BUFFER_LVALUE->yy_input_file = FtaParserin;
1780                         YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
1781                         }
1782
1783                 /* Note that here we test for yy_c_buf_p "<=" to the position
1784                  * of the first EOB in the buffer, since yy_c_buf_p will
1785                  * already have been incremented past the NUL character
1786                  * (since all states make transitions on EOB to the
1787                  * end-of-buffer state).  Contrast this with the test
1788                  * in input().
1789                  */
1790                 if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )
1791                         { /* This was really a NUL. */
1792                         yy_state_type yy_next_state;
1793
1794                         (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text;
1795
1796                         yy_current_state = yy_get_previous_state(  );
1797
1798                         /* Okay, we're now positioned to make the NUL
1799                          * transition.  We couldn't have
1800                          * yy_get_previous_state() go ahead and do it
1801                          * for us because it doesn't know how to deal
1802                          * with the possibility of jamming (and we don't
1803                          * want to build jamming into it because then it
1804                          * will run more slowly).
1805                          */
1806
1807                         yy_next_state = yy_try_NUL_trans( yy_current_state );
1808
1809                         yy_bp = (yytext_ptr) + YY_MORE_ADJ;
1810
1811                         if ( yy_next_state )
1812                                 {
1813                                 /* Consume the NUL. */
1814                                 yy_cp = ++(yy_c_buf_p);
1815                                 yy_current_state = yy_next_state;
1816                                 goto yy_match;
1817                                 }
1818
1819                         else
1820                                 {
1821                                 yy_cp = (yy_c_buf_p);
1822                                 goto yy_find_action;
1823                                 }
1824                         }
1825
1826                 else switch ( yy_get_next_buffer(  ) )
1827                         {
1828                         case EOB_ACT_END_OF_FILE:
1829                                 {
1830                                 (yy_did_buffer_switch_on_eof) = 0;
1831
1832                                 if ( FtaParserwrap( ) )
1833                                         {
1834                                         /* Note: because we've taken care in
1835                                          * yy_get_next_buffer() to have set up
1836                                          * FtaParsertext, we can now set up
1837                                          * yy_c_buf_p so that if some total
1838                                          * hoser (like flex itself) wants to
1839                                          * call the scanner after we return the
1840                                          * YY_NULL, it'll still work - another
1841                                          * YY_NULL will get returned.
1842                                          */
1843                                         (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ;
1844
1845                                         yy_act = YY_STATE_EOF(YY_START);
1846                                         goto do_action;
1847                                         }
1848
1849                                 else
1850                                         {
1851                                         if ( ! (yy_did_buffer_switch_on_eof) )
1852                                                 YY_NEW_FILE;
1853                                         }
1854                                 break;
1855                                 }
1856
1857                         case EOB_ACT_CONTINUE_SCAN:
1858                                 (yy_c_buf_p) =
1859                                         (yytext_ptr) + yy_amount_of_matched_text;
1860
1861                                 yy_current_state = yy_get_previous_state(  );
1862
1863                                 yy_cp = (yy_c_buf_p);
1864                                 yy_bp = (yytext_ptr) + YY_MORE_ADJ;
1865                                 goto yy_match;
1866
1867                         case EOB_ACT_LAST_MATCH:
1868                                 (yy_c_buf_p) =
1869                                 &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)];
1870
1871                                 yy_current_state = yy_get_previous_state(  );
1872
1873                                 yy_cp = (yy_c_buf_p);
1874                                 yy_bp = (yytext_ptr) + YY_MORE_ADJ;
1875                                 goto yy_find_action;
1876                         }
1877                 break;
1878                 }
1879
1880         default:
1881                 YY_FATAL_ERROR(
1882                         "fatal flex scanner internal error--no action found" );
1883         } /* end of action switch */
1884                 } /* end of scanning one token */
1885         } /* end of user's declarations */
1886 } /* end of FtaParserlex */
1887
1888 /* yy_get_next_buffer - try to read in a new buffer
1889  *
1890  * Returns a code representing an action:
1891  *      EOB_ACT_LAST_MATCH -
1892  *      EOB_ACT_CONTINUE_SCAN - continue scanning from current position
1893  *      EOB_ACT_END_OF_FILE - end of file
1894  */
1895 static int yy_get_next_buffer (void)
1896 {
1897         char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
1898         char *source = (yytext_ptr);
1899         yy_size_t number_to_move, i;
1900         int ret_val;
1901
1902         if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] )
1903                 YY_FATAL_ERROR(
1904                 "fatal flex scanner internal error--end of buffer missed" );
1905
1906         if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
1907                 { /* Don't try to fill the buffer, so this is an EOF. */
1908                 if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 )
1909                         {
1910                         /* We matched a single character, the EOB, so
1911                          * treat this as a final EOF.
1912                          */
1913                         return EOB_ACT_END_OF_FILE;
1914                         }
1915
1916                 else
1917                         {
1918                         /* We matched some text prior to the EOB, first
1919                          * process it.
1920                          */
1921                         return EOB_ACT_LAST_MATCH;
1922                         }
1923                 }
1924
1925         /* Try to read more data. */
1926
1927         /* First move last chars to start of buffer. */
1928         number_to_move = (yy_size_t) ((yy_c_buf_p) - (yytext_ptr)) - 1;
1929
1930         for ( i = 0; i < number_to_move; ++i )
1931                 *(dest++) = *(source++);
1932
1933         if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
1934                 /* don't do the read, it's not guaranteed to return an EOF,
1935                  * just force an EOF
1936                  */
1937                 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0;
1938
1939         else
1940                 {
1941                         yy_size_t num_to_read =
1942                         YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
1943
1944                 while ( num_to_read <= 0 )
1945                         { /* Not enough room in the buffer - grow it. */
1946
1947                         /* just a shorter name for the current buffer */
1948                         YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE;
1949
1950                         int yy_c_buf_p_offset =
1951                                 (int) ((yy_c_buf_p) - b->yy_ch_buf);
1952
1953                         if ( b->yy_is_our_buffer )
1954                                 {
1955                                 yy_size_t new_size = b->yy_buf_size * 2;
1956
1957                                 if ( new_size <= 0 )
1958                                         b->yy_buf_size += b->yy_buf_size / 8;
1959                                 else
1960                                         b->yy_buf_size *= 2;
1961
1962                                 b->yy_ch_buf = (char *)
1963                                         /* Include room in for 2 EOB chars. */
1964                                         FtaParserrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2  );
1965                                 }
1966                         else
1967                                 /* Can't grow it, we don't own it. */
1968                                 b->yy_ch_buf = 0;
1969
1970                         if ( ! b->yy_ch_buf )
1971                                 YY_FATAL_ERROR(
1972                                 "fatal error - scanner input buffer overflow" );
1973
1974                         (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset];
1975
1976                         num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
1977                                                 number_to_move - 1;
1978
1979                         }
1980
1981                 if ( num_to_read > YY_READ_BUF_SIZE )
1982                         num_to_read = YY_READ_BUF_SIZE;
1983
1984                 /* Read in more data. */
1985                 YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
1986                         (yy_n_chars), num_to_read );
1987
1988                 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
1989                 }
1990
1991         if ( (yy_n_chars) == 0 )
1992                 {
1993                 if ( number_to_move == YY_MORE_ADJ )
1994                         {
1995                         ret_val = EOB_ACT_END_OF_FILE;
1996                         FtaParserrestart(FtaParserin  );
1997                         }
1998
1999                 else
2000                         {
2001                         ret_val = EOB_ACT_LAST_MATCH;
2002                         YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
2003                                 YY_BUFFER_EOF_PENDING;
2004                         }
2005                 }
2006
2007         else
2008                 ret_val = EOB_ACT_CONTINUE_SCAN;
2009
2010         if ((int) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
2011                 /* Extend the array by 50%, plus the number we really need. */
2012                 int new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1);
2013                 YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) FtaParserrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size  );
2014                 if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
2015                         YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
2016         }
2017
2018         (yy_n_chars) += number_to_move;
2019         YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR;
2020         YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR;
2021
2022         (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
2023
2024         return ret_val;
2025 }
2026
2027 /* yy_get_previous_state - get the state just before the EOB char was reached */
2028
2029     static yy_state_type yy_get_previous_state (void)
2030 {
2031         yy_state_type yy_current_state;
2032         char *yy_cp;
2033     
2034         yy_current_state = (yy_start);
2035
2036         for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp )
2037                 {
2038                 YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
2039                 if ( yy_accept[yy_current_state] )
2040                         {
2041                         (yy_last_accepting_state) = yy_current_state;
2042                         (yy_last_accepting_cpos) = yy_cp;
2043                         }
2044                 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
2045                         {
2046                         yy_current_state = (int) yy_def[yy_current_state];
2047                         if ( yy_current_state >= 692 )
2048                                 yy_c = yy_meta[(unsigned int) yy_c];
2049                         }
2050                 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
2051                 }
2052
2053         return yy_current_state;
2054 }
2055
2056 /* yy_try_NUL_trans - try to make a transition on the NUL character
2057  *
2058  * synopsis
2059  *      next_state = yy_try_NUL_trans( current_state );
2060  */
2061     static yy_state_type yy_try_NUL_trans  (yy_state_type yy_current_state )
2062 {
2063         int yy_is_jam;
2064         char *yy_cp = (yy_c_buf_p);
2065
2066         YY_CHAR yy_c = 1;
2067         if ( yy_accept[yy_current_state] )
2068                 {
2069                 (yy_last_accepting_state) = yy_current_state;
2070                 (yy_last_accepting_cpos) = yy_cp;
2071                 }
2072         while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
2073                 {
2074                 yy_current_state = (int) yy_def[yy_current_state];
2075                 if ( yy_current_state >= 692 )
2076                         yy_c = yy_meta[(unsigned int) yy_c];
2077                 }
2078         yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
2079         yy_is_jam = (yy_current_state == 691);
2080
2081                 return yy_is_jam ? 0 : yy_current_state;
2082 }
2083
2084 #ifndef YY_NO_UNPUT
2085
2086     static void yyunput (int c, char * yy_bp )
2087 {
2088         char *yy_cp;
2089     
2090     yy_cp = (yy_c_buf_p);
2091
2092         /* undo effects of setting up FtaParsertext */
2093         *yy_cp = (yy_hold_char);
2094
2095         if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
2096                 { /* need to shift things up to make room */
2097                 /* +2 for EOB chars. */
2098                 yy_size_t number_to_move = (yy_n_chars) + 2;
2099                 char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[
2100                                         YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2];
2101                 char *source =
2102                                 &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move];
2103
2104                 while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
2105                         *--dest = *--source;
2106
2107                 yy_cp += (int) (dest - source);
2108                 yy_bp += (int) (dest - source);
2109                 YY_CURRENT_BUFFER_LVALUE->yy_n_chars =
2110                         (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_buf_size;
2111
2112                 if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
2113                         YY_FATAL_ERROR( "flex scanner push-back overflow" );
2114                 }
2115
2116         *--yy_cp = (char) c;
2117
2118         (yytext_ptr) = yy_bp;
2119         (yy_hold_char) = *yy_cp;
2120         (yy_c_buf_p) = yy_cp;
2121 }
2122
2123 #endif
2124
2125 #ifndef YY_NO_INPUT
2126 #ifdef __cplusplus
2127     static int yyinput (void)
2128 #else
2129     static int input  (void)
2130 #endif
2131
2132 {
2133         int c;
2134     
2135         *(yy_c_buf_p) = (yy_hold_char);
2136
2137         if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR )
2138                 {
2139                 /* yy_c_buf_p now points to the character we want to return.
2140                  * If this occurs *before* the EOB characters, then it's a
2141                  * valid NUL; if not, then we've hit the end of the buffer.
2142                  */
2143                 if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )
2144                         /* This was really a NUL. */
2145                         *(yy_c_buf_p) = '\0';
2146
2147                 else
2148                         { /* need more input */
2149                         yy_size_t offset = (yy_c_buf_p) - (yytext_ptr);
2150                         ++(yy_c_buf_p);
2151
2152                         switch ( yy_get_next_buffer(  ) )
2153                                 {
2154                                 case EOB_ACT_LAST_MATCH:
2155                                         /* This happens because yy_g_n_b()
2156                                          * sees that we've accumulated a
2157                                          * token and flags that we need to
2158                                          * try matching the token before
2159                                          * proceeding.  But for input(),
2160                                          * there's no matching to consider.
2161                                          * So convert the EOB_ACT_LAST_MATCH
2162                                          * to EOB_ACT_END_OF_FILE.
2163                                          */
2164
2165                                         /* Reset buffer status. */
2166                                         FtaParserrestart(FtaParserin );
2167
2168                                         /*FALLTHROUGH*/
2169
2170                                 case EOB_ACT_END_OF_FILE:
2171                                         {
2172                                         if ( FtaParserwrap( ) )
2173                                                 return EOF;
2174
2175                                         if ( ! (yy_did_buffer_switch_on_eof) )
2176                                                 YY_NEW_FILE;
2177 #ifdef __cplusplus
2178                                         return yyinput();
2179 #else
2180                                         return input();
2181 #endif
2182                                         }
2183
2184                                 case EOB_ACT_CONTINUE_SCAN:
2185                                         (yy_c_buf_p) = (yytext_ptr) + offset;
2186                                         break;
2187                                 }
2188                         }
2189                 }
2190
2191         c = *(unsigned char *) (yy_c_buf_p);    /* cast for 8-bit char's */
2192         *(yy_c_buf_p) = '\0';   /* preserve FtaParsertext */
2193         (yy_hold_char) = *++(yy_c_buf_p);
2194
2195         return c;
2196 }
2197 #endif  /* ifndef YY_NO_INPUT */
2198
2199 /** Immediately switch to a different input stream.
2200  * @param input_file A readable stream.
2201  * 
2202  * @note This function does not reset the start condition to @c INITIAL .
2203  */
2204     void FtaParserrestart  (FILE * input_file )
2205 {
2206     
2207         if ( ! YY_CURRENT_BUFFER ){
2208         FtaParserensure_buffer_stack ();
2209                 YY_CURRENT_BUFFER_LVALUE =
2210             FtaParser_create_buffer(FtaParserin,YY_BUF_SIZE );
2211         }
2212
2213         FtaParser_init_buffer(YY_CURRENT_BUFFER,input_file );
2214         FtaParser_load_buffer_state( );
2215 }
2216
2217 /** Switch to a different input buffer.
2218  * @param new_buffer The new input buffer.
2219  * 
2220  */
2221     void FtaParser_switch_to_buffer  (YY_BUFFER_STATE  new_buffer )
2222 {
2223     
2224         /* TODO. We should be able to replace this entire function body
2225          * with
2226          *              FtaParserpop_buffer_state();
2227          *              FtaParserpush_buffer_state(new_buffer);
2228      */
2229         FtaParserensure_buffer_stack ();
2230         if ( YY_CURRENT_BUFFER == new_buffer )
2231                 return;
2232
2233         if ( YY_CURRENT_BUFFER )
2234                 {
2235                 /* Flush out information for old buffer. */
2236                 *(yy_c_buf_p) = (yy_hold_char);
2237                 YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);
2238                 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
2239                 }
2240
2241         YY_CURRENT_BUFFER_LVALUE = new_buffer;
2242         FtaParser_load_buffer_state( );
2243
2244         /* We don't actually know whether we did this switch during
2245          * EOF (FtaParserwrap()) processing, but the only time this flag
2246          * is looked at is after FtaParserwrap() is called, so it's safe
2247          * to go ahead and always set it.
2248          */
2249         (yy_did_buffer_switch_on_eof) = 1;
2250 }
2251
2252 static void FtaParser_load_buffer_state  (void)
2253 {
2254         (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
2255         (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
2256         FtaParserin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
2257         (yy_hold_char) = *(yy_c_buf_p);
2258 }
2259
2260 /** Allocate and initialize an input buffer state.
2261  * @param file A readable stream.
2262  * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
2263  * 
2264  * @return the allocated buffer state.
2265  */
2266     YY_BUFFER_STATE FtaParser_create_buffer  (FILE * file, int  size )
2267 {
2268         YY_BUFFER_STATE b;
2269     
2270         b = (YY_BUFFER_STATE) FtaParseralloc(sizeof( struct yy_buffer_state )  );
2271         if ( ! b )
2272                 YY_FATAL_ERROR( "out of dynamic memory in FtaParser_create_buffer()" );
2273
2274         b->yy_buf_size = (yy_size_t)size;
2275
2276         /* yy_ch_buf has to be 2 characters longer than the size given because
2277          * we need to put in 2 end-of-buffer characters.
2278          */
2279         b->yy_ch_buf = (char *) FtaParseralloc(b->yy_buf_size + 2  );
2280         if ( ! b->yy_ch_buf )
2281                 YY_FATAL_ERROR( "out of dynamic memory in FtaParser_create_buffer()" );
2282
2283         b->yy_is_our_buffer = 1;
2284
2285         FtaParser_init_buffer(b,file );
2286
2287         return b;
2288 }
2289
2290 /** Destroy the buffer.
2291  * @param b a buffer created with FtaParser_create_buffer()
2292  * 
2293  */
2294     void FtaParser_delete_buffer (YY_BUFFER_STATE  b )
2295 {
2296     
2297         if ( ! b )
2298                 return;
2299
2300         if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
2301                 YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
2302
2303         if ( b->yy_is_our_buffer )
2304                 FtaParserfree((void *) b->yy_ch_buf  );
2305
2306         FtaParserfree((void *) b  );
2307 }
2308
2309 /* Initializes or reinitializes a buffer.
2310  * This function is sometimes called more than once on the same buffer,
2311  * such as during a FtaParserrestart() or at EOF.
2312  */
2313     static void FtaParser_init_buffer  (YY_BUFFER_STATE  b, FILE * file )
2314
2315 {
2316         int oerrno = errno;
2317     
2318         FtaParser_flush_buffer(b );
2319
2320         b->yy_input_file = file;
2321         b->yy_fill_buffer = 1;
2322
2323     /* If b is the current buffer, then FtaParser_init_buffer was _probably_
2324      * called from FtaParserrestart() or through yy_get_next_buffer.
2325      * In that case, we don't want to reset the lineno or column.
2326      */
2327     if (b != YY_CURRENT_BUFFER){
2328         b->yy_bs_lineno = 1;
2329         b->yy_bs_column = 0;
2330     }
2331
2332         b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
2333     
2334         errno = oerrno;
2335 }
2336
2337 /** Discard all buffered characters. On the next scan, YY_INPUT will be called.
2338  * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
2339  * 
2340  */
2341     void FtaParser_flush_buffer (YY_BUFFER_STATE  b )
2342 {
2343         if ( ! b )
2344                 return;
2345
2346         b->yy_n_chars = 0;
2347
2348         /* We always need two end-of-buffer characters.  The first causes
2349          * a transition to the end-of-buffer state.  The second causes
2350          * a jam in that state.
2351          */
2352         b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
2353         b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
2354
2355         b->yy_buf_pos = &b->yy_ch_buf[0];
2356
2357         b->yy_at_bol = 1;
2358         b->yy_buffer_status = YY_BUFFER_NEW;
2359
2360         if ( b == YY_CURRENT_BUFFER )
2361                 FtaParser_load_buffer_state( );
2362 }
2363
2364 /** Pushes the new state onto the stack. The new state becomes
2365  *  the current state. This function will allocate the stack
2366  *  if necessary.
2367  *  @param new_buffer The new state.
2368  *  
2369  */
2370 void FtaParserpush_buffer_state (YY_BUFFER_STATE new_buffer )
2371 {
2372         if (new_buffer == NULL)
2373                 return;
2374
2375         FtaParserensure_buffer_stack();
2376
2377         /* This block is copied from FtaParser_switch_to_buffer. */
2378         if ( YY_CURRENT_BUFFER )
2379                 {
2380                 /* Flush out information for old buffer. */
2381                 *(yy_c_buf_p) = (yy_hold_char);
2382                 YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);
2383                 YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
2384                 }
2385
2386         /* Only push if top exists. Otherwise, replace top. */
2387         if (YY_CURRENT_BUFFER)
2388                 (yy_buffer_stack_top)++;
2389         YY_CURRENT_BUFFER_LVALUE = new_buffer;
2390
2391         /* copied from FtaParser_switch_to_buffer. */
2392         FtaParser_load_buffer_state( );
2393         (yy_did_buffer_switch_on_eof) = 1;
2394 }
2395
2396 /** Removes and deletes the top of the stack, if present.
2397  *  The next element becomes the new top.
2398  *  
2399  */
2400 void FtaParserpop_buffer_state (void)
2401 {
2402         if (!YY_CURRENT_BUFFER)
2403                 return;
2404
2405         FtaParser_delete_buffer(YY_CURRENT_BUFFER );
2406         YY_CURRENT_BUFFER_LVALUE = NULL;
2407         if ((yy_buffer_stack_top) > 0)
2408                 --(yy_buffer_stack_top);
2409
2410         if (YY_CURRENT_BUFFER) {
2411                 FtaParser_load_buffer_state( );
2412                 (yy_did_buffer_switch_on_eof) = 1;
2413         }
2414 }
2415
2416 /* Allocates the stack if it does not exist.
2417  *  Guarantees space for at least one push.
2418  */
2419 static void FtaParserensure_buffer_stack (void)
2420 {
2421         yy_size_t num_to_alloc;
2422     
2423         if (!(yy_buffer_stack)) {
2424
2425                 /* First allocation is just for 2 elements, since we don't know if this
2426                  * scanner will even need a stack. We use 2 instead of 1 to avoid an
2427                  * immediate realloc on the next call.
2428          */
2429                 num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */
2430                 (yy_buffer_stack) = (struct yy_buffer_state**)FtaParseralloc
2431                                                                 (num_to_alloc * sizeof(struct yy_buffer_state*)
2432                                                                 );
2433                 if ( ! (yy_buffer_stack) )
2434                         YY_FATAL_ERROR( "out of dynamic memory in FtaParserensure_buffer_stack()" );
2435                                                                   
2436                 memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*));
2437                                 
2438                 (yy_buffer_stack_max) = num_to_alloc;
2439                 (yy_buffer_stack_top) = 0;
2440                 return;
2441         }
2442
2443         if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){
2444
2445                 /* Increase the buffer to prepare for a possible push. */
2446                 yy_size_t grow_size = 8 /* arbitrary grow size */;
2447
2448                 num_to_alloc = (yy_buffer_stack_max) + grow_size;
2449                 (yy_buffer_stack) = (struct yy_buffer_state**)FtaParserrealloc
2450                                                                 ((yy_buffer_stack),
2451                                                                 num_to_alloc * sizeof(struct yy_buffer_state*)
2452                                                                 );
2453                 if ( ! (yy_buffer_stack) )
2454                         YY_FATAL_ERROR( "out of dynamic memory in FtaParserensure_buffer_stack()" );
2455
2456                 /* zero only the new slots.*/
2457                 memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*));
2458                 (yy_buffer_stack_max) = num_to_alloc;
2459         }
2460 }
2461
2462 /** Setup the input buffer state to scan directly from a user-specified character buffer.
2463  * @param base the character buffer
2464  * @param size the size in bytes of the character buffer
2465  * 
2466  * @return the newly allocated buffer state object. 
2467  */
2468 YY_BUFFER_STATE FtaParser_scan_buffer  (char * base, yy_size_t  size )
2469 {
2470         YY_BUFFER_STATE b;
2471     
2472         if ( size < 2 ||
2473              base[size-2] != YY_END_OF_BUFFER_CHAR ||
2474              base[size-1] != YY_END_OF_BUFFER_CHAR )
2475                 /* They forgot to leave room for the EOB's. */
2476                 return 0;
2477
2478         b = (YY_BUFFER_STATE) FtaParseralloc(sizeof( struct yy_buffer_state )  );
2479         if ( ! b )
2480                 YY_FATAL_ERROR( "out of dynamic memory in FtaParser_scan_buffer()" );
2481
2482         b->yy_buf_size = size - 2;      /* "- 2" to take care of EOB's */
2483         b->yy_buf_pos = b->yy_ch_buf = base;
2484         b->yy_is_our_buffer = 0;
2485         b->yy_input_file = 0;
2486         b->yy_n_chars = b->yy_buf_size;
2487         b->yy_is_interactive = 0;
2488         b->yy_at_bol = 1;
2489         b->yy_fill_buffer = 0;
2490         b->yy_buffer_status = YY_BUFFER_NEW;
2491
2492         FtaParser_switch_to_buffer(b  );
2493
2494         return b;
2495 }
2496
2497 /** Setup the input buffer state to scan a string. The next call to FtaParserlex() will
2498  * scan from a @e copy of @a str.
2499  * @param yystr a NUL-terminated string to scan
2500  * 
2501  * @return the newly allocated buffer state object.
2502  * @note If you want to scan bytes that may contain NUL values, then use
2503  *       FtaParser_scan_bytes() instead.
2504  */
2505 YY_BUFFER_STATE FtaParser_scan_string (yyconst char * yystr )
2506 {
2507     
2508         return FtaParser_scan_bytes(yystr,strlen(yystr) );
2509 }
2510
2511 /** Setup the input buffer state to scan the given bytes. The next call to FtaParserlex() will
2512  * scan from a @e copy of @a bytes.
2513  * @param yybytes the byte buffer to scan
2514  * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
2515  * 
2516  * @return the newly allocated buffer state object.
2517  */
2518 YY_BUFFER_STATE FtaParser_scan_bytes  (yyconst char * yybytes, yy_size_t  _yybytes_len )
2519 {
2520         YY_BUFFER_STATE b;
2521         char *buf;
2522         yy_size_t n;
2523         yy_size_t i;
2524     
2525         /* Get memory for full buffer, including space for trailing EOB's. */
2526         n = _yybytes_len + 2;
2527         buf = (char *) FtaParseralloc(n  );
2528         if ( ! buf )
2529                 YY_FATAL_ERROR( "out of dynamic memory in FtaParser_scan_bytes()" );
2530
2531         for ( i = 0; i < _yybytes_len; ++i )
2532                 buf[i] = yybytes[i];
2533
2534         buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
2535
2536         b = FtaParser_scan_buffer(buf,n );
2537         if ( ! b )
2538                 YY_FATAL_ERROR( "bad buffer in FtaParser_scan_bytes()" );
2539
2540         /* It's okay to grow etc. this buffer, and we should throw it
2541          * away when we're done.
2542          */
2543         b->yy_is_our_buffer = 1;
2544
2545         return b;
2546 }
2547
2548 #ifndef YY_EXIT_FAILURE
2549 #define YY_EXIT_FAILURE 2
2550 #endif
2551
2552 static void yy_fatal_error (yyconst char* msg )
2553 {
2554                         (void) fprintf( stderr, "%s\n", msg );
2555         exit( YY_EXIT_FAILURE );
2556 }
2557
2558 /* Redefine yyless() so it works in section 3 code. */
2559
2560 #undef yyless
2561 #define yyless(n) \
2562         do \
2563                 { \
2564                 /* Undo effects of setting up FtaParsertext. */ \
2565         int yyless_macro_arg = (n); \
2566         YY_LESS_LINENO(yyless_macro_arg);\
2567                 FtaParsertext[FtaParserleng] = (yy_hold_char); \
2568                 (yy_c_buf_p) = FtaParsertext + yyless_macro_arg; \
2569                 (yy_hold_char) = *(yy_c_buf_p); \
2570                 *(yy_c_buf_p) = '\0'; \
2571                 FtaParserleng = yyless_macro_arg; \
2572                 } \
2573         while ( 0 )
2574
2575 /* Accessor  methods (get/set functions) to struct members. */
2576
2577 /** Get the current line number.
2578  * 
2579  */
2580 int FtaParserget_lineno  (void)
2581 {
2582         
2583     return FtaParserlineno;
2584 }
2585
2586 /** Get the input stream.
2587  * 
2588  */
2589 FILE *FtaParserget_in  (void)
2590 {
2591         return FtaParserin;
2592 }
2593
2594 /** Get the output stream.
2595  * 
2596  */
2597 FILE *FtaParserget_out  (void)
2598 {
2599         return FtaParserout;
2600 }
2601
2602 /** Get the length of the current token.
2603  * 
2604  */
2605 yy_size_t FtaParserget_leng  (void)
2606 {
2607         return FtaParserleng;
2608 }
2609
2610 /** Get the current token.
2611  * 
2612  */
2613
2614 char *FtaParserget_text  (void)
2615 {
2616         return FtaParsertext;
2617 }
2618
2619 /** Set the current line number.
2620  * @param _line_number line number
2621  * 
2622  */
2623 void FtaParserset_lineno (int  _line_number )
2624 {
2625     
2626     FtaParserlineno = _line_number;
2627 }
2628
2629 /** Set the input stream. This does not discard the current
2630  * input buffer.
2631  * @param _in_str A readable stream.
2632  * 
2633  * @see FtaParser_switch_to_buffer
2634  */
2635 void FtaParserset_in (FILE *  _in_str )
2636 {
2637         FtaParserin = _in_str ;
2638 }
2639
2640 void FtaParserset_out (FILE *  _out_str )
2641 {
2642         FtaParserout = _out_str ;
2643 }
2644
2645 int FtaParserget_debug  (void)
2646 {
2647         return FtaParser_flex_debug;
2648 }
2649
2650 void FtaParserset_debug (int  _bdebug )
2651 {
2652         FtaParser_flex_debug = _bdebug ;
2653 }
2654
2655 static int yy_init_globals (void)
2656 {
2657         /* Initialization is the same as for the non-reentrant scanner.
2658      * This function is called from FtaParserlex_destroy(), so don't allocate here.
2659      */
2660
2661     (yy_buffer_stack) = 0;
2662     (yy_buffer_stack_top) = 0;
2663     (yy_buffer_stack_max) = 0;
2664     (yy_c_buf_p) = (char *) 0;
2665     (yy_init) = 0;
2666     (yy_start) = 0;
2667
2668 /* Defined in main.c */
2669 #ifdef YY_STDINIT
2670     FtaParserin = stdin;
2671     FtaParserout = stdout;
2672 #else
2673     FtaParserin = (FILE *) 0;
2674     FtaParserout = (FILE *) 0;
2675 #endif
2676
2677     /* For future reference: Set errno on error, since we are called by
2678      * FtaParserlex_init()
2679      */
2680     return 0;
2681 }
2682
2683 /* FtaParserlex_destroy is for both reentrant and non-reentrant scanners. */
2684 int FtaParserlex_destroy  (void)
2685 {
2686     
2687     /* Pop the buffer stack, destroying each element. */
2688         while(YY_CURRENT_BUFFER){
2689                 FtaParser_delete_buffer(YY_CURRENT_BUFFER  );
2690                 YY_CURRENT_BUFFER_LVALUE = NULL;
2691                 FtaParserpop_buffer_state();
2692         }
2693
2694         /* Destroy the stack itself. */
2695         FtaParserfree((yy_buffer_stack) );
2696         (yy_buffer_stack) = NULL;
2697
2698     /* Reset the globals. This is important in a non-reentrant scanner so the next time
2699      * FtaParserlex() is called, initialization will occur. */
2700     yy_init_globals( );
2701
2702     return 0;
2703 }
2704
2705 /*
2706  * Internal utility routines.
2707  */
2708
2709 #ifndef yytext_ptr
2710 static void yy_flex_strncpy (char* s1, yyconst char * s2, int n )
2711 {
2712                 
2713         int i;
2714         for ( i = 0; i < n; ++i )
2715                 s1[i] = s2[i];
2716 }
2717 #endif
2718
2719 #ifdef YY_NEED_STRLEN
2720 static int yy_flex_strlen (yyconst char * s )
2721 {
2722         int n;
2723         for ( n = 0; s[n]; ++n )
2724                 ;
2725
2726         return n;
2727 }
2728 #endif
2729
2730 void *FtaParseralloc (yy_size_t  size )
2731 {
2732                         return (void *) malloc( size );
2733 }
2734
2735 void *FtaParserrealloc  (void * ptr, yy_size_t  size )
2736 {
2737                 
2738         /* The cast to (char *) in the following accommodates both
2739          * implementations that use char* generic pointers, and those
2740          * that use void* generic pointers.  It works with the latter
2741          * because both ANSI C and C++ allow castless assignment from
2742          * any pointer type to void*, and deal with argument conversions
2743          * as though doing an assignment.
2744          */
2745         return (void *) realloc( (char *) ptr, size );
2746 }
2747
2748 void FtaParserfree (void * ptr )
2749 {
2750                         free( (char *) ptr );   /* see FtaParserrealloc() for (char *) cast */
2751 }
2752
2753 #define YYTABLES_NAME "yytables"
2754
2755 #line 262 "fta.l"
2756
2757
2758
2759 int my_FtaParser_yyinput(char *buf, int max_size){
2760         int c = 0;
2761         int inchar = 0;
2762         
2763         if(flex_fta_stringinput != NULL){
2764                 while(c<max_size){
2765                         if(flex_fta_stringinput[flex_fta_stringinput_ptr] != '\0'){
2766                                 buf[c++] = flex_fta_stringinput[flex_fta_stringinput_ptr++];
2767                         }else{
2768                                 break;
2769                         }
2770                 }
2771                 return(c);
2772         }
2773         
2774         if(flex_fta_fileinput != NULL){
2775                 while(c < max_size){
2776                         inchar = getc(flex_fta_fileinput);
2777                         if(inchar != EOF){
2778                                 buf[c++] = inchar;
2779                         }else{
2780                                 break;
2781                         }
2782                 }
2783                 return(c);
2784         }
2785         
2786         return(0);
2787 }
2788
2789 void FtaParser_setfileinput(FILE *f){
2790         FtaParserrestart(NULL);
2791
2792         flex_fta_fileinput = f;
2793         flex_fta_stringinput = NULL;
2794         flex_fta_lineno = 1;
2795         flex_fta_ch = 0;
2796 }
2797
2798 void FtaParser_setstringinput(char *s){
2799         FtaParserrestart(NULL);
2800
2801         flex_fta_fileinput = NULL;
2802         flex_fta_stringinput = s;
2803         flex_fta_stringinput_ptr = 0;
2804         flex_fta_lineno = 1;
2805         flex_fta_ch = 0;
2806 }
2807         
2808                 
2809
2810
2811