5 #define YY_INT_ALIGNED short int
7 /* A lexical scanner generated by flex */
10 #define YY_FLEX_MAJOR_VERSION 2
11 #define YY_FLEX_MINOR_VERSION 5
12 #define YY_FLEX_SUBMINOR_VERSION 31
13 #if YY_FLEX_SUBMINOR_VERSION > 0
17 /* First, we deal with platform-specific or compiler-specific issues. */
19 /* begin standard C headers. */
25 /* end standard C headers. */
27 /* flex integer type definitions */
32 /* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
34 #if defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L
36 typedef int8_t flex_int8_t
;
37 typedef uint8_t flex_uint8_t
;
38 typedef int16_t flex_int16_t
;
39 typedef uint16_t flex_uint16_t
;
40 typedef int32_t flex_int32_t
;
41 typedef uint32_t flex_uint32_t
;
43 typedef signed char flex_int8_t
;
44 typedef short int flex_int16_t
;
45 typedef int flex_int32_t
;
46 typedef unsigned char flex_uint8_t
;
47 typedef unsigned short int flex_uint16_t
;
48 typedef unsigned int flex_uint32_t
;
51 /* Limits of integral types. */
53 #define INT8_MIN (-128)
56 #define INT16_MIN (-32767-1)
59 #define INT32_MIN (-2147483647-1)
62 #define INT8_MAX (127)
65 #define INT16_MAX (32767)
68 #define INT32_MAX (2147483647)
71 #define UINT8_MAX (255U)
74 #define UINT16_MAX (65535U)
77 #define UINT32_MAX (4294967295U)
80 #endif /* ! FLEXINT_H */
84 /* The "const" storage-class-modifier is valid. */
87 #else /* ! __cplusplus */
94 #endif /* ! __cplusplus */
102 /* Returned upon end-of-file. */
105 /* Promotes a possibly negative, possibly signed char to an unsigned
106 * integer for use as an array index. If the signed char is negative,
107 * we want to instead treat it as an 8-bit unsigned char, hence the
110 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
112 /* An opaque pointer. */
113 #ifndef YY_TYPEDEF_YY_SCANNER_T
114 #define YY_TYPEDEF_YY_SCANNER_T
115 typedef void* yyscan_t
;
118 /* For convenience, these vars (plus the bison vars far below)
119 are macros in the reentrant scanner. */
120 #define yyin yyg->yyin_r
121 #define yyout yyg->yyout_r
122 #define yyextra yyg->yyextra_r
123 #define yyleng yyg->yyleng_r
124 #define yytext yyg->yytext_r
125 #define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
126 #define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
127 #define yy_flex_debug yyg->yy_flex_debug_r
129 int ast_yylex_init (yyscan_t
* scanner
);
131 /* Enter a start condition. This macro really ought to take a parameter,
132 * but we do it the disgusting crufty way forced on us by the ()-less
133 * definition of BEGIN.
135 #define BEGIN yyg->yy_start = 1 + 2 *
137 /* Translate the current start state into a value that can be later handed
138 * to BEGIN to return to the state. The YYSTATE alias is for lex
141 #define YY_START ((yyg->yy_start - 1) / 2)
142 #define YYSTATE YY_START
144 /* Action number for EOF rule of a given start state. */
145 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
147 /* Special action meaning "start processing a new file". */
148 #define YY_NEW_FILE ast_yyrestart(yyin ,yyscanner )
150 #define YY_END_OF_BUFFER_CHAR 0
152 /* Size of default input buffer. */
154 #define YY_BUF_SIZE 16384
157 #ifndef YY_TYPEDEF_YY_BUFFER_STATE
158 #define YY_TYPEDEF_YY_BUFFER_STATE
159 typedef struct yy_buffer_state
*YY_BUFFER_STATE
;
162 #define EOB_ACT_CONTINUE_SCAN 0
163 #define EOB_ACT_END_OF_FILE 1
164 #define EOB_ACT_LAST_MATCH 2
166 #define YY_LESS_LINENO(n)
168 /* Return all but the first "n" matched characters back to the input stream. */
172 /* Undo effects of setting up yytext. */ \
173 int yyless_macro_arg = (n); \
174 YY_LESS_LINENO(yyless_macro_arg);\
175 *yy_cp = yyg->yy_hold_char; \
176 YY_RESTORE_YY_MORE_OFFSET \
177 yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
178 YY_DO_BEFORE_ACTION; /* set up yytext again */ \
182 #define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
184 /* The following is because we cannot portably get our hands on size_t
185 * (without autoconf's help, which isn't available because we want
186 * flex-generated scanners to compile on their own).
189 #ifndef YY_TYPEDEF_YY_SIZE_T
190 #define YY_TYPEDEF_YY_SIZE_T
191 typedef unsigned int yy_size_t
;
194 #ifndef YY_STRUCT_YY_BUFFER_STATE
195 #define YY_STRUCT_YY_BUFFER_STATE
196 struct yy_buffer_state
200 char *yy_ch_buf
; /* input buffer */
201 char *yy_buf_pos
; /* current position in input buffer */
203 /* Size of input buffer in bytes, not including room for EOB
206 yy_size_t yy_buf_size
;
208 /* Number of characters read into yy_ch_buf, not including EOB
213 /* Whether we "own" the buffer - i.e., we know we created it,
214 * and can realloc() it to grow it, and should free() it to
217 int yy_is_our_buffer
;
219 /* Whether this is an "interactive" input source; if so, and
220 * if we're using stdio for input, then we want to use getc()
221 * instead of fread(), to make sure we stop fetching input after
224 int yy_is_interactive
;
226 /* Whether we're considered to be at the beginning of a line.
227 * If so, '^' rules will be active on the next match, otherwise
232 int yy_bs_lineno
; /**< The line count. */
233 int yy_bs_column
; /**< The column count. */
235 /* Whether to try to fill the input buffer when we reach the
240 int yy_buffer_status
;
242 #define YY_BUFFER_NEW 0
243 #define YY_BUFFER_NORMAL 1
244 /* When an EOF's been seen but there's still some text to process
245 * then we mark the buffer as YY_EOF_PENDING, to indicate that we
246 * shouldn't try reading from the input source any more. We might
247 * still have a bunch of tokens to match, though, because of
248 * possible backing-up.
250 * When we actually see the EOF, we change the status to "new"
251 * (via ast_yyrestart()), so that the user can continue scanning by
252 * just pointing yyin at a new input file.
254 #define YY_BUFFER_EOF_PENDING 2
257 #endif /* !YY_STRUCT_YY_BUFFER_STATE */
259 /* We provide macros for accessing buffer states in case in the
260 * future we want to put the buffer states in a more general
263 * Returns the top of the stack, or NULL.
265 #define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \
266 ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \
269 /* Same as previous macro, but useful when we know that the buffer stack is not
270 * NULL or when we need an lvalue. For internal use only.
272 #define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
274 void ast_yyrestart (FILE *input_file
,yyscan_t yyscanner
);
275 void ast_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer
,yyscan_t yyscanner
);
276 YY_BUFFER_STATE
ast_yy_create_buffer (FILE *file
,int size
,yyscan_t yyscanner
);
277 void ast_yy_delete_buffer (YY_BUFFER_STATE b
,yyscan_t yyscanner
);
278 void ast_yy_flush_buffer (YY_BUFFER_STATE b
,yyscan_t yyscanner
);
279 void ast_yypush_buffer_state (YY_BUFFER_STATE new_buffer
,yyscan_t yyscanner
);
280 void ast_yypop_buffer_state (yyscan_t yyscanner
);
282 static void ast_yyensure_buffer_stack (yyscan_t yyscanner
);
283 static void ast_yy_load_buffer_state (yyscan_t yyscanner
);
284 static void ast_yy_init_buffer (YY_BUFFER_STATE b
,FILE *file
,yyscan_t yyscanner
);
286 #define YY_FLUSH_BUFFER ast_yy_flush_buffer(YY_CURRENT_BUFFER ,yyscanner)
288 YY_BUFFER_STATE
ast_yy_scan_buffer (char *base
,yy_size_t size
,yyscan_t yyscanner
);
289 YY_BUFFER_STATE
ast_yy_scan_string (yyconst
char *yy_str
,yyscan_t yyscanner
);
290 YY_BUFFER_STATE
ast_yy_scan_bytes (yyconst
char *bytes
,int len
,yyscan_t yyscanner
);
292 void *ast_yyalloc (yy_size_t
,yyscan_t yyscanner
);
293 void *ast_yyrealloc (void *,yy_size_t
,yyscan_t yyscanner
);
294 void ast_yyfree (void * ,yyscan_t yyscanner
);
296 #define yy_new_buffer ast_yy_create_buffer
298 #define yy_set_interactive(is_interactive) \
300 if ( ! YY_CURRENT_BUFFER ){ \
301 ast_yyensure_buffer_stack (yyscanner); \
302 YY_CURRENT_BUFFER_LVALUE = \
303 ast_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
305 YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
308 #define yy_set_bol(at_bol) \
310 if ( ! YY_CURRENT_BUFFER ){\
311 ast_yyensure_buffer_stack (yyscanner); \
312 YY_CURRENT_BUFFER_LVALUE = \
313 ast_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
315 YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
318 #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
320 /* Begin user sect3 */
322 #define ast_yywrap(n) 1
323 #define YY_SKIP_YYWRAP
325 typedef char YY_CHAR
;
327 typedef int yy_state_type
;
329 #define yytext_ptr yytext_r
330 static yyconst flex_int16_t yy_nxt
[][128] =
333 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
334 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
335 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
336 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
337 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
338 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
339 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
340 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
341 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
342 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
344 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
345 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
346 0, 0, 0, 0, 0, 0, 0, 0
350 7, 8, 8, 8, 8, 8, 8, 8, 8, 9,
351 10, 8, 8, 9, 8, 8, 8, 8, 8, 8,
352 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
353 8, 8, 9, 11, 12, 13, 14, 15, 16, 13,
354 17, 18, 19, 20, 13, 21, 13, 22, 23, 23,
355 23, 23, 23, 23, 23, 23, 23, 23, 24, 13,
356 25, 26, 27, 28, 13, 13, 13, 13, 13, 13,
358 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
359 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
360 13, 8, 13, 8, 13, 13, 8, 13, 13, 13,
361 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
362 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
363 13, 13, 13, 8, 29, 8, 8, 8
367 7, 8, 8, 8, 8, 8, 8, 8, 8, 9,
368 10, 8, 8, 9, 8, 8, 8, 8, 8, 8,
369 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
370 8, 8, 9, 11, 12, 13, 14, 15, 16, 13,
372 17, 18, 19, 20, 13, 21, 13, 22, 23, 23,
373 23, 23, 23, 23, 23, 23, 23, 23, 24, 13,
374 25, 26, 27, 28, 13, 13, 13, 13, 13, 13,
375 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
376 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
377 13, 8, 13, 8, 13, 13, 8, 13, 13, 13,
378 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
379 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
380 13, 13, 13, 8, 29, 8, 8, 8
384 7, 30, 30, 30, 30, 30, 30, 30, 30, 30,
386 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
387 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
388 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
389 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
390 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
391 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
392 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
393 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
394 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
395 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
397 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
398 30, 30, 30, 31, 30, 32, 30, 30
402 7, 30, 30, 30, 30, 30, 30, 30, 30, 30,
403 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
404 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
405 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
406 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
407 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
408 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
409 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
411 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
412 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
413 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
414 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
415 30, 30, 30, 31, 30, 32, 30, 30
419 7, 33, 33, 33, 33, 33, 33, 33, 33, 34,
420 34, 33, 33, 34, 33, 33, 33, 33, 33, 33,
421 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
422 33, 33, 34, 34, 33, 33, 35, 34, 34, 33,
423 34, 34, 34, 34, 33, 34, 33, 34, 33, 33,
425 33, 33, 33, 33, 33, 33, 33, 33, 34, 33,
426 34, 34, 34, 34, 33, 33, 33, 33, 33, 33,
427 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
428 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
429 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
430 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
431 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
432 33, 33, 33, 33, 34, 33, 33, 33
436 7, 33, 33, 33, 33, 33, 33, 33, 33, 34,
437 34, 33, 33, 34, 33, 33, 33, 33, 33, 33,
439 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
440 33, 33, 34, 34, 33, 33, 35, 34, 34, 33,
441 34, 34, 34, 34, 33, 34, 33, 34, 33, 33,
442 33, 33, 33, 33, 33, 33, 33, 33, 34, 33,
443 34, 34, 34, 34, 33, 33, 33, 33, 33, 33,
444 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
445 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
446 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
447 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
448 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
450 33, 33, 33, 33, 34, 33, 33, 33
454 -7, -7, -7, -7, -7, -7, -7, -7, -7, -7,
455 -7, -7, -7, -7, -7, -7, -7, -7, -7, -7,
456 -7, -7, -7, -7, -7, -7, -7, -7, -7, -7,
457 -7, -7, -7, -7, -7, -7, -7, -7, -7, -7,
458 -7, -7, -7, -7, -7, -7, -7, -7, -7, -7,
459 -7, -7, -7, -7, -7, -7, -7, -7, -7, -7,
460 -7, -7, -7, -7, -7, -7, -7, -7, -7, -7,
461 -7, -7, -7, -7, -7, -7, -7, -7, -7, -7,
462 -7, -7, -7, -7, -7, -7, -7, -7, -7, -7,
464 -7, -7, -7, -7, -7, -7, -7, -7, -7, -7,
465 -7, -7, -7, -7, -7, -7, -7, -7, -7, -7,
466 -7, -7, -7, -7, -7, -7, -7, -7, -7, -7,
467 -7, -7, -7, -7, -7, -7, -7, -7
471 7, -8, -8, -8, -8, -8, -8, -8, -8, -8,
472 -8, -8, -8, -8, -8, -8, -8, -8, -8, -8,
473 -8, -8, -8, -8, -8, -8, -8, -8, -8, -8,
474 -8, -8, -8, -8, -8, -8, -8, -8, -8, -8,
475 -8, -8, -8, -8, -8, -8, -8, -8, -8, -8,
476 -8, -8, -8, -8, -8, -8, -8, -8, -8, -8,
478 -8, -8, -8, -8, -8, -8, -8, -8, -8, -8,
479 -8, -8, -8, -8, -8, -8, -8, -8, -8, -8,
480 -8, -8, -8, -8, -8, -8, -8, -8, -8, -8,
481 -8, -8, -8, -8, -8, -8, -8, -8, -8, -8,
482 -8, -8, -8, -8, -8, -8, -8, -8, -8, -8,
483 -8, -8, -8, -8, -8, -8, -8, -8, -8, -8,
484 -8, -8, -8, -8, -8, -8, -8, -8
488 7, -9, -9, -9, -9, -9, -9, -9, -9, -9,
489 -9, -9, -9, -9, -9, -9, -9, -9, -9, -9,
490 -9, -9, -9, -9, -9, -9, -9, -9, -9, -9,
492 -9, -9, -9, -9, -9, -9, -9, -9, -9, -9,
493 -9, -9, -9, -9, -9, -9, -9, -9, -9, -9,
494 -9, -9, -9, -9, -9, -9, -9, -9, -9, -9,
495 -9, -9, -9, -9, -9, -9, -9, -9, -9, -9,
496 -9, -9, -9, -9, -9, -9, -9, -9, -9, -9,
497 -9, -9, -9, -9, -9, -9, -9, -9, -9, -9,
498 -9, -9, -9, -9, -9, -9, -9, -9, -9, -9,
499 -9, -9, -9, -9, -9, -9, -9, -9, -9, -9,
500 -9, -9, -9, -9, -9, -9, -9, -9, -9, -9,
501 -9, -9, -9, -9, -9, -9, -9, -9
506 7, -10, -10, -10, -10, -10, -10, -10, -10, -10,
507 -10, -10, -10, -10, -10, -10, -10, -10, -10, -10,
508 -10, -10, -10, -10, -10, -10, -10, -10, -10, -10,
509 -10, -10, -10, -10, -10, -10, -10, -10, -10, -10,
510 -10, -10, -10, -10, -10, -10, -10, -10, -10, -10,
511 -10, -10, -10, -10, -10, -10, -10, -10, -10, -10,
512 -10, -10, -10, -10, -10, -10, -10, -10, -10, -10,
513 -10, -10, -10, -10, -10, -10, -10, -10, -10, -10,
514 -10, -10, -10, -10, -10, -10, -10, -10, -10, -10,
515 -10, -10, -10, -10, -10, -10, -10, -10, -10, -10,
517 -10, -10, -10, -10, -10, -10, -10, -10, -10, -10,
518 -10, -10, -10, -10, -10, -10, -10, -10, -10, -10,
519 -10, -10, -10, -10, -10, -10, -10, -10
523 7, -11, -11, -11, -11, -11, -11, -11, -11, -11,
524 -11, -11, -11, -11, -11, -11, -11, -11, -11, -11,
525 -11, -11, -11, -11, -11, -11, -11, -11, -11, -11,
526 -11, -11, -11, -11, -11, -11, -11, -11, -11, -11,
527 -11, -11, -11, -11, -11, -11, -11, -11, -11, -11,
528 -11, -11, -11, -11, -11, -11, -11, -11, -11, -11,
529 -11, 36, -11, -11, -11, -11, -11, -11, -11, -11,
531 -11, -11, -11, -11, -11, -11, -11, -11, -11, -11,
532 -11, -11, -11, -11, -11, -11, -11, -11, -11, -11,
533 -11, -11, -11, -11, -11, -11, -11, -11, -11, -11,
534 -11, -11, -11, -11, -11, -11, -11, -11, -11, -11,
535 -11, -11, -11, -11, -11, -11, -11, -11, -11, -11,
536 -11, -11, -11, -11, -11, -11, -11, -11
540 7, 37, 37, 37, 37, 37, 37, 37, 37, 37,
541 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
542 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
543 37, 37, 37, 37, 38, 37, 37, 37, 37, 37,
545 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
546 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
547 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
548 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
549 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
550 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
551 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
552 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
553 37, 37, 37, 37, 37, 37, 37, 37
557 7, -13, -13, -13, -13, -13, -13, -13, -13, -13,
559 -13, -13, -13, -13, -13, -13, -13, -13, -13, -13,
560 -13, -13, -13, -13, -13, -13, -13, -13, -13, -13,
561 -13, -13, -13, -13, -13, 39, 39, -13, -13, 39,
562 -13, -13, -13, -13, 39, -13, 39, -13, 39, 39,
563 39, 39, 39, 39, 39, 39, 39, 39, -13, 39,
564 -13, -13, -13, -13, 39, 39, 39, 39, 39, 39,
565 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
566 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
567 39, -13, 39, -13, 39, 39, -13, 39, 39, 39,
568 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
570 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
571 39, 39, 39, -13, -13, -13, -13, -13
575 7, -14, -14, -14, -14, -14, -14, -14, -14, -14,
576 -14, -14, -14, -14, -14, -14, -14, -14, -14, -14,
577 -14, -14, -14, -14, -14, -14, -14, -14, -14, -14,
578 -14, -14, -14, -14, -14, 39, 39, -14, -14, 39,
579 -14, -14, -14, -14, 39, -14, 39, -14, 39, 39,
580 39, 39, 39, 39, 39, 39, 39, 39, -14, 39,
581 -14, -14, -14, -14, 39, 39, 39, 39, 39, 39,
582 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
584 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
585 39, -14, 39, -14, 39, 39, -14, 39, 39, 39,
586 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
587 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
588 39, 39, 39, 40, -14, -14, -14, -14
592 7, -15, -15, -15, -15, -15, -15, -15, -15, -15,
593 -15, -15, -15, -15, -15, -15, -15, -15, -15, -15,
594 -15, -15, -15, -15, -15, -15, -15, -15, -15, -15,
595 -15, -15, -15, -15, -15, -15, -15, -15, -15, -15,
596 -15, -15, -15, -15, -15, -15, -15, -15, -15, -15,
598 -15, -15, -15, -15, -15, -15, -15, -15, -15, -15,
599 -15, -15, -15, -15, -15, -15, -15, -15, -15, -15,
600 -15, -15, -15, -15, -15, -15, -15, -15, -15, -15,
601 -15, -15, -15, -15, -15, -15, -15, -15, -15, -15,
602 -15, -15, -15, -15, -15, -15, -15, -15, -15, -15,
603 -15, -15, -15, -15, -15, -15, -15, -15, -15, -15,
604 -15, -15, -15, -15, -15, -15, -15, -15, -15, -15,
605 -15, -15, -15, -15, -15, -15, -15, -15
609 7, -16, -16, -16, -16, -16, -16, -16, -16, -16,
610 -16, -16, -16, -16, -16, -16, -16, -16, -16, -16,
612 -16, -16, -16, -16, -16, -16, -16, -16, -16, -16,
613 -16, -16, -16, -16, -16, -16, -16, -16, 41, -16,
614 -16, -16, -16, -16, -16, -16, -16, -16, -16, -16,
615 -16, -16, -16, -16, -16, -16, -16, -16, -16, -16,
616 -16, -16, -16, -16, -16, -16, -16, -16, -16, -16,
617 -16, -16, -16, -16, -16, -16, -16, -16, -16, -16,
618 -16, -16, -16, -16, -16, -16, -16, -16, -16, -16,
619 -16, -16, -16, -16, -16, -16, -16, -16, -16, -16,
620 -16, -16, -16, -16, -16, -16, -16, -16, -16, -16,
621 -16, -16, -16, -16, -16, -16, -16, -16, -16, -16,
623 -16, -16, -16, -16, -16, -16, -16, -16
627 7, -17, -17, -17, -17, -17, -17, -17, -17, -17,
628 -17, -17, -17, -17, -17, -17, -17, -17, -17, -17,
629 -17, -17, -17, -17, -17, -17, -17, -17, -17, -17,
630 -17, -17, -17, -17, -17, -17, -17, -17, -17, -17,
631 -17, -17, -17, -17, -17, -17, -17, -17, -17, -17,
632 -17, -17, -17, -17, -17, -17, -17, -17, -17, -17,
633 -17, -17, -17, -17, -17, -17, -17, -17, -17, -17,
634 -17, -17, -17, -17, -17, -17, -17, -17, -17, -17,
635 -17, -17, -17, -17, -17, -17, -17, -17, -17, -17,
637 -17, -17, -17, -17, -17, -17, -17, -17, -17, -17,
638 -17, -17, -17, -17, -17, -17, -17, -17, -17, -17,
639 -17, -17, -17, -17, -17, -17, -17, -17, -17, -17,
640 -17, -17, -17, -17, -17, -17, -17, -17
644 7, -18, -18, -18, -18, -18, -18, -18, -18, -18,
645 -18, -18, -18, -18, -18, -18, -18, -18, -18, -18,
646 -18, -18, -18, -18, -18, -18, -18, -18, -18, -18,
647 -18, -18, -18, -18, -18, -18, -18, -18, -18, -18,
648 -18, -18, -18, -18, -18, -18, -18, -18, -18, -18,
649 -18, -18, -18, -18, -18, -18, -18, -18, -18, -18,
651 -18, -18, -18, -18, -18, -18, -18, -18, -18, -18,
652 -18, -18, -18, -18, -18, -18, -18, -18, -18, -18,
653 -18, -18, -18, -18, -18, -18, -18, -18, -18, -18,
654 -18, -18, -18, -18, -18, -18, -18, -18, -18, -18,
655 -18, -18, -18, -18, -18, -18, -18, -18, -18, -18,
656 -18, -18, -18, -18, -18, -18, -18, -18, -18, -18,
657 -18, -18, -18, -18, -18, -18, -18, -18
661 7, -19, -19, -19, -19, -19, -19, -19, -19, -19,
662 -19, -19, -19, -19, -19, -19, -19, -19, -19, -19,
663 -19, -19, -19, -19, -19, -19, -19, -19, -19, -19,
665 -19, -19, -19, -19, -19, -19, -19, -19, -19, -19,
666 -19, -19, -19, -19, -19, -19, -19, -19, -19, -19,
667 -19, -19, -19, -19, -19, -19, -19, -19, -19, -19,
668 -19, -19, -19, -19, -19, -19, -19, -19, -19, -19,
669 -19, -19, -19, -19, -19, -19, -19, -19, -19, -19,
670 -19, -19, -19, -19, -19, -19, -19, -19, -19, -19,
671 -19, -19, -19, -19, -19, -19, -19, -19, -19, -19,
672 -19, -19, -19, -19, -19, -19, -19, -19, -19, -19,
673 -19, -19, -19, -19, -19, -19, -19, -19, -19, -19,
674 -19, -19, -19, -19, -19, -19, -19, -19
679 7, -20, -20, -20, -20, -20, -20, -20, -20, -20,
680 -20, -20, -20, -20, -20, -20, -20, -20, -20, -20,
681 -20, -20, -20, -20, -20, -20, -20, -20, -20, -20,
682 -20, -20, -20, -20, -20, -20, -20, -20, -20, -20,
683 -20, -20, -20, -20, -20, -20, -20, -20, -20, -20,
684 -20, -20, -20, -20, -20, -20, -20, -20, -20, -20,
685 -20, -20, -20, -20, -20, -20, -20, -20, -20, -20,
686 -20, -20, -20, -20, -20, -20, -20, -20, -20, -20,
687 -20, -20, -20, -20, -20, -20, -20, -20, -20, -20,
688 -20, -20, -20, -20, -20, -20, -20, -20, -20, -20,
690 -20, -20, -20, -20, -20, -20, -20, -20, -20, -20,
691 -20, -20, -20, -20, -20, -20, -20, -20, -20, -20,
692 -20, -20, -20, -20, -20, -20, -20, -20
696 7, -21, -21, -21, -21, -21, -21, -21, -21, -21,
697 -21, -21, -21, -21, -21, -21, -21, -21, -21, -21,
698 -21, -21, -21, -21, -21, -21, -21, -21, -21, -21,
699 -21, -21, -21, -21, -21, -21, -21, -21, -21, -21,
700 -21, -21, -21, -21, -21, -21, -21, -21, -21, -21,
701 -21, -21, -21, -21, -21, -21, -21, -21, -21, -21,
702 -21, -21, -21, -21, -21, -21, -21, -21, -21, -21,
704 -21, -21, -21, -21, -21, -21, -21, -21, -21, -21,
705 -21, -21, -21, -21, -21, -21, -21, -21, -21, -21,
706 -21, -21, -21, -21, -21, -21, -21, -21, -21, -21,
707 -21, -21, -21, -21, -21, -21, -21, -21, -21, -21,
708 -21, -21, -21, -21, -21, -21, -21, -21, -21, -21,
709 -21, -21, -21, -21, -21, -21, -21, -21
713 7, -22, -22, -22, -22, -22, -22, -22, -22, -22,
714 -22, -22, -22, -22, -22, -22, -22, -22, -22, -22,
715 -22, -22, -22, -22, -22, -22, -22, -22, -22, -22,
716 -22, -22, -22, -22, -22, -22, -22, -22, -22, -22,
718 -22, -22, -22, -22, -22, -22, -22, -22, -22, -22,
719 -22, -22, -22, -22, -22, -22, -22, -22, -22, -22,
720 -22, -22, -22, -22, -22, -22, -22, -22, -22, -22,
721 -22, -22, -22, -22, -22, -22, -22, -22, -22, -22,
722 -22, -22, -22, -22, -22, -22, -22, -22, -22, -22,
723 -22, -22, -22, -22, -22, -22, -22, -22, -22, -22,
724 -22, -22, -22, -22, -22, -22, -22, -22, -22, -22,
725 -22, -22, -22, -22, -22, -22, -22, -22, -22, -22,
726 -22, -22, -22, -22, -22, -22, -22, -22
730 7, -23, -23, -23, -23, -23, -23, -23, -23, -23,
732 -23, -23, -23, -23, -23, -23, -23, -23, -23, -23,
733 -23, -23, -23, -23, -23, -23, -23, -23, -23, -23,
734 -23, -23, -23, -23, -23, 39, 39, -23, -23, 39,
735 -23, -23, -23, -23, 39, -23, 39, -23, 42, 42,
736 42, 42, 42, 42, 42, 42, 42, 42, -23, 39,
737 -23, -23, -23, -23, 39, 39, 39, 39, 39, 39,
738 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
739 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
740 39, -23, 39, -23, 39, 39, -23, 39, 39, 39,
741 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
743 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
744 39, 39, 39, -23, -23, -23, -23, -23
748 7, -24, -24, -24, -24, -24, -24, -24, -24, -24,
749 -24, -24, -24, -24, -24, -24, -24, -24, -24, -24,
750 -24, -24, -24, -24, -24, -24, -24, -24, -24, -24,
751 -24, -24, -24, -24, -24, -24, -24, -24, -24, -24,
752 -24, -24, -24, -24, -24, -24, -24, -24, -24, -24,
753 -24, -24, -24, -24, -24, -24, -24, -24, 43, -24,
754 -24, -24, -24, -24, -24, -24, -24, -24, -24, -24,
755 -24, -24, -24, -24, -24, -24, -24, -24, -24, -24,
757 -24, -24, -24, -24, -24, -24, -24, -24, -24, -24,
758 -24, -24, -24, -24, -24, -24, -24, -24, -24, -24,
759 -24, -24, -24, -24, -24, -24, -24, -24, -24, -24,
760 -24, -24, -24, -24, -24, -24, -24, -24, -24, -24,
761 -24, -24, -24, -24, -24, -24, -24, -24
765 7, -25, -25, -25, -25, -25, -25, -25, -25, -25,
766 -25, -25, -25, -25, -25, -25, -25, -25, -25, -25,
767 -25, -25, -25, -25, -25, -25, -25, -25, -25, -25,
768 -25, -25, -25, -25, -25, -25, -25, -25, -25, -25,
769 -25, -25, -25, -25, -25, -25, -25, -25, -25, -25,
771 -25, -25, -25, -25, -25, -25, -25, -25, -25, -25,
772 -25, 44, -25, -25, -25, -25, -25, -25, -25, -25,
773 -25, -25, -25, -25, -25, -25, -25, -25, -25, -25,
774 -25, -25, -25, -25, -25, -25, -25, -25, -25, -25,
775 -25, -25, -25, -25, -25, -25, -25, -25, -25, -25,
776 -25, -25, -25, -25, -25, -25, -25, -25, -25, -25,
777 -25, -25, -25, -25, -25, -25, -25, -25, -25, -25,
778 -25, -25, -25, -25, -25, -25, -25, -25
782 7, -26, -26, -26, -26, -26, -26, -26, -26, -26,
783 -26, -26, -26, -26, -26, -26, -26, -26, -26, -26,
785 -26, -26, -26, -26, -26, -26, -26, -26, -26, -26,
786 -26, -26, -26, -26, -26, -26, -26, -26, -26, -26,
787 -26, -26, -26, -26, -26, -26, -26, -26, -26, -26,
788 -26, -26, -26, -26, -26, -26, -26, -26, -26, -26,
789 -26, 45, -26, -26, -26, -26, -26, -26, -26, -26,
790 -26, -26, -26, -26, -26, -26, -26, -26, -26, -26,
791 -26, -26, -26, -26, -26, -26, -26, -26, -26, -26,
792 -26, -26, -26, -26, -26, -26, -26, -26, -26, -26,
793 -26, -26, -26, -26, -26, -26, -26, -26, -26, -26,
794 -26, -26, -26, -26, -26, -26, -26, -26, -26, -26,
796 -26, -26, -26, -26, -26, -26, 46, -26
800 7, -27, -27, -27, -27, -27, -27, -27, -27, -27,
801 -27, -27, -27, -27, -27, -27, -27, -27, -27, -27,
802 -27, -27, -27, -27, -27, -27, -27, -27, -27, -27,
803 -27, -27, -27, -27, -27, -27, -27, -27, -27, -27,
804 -27, -27, -27, -27, -27, -27, -27, -27, -27, -27,
805 -27, -27, -27, -27, -27, -27, -27, -27, -27, -27,
806 -27, 47, -27, -27, -27, -27, -27, -27, -27, -27,
807 -27, -27, -27, -27, -27, -27, -27, -27, -27, -27,
808 -27, -27, -27, -27, -27, -27, -27, -27, -27, -27,
810 -27, -27, -27, -27, -27, -27, -27, -27, -27, -27,
811 -27, -27, -27, -27, -27, -27, -27, -27, -27, -27,
812 -27, -27, -27, -27, -27, -27, -27, -27, -27, -27,
813 -27, -27, -27, -27, -27, -27, -27, -27
817 7, -28, -28, -28, -28, -28, -28, -28, -28, -28,
818 -28, -28, -28, -28, -28, -28, -28, -28, -28, -28,
819 -28, -28, -28, -28, -28, -28, -28, -28, -28, -28,
820 -28, -28, -28, -28, -28, -28, -28, -28, -28, -28,
821 -28, -28, -28, -28, -28, -28, -28, -28, -28, -28,
822 -28, -28, -28, -28, -28, -28, -28, -28, -28, -28,
824 -28, -28, -28, -28, -28, -28, -28, -28, -28, -28,
825 -28, -28, -28, -28, -28, -28, -28, -28, -28, -28,
826 -28, -28, -28, -28, -28, -28, -28, -28, -28, -28,
827 -28, -28, -28, -28, -28, -28, -28, -28, -28, -28,
828 -28, -28, -28, -28, -28, -28, -28, -28, -28, -28,
829 -28, -28, -28, -28, -28, -28, -28, -28, -28, -28,
830 -28, -28, -28, -28, -28, -28, -28, -28
834 7, -29, -29, -29, -29, -29, -29, -29, -29, -29,
835 -29, -29, -29, -29, -29, -29, -29, -29, -29, -29,
836 -29, -29, -29, -29, -29, -29, -29, -29, -29, -29,
838 -29, -29, -29, -29, -29, -29, -29, -29, -29, -29,
839 -29, -29, -29, -29, -29, -29, -29, -29, -29, -29,
840 -29, -29, -29, -29, -29, -29, -29, -29, -29, -29,
841 -29, -29, -29, -29, -29, -29, -29, -29, -29, -29,
842 -29, -29, -29, -29, -29, -29, -29, -29, -29, -29,
843 -29, -29, -29, -29, -29, -29, -29, -29, -29, -29,
844 -29, -29, -29, -29, -29, -29, -29, -29, -29, -29,
845 -29, -29, -29, -29, -29, -29, -29, -29, -29, -29,
846 -29, -29, -29, -29, -29, -29, -29, -29, -29, -29,
847 -29, -29, -29, -29, 48, -29, -29, -29
852 7, 49, 49, 49, 49, 49, 49, 49, 49, 49,
853 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
854 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
855 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
856 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
857 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
858 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
859 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
860 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
861 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
863 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
864 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
865 49, 49, 49, 50, 49, 51, 49, 49
869 7, -31, -31, -31, -31, -31, -31, -31, -31, -31,
870 -31, -31, -31, -31, -31, -31, -31, -31, -31, -31,
871 -31, -31, -31, -31, -31, -31, -31, -31, -31, -31,
872 -31, -31, -31, -31, -31, -31, -31, -31, -31, -31,
873 -31, -31, -31, -31, -31, -31, -31, -31, -31, -31,
874 -31, -31, -31, -31, -31, -31, -31, -31, -31, -31,
875 -31, -31, -31, -31, -31, -31, -31, -31, -31, -31,
877 -31, -31, -31, -31, -31, -31, -31, -31, -31, -31,
878 -31, -31, -31, -31, -31, -31, -31, -31, -31, -31,
879 -31, -31, -31, -31, -31, -31, -31, -31, -31, -31,
880 -31, -31, -31, -31, -31, -31, -31, -31, -31, -31,
881 -31, -31, -31, -31, -31, -31, -31, -31, -31, -31,
882 -31, -31, -31, -31, -31, -31, -31, -31
886 7, -32, -32, -32, -32, -32, -32, -32, -32, -32,
887 -32, -32, -32, -32, -32, -32, -32, -32, -32, -32,
888 -32, -32, -32, -32, -32, -32, -32, -32, -32, -32,
889 -32, -32, -32, -32, -32, -32, -32, -32, -32, -32,
891 -32, -32, -32, -32, -32, -32, -32, -32, -32, -32,
892 -32, -32, -32, -32, -32, -32, -32, -32, -32, -32,
893 -32, -32, -32, -32, -32, -32, -32, -32, -32, -32,
894 -32, -32, -32, -32, -32, -32, -32, -32, -32, -32,
895 -32, -32, -32, -32, -32, -32, -32, -32, -32, -32,
896 -32, -32, -32, -32, -32, -32, -32, -32, -32, -32,
897 -32, -32, -32, -32, -32, -32, -32, -32, -32, -32,
898 -32, -32, -32, -32, -32, -32, -32, -32, -32, -32,
899 -32, -32, -32, -32, -32, -32, -32, -32
903 7, 52, 52, 52, 52, 52, 52, 52, 52, -33,
905 -33, 52, 52, -33, 52, 52, 52, 52, 52, 52,
906 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,
907 52, 52, -33, -33, 52, 52, -33, -33, -33, 52,
908 -33, -33, -33, -33, 52, -33, 52, -33, 52, 52,
909 52, 52, 52, 52, 52, 52, 52, 52, -33, 52,
910 -33, -33, -33, -33, 52, 52, 52, 52, 52, 52,
911 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,
912 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,
913 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,
914 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,
916 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,
917 52, 52, 52, 52, -33, 52, 52, 52
921 7, -34, -34, -34, -34, -34, -34, -34, -34, -34,
922 -34, -34, -34, -34, -34, -34, -34, -34, -34, -34,
923 -34, -34, -34, -34, -34, -34, -34, -34, -34, -34,
924 -34, -34, -34, -34, -34, -34, -34, -34, -34, -34,
925 -34, -34, -34, -34, -34, -34, -34, -34, -34, -34,
926 -34, -34, -34, -34, -34, -34, -34, -34, -34, -34,
927 -34, -34, -34, -34, -34, -34, -34, -34, -34, -34,
928 -34, -34, -34, -34, -34, -34, -34, -34, -34, -34,
930 -34, -34, -34, -34, -34, -34, -34, -34, -34, -34,
931 -34, -34, -34, -34, -34, -34, -34, -34, -34, -34,
932 -34, -34, -34, -34, -34, -34, -34, -34, -34, -34,
933 -34, -34, -34, -34, -34, -34, -34, -34, -34, -34,
934 -34, -34, -34, -34, -34, -34, -34, -34
938 7, -35, -35, -35, -35, -35, -35, -35, -35, -35,
939 -35, -35, -35, -35, -35, -35, -35, -35, -35, -35,
940 -35, -35, -35, -35, -35, -35, -35, -35, -35, -35,
941 -35, -35, -35, -35, -35, -35, -35, -35, -35, -35,
942 -35, -35, -35, -35, -35, -35, -35, -35, -35, -35,
944 -35, -35, -35, -35, -35, -35, -35, -35, -35, -35,
945 -35, -35, -35, -35, -35, -35, -35, -35, -35, -35,
946 -35, -35, -35, -35, -35, -35, -35, -35, -35, -35,
947 -35, -35, -35, -35, -35, -35, -35, -35, -35, -35,
948 -35, -35, -35, -35, -35, -35, -35, -35, -35, -35,
949 -35, -35, -35, -35, -35, -35, -35, -35, -35, -35,
950 -35, -35, -35, -35, -35, -35, -35, -35, -35, -35,
951 -35, -35, -35, 53, -35, -35, -35, -35
955 7, -36, -36, -36, -36, -36, -36, -36, -36, -36,
956 -36, -36, -36, -36, -36, -36, -36, -36, -36, -36,
958 -36, -36, -36, -36, -36, -36, -36, -36, -36, -36,
959 -36, -36, -36, -36, -36, -36, -36, -36, -36, -36,
960 -36, -36, -36, -36, -36, -36, -36, -36, -36, -36,
961 -36, -36, -36, -36, -36, -36, -36, -36, -36, -36,
962 -36, -36, -36, -36, -36, -36, -36, -36, -36, -36,
963 -36, -36, -36, -36, -36, -36, -36, -36, -36, -36,
964 -36, -36, -36, -36, -36, -36, -36, -36, -36, -36,
965 -36, -36, -36, -36, -36, -36, -36, -36, -36, -36,
966 -36, -36, -36, -36, -36, -36, -36, -36, -36, -36,
967 -36, -36, -36, -36, -36, -36, -36, -36, -36, -36,
969 -36, -36, -36, -36, -36, -36, -36, -36
973 7, 37, 37, 37, 37, 37, 37, 37, 37, 37,
974 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
975 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
976 37, 37, 37, 37, 38, 37, 37, 37, 37, 37,
977 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
978 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
979 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
980 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
981 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
983 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
984 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
985 37, 37, 37, 37, 37, 37, 37, 37, 37, 37,
986 37, 37, 37, 37, 37, 37, 37, 37
990 7, -38, -38, -38, -38, -38, -38, -38, -38, -38,
991 -38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
992 -38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
993 -38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
994 -38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
995 -38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
997 -38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
998 -38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
999 -38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
1000 -38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
1001 -38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
1002 -38, -38, -38, -38, -38, -38, -38, -38, -38, -38,
1003 -38, -38, -38, -38, -38, -38, -38, -38
1007 7, -39, -39, -39, -39, -39, -39, -39, -39, -39,
1008 -39, -39, -39, -39, -39, -39, -39, -39, -39, -39,
1009 -39, -39, -39, -39, -39, -39, -39, -39, -39, -39,
1011 -39, -39, -39, -39, -39, 39, 39, -39, -39, 39,
1012 -39, -39, -39, -39, 39, -39, 39, -39, 39, 39,
1013 39, 39, 39, 39, 39, 39, 39, 39, -39, 39,
1014 -39, -39, -39, -39, 39, 39, 39, 39, 39, 39,
1015 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
1016 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
1017 39, -39, 39, -39, 39, 39, -39, 39, 39, 39,
1018 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
1019 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
1020 39, 39, 39, -39, -39, -39, -39, -39
1025 7, -40, -40, -40, -40, -40, -40, -40, -40, -40,
1026 -40, -40, -40, -40, -40, -40, -40, -40, -40, -40,
1027 -40, -40, -40, -40, -40, -40, -40, -40, -40, -40,
1028 -40, -40, -40, -40, -40, -40, -40, -40, -40, -40,
1029 -40, -40, -40, -40, -40, -40, -40, -40, -40, -40,
1030 -40, -40, -40, -40, -40, -40, -40, -40, -40, -40,
1031 -40, -40, -40, -40, -40, -40, -40, -40, -40, -40,
1032 -40, -40, -40, -40, -40, -40, -40, -40, -40, -40,
1033 -40, -40, -40, -40, -40, -40, -40, -40, -40, -40,
1034 -40, -40, -40, -40, -40, -40, -40, -40, -40, -40,
1036 -40, -40, -40, -40, -40, -40, -40, -40, -40, -40,
1037 -40, -40, -40, -40, -40, -40, -40, -40, -40, -40,
1038 -40, -40, -40, -40, -40, -40, -40, -40
1042 7, -41, -41, -41, -41, -41, -41, -41, -41, -41,
1043 -41, -41, -41, -41, -41, -41, -41, -41, -41, -41,
1044 -41, -41, -41, -41, -41, -41, -41, -41, -41, -41,
1045 -41, -41, -41, -41, -41, -41, -41, -41, -41, -41,
1046 -41, -41, -41, -41, -41, -41, -41, -41, -41, -41,
1047 -41, -41, -41, -41, -41, -41, -41, -41, -41, -41,
1048 -41, -41, -41, -41, -41, -41, -41, -41, -41, -41,
1050 -41, -41, -41, -41, -41, -41, -41, -41, -41, -41,
1051 -41, -41, -41, -41, -41, -41, -41, -41, -41, -41,
1052 -41, -41, -41, -41, -41, -41, -41, -41, -41, -41,
1053 -41, -41, -41, -41, -41, -41, -41, -41, -41, -41,
1054 -41, -41, -41, -41, -41, -41, -41, -41, -41, -41,
1055 -41, -41, -41, -41, -41, -41, -41, -41
1059 7, -42, -42, -42, -42, -42, -42, -42, -42, -42,
1060 -42, -42, -42, -42, -42, -42, -42, -42, -42, -42,
1061 -42, -42, -42, -42, -42, -42, -42, -42, -42, -42,
1062 -42, -42, -42, -42, -42, 39, 39, -42, -42, 39,
1064 -42, -42, -42, -42, 39, -42, 39, -42, 42, 42,
1065 42, 42, 42, 42, 42, 42, 42, 42, -42, 39,
1066 -42, -42, -42, -42, 39, 39, 39, 39, 39, 39,
1067 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
1068 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
1069 39, -42, 39, -42, 39, 39, -42, 39, 39, 39,
1070 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
1071 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
1072 39, 39, 39, -42, -42, -42, -42, -42
1076 7, -43, -43, -43, -43, -43, -43, -43, -43, -43,
1078 -43, -43, -43, -43, -43, -43, -43, -43, -43, -43,
1079 -43, -43, -43, -43, -43, -43, -43, -43, -43, -43,
1080 -43, -43, -43, -43, -43, -43, -43, -43, -43, -43,
1081 -43, -43, -43, -43, -43, -43, -43, -43, -43, -43,
1082 -43, -43, -43, -43, -43, -43, -43, -43, -43, -43,
1083 -43, -43, -43, -43, -43, -43, -43, -43, -43, -43,
1084 -43, -43, -43, -43, -43, -43, -43, -43, -43, -43,
1085 -43, -43, -43, -43, -43, -43, -43, -43, -43, -43,
1086 -43, -43, -43, -43, -43, -43, -43, -43, -43, -43,
1087 -43, -43, -43, -43, -43, -43, -43, -43, -43, -43,
1089 -43, -43, -43, -43, -43, -43, -43, -43, -43, -43,
1090 -43, -43, -43, -43, -43, -43, -43, -43
1094 7, -44, -44, -44, -44, -44, -44, -44, -44, -44,
1095 -44, -44, -44, -44, -44, -44, -44, -44, -44, -44,
1096 -44, -44, -44, -44, -44, -44, -44, -44, -44, -44,
1097 -44, -44, -44, -44, -44, -44, -44, -44, -44, -44,
1098 -44, -44, -44, -44, -44, -44, -44, -44, -44, -44,
1099 -44, -44, -44, -44, -44, -44, -44, -44, -44, -44,
1100 -44, -44, -44, -44, -44, -44, -44, -44, -44, -44,
1101 -44, -44, -44, -44, -44, -44, -44, -44, -44, -44,
1103 -44, -44, -44, -44, -44, -44, -44, -44, -44, -44,
1104 -44, -44, -44, -44, -44, -44, -44, -44, -44, -44,
1105 -44, -44, -44, -44, -44, -44, -44, -44, -44, -44,
1106 -44, -44, -44, -44, -44, -44, -44, -44, -44, -44,
1107 -44, -44, -44, -44, -44, -44, -44, -44
1111 7, -45, -45, -45, -45, -45, -45, -45, -45, -45,
1112 -45, -45, -45, -45, -45, -45, -45, -45, -45, -45,
1113 -45, -45, -45, -45, -45, -45, -45, -45, -45, -45,
1114 -45, -45, -45, -45, -45, -45, -45, -45, -45, -45,
1115 -45, -45, -45, -45, -45, -45, -45, -45, -45, -45,
1117 -45, -45, -45, -45, -45, -45, -45, -45, -45, -45,
1118 -45, -45, -45, -45, -45, -45, -45, -45, -45, -45,
1119 -45, -45, -45, -45, -45, -45, -45, -45, -45, -45,
1120 -45, -45, -45, -45, -45, -45, -45, -45, -45, -45,
1121 -45, -45, -45, -45, -45, -45, -45, -45, -45, -45,
1122 -45, -45, -45, -45, -45, -45, -45, -45, -45, -45,
1123 -45, -45, -45, -45, -45, -45, -45, -45, -45, -45,
1124 -45, -45, -45, -45, -45, -45, -45, -45
1128 7, -46, -46, -46, -46, -46, -46, -46, -46, -46,
1129 -46, -46, -46, -46, -46, -46, -46, -46, -46, -46,
1131 -46, -46, -46, -46, -46, -46, -46, -46, -46, -46,
1132 -46, -46, -46, -46, -46, -46, -46, -46, -46, -46,
1133 -46, -46, -46, -46, -46, -46, -46, -46, -46, -46,
1134 -46, -46, -46, -46, -46, -46, -46, -46, -46, -46,
1135 -46, -46, -46, -46, -46, -46, -46, -46, -46, -46,
1136 -46, -46, -46, -46, -46, -46, -46, -46, -46, -46,
1137 -46, -46, -46, -46, -46, -46, -46, -46, -46, -46,
1138 -46, -46, -46, -46, -46, -46, -46, -46, -46, -46,
1139 -46, -46, -46, -46, -46, -46, -46, -46, -46, -46,
1140 -46, -46, -46, -46, -46, -46, -46, -46, -46, -46,
1142 -46, -46, -46, -46, -46, -46, -46, -46
1146 7, -47, -47, -47, -47, -47, -47, -47, -47, -47,
1147 -47, -47, -47, -47, -47, -47, -47, -47, -47, -47,
1148 -47, -47, -47, -47, -47, -47, -47, -47, -47, -47,
1149 -47, -47, -47, -47, -47, -47, -47, -47, -47, -47,
1150 -47, -47, -47, -47, -47, -47, -47, -47, -47, -47,
1151 -47, -47, -47, -47, -47, -47, -47, -47, -47, -47,
1152 -47, -47, -47, -47, -47, -47, -47, -47, -47, -47,
1153 -47, -47, -47, -47, -47, -47, -47, -47, -47, -47,
1154 -47, -47, -47, -47, -47, -47, -47, -47, -47, -47,
1156 -47, -47, -47, -47, -47, -47, -47, -47, -47, -47,
1157 -47, -47, -47, -47, -47, -47, -47, -47, -47, -47,
1158 -47, -47, -47, -47, -47, -47, -47, -47, -47, -47,
1159 -47, -47, -47, -47, -47, -47, -47, -47
1163 7, -48, -48, -48, -48, -48, -48, -48, -48, -48,
1164 -48, -48, -48, -48, -48, -48, -48, -48, -48, -48,
1165 -48, -48, -48, -48, -48, -48, -48, -48, -48, -48,
1166 -48, -48, -48, -48, -48, -48, -48, -48, -48, -48,
1167 -48, -48, -48, -48, -48, -48, -48, -48, -48, -48,
1168 -48, -48, -48, -48, -48, -48, -48, -48, -48, -48,
1170 -48, -48, -48, -48, -48, -48, -48, -48, -48, -48,
1171 -48, -48, -48, -48, -48, -48, -48, -48, -48, -48,
1172 -48, -48, -48, -48, -48, -48, -48, -48, -48, -48,
1173 -48, -48, -48, -48, -48, -48, -48, -48, -48, -48,
1174 -48, -48, -48, -48, -48, -48, -48, -48, -48, -48,
1175 -48, -48, -48, -48, -48, -48, -48, -48, -48, -48,
1176 -48, -48, -48, -48, -48, -48, -48, -48
1180 7, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1181 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1182 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1184 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1185 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1186 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1187 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1188 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1189 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1190 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1191 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1192 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,
1193 49, 49, 49, 50, 49, 51, 49, 49
1198 7, -50, -50, -50, -50, -50, -50, -50, -50, -50,
1199 -50, -50, -50, -50, -50, -50, -50, -50, -50, -50,
1200 -50, -50, -50, -50, -50, -50, -50, -50, -50, -50,
1201 -50, -50, -50, -50, -50, -50, -50, -50, -50, -50,
1202 -50, -50, -50, -50, -50, -50, -50, -50, -50, -50,
1203 -50, -50, -50, -50, -50, -50, -50, -50, -50, -50,
1204 -50, -50, -50, -50, -50, -50, -50, -50, -50, -50,
1205 -50, -50, -50, -50, -50, -50, -50, -50, -50, -50,
1206 -50, -50, -50, -50, -50, -50, -50, -50, -50, -50,
1207 -50, -50, -50, -50, -50, -50, -50, -50, -50, -50,
1209 -50, -50, -50, -50, -50, -50, -50, -50, -50, -50,
1210 -50, -50, -50, -50, -50, -50, -50, -50, -50, -50,
1211 -50, -50, -50, -50, -50, -50, -50, -50
1215 7, -51, -51, -51, -51, -51, -51, -51, -51, -51,
1216 -51, -51, -51, -51, -51, -51, -51, -51, -51, -51,
1217 -51, -51, -51, -51, -51, -51, -51, -51, -51, -51,
1218 -51, -51, -51, -51, -51, -51, -51, -51, -51, -51,
1219 -51, -51, -51, -51, -51, -51, -51, -51, -51, -51,
1220 -51, -51, -51, -51, -51, -51, -51, -51, -51, -51,
1221 -51, -51, -51, -51, -51, -51, -51, -51, -51, -51,
1223 -51, -51, -51, -51, -51, -51, -51, -51, -51, -51,
1224 -51, -51, -51, -51, -51, -51, -51, -51, -51, -51,
1225 -51, -51, -51, -51, -51, -51, -51, -51, -51, -51,
1226 -51, -51, -51, -51, -51, -51, -51, -51, -51, -51,
1227 -51, -51, -51, -51, -51, -51, -51, -51, -51, -51,
1228 -51, -51, -51, -51, -51, -51, -51, -51
1232 7, 52, 52, 52, 52, 52, 52, 52, 52, -52,
1233 -52, 52, 52, -52, 52, 52, 52, 52, 52, 52,
1234 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,
1235 52, 52, -52, -52, 52, 52, -52, -52, -52, 52,
1237 -52, -52, -52, -52, 52, -52, 52, -52, 52, 52,
1238 52, 52, 52, 52, 52, 52, 52, 52, -52, 52,
1239 -52, -52, -52, -52, 52, 52, 52, 52, 52, 52,
1240 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,
1241 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,
1242 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,
1243 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,
1244 52, 52, 52, 52, 52, 52, 52, 52, 52, 52,
1245 52, 52, 52, 52, -52, 52, 52, 52
1249 7, -53, -53, -53, -53, -53, -53, -53, -53, -53,
1251 -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
1252 -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
1253 -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
1254 -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
1255 -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
1256 -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
1257 -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
1258 -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
1259 -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
1260 -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
1262 -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
1263 -53, -53, -53, -53, -53, -53, -53, -53
1268 static yy_state_type
yy_get_previous_state (yyscan_t yyscanner
);
1269 static yy_state_type
yy_try_NUL_trans (yy_state_type current_state
,yyscan_t yyscanner
);
1270 static int yy_get_next_buffer (yyscan_t yyscanner
);
1271 static void yy_fatal_error (yyconst
char msg
[] ,yyscan_t yyscanner
);
1273 /* Done after the current pattern has been matched and before the
1274 * corresponding action - sets up yytext.
1276 #define YY_DO_BEFORE_ACTION \
1277 yyg->yytext_ptr = yy_bp; \
1278 yyg->yytext_ptr -= yyg->yy_more_len; \
1279 yyleng = (size_t) (yy_cp - yyg->yytext_ptr); \
1280 yyg->yy_hold_char = *yy_cp; \
1282 yyg->yy_c_buf_p = yy_cp;
1284 #define YY_NUM_RULES 35
1285 #define YY_END_OF_BUFFER 36
1286 /* This struct is not used in this scanner,
1287 but its presence is necessary. */
1288 struct yy_trans_info
1290 flex_int32_t yy_verify
;
1291 flex_int32_t yy_nxt
;
1293 static yyconst flex_int16_t yy_accept
[54] =
1295 0, 0, 0, 0, 32, 32, 36, 35, 25, 27,
1296 19, 35, 29, 29, 17, 2, 22, 23, 15, 13,
1297 14, 16, 28, 20, 9, 3, 8, 18, 1, 35,
1298 31, 30, 32, 33, 33, 12, 0, 26, 29, 24,
1299 5, 28, 21, 11, 6, 7, 10, 4, 0, 31,
1303 static yyconst yy_state_type yy_NUL_trans
[54] =
1305 8, 8, 30, 30, 33, 33, 0, 0, 0, 0,
1306 0, 37, 0, 0, 0, 0, 0, 0, 0, 0,
1307 0, 0, 0, 0, 0, 0, 0, 0, 0, 49,
1308 0, 0, 52, 0, 0, 0, 37, 0, 0, 0,
1309 0, 0, 0, 0, 0, 0, 0, 0, 49, 0,
1313 /* The intent behind this definition is that it'll catch
1314 * any uses of REJECT which flex missed.
1316 #define REJECT reject_used_but_not_detected
1317 #define yymore() (yyg->yy_more_flag = 1)
1318 #define YY_MORE_ADJ yyg->yy_more_len
1319 #define YY_RESTORE_YY_MORE_OFFSET
1320 #line 1 "ast_expr2.fl"
1321 #line 2 "ast_expr2.fl"
1323 * Asterisk -- An open source telephony toolkit.
1325 * Copyright (C) 1999 - 2006, Digium, Inc.
1327 * Mark Spencer <markster@digium.com>
1329 * See http://www.asterisk.org for more information about
1330 * the Asterisk project. Please do not directly contact
1331 * any of the maintainers of this project for assistance;
1332 * the project provides a web site, mailing lists and IRC
1333 * channels for your use.
1335 * This program is free software, distributed under the terms of
1336 * the GNU General Public License Version 2. See the LICENSE file
1337 * at the top of the source tree.
1342 * \brief Dialplan Expression Lexical Scanner
1345 #include "asterisk.h"
1348 ASTERISK_FILE_VERSION(__FILE__
, "$Revision$")
1351 #include <sys/types.h>
1357 #if !defined(SOLARIS) && !defined(__CYGWIN__)
1358 /* #include <err.h> */
1360 #define quad_t int64_t
1366 #include "asterisk/ast_expr.h"
1367 #include "asterisk/logger.h"
1368 #include "asterisk/strings.h"
1371 AST_EXPR_integer
, AST_EXPR_numeric_string
, AST_EXPR_string
1382 #include "ast_expr2.h" /* the o/p of the bison on ast_expr2.y */
1384 #define SET_COLUMNS do { \
1385 yylloc_param->first_column = (int)(yyg->yytext_r - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf); \
1386 yylloc_param->last_column += yyleng - 1; \
1387 yylloc_param->first_line = yylloc_param->last_line = 1; \
1390 #define SET_STRING do { \
1391 yylval_param->val = calloc(1, sizeof(struct val)); \
1392 yylval_param->val->type = AST_EXPR_string; \
1393 yylval_param->val->u.s = strdup(yytext); \
1396 #define SET_NUMERIC_STRING do { \
1397 yylval_param->val = calloc(1, sizeof(struct val)); \
1398 yylval_param->val->type = AST_EXPR_numeric_string; \
1399 yylval_param->val->u.s = strdup(yytext); \
1409 void ast_yyset_column(int column_no
, yyscan_t yyscanner
);
1410 int ast_yyget_column(yyscan_t yyscanner
);
1411 static int curlycount
= 0;
1412 static char *expr2_token_subst(char *mess
);
1414 #line 1415 "ast_expr2f.c"
1420 /* Special case for "unistd.h", since it is non-ANSI. We include it way
1421 * down here because we want the user's section 1 to have been scanned first.
1422 * The user has a chance to override it with an option.
1426 #ifndef YY_EXTRA_TYPE
1427 #define YY_EXTRA_TYPE void *
1430 /* Holds the entire state of the reentrant scanner. */
1434 /* User-defined. Not touched by flex. */
1435 YY_EXTRA_TYPE yyextra_r
;
1437 /* The rest are the same as the globals declared in the non-reentrant scanner. */
1438 FILE *yyin_r
, *yyout_r
;
1439 size_t yy_buffer_stack_top
; /**< index of top of stack. */
1440 size_t yy_buffer_stack_max
; /**< capacity of stack. */
1441 YY_BUFFER_STATE
* yy_buffer_stack
; /**< Stack as an array. */
1448 int yy_did_buffer_switch_on_eof
;
1449 int yy_start_stack_ptr
;
1450 int yy_start_stack_depth
;
1451 int *yy_start_stack
;
1452 yy_state_type yy_last_accepting_state
;
1453 char* yy_last_accepting_cpos
;
1456 int yy_flex_debug_r
;
1466 }; /* end struct yyguts_t */
1468 /* This must go here because YYSTYPE and YYLTYPE are included
1469 * from bison output in section 1.*/
1470 # define yylval yyg->yylval_r
1472 # define yylloc yyg->yylloc_r
1474 /* Accessor methods to globals.
1475 These are made visible to non-reentrant scanners for convenience. */
1477 int ast_yylex_destroy (yyscan_t yyscanner
);
1479 int ast_yyget_debug (yyscan_t yyscanner
);
1481 void ast_yyset_debug (int debug_flag
,yyscan_t yyscanner
);
1483 YY_EXTRA_TYPE
ast_yyget_extra (yyscan_t yyscanner
);
1485 void ast_yyset_extra (YY_EXTRA_TYPE user_defined
,yyscan_t yyscanner
);
1487 FILE *ast_yyget_in (yyscan_t yyscanner
);
1489 void ast_yyset_in (FILE * in_str
,yyscan_t yyscanner
);
1491 FILE *ast_yyget_out (yyscan_t yyscanner
);
1493 void ast_yyset_out (FILE * out_str
,yyscan_t yyscanner
);
1495 int ast_yyget_leng (yyscan_t yyscanner
);
1497 char *ast_yyget_text (yyscan_t yyscanner
);
1499 int ast_yyget_lineno (yyscan_t yyscanner
);
1501 void ast_yyset_lineno (int line_number
,yyscan_t yyscanner
);
1503 YYSTYPE
* ast_yyget_lval (yyscan_t yyscanner
);
1505 void ast_yyset_lval (YYSTYPE
* yylval_param
,yyscan_t yyscanner
);
1507 YYLTYPE
*ast_yyget_lloc (yyscan_t yyscanner
);
1509 void ast_yyset_lloc (YYLTYPE
* yylloc_param
,yyscan_t yyscanner
);
1511 /* Macros after this point can all be overridden by user definitions in
1515 #ifndef YY_SKIP_YYWRAP
1517 extern "C" int ast_yywrap (yyscan_t yyscanner
);
1519 extern int ast_yywrap (yyscan_t yyscanner
);
1523 static void yyunput (int c
,char *buf_ptr
,yyscan_t yyscanner
);
1526 static void yy_flex_strncpy (char *,yyconst
char *,int ,yyscan_t yyscanner
);
1529 #ifdef YY_NEED_STRLEN
1530 static int yy_flex_strlen (yyconst
char * ,yyscan_t yyscanner
);
1536 static int yyinput (yyscan_t yyscanner
);
1538 static int input (yyscan_t yyscanner
);
1543 /* Amount of stuff to slurp up with each read. */
1544 #ifndef YY_READ_BUF_SIZE
1545 #define YY_READ_BUF_SIZE 8192
1548 /* Copy whatever the last rule matched to the standard output. */
1550 /* This used to be an fputs(), but since the string might contain NUL's,
1551 * we now use fwrite().
1553 #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
1556 /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
1557 * is returned in "result".
1560 #define YY_INPUT(buf,result,max_size) \
1562 while ( (result = read( fileno(yyin), (char *) buf, max_size )) < 0 ) \
1564 if( errno != EINTR) \
1566 YY_FATAL_ERROR( "input in flex scanner failed" ); \
1576 /* No semi-colon after return; correct usage is to write "yyterminate();" -
1577 * we don't want an extra ';' after the "return" because that will cause
1578 * some compilers to complain about unreachable statements.
1581 #define yyterminate() return YY_NULL
1584 /* Number of entries by which start-condition stack grows. */
1585 #ifndef YY_START_STACK_INCR
1586 #define YY_START_STACK_INCR 25
1589 /* Report a fatal error. */
1590 #ifndef YY_FATAL_ERROR
1591 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner)
1594 /* end tables serialization structures and prototypes */
1596 /* Default declaration of generated scanner - a define so the user can
1597 * easily add parameters.
1600 #define YY_DECL_IS_OURS 1
1602 extern int ast_yylex (YYSTYPE
* yylval_param
,YYLTYPE
* yylloc_param
,yyscan_t yyscanner
);
1604 #define YY_DECL int ast_yylex (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner)
1605 #endif /* !YY_DECL */
1607 /* Code executed at the beginning of each rule, after yytext and yyleng
1610 #ifndef YY_USER_ACTION
1611 #define YY_USER_ACTION
1614 /* Code executed at the end of each rule. */
1616 #define YY_BREAK break;
1619 #define YY_RULE_SETUP \
1622 /** The main scanner function which does all the work.
1626 register yy_state_type yy_current_state
;
1627 register char *yy_cp
, *yy_bp
;
1628 register int yy_act
;
1629 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
1631 #line 104 "ast_expr2.fl"
1634 #line 1635 "ast_expr2f.c"
1636 yylval
= yylval_param
;
1638 yylloc
= yylloc_param
;
1648 if ( ! yyg
->yy_start
)
1649 yyg
->yy_start
= 1; /* first start state */
1657 if ( ! YY_CURRENT_BUFFER
) {
1658 ast_yyensure_buffer_stack (yyscanner
);
1659 YY_CURRENT_BUFFER_LVALUE
=
1660 ast_yy_create_buffer(yyin
,YY_BUF_SIZE
,yyscanner
);
1663 ast_yy_load_buffer_state(yyscanner
);
1666 while ( 1 ) /* loops until end-of-file is reached */
1668 yyg
->yy_more_len
= 0;
1669 if ( yyg
->yy_more_flag
)
1671 yyg
->yy_more_len
= yyg
->yy_c_buf_p
- yyg
->yytext_ptr
;
1672 yyg
->yy_more_flag
= 0;
1674 yy_cp
= yyg
->yy_c_buf_p
;
1676 /* Support of yytext. */
1677 *yy_cp
= yyg
->yy_hold_char
;
1679 /* yy_bp points to the position in yy_ch_buf of the start of
1684 yy_current_state
= yyg
->yy_start
;
1686 while ( (yy_current_state
= yy_nxt
[yy_current_state
][ YY_SC_TO_UI(*yy_cp
) ]) > 0 )
1688 if ( yy_accept
[yy_current_state
] )
1690 yyg
->yy_last_accepting_state
= yy_current_state
;
1691 yyg
->yy_last_accepting_cpos
= yy_cp
;
1697 yy_current_state
= -yy_current_state
;
1700 yy_act
= yy_accept
[yy_current_state
];
1702 YY_DO_BEFORE_ACTION
;
1704 do_action
: /* This label is used only to access EOF actions. */
1707 { /* beginning of action switch */
1708 case 0: /* must back up */
1709 /* undo the effects of YY_DO_BEFORE_ACTION */
1710 *yy_cp
= yyg
->yy_hold_char
;
1711 yy_cp
= yyg
->yy_last_accepting_cpos
+ 1;
1712 yy_current_state
= yyg
->yy_last_accepting_state
;
1713 goto yy_find_action
;
1717 #line 106 "ast_expr2.fl"
1718 { SET_COLUMNS
; SET_STRING
; return TOK_OR
;}
1722 #line 107 "ast_expr2.fl"
1723 { SET_COLUMNS
; SET_STRING
; return TOK_AND
;}
1727 #line 108 "ast_expr2.fl"
1728 { SET_COLUMNS
; SET_STRING
; return TOK_EQ
;}
1732 #line 109 "ast_expr2.fl"
1733 { SET_COLUMNS
; SET_STRING
; return TOK_OR
;}
1737 #line 110 "ast_expr2.fl"
1738 { SET_COLUMNS
; SET_STRING
; return TOK_AND
;}
1742 #line 111 "ast_expr2.fl"
1743 { SET_COLUMNS
; SET_STRING
; return TOK_EQ
;}
1747 #line 112 "ast_expr2.fl"
1748 { SET_COLUMNS
; SET_STRING
; return TOK_EQTILDE
;}
1752 #line 113 "ast_expr2.fl"
1753 { SET_COLUMNS
; SET_STRING
; return TOK_GT
;}
1757 #line 114 "ast_expr2.fl"
1758 { SET_COLUMNS
; SET_STRING
; return TOK_LT
;}
1762 #line 115 "ast_expr2.fl"
1763 { SET_COLUMNS
; SET_STRING
; return TOK_GE
;}
1767 #line 116 "ast_expr2.fl"
1768 { SET_COLUMNS
; SET_STRING
; return TOK_LE
;}
1772 #line 117 "ast_expr2.fl"
1773 { SET_COLUMNS
; SET_STRING
; return TOK_NE
;}
1777 #line 118 "ast_expr2.fl"
1778 { SET_COLUMNS
; SET_STRING
; return TOK_PLUS
;}
1782 #line 119 "ast_expr2.fl"
1783 { SET_COLUMNS
; SET_STRING
; return TOK_MINUS
;}
1787 #line 120 "ast_expr2.fl"
1788 { SET_COLUMNS
; SET_STRING
; return TOK_MULT
;}
1792 #line 121 "ast_expr2.fl"
1793 { SET_COLUMNS
; SET_STRING
; return TOK_DIV
;}
1797 #line 122 "ast_expr2.fl"
1798 { SET_COLUMNS
; SET_STRING
; return TOK_MOD
;}
1802 #line 123 "ast_expr2.fl"
1803 { SET_COLUMNS
; SET_STRING
; return TOK_COND
;}
1807 #line 124 "ast_expr2.fl"
1808 { SET_COLUMNS
; SET_STRING
; return TOK_COMPL
;}
1812 #line 125 "ast_expr2.fl"
1813 { SET_COLUMNS
; SET_STRING
; return TOK_COLON
;}
1817 #line 126 "ast_expr2.fl"
1818 { SET_COLUMNS
; SET_STRING
; return TOK_COLONCOLON
;}
1822 #line 127 "ast_expr2.fl"
1823 { SET_COLUMNS
; SET_STRING
; return TOK_LP
;}
1827 #line 128 "ast_expr2.fl"
1828 { SET_COLUMNS
; SET_STRING
; return TOK_RP
;}
1832 #line 129 "ast_expr2.fl"
1834 /* gather the contents of ${} expressions, with trailing stuff,
1835 * into a single TOKEN.
1836 * They are much more complex now than they used to be
1845 #line 139 "ast_expr2.fl"
1849 /* rule 26 can match eol */
1851 #line 140 "ast_expr2.fl"
1852 {SET_COLUMNS
; SET_STRING
; return TOKEN
;}
1855 /* rule 27 can match eol */
1857 #line 142 "ast_expr2.fl"
1858 {/* what to do with eol */}
1862 #line 143 "ast_expr2.fl"
1865 /* the original behavior of the expression parser was
1866 * to bring in numbers as a numeric string
1874 #line 152 "ast_expr2.fl"
1882 /* rule 30 can match eol */
1884 #line 159 "ast_expr2.fl"
1887 if (curlycount
< 0) {
1896 /* rule 31 can match eol */
1898 #line 169 "ast_expr2.fl"
1906 #line 175 "ast_expr2.fl"
1915 /* rule 33 can match eol */
1917 #line 182 "ast_expr2.fl"
1919 char c
= yytext
[yyleng
-1];
1929 #line 191 "ast_expr2.fl"
1936 case YY_STATE_EOF(trail
):
1937 #line 197 "ast_expr2.fl"
1943 /*actually, if an expr is only a variable ref, this could happen a LOT */
1948 #line 205 "ast_expr2.fl"
1951 #line 1952 "ast_expr2f.c"
1952 case YY_STATE_EOF(INITIAL
):
1953 case YY_STATE_EOF(var
):
1956 case YY_END_OF_BUFFER
:
1958 /* Amount of text matched not including the EOB char. */
1959 int yy_amount_of_matched_text
= (int) (yy_cp
- yyg
->yytext_ptr
) - 1;
1961 /* Undo the effects of YY_DO_BEFORE_ACTION. */
1962 *yy_cp
= yyg
->yy_hold_char
;
1963 YY_RESTORE_YY_MORE_OFFSET
1965 if ( YY_CURRENT_BUFFER_LVALUE
->yy_buffer_status
== YY_BUFFER_NEW
)
1967 /* We're scanning a new file or input source. It's
1968 * possible that this happened because the user
1969 * just pointed yyin at a new source and called
1970 * ast_yylex(). If so, then we have to assure
1971 * consistency between YY_CURRENT_BUFFER and our
1972 * globals. Here is the right place to do so, because
1973 * this is the first action (other than possibly a
1974 * back-up) that will match for the new input source.
1976 yyg
->yy_n_chars
= YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
;
1977 YY_CURRENT_BUFFER_LVALUE
->yy_input_file
= yyin
;
1978 YY_CURRENT_BUFFER_LVALUE
->yy_buffer_status
= YY_BUFFER_NORMAL
;
1981 /* Note that here we test for yy_c_buf_p "<=" to the position
1982 * of the first EOB in the buffer, since yy_c_buf_p will
1983 * already have been incremented past the NUL character
1984 * (since all states make transitions on EOB to the
1985 * end-of-buffer state). Contrast this with the test
1988 if ( yyg
->yy_c_buf_p
<= &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[yyg
->yy_n_chars
] )
1989 { /* This was really a NUL. */
1990 yy_state_type yy_next_state
;
1992 yyg
->yy_c_buf_p
= yyg
->yytext_ptr
+ yy_amount_of_matched_text
;
1994 yy_current_state
= yy_get_previous_state( yyscanner
);
1996 /* Okay, we're now positioned to make the NUL
1997 * transition. We couldn't have
1998 * yy_get_previous_state() go ahead and do it
1999 * for us because it doesn't know how to deal
2000 * with the possibility of jamming (and we don't
2001 * want to build jamming into it because then it
2002 * will run more slowly).
2005 yy_next_state
= yy_try_NUL_trans( yy_current_state
, yyscanner
);
2007 yy_bp
= yyg
->yytext_ptr
+ YY_MORE_ADJ
;
2009 if ( yy_next_state
)
2011 /* Consume the NUL. */
2012 yy_cp
= ++yyg
->yy_c_buf_p
;
2013 yy_current_state
= yy_next_state
;
2019 yy_cp
= yyg
->yy_c_buf_p
;
2020 goto yy_find_action
;
2024 else switch ( yy_get_next_buffer( yyscanner
) )
2026 case EOB_ACT_END_OF_FILE
:
2028 yyg
->yy_did_buffer_switch_on_eof
= 0;
2030 if ( ast_yywrap(yyscanner
) )
2032 /* Note: because we've taken care in
2033 * yy_get_next_buffer() to have set up
2034 * yytext, we can now set up
2035 * yy_c_buf_p so that if some total
2036 * hoser (like flex itself) wants to
2037 * call the scanner after we return the
2038 * YY_NULL, it'll still work - another
2039 * YY_NULL will get returned.
2041 yyg
->yy_c_buf_p
= yyg
->yytext_ptr
+ YY_MORE_ADJ
;
2043 yy_act
= YY_STATE_EOF(YY_START
);
2049 if ( ! yyg
->yy_did_buffer_switch_on_eof
)
2055 case EOB_ACT_CONTINUE_SCAN
:
2057 yyg
->yytext_ptr
+ yy_amount_of_matched_text
;
2059 yy_current_state
= yy_get_previous_state( yyscanner
);
2061 yy_cp
= yyg
->yy_c_buf_p
;
2062 yy_bp
= yyg
->yytext_ptr
+ YY_MORE_ADJ
;
2065 case EOB_ACT_LAST_MATCH
:
2067 &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[yyg
->yy_n_chars
];
2069 yy_current_state
= yy_get_previous_state( yyscanner
);
2071 yy_cp
= yyg
->yy_c_buf_p
;
2072 yy_bp
= yyg
->yytext_ptr
+ YY_MORE_ADJ
;
2073 goto yy_find_action
;
2080 "fatal flex scanner internal error--no action found" );
2081 } /* end of action switch */
2082 } /* end of scanning one token */
2083 } /* end of ast_yylex */
2085 /* yy_get_next_buffer - try to read in a new buffer
2087 * Returns a code representing an action:
2088 * EOB_ACT_LAST_MATCH -
2089 * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
2090 * EOB_ACT_END_OF_FILE - end of file
2092 static int yy_get_next_buffer (yyscan_t yyscanner
)
2094 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2095 register char *dest
= YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
;
2096 register char *source
= yyg
->yytext_ptr
;
2097 register int number_to_move
, i
;
2100 if ( yyg
->yy_c_buf_p
> &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[yyg
->yy_n_chars
+ 1] )
2102 "fatal flex scanner internal error--end of buffer missed" );
2104 if ( YY_CURRENT_BUFFER_LVALUE
->yy_fill_buffer
== 0 )
2105 { /* Don't try to fill the buffer, so this is an EOF. */
2106 if ( yyg
->yy_c_buf_p
- yyg
->yytext_ptr
- YY_MORE_ADJ
== 1 )
2108 /* We matched a single character, the EOB, so
2109 * treat this as a final EOF.
2111 return EOB_ACT_END_OF_FILE
;
2116 /* We matched some text prior to the EOB, first
2119 return EOB_ACT_LAST_MATCH
;
2123 /* Try to read more data. */
2125 /* First move last chars to start of buffer. */
2126 number_to_move
= (int) (yyg
->yy_c_buf_p
- yyg
->yytext_ptr
) - 1;
2128 for ( i
= 0; i
< number_to_move
; ++i
)
2129 *(dest
++) = *(source
++);
2131 if ( YY_CURRENT_BUFFER_LVALUE
->yy_buffer_status
== YY_BUFFER_EOF_PENDING
)
2132 /* don't do the read, it's not guaranteed to return an EOF,
2135 YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
= yyg
->yy_n_chars
= 0;
2139 size_t num_to_read
=
2140 YY_CURRENT_BUFFER_LVALUE
->yy_buf_size
- number_to_move
- 1;
2142 while ( num_to_read
<= 0 )
2143 { /* Not enough room in the buffer - grow it. */
2145 /* just a shorter name for the current buffer */
2146 YY_BUFFER_STATE b
= YY_CURRENT_BUFFER
;
2148 int yy_c_buf_p_offset
=
2149 (int) (yyg
->yy_c_buf_p
- b
->yy_ch_buf
);
2151 if ( b
->yy_is_our_buffer
)
2153 int new_size
= b
->yy_buf_size
* 2;
2155 if ( new_size
<= 0 )
2156 b
->yy_buf_size
+= b
->yy_buf_size
/ 8;
2158 b
->yy_buf_size
*= 2;
2160 b
->yy_ch_buf
= (char *)
2161 /* Include room in for 2 EOB chars. */
2162 ast_yyrealloc((void *) b
->yy_ch_buf
,b
->yy_buf_size
+ 2 ,yyscanner
);
2165 /* Can't grow it, we don't own it. */
2168 if ( ! b
->yy_ch_buf
)
2170 "fatal error - scanner input buffer overflow" );
2172 yyg
->yy_c_buf_p
= &b
->yy_ch_buf
[yy_c_buf_p_offset
];
2174 num_to_read
= YY_CURRENT_BUFFER_LVALUE
->yy_buf_size
-
2179 if ( num_to_read
> YY_READ_BUF_SIZE
)
2180 num_to_read
= YY_READ_BUF_SIZE
;
2182 /* Read in more data. */
2183 YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[number_to_move
]),
2184 yyg
->yy_n_chars
, num_to_read
);
2186 YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
= yyg
->yy_n_chars
;
2189 if ( yyg
->yy_n_chars
== 0 )
2191 if ( number_to_move
== YY_MORE_ADJ
)
2193 ret_val
= EOB_ACT_END_OF_FILE
;
2194 ast_yyrestart(yyin
,yyscanner
);
2199 ret_val
= EOB_ACT_LAST_MATCH
;
2200 YY_CURRENT_BUFFER_LVALUE
->yy_buffer_status
=
2201 YY_BUFFER_EOF_PENDING
;
2206 ret_val
= EOB_ACT_CONTINUE_SCAN
;
2208 yyg
->yy_n_chars
+= number_to_move
;
2209 YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[yyg
->yy_n_chars
] = YY_END_OF_BUFFER_CHAR
;
2210 YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[yyg
->yy_n_chars
+ 1] = YY_END_OF_BUFFER_CHAR
;
2212 yyg
->yytext_ptr
= &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[0];
2217 /* yy_get_previous_state - get the state just before the EOB char was reached */
2219 static yy_state_type
yy_get_previous_state (yyscan_t yyscanner
)
2221 register yy_state_type yy_current_state
;
2222 register char *yy_cp
;
2223 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2225 yy_current_state
= yyg
->yy_start
;
2227 for ( yy_cp
= yyg
->yytext_ptr
+ YY_MORE_ADJ
; yy_cp
< yyg
->yy_c_buf_p
; ++yy_cp
)
2231 yy_current_state
= yy_nxt
[yy_current_state
][YY_SC_TO_UI(*yy_cp
)];
2234 yy_current_state
= yy_NUL_trans
[yy_current_state
];
2235 if ( yy_accept
[yy_current_state
] )
2237 yyg
->yy_last_accepting_state
= yy_current_state
;
2238 yyg
->yy_last_accepting_cpos
= yy_cp
;
2242 return yy_current_state
;
2245 /* yy_try_NUL_trans - try to make a transition on the NUL character
2248 * next_state = yy_try_NUL_trans( current_state );
2250 static yy_state_type
yy_try_NUL_trans (yy_state_type yy_current_state
, yyscan_t yyscanner
)
2252 register int yy_is_jam
;
2253 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2254 register char *yy_cp
= yyg
->yy_c_buf_p
;
2256 yy_current_state
= yy_NUL_trans
[yy_current_state
];
2257 yy_is_jam
= (yy_current_state
== 0);
2261 if ( yy_accept
[yy_current_state
] )
2263 yyg
->yy_last_accepting_state
= yy_current_state
;
2264 yyg
->yy_last_accepting_cpos
= yy_cp
;
2268 return yy_is_jam
? 0 : yy_current_state
;
2271 static void yyunput (int c
, register char * yy_bp
, yyscan_t yyscanner
)
2273 register char *yy_cp
;
2274 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2276 yy_cp
= yyg
->yy_c_buf_p
;
2278 /* undo effects of setting up yytext */
2279 *yy_cp
= yyg
->yy_hold_char
;
2281 if ( yy_cp
< YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
+ 2 )
2282 { /* need to shift things up to make room */
2283 /* +2 for EOB chars. */
2284 register int number_to_move
= yyg
->yy_n_chars
+ 2;
2285 register char *dest
= &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[
2286 YY_CURRENT_BUFFER_LVALUE
->yy_buf_size
+ 2];
2287 register char *source
=
2288 &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[number_to_move
];
2290 while ( source
> YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
)
2291 *--dest
= *--source
;
2293 yy_cp
+= (int) (dest
- source
);
2294 yy_bp
+= (int) (dest
- source
);
2295 YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
=
2296 yyg
->yy_n_chars
= YY_CURRENT_BUFFER_LVALUE
->yy_buf_size
;
2298 if ( yy_cp
< YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
+ 2 )
2299 YY_FATAL_ERROR( "flex scanner push-back overflow" );
2302 *--yy_cp
= (char) c
;
2304 yyg
->yytext_ptr
= yy_bp
;
2305 yyg
->yy_hold_char
= *yy_cp
;
2306 yyg
->yy_c_buf_p
= yy_cp
;
2311 static int yyinput (yyscan_t yyscanner
)
2313 static int input (yyscan_t yyscanner
)
2318 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2320 *yyg
->yy_c_buf_p
= yyg
->yy_hold_char
;
2322 if ( *yyg
->yy_c_buf_p
== YY_END_OF_BUFFER_CHAR
)
2324 /* yy_c_buf_p now points to the character we want to return.
2325 * If this occurs *before* the EOB characters, then it's a
2326 * valid NUL; if not, then we've hit the end of the buffer.
2328 if ( yyg
->yy_c_buf_p
< &YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
[yyg
->yy_n_chars
] )
2329 /* This was really a NUL. */
2330 *yyg
->yy_c_buf_p
= '\0';
2333 { /* need more input */
2334 int offset
= yyg
->yy_c_buf_p
- yyg
->yytext_ptr
;
2337 switch ( yy_get_next_buffer( yyscanner
) )
2339 case EOB_ACT_LAST_MATCH
:
2340 /* This happens because yy_g_n_b()
2341 * sees that we've accumulated a
2342 * token and flags that we need to
2343 * try matching the token before
2344 * proceeding. But for input(),
2345 * there's no matching to consider.
2346 * So convert the EOB_ACT_LAST_MATCH
2347 * to EOB_ACT_END_OF_FILE.
2350 /* Reset buffer status. */
2351 ast_yyrestart(yyin
,yyscanner
);
2355 case EOB_ACT_END_OF_FILE
:
2357 if ( ast_yywrap(yyscanner
) )
2360 if ( ! yyg
->yy_did_buffer_switch_on_eof
)
2363 return yyinput(yyscanner
);
2365 return input(yyscanner
);
2369 case EOB_ACT_CONTINUE_SCAN
:
2370 yyg
->yy_c_buf_p
= yyg
->yytext_ptr
+ offset
;
2376 c
= *(unsigned char *) yyg
->yy_c_buf_p
; /* cast for 8-bit char's */
2377 *yyg
->yy_c_buf_p
= '\0'; /* preserve yytext */
2378 yyg
->yy_hold_char
= *++yyg
->yy_c_buf_p
;
2382 #endif /* ifndef YY_NO_INPUT */
2384 /** Immediately switch to a different input stream.
2385 * @param input_file A readable stream.
2386 * @param yyscanner The scanner object.
2387 * @note This function does not reset the start condition to @c INITIAL .
2389 void ast_yyrestart (FILE * input_file
, yyscan_t yyscanner
)
2391 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2393 if ( ! YY_CURRENT_BUFFER
){
2394 ast_yyensure_buffer_stack (yyscanner
);
2395 YY_CURRENT_BUFFER_LVALUE
=
2396 ast_yy_create_buffer(yyin
,YY_BUF_SIZE
,yyscanner
);
2399 ast_yy_init_buffer(YY_CURRENT_BUFFER
,input_file
,yyscanner
);
2400 ast_yy_load_buffer_state(yyscanner
);
2403 /** Switch to a different input buffer.
2404 * @param new_buffer The new input buffer.
2405 * @param yyscanner The scanner object.
2407 void ast_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer
, yyscan_t yyscanner
)
2409 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2411 /* TODO. We should be able to replace this entire function body
2413 * ast_yypop_buffer_state();
2414 * ast_yypush_buffer_state(new_buffer);
2416 ast_yyensure_buffer_stack (yyscanner
);
2417 if ( YY_CURRENT_BUFFER
== new_buffer
)
2420 if ( YY_CURRENT_BUFFER
)
2422 /* Flush out information for old buffer. */
2423 *yyg
->yy_c_buf_p
= yyg
->yy_hold_char
;
2424 YY_CURRENT_BUFFER_LVALUE
->yy_buf_pos
= yyg
->yy_c_buf_p
;
2425 YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
= yyg
->yy_n_chars
;
2428 YY_CURRENT_BUFFER_LVALUE
= new_buffer
;
2429 ast_yy_load_buffer_state(yyscanner
);
2431 /* We don't actually know whether we did this switch during
2432 * EOF (ast_yywrap()) processing, but the only time this flag
2433 * is looked at is after ast_yywrap() is called, so it's safe
2434 * to go ahead and always set it.
2436 yyg
->yy_did_buffer_switch_on_eof
= 1;
2439 static void ast_yy_load_buffer_state (yyscan_t yyscanner
)
2441 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2442 yyg
->yy_n_chars
= YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
;
2443 yyg
->yytext_ptr
= yyg
->yy_c_buf_p
= YY_CURRENT_BUFFER_LVALUE
->yy_buf_pos
;
2444 yyin
= YY_CURRENT_BUFFER_LVALUE
->yy_input_file
;
2445 yyg
->yy_hold_char
= *yyg
->yy_c_buf_p
;
2448 /** Allocate and initialize an input buffer state.
2449 * @param file A readable stream.
2450 * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
2451 * @param yyscanner The scanner object.
2452 * @return the allocated buffer state.
2454 YY_BUFFER_STATE
ast_yy_create_buffer (FILE * file
, int size
, yyscan_t yyscanner
)
2458 b
= (YY_BUFFER_STATE
) ast_yyalloc(sizeof( struct yy_buffer_state
) ,yyscanner
);
2460 YY_FATAL_ERROR( "out of dynamic memory in ast_yy_create_buffer()" );
2462 b
->yy_buf_size
= size
;
2464 /* yy_ch_buf has to be 2 characters longer than the size given because
2465 * we need to put in 2 end-of-buffer characters.
2467 b
->yy_ch_buf
= (char *) ast_yyalloc(b
->yy_buf_size
+ 2 ,yyscanner
);
2468 if ( ! b
->yy_ch_buf
)
2469 YY_FATAL_ERROR( "out of dynamic memory in ast_yy_create_buffer()" );
2471 b
->yy_is_our_buffer
= 1;
2473 ast_yy_init_buffer(b
,file
,yyscanner
);
2478 /** Destroy the buffer.
2479 * @param b a buffer created with ast_yy_create_buffer()
2480 * @param yyscanner The scanner object.
2482 void ast_yy_delete_buffer (YY_BUFFER_STATE b
, yyscan_t yyscanner
)
2484 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2489 if ( b
== YY_CURRENT_BUFFER
) /* Not sure if we should pop here. */
2490 YY_CURRENT_BUFFER_LVALUE
= (YY_BUFFER_STATE
) 0;
2492 if ( b
->yy_is_our_buffer
)
2493 ast_yyfree((void *) b
->yy_ch_buf
,yyscanner
);
2495 ast_yyfree((void *) b
,yyscanner
);
2499 extern int isatty (int );
2500 #endif /* __cplusplus */
2502 /* Initializes or reinitializes a buffer.
2503 * This function is sometimes called more than once on the same buffer,
2504 * such as during a ast_yyrestart() or at EOF.
2506 static void ast_yy_init_buffer (YY_BUFFER_STATE b
, FILE * file
, yyscan_t yyscanner
)
2510 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2512 ast_yy_flush_buffer(b
,yyscanner
);
2514 b
->yy_input_file
= file
;
2515 b
->yy_fill_buffer
= 1;
2517 /* If b is the current buffer, then ast_yy_init_buffer was _probably_
2518 * called from ast_yyrestart() or through yy_get_next_buffer.
2519 * In that case, we don't want to reset the lineno or column.
2521 if (b
!= YY_CURRENT_BUFFER
){
2522 b
->yy_bs_lineno
= 1;
2523 b
->yy_bs_column
= 0;
2526 b
->yy_is_interactive
= file
? (isatty( fileno(file
) ) > 0) : 0;
2531 /** Discard all buffered characters. On the next scan, YY_INPUT will be called.
2532 * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
2533 * @param yyscanner The scanner object.
2535 void ast_yy_flush_buffer (YY_BUFFER_STATE b
, yyscan_t yyscanner
)
2537 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2543 /* We always need two end-of-buffer characters. The first causes
2544 * a transition to the end-of-buffer state. The second causes
2545 * a jam in that state.
2547 b
->yy_ch_buf
[0] = YY_END_OF_BUFFER_CHAR
;
2548 b
->yy_ch_buf
[1] = YY_END_OF_BUFFER_CHAR
;
2550 b
->yy_buf_pos
= &b
->yy_ch_buf
[0];
2553 b
->yy_buffer_status
= YY_BUFFER_NEW
;
2555 if ( b
== YY_CURRENT_BUFFER
)
2556 ast_yy_load_buffer_state(yyscanner
);
2559 /** Pushes the new state onto the stack. The new state becomes
2560 * the current state. This function will allocate the stack
2562 * @param new_buffer The new state.
2563 * @param yyscanner The scanner object.
2565 void ast_yypush_buffer_state (YY_BUFFER_STATE new_buffer
, yyscan_t yyscanner
)
2567 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2568 if (new_buffer
== NULL
)
2571 ast_yyensure_buffer_stack(yyscanner
);
2573 /* This block is copied from ast_yy_switch_to_buffer. */
2574 if ( YY_CURRENT_BUFFER
)
2576 /* Flush out information for old buffer. */
2577 *yyg
->yy_c_buf_p
= yyg
->yy_hold_char
;
2578 YY_CURRENT_BUFFER_LVALUE
->yy_buf_pos
= yyg
->yy_c_buf_p
;
2579 YY_CURRENT_BUFFER_LVALUE
->yy_n_chars
= yyg
->yy_n_chars
;
2582 /* Only push if top exists. Otherwise, replace top. */
2583 if (YY_CURRENT_BUFFER
)
2584 yyg
->yy_buffer_stack_top
++;
2585 YY_CURRENT_BUFFER_LVALUE
= new_buffer
;
2587 /* copied from ast_yy_switch_to_buffer. */
2588 ast_yy_load_buffer_state(yyscanner
);
2589 yyg
->yy_did_buffer_switch_on_eof
= 1;
2592 /** Removes and deletes the top of the stack, if present.
2593 * The next element becomes the new top.
2594 * @param yyscanner The scanner object.
2596 void ast_yypop_buffer_state (yyscan_t yyscanner
)
2598 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2599 if (!YY_CURRENT_BUFFER
)
2602 ast_yy_delete_buffer(YY_CURRENT_BUFFER
,yyscanner
);
2603 YY_CURRENT_BUFFER_LVALUE
= NULL
;
2604 if (yyg
->yy_buffer_stack_top
> 0)
2605 --yyg
->yy_buffer_stack_top
;
2607 if (YY_CURRENT_BUFFER
) {
2608 ast_yy_load_buffer_state(yyscanner
);
2609 yyg
->yy_did_buffer_switch_on_eof
= 1;
2613 /* Allocates the stack if it does not exist.
2614 * Guarantees space for at least one push.
2616 static void ast_yyensure_buffer_stack (yyscan_t yyscanner
)
2619 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2621 if (!yyg
->yy_buffer_stack
) {
2623 /* First allocation is just for 2 elements, since we don't know if this
2624 * scanner will even need a stack. We use 2 instead of 1 to avoid an
2625 * immediate realloc on the next call.
2628 yyg
->yy_buffer_stack
= (struct yy_buffer_state
**)ast_yyalloc
2629 (num_to_alloc
* sizeof(struct yy_buffer_state
*)
2632 memset(yyg
->yy_buffer_stack
, 0, num_to_alloc
* sizeof(struct yy_buffer_state
*));
2634 yyg
->yy_buffer_stack_max
= num_to_alloc
;
2635 yyg
->yy_buffer_stack_top
= 0;
2639 if (yyg
->yy_buffer_stack_top
>= (yyg
->yy_buffer_stack_max
) - 1){
2641 /* Increase the buffer to prepare for a possible push. */
2642 int grow_size
= 8 /* arbitrary grow size */;
2644 num_to_alloc
= yyg
->yy_buffer_stack_max
+ grow_size
;
2645 yyg
->yy_buffer_stack
= (struct yy_buffer_state
**)ast_yyrealloc
2646 (yyg
->yy_buffer_stack
,
2647 num_to_alloc
* sizeof(struct yy_buffer_state
*)
2650 /* zero only the new slots.*/
2651 memset(yyg
->yy_buffer_stack
+ yyg
->yy_buffer_stack_max
, 0, grow_size
* sizeof(struct yy_buffer_state
*));
2652 yyg
->yy_buffer_stack_max
= num_to_alloc
;
2656 /** Setup the input buffer state to scan directly from a user-specified character buffer.
2657 * @param base the character buffer
2658 * @param size the size in bytes of the character buffer
2659 * @param yyscanner The scanner object.
2660 * @return the newly allocated buffer state object.
2662 YY_BUFFER_STATE
ast_yy_scan_buffer (char * base
, yy_size_t size
, yyscan_t yyscanner
)
2667 base
[size
-2] != YY_END_OF_BUFFER_CHAR
||
2668 base
[size
-1] != YY_END_OF_BUFFER_CHAR
)
2669 /* They forgot to leave room for the EOB's. */
2672 b
= (YY_BUFFER_STATE
) ast_yyalloc(sizeof( struct yy_buffer_state
) ,yyscanner
);
2674 YY_FATAL_ERROR( "out of dynamic memory in ast_yy_scan_buffer()" );
2676 b
->yy_buf_size
= size
- 2; /* "- 2" to take care of EOB's */
2677 b
->yy_buf_pos
= b
->yy_ch_buf
= base
;
2678 b
->yy_is_our_buffer
= 0;
2679 b
->yy_input_file
= 0;
2680 b
->yy_n_chars
= b
->yy_buf_size
;
2681 b
->yy_is_interactive
= 0;
2683 b
->yy_fill_buffer
= 0;
2684 b
->yy_buffer_status
= YY_BUFFER_NEW
;
2686 ast_yy_switch_to_buffer(b
,yyscanner
);
2691 /** Setup the input buffer state to scan a string. The next call to ast_yylex() will
2692 * scan from a @e copy of @a str.
2693 * @param str a NUL-terminated string to scan
2694 * @param yyscanner The scanner object.
2695 * @return the newly allocated buffer state object.
2696 * @note If you want to scan bytes that may contain NUL values, then use
2697 * ast_yy_scan_bytes() instead.
2699 YY_BUFFER_STATE
ast_yy_scan_string (yyconst
char * str
, yyscan_t yyscanner
)
2702 return ast_yy_scan_bytes(str
,strlen(str
) ,yyscanner
);
2705 /** Setup the input buffer state to scan the given bytes. The next call to ast_yylex() will
2706 * scan from a @e copy of @a bytes.
2707 * @param bytes the byte buffer to scan
2708 * @param len the number of bytes in the buffer pointed to by @a bytes.
2709 * @param yyscanner The scanner object.
2710 * @return the newly allocated buffer state object.
2712 YY_BUFFER_STATE
ast_yy_scan_bytes (yyconst
char * bytes
, int len
, yyscan_t yyscanner
)
2719 /* Get memory for full buffer, including space for trailing EOB's. */
2721 buf
= (char *) ast_yyalloc(n
,yyscanner
);
2723 YY_FATAL_ERROR( "out of dynamic memory in ast_yy_scan_bytes()" );
2725 for ( i
= 0; i
< len
; ++i
)
2728 buf
[len
] = buf
[len
+1] = YY_END_OF_BUFFER_CHAR
;
2730 b
= ast_yy_scan_buffer(buf
,n
,yyscanner
);
2732 YY_FATAL_ERROR( "bad buffer in ast_yy_scan_bytes()" );
2734 /* It's okay to grow etc. this buffer, and we should throw it
2735 * away when we're done.
2737 b
->yy_is_our_buffer
= 1;
2742 #ifndef YY_EXIT_FAILURE
2743 #define YY_EXIT_FAILURE 2
2746 static void yy_fatal_error (yyconst
char* msg
, yyscan_t yyscanner
)
2748 (void) fprintf( stderr
, "%s\n", msg
);
2749 exit( YY_EXIT_FAILURE
);
2752 /* Redefine yyless() so it works in section 3 code. */
2758 /* Undo effects of setting up yytext. */ \
2759 int yyless_macro_arg = (n); \
2760 YY_LESS_LINENO(yyless_macro_arg);\
2761 yytext[yyleng] = yyg->yy_hold_char; \
2762 yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
2763 yyg->yy_hold_char = *yyg->yy_c_buf_p; \
2764 *yyg->yy_c_buf_p = '\0'; \
2765 yyleng = yyless_macro_arg; \
2769 /* Accessor methods (get/set functions) to struct members. */
2771 /** Get the user-defined data for this scanner.
2772 * @param yyscanner The scanner object.
2774 YY_EXTRA_TYPE
ast_yyget_extra (yyscan_t yyscanner
)
2776 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2780 /** Get the current line number.
2781 * @param yyscanner The scanner object.
2783 int ast_yyget_lineno (yyscan_t yyscanner
)
2785 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2787 if (! YY_CURRENT_BUFFER
)
2793 /** Get the current column number.
2794 * @param yyscanner The scanner object.
2796 int ast_yyget_column (yyscan_t yyscanner
)
2798 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2800 if (! YY_CURRENT_BUFFER
)
2806 /** Get the input stream.
2807 * @param yyscanner The scanner object.
2809 FILE *ast_yyget_in (yyscan_t yyscanner
)
2811 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2815 /** Get the output stream.
2816 * @param yyscanner The scanner object.
2818 FILE *ast_yyget_out (yyscan_t yyscanner
)
2820 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2824 /** Get the length of the current token.
2825 * @param yyscanner The scanner object.
2827 int ast_yyget_leng (yyscan_t yyscanner
)
2829 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2833 /** Get the current token.
2834 * @param yyscanner The scanner object.
2837 char *ast_yyget_text (yyscan_t yyscanner
)
2839 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2843 /** Set the user-defined data. This data is never touched by the scanner.
2844 * @param user_defined The data to be associated with this scanner.
2845 * @param yyscanner The scanner object.
2847 void ast_yyset_extra (YY_EXTRA_TYPE user_defined
, yyscan_t yyscanner
)
2849 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2850 yyextra
= user_defined
;
2853 /** Set the current line number.
2854 * @param line_number
2855 * @param yyscanner The scanner object.
2857 void ast_yyset_lineno (int line_number
, yyscan_t yyscanner
)
2859 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2861 /* lineno is only valid if an input buffer exists. */
2862 if (! YY_CURRENT_BUFFER
)
2863 yy_fatal_error( "ast_yyset_lineno called with no buffer" , yyscanner
);
2865 yylineno
= line_number
;
2868 /** Set the current column.
2869 * @param line_number
2870 * @param yyscanner The scanner object.
2872 void ast_yyset_column (int column_no
, yyscan_t yyscanner
)
2874 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2876 /* column is only valid if an input buffer exists. */
2877 if (! YY_CURRENT_BUFFER
)
2878 yy_fatal_error( "ast_yyset_column called with no buffer" , yyscanner
);
2880 yycolumn
= column_no
;
2883 /** Set the input stream. This does not discard the current
2885 * @param in_str A readable stream.
2886 * @param yyscanner The scanner object.
2887 * @see ast_yy_switch_to_buffer
2889 void ast_yyset_in (FILE * in_str
, yyscan_t yyscanner
)
2891 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2895 void ast_yyset_out (FILE * out_str
, yyscan_t yyscanner
)
2897 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2901 int ast_yyget_debug (yyscan_t yyscanner
)
2903 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2904 return yy_flex_debug
;
2907 void ast_yyset_debug (int bdebug
, yyscan_t yyscanner
)
2909 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2910 yy_flex_debug
= bdebug
;
2913 /* Accessor methods for yylval and yylloc */
2915 YYSTYPE
* ast_yyget_lval (yyscan_t yyscanner
)
2917 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2921 void ast_yyset_lval (YYSTYPE
* yylval_param
, yyscan_t yyscanner
)
2923 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2924 yylval
= yylval_param
;
2927 YYLTYPE
*ast_yyget_lloc (yyscan_t yyscanner
)
2929 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2933 void ast_yyset_lloc (YYLTYPE
* yylloc_param
, yyscan_t yyscanner
)
2935 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2936 yylloc
= yylloc_param
;
2939 static int yy_init_globals (yyscan_t yyscanner
)
2941 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
2942 /* Initialization is the same as for the non-reentrant scanner.
2943 This function is called once per scanner lifetime. */
2945 yyg
->yy_buffer_stack
= 0;
2946 yyg
->yy_buffer_stack_top
= 0;
2947 yyg
->yy_buffer_stack_max
= 0;
2948 yyg
->yy_c_buf_p
= (char *) 0;
2951 yyg
->yy_start_stack_ptr
= 0;
2952 yyg
->yy_start_stack_depth
= 0;
2953 yyg
->yy_start_stack
= (int *) 0;
2955 /* Defined in main.c */
2964 /* For future reference: Set errno on error, since we are called by
2970 /* User-visible API */
2972 /* ast_yylex_init is special because it creates the scanner itself, so it is
2973 * the ONLY reentrant function that doesn't take the scanner as the last argument.
2974 * That's why we explicitly handle the declaration, instead of using our macros.
2977 int ast_yylex_init(yyscan_t
* ptr_yy_globals
)
2980 if (ptr_yy_globals
== NULL
){
2985 *ptr_yy_globals
= (yyscan_t
) ast_yyalloc ( sizeof( struct yyguts_t
), NULL
);
2987 if (*ptr_yy_globals
== NULL
){
2992 memset(*ptr_yy_globals
,0,sizeof(struct yyguts_t
));
2994 return yy_init_globals ( *ptr_yy_globals
);
2997 /* ast_yylex_destroy is for both reentrant and non-reentrant scanners. */
2998 int ast_yylex_destroy (yyscan_t yyscanner
)
3000 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3002 /* Pop the buffer stack, destroying each element. */
3003 while(YY_CURRENT_BUFFER
){
3004 ast_yy_delete_buffer(YY_CURRENT_BUFFER
,yyscanner
);
3005 YY_CURRENT_BUFFER_LVALUE
= NULL
;
3006 ast_yypop_buffer_state(yyscanner
);
3009 /* Destroy the stack itself. */
3010 ast_yyfree(yyg
->yy_buffer_stack
,yyscanner
);
3011 yyg
->yy_buffer_stack
= NULL
;
3013 /* Destroy the start condition stack. */
3014 ast_yyfree(yyg
->yy_start_stack
,yyscanner
);
3015 yyg
->yy_start_stack
= NULL
;
3017 /* Destroy the main struct (reentrant only). */
3018 ast_yyfree ( yyscanner
, yyscanner
);
3023 * Internal utility routines.
3027 static void yy_flex_strncpy (char* s1
, yyconst
char * s2
, int n
, yyscan_t yyscanner
)
3030 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3031 for ( i
= 0; i
< n
; ++i
)
3036 #ifdef YY_NEED_STRLEN
3037 static int yy_flex_strlen (yyconst
char * s
, yyscan_t yyscanner
)
3040 struct yyguts_t
* yyg
= (struct yyguts_t
*)yyscanner
;
3041 for ( n
= 0; s
[n
]; ++n
)
3048 void *ast_yyalloc (yy_size_t size
, yyscan_t yyscanner
)
3050 return (void *) malloc( size
);
3053 void *ast_yyrealloc (void * ptr
, yy_size_t size
, yyscan_t yyscanner
)
3055 /* The cast to (char *) in the following accommodates both
3056 * implementations that use char* generic pointers, and those
3057 * that use void* generic pointers. It works with the latter
3058 * because both ANSI C and C++ allow castless assignment from
3059 * any pointer type to void*, and deal with argument conversions
3060 * as though doing an assignment.
3062 return (void *) realloc( (char *) ptr
, size
);
3065 void ast_yyfree (void * ptr
, yyscan_t yyscanner
)
3067 free( (char *) ptr
); /* see ast_yyrealloc() for (char *) cast */
3070 #define YYTABLES_NAME "yytables"
3073 #undef YY_FLUSH_BUFFER
3075 #undef yy_new_buffer
3076 #undef yy_set_interactive
3078 #undef YY_DO_BEFORE_ACTION
3080 #ifdef YY_DECL_IS_OURS
3081 #undef YY_DECL_IS_OURS
3084 #line 205 "ast_expr2.fl"
3088 /* I'm putting the interface routine to the whole parse here in the flexer input file
3089 mainly because of all the flexer initialization that has to be done. Shouldn't matter
3090 where it is, as long as it's somewhere. I didn't want to define a prototype for the
3091 ast_yy_scan_string in the .y file, because then, I'd have to define YY_BUFFER_STATE there...
3092 UGH! that would be inappropriate. */
3094 int ast_yyparse(void *); /* need to/should define this prototype for the call to yyparse */
3095 int ast_yyerror(const char *, YYLTYPE
*, struct parse_io
*); /* likewise */
3097 int ast_expr(char *expr
, char *buf
, int length
)
3100 int return_value
= 0;
3102 memset(&io
, 0, sizeof(io
));
3103 io
.string
= expr
; /* to pass to the error routine */
3105 ast_yylex_init(&io
.scanner
);
3107 ast_yy_scan_string(expr
, io
.scanner
);
3109 ast_yyparse ((void *) &io
);
3111 ast_yylex_destroy(io
.scanner
);
3119 if (io
.val
->type
== AST_EXPR_integer
) {
3122 res_length
= snprintf(buf
, length
, "%ld", (long int) io
.val
->u
.i
);
3123 return_value
= (res_length
<= length
) ? res_length
: length
;
3125 #if defined(STANDALONE) || defined(LOW_MEMORY)
3126 strncpy(buf
, io
.val
->u
.s
, length
- 1);
3127 #else /* !STANDALONE && !LOW_MEMORY */
3128 ast_copy_string(buf
, io
.val
->u
.s
, length
);
3129 #endif /* STANDALONE || LOW_MEMORY */
3130 return_value
= strlen(buf
);
3135 return return_value
;
3139 char extra_error_message
[4095];
3140 int extra_error_message_supplied
= 0;
3141 void ast_expr_register_extra_error_info(char *message
);
3142 void ast_expr_clear_extra_error_info(void);
3144 void ast_expr_register_extra_error_info(char *message
)
3146 extra_error_message_supplied
=1;
3147 strcpy(extra_error_message
, message
);
3150 void ast_expr_clear_extra_error_info(void)
3152 extra_error_message_supplied
=0;
3153 extra_error_message
[0] = 0;
3156 static char *expr2_token_equivs1
[] =
3181 static char *expr2_token_equivs2
[] =
3207 static char *expr2_token_subst(char *mess
)
3209 /* calc a length, malloc, fill, and return; yyerror had better free it! */
3213 int expr2_token_equivs_entries
= sizeof(expr2_token_equivs1
)/sizeof(char*);
3215 for (p
=mess
; *p
; p
++) {
3216 for (i
=0; i
<expr2_token_equivs_entries
; i
++) {
3217 if ( strncmp(p
,expr2_token_equivs1
[i
],strlen(expr2_token_equivs1
[i
])) == 0 )
3219 len
+=strlen(expr2_token_equivs2
[i
])+2;
3220 p
+= strlen(expr2_token_equivs1
[i
])-1;
3226 res
= (char*)malloc(len
+1);
3231 for (i
=0; i
<expr2_token_equivs_entries
; i
++) {
3232 if ( strncmp(p
,expr2_token_equivs1
[i
],strlen(expr2_token_equivs1
[i
])) == 0 ) {
3234 for (t
=expr2_token_equivs2
[i
]; *t
;) {
3238 p
+= strlen(expr2_token_equivs1
[i
]);
3250 int ast_yyerror (const char *s
, yyltype
*loc
, struct parse_io
*parseio
)
3252 struct yyguts_t
* yyg
= (struct yyguts_t
*)(parseio
->scanner
);
3253 char spacebuf
[8000]; /* best safe than sorry */
3254 char spacebuf2
[8000]; /* best safe than sorry */
3256 char *s2
= expr2_token_subst((char *)s
);
3259 for(i
=0;i
< (int)(yytext
- YY_CURRENT_BUFFER_LVALUE
->yy_ch_buf
);i
++) spacebuf2
[i
] = ' '; /* uh... assuming yyg is defined, then I can use the yycolumn macro,
3260 which is the same thing as... get this:
3261 yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]->yy_bs_column
3262 I was tempted to just use yy_buf_pos in the STATE, but..., well:
3263 a. the yy_buf_pos is the current position in the buffer, which
3264 may not relate to the entire string/buffer because of the
3266 b. but, analysis of the situation is that when you use the
3267 ast_yy_scan_string func, it creates a single buffer the size of
3268 string, so the two would be the same...
3269 so, in the end, the yycolumn macro is available, shorter, therefore easier. */
3274 /* easier to read in the standalone version */
3275 printf("ast_yyerror(): %s syntax error: %s; Input:\n%s\n%s\n",
3276 (extra_error_message_supplied
?extra_error_message
:""), s2
, parseio
->string
,spacebuf2
);
3278 ast_log(LOG_WARNING
,"ast_yyerror(): %s syntax error: %s; Input:\n%s\n%s\n",
3279 (extra_error_message_supplied
?extra_error_message
:""), s2
, parseio
->string
,spacebuf2
);
3282 ast_log(LOG_WARNING
,"If you have questions, please refer to doc/channelvariables.txt in the asterisk source.\n");