00001
00002
00003
00004
00005
00006
00007 #define FLEX_SCANNER
00008 #define YY_FLEX_MAJOR_VERSION 2
00009 #define YY_FLEX_MINOR_VERSION 5
00010
00011 #include <stdio.h>
00012 #include <unistd.h>
00013
00014
00015
00016 #ifdef c_plusplus
00017 #ifndef __cplusplus
00018 #define __cplusplus
00019 #endif
00020 #endif
00021
00022
00023 #ifdef __cplusplus
00024
00025 #include <stdlib.h>
00026
00027
00028 #define YY_USE_PROTOS
00029
00030
00031 #define YY_USE_CONST
00032
00033 #else
00034
00035 #if __STDC__
00036
00037 #define YY_USE_PROTOS
00038 #define YY_USE_CONST
00039
00040 #endif
00041 #endif
00042
00043 #ifdef __TURBOC__
00044 #pragma warn -rch
00045 #pragma warn -use
00046 #include <io.h>
00047 #include <stdlib.h>
00048 #define YY_USE_CONST
00049 #define YY_USE_PROTOS
00050 #endif
00051
00052 #ifdef YY_USE_CONST
00053 #define yyconst const
00054 #else
00055 #define yyconst
00056 #endif
00057
00058
00059 #ifdef YY_USE_PROTOS
00060 #define YY_PROTO(proto) proto
00061 #else
00062 #define YY_PROTO(proto) ()
00063 #endif
00064
00065
00066 #define YY_NULL 0
00067
00068
00069
00070
00071
00072
00073 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
00074
00075
00076
00077
00078
00079 #define BEGIN yy_start = 1 + 2 *
00080
00081
00082
00083
00084
00085 #define YY_START ((yy_start - 1) / 2)
00086 #define YYSTATE YY_START
00087
00088
00089 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
00090
00091
00092 #define YY_NEW_FILE yyrestart( yyin )
00093
00094 #define YY_END_OF_BUFFER_CHAR 0
00095
00096
00097 #define YY_BUF_SIZE 16384
00098
00099 typedef struct yy_buffer_state *YY_BUFFER_STATE;
00100
00101 extern int yyleng;
00102 extern FILE *yyin, *yyout;
00103
00104 #define EOB_ACT_CONTINUE_SCAN 0
00105 #define EOB_ACT_END_OF_FILE 1
00106 #define EOB_ACT_LAST_MATCH 2
00107
00108
00109
00110
00111
00112
00113
00114
00115
00116
00117
00118
00119
00120
00121
00122
00123
00124 #define yyless(n) \
00125 do \
00126 { \
00127 \
00128 *yy_cp = yy_hold_char; \
00129 YY_RESTORE_YY_MORE_OFFSET \
00130 yy_c_buf_p = yy_cp = yy_bp + n - YY_MORE_ADJ; \
00131 YY_DO_BEFORE_ACTION; \
00132 } \
00133 while ( 0 )
00134
00135 #define unput(c) yyunput( c, yytext_ptr )
00136
00137
00138
00139
00140
00141 typedef unsigned int yy_size_t;
00142
00143
00144 struct yy_buffer_state
00145 {
00146 FILE *yy_input_file;
00147
00148 char *yy_ch_buf;
00149 char *yy_buf_pos;
00150
00151
00152
00153
00154 yy_size_t yy_buf_size;
00155
00156
00157
00158
00159 int yy_n_chars;
00160
00161
00162
00163
00164
00165 int yy_is_our_buffer;
00166
00167
00168
00169
00170
00171
00172 int yy_is_interactive;
00173
00174
00175
00176
00177
00178 int yy_at_bol;
00179
00180
00181
00182
00183 int yy_fill_buffer;
00184
00185 int yy_buffer_status;
00186 #define YY_BUFFER_NEW 0
00187 #define YY_BUFFER_NORMAL 1
00188
00189
00190
00191
00192
00193
00194
00195
00196
00197
00198 #define YY_BUFFER_EOF_PENDING 2
00199 };
00200
00201 static YY_BUFFER_STATE yy_current_buffer = 0;
00202
00203
00204
00205
00206
00207 #define YY_CURRENT_BUFFER yy_current_buffer
00208
00209
00210
00211 static char yy_hold_char;
00212
00213 static int yy_n_chars;
00214
00215
00216 int yyleng;
00217
00218
00219 static char *yy_c_buf_p = (char *) 0;
00220 static int yy_init = 1;
00221 static int yy_start = 0;
00222
00223
00224
00225
00226 static int yy_did_buffer_switch_on_eof;
00227
00228 void yyrestart YY_PROTO(( FILE *input_file ));
00229
00230 void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
00231 void yy_load_buffer_state YY_PROTO(( void ));
00232 YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
00233 void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
00234 void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));
00235 void yy_flush_buffer YY_PROTO(( YY_BUFFER_STATE b ));
00236 #define YY_FLUSH_BUFFER yy_flush_buffer( yy_current_buffer )
00237
00238 YY_BUFFER_STATE yy_scan_buffer YY_PROTO(( char *base, yy_size_t size ));
00239 YY_BUFFER_STATE yy_scan_string YY_PROTO(( yyconst char *yy_str ));
00240 YY_BUFFER_STATE yy_scan_bytes YY_PROTO(( yyconst char *bytes, int len ));
00241
00242 static void *yy_flex_alloc YY_PROTO(( yy_size_t ));
00243 static void *yy_flex_realloc YY_PROTO(( void *, yy_size_t ));
00244 static void yy_flex_free YY_PROTO(( void * ));
00245
00246 #define yy_new_buffer yy_create_buffer
00247
00248 #define yy_set_interactive(is_interactive) \
00249 { \
00250 if ( ! yy_current_buffer ) \
00251 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
00252 yy_current_buffer->yy_is_interactive = is_interactive; \
00253 }
00254
00255 #define yy_set_bol(at_bol) \
00256 { \
00257 if ( ! yy_current_buffer ) \
00258 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
00259 yy_current_buffer->yy_at_bol = at_bol; \
00260 }
00261
00262 #define YY_AT_BOL() (yy_current_buffer->yy_at_bol)
00263
00264
00265 #define yywrap() 1
00266 #define YY_SKIP_YYWRAP
00267 typedef unsigned char YY_CHAR;
00268 FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
00269 typedef int yy_state_type;
00270 extern char *yytext;
00271 #define yytext_ptr yytext
00272
00273 static yy_state_type yy_get_previous_state YY_PROTO(( void ));
00274 static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
00275 static int yy_get_next_buffer YY_PROTO(( void ));
00276 static void yy_fatal_error YY_PROTO(( yyconst char msg[] ));
00277
00278
00279
00280
00281 #define YY_DO_BEFORE_ACTION \
00282 yytext_ptr = yy_bp; \
00283 yyleng = (int) (yy_cp - yy_bp); \
00284 yy_hold_char = *yy_cp; \
00285 *yy_cp = '\0'; \
00286 yy_c_buf_p = yy_cp;
00287
00288 #define YY_NUM_RULES 32
00289 #define YY_END_OF_BUFFER 33
00290 static yyconst short int yy_accept[66] =
00291 { 0,
00292 0, 0, 33, 30, 1, 31, 30, 30, 22, 30,
00293 30, 30, 24, 24, 24, 24, 13, 30, 15, 30,
00294 22, 22, 22, 22, 30, 1, 18, 0, 2, 0,
00295 22, 19, 0, 3, 10, 0, 24, 24, 24, 0,
00296 29, 27, 26, 28, 0, 11, 14, 17, 16, 12,
00297 21, 8, 7, 6, 5, 4, 9, 20, 2, 23,
00298 25, 0, 0, 23, 0
00299 } ;
00300
00301 static yyconst int yy_ec[256] =
00302 { 0,
00303 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
00304 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00305 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00306 1, 2, 4, 5, 1, 6, 1, 7, 8, 1,
00307 1, 9, 10, 1, 10, 11, 1, 12, 13, 14,
00308 14, 14, 14, 14, 14, 15, 15, 1, 1, 16,
00309 17, 18, 1, 6, 19, 19, 19, 19, 20, 19,
00310 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
00311 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
00312 1, 22, 1, 23, 21, 1, 19, 24, 19, 25,
00313
00314 26, 19, 27, 28, 21, 21, 21, 29, 21, 30,
00315 31, 21, 32, 21, 21, 33, 21, 21, 21, 34,
00316 21, 21, 1, 35, 1, 1, 1, 1, 1, 1,
00317 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00318 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00319 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00320 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00321 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00322 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00323 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00324
00325 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00326 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00327 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00328 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00329 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00330 1, 1, 1, 1, 1
00331 } ;
00332
00333 static yyconst int yy_meta[36] =
00334 { 0,
00335 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00336 1, 2, 2, 2, 2, 1, 1, 1, 3, 2,
00337 4, 1, 1, 3, 3, 2, 4, 5, 4, 4,
00338 4, 4, 4, 4, 1
00339 } ;
00340
00341 static yyconst short int yy_base[72] =
00342 { 0,
00343 0, 0, 129, 130, 126, 130, 110, 31, 0, 119,
00344 117, 115, 43, 89, 25, 29, 23, 105, 27, 98,
00345 88, 39, 40, 90, 50, 82, 130, 42, 130, 56,
00346 0, 130, 75, 130, 130, 67, 42, 0, 0, 47,
00347 23, 22, 130, 130, 0, 130, 130, 130, 130, 130,
00348 130, 0, 0, 0, 0, 0, 0, 130, 65, 26,
00349 0, 76, 80, 84, 130, 99, 103, 108, 112, 116,
00350 46
00351 } ;
00352
00353 static yyconst short int yy_def[72] =
00354 { 0,
00355 65, 1, 65, 65, 65, 65, 65, 66, 67, 65,
00356 68, 65, 65, 13, 13, 15, 65, 65, 65, 65,
00357 67, 67, 67, 67, 65, 65, 65, 66, 65, 66,
00358 67, 65, 68, 65, 65, 65, 13, 15, 16, 69,
00359 69, 69, 65, 65, 70, 65, 65, 65, 65, 65,
00360 65, 67, 67, 67, 67, 67, 67, 65, 66, 71,
00361 70, 65, 65, 65, 0, 65, 65, 65, 65, 65,
00362 65
00363 } ;
00364
00365 static yyconst short int yy_nxt[166] =
00366 { 0,
00367 4, 5, 6, 7, 8, 9, 10, 11, 12, 4,
00368 4, 13, 14, 15, 16, 17, 18, 19, 9, 9,
00369 9, 4, 20, 9, 9, 21, 22, 9, 23, 24,
00370 9, 9, 9, 9, 25, 29, 38, 38, 46, 47,
00371 39, 39, 39, 49, 50, 62, 29, 60, 40, 43,
00372 43, 62, 30, 36, 37, 37, 38, 39, 65, 65,
00373 59, 40, 40, 30, 53, 55, 41, 42, 40, 29,
00374 43, 54, 56, 44, 43, 65, 45, 30, 60, 60,
00375 60, 60, 34, 26, 58, 63, 30, 64, 64, 64,
00376 64, 64, 64, 64, 64, 64, 64, 64, 64, 28,
00377
00378 28, 28, 28, 28, 31, 31, 31, 31, 33, 33,
00379 33, 33, 33, 40, 40, 57, 40, 61, 61, 52,
00380 51, 48, 65, 35, 34, 32, 27, 26, 65, 3,
00381 65, 65, 65, 65, 65, 65, 65, 65, 65, 65,
00382 65, 65, 65, 65, 65, 65, 65, 65, 65, 65,
00383 65, 65, 65, 65, 65, 65, 65, 65, 65, 65,
00384 65, 65, 65, 65, 65
00385 } ;
00386
00387 static yyconst short int yy_chk[166] =
00388 { 0,
00389 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00390 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00391 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00392 1, 1, 1, 1, 1, 8, 15, 15, 17, 17,
00393 16, 16, 16, 19, 19, 60, 28, 71, 15, 42,
00394 41, 60, 8, 13, 13, 13, 13, 13, 15, 16,
00395 30, 13, 13, 28, 22, 23, 13, 13, 13, 59,
00396 13, 22, 23, 13, 40, 37, 13, 30, 36, 36,
00397 36, 36, 33, 26, 25, 62, 59, 62, 62, 62,
00398 62, 63, 63, 63, 63, 64, 64, 64, 64, 66,
00399
00400 66, 66, 66, 66, 67, 67, 67, 67, 68, 68,
00401 68, 68, 68, 69, 69, 24, 69, 70, 70, 21,
00402 20, 18, 14, 12, 11, 10, 7, 5, 3, 65,
00403 65, 65, 65, 65, 65, 65, 65, 65, 65, 65,
00404 65, 65, 65, 65, 65, 65, 65, 65, 65, 65,
00405 65, 65, 65, 65, 65, 65, 65, 65, 65, 65,
00406 65, 65, 65, 65, 65
00407 } ;
00408
00409 static yy_state_type yy_last_accepting_state;
00410 static char *yy_last_accepting_cpos;
00411
00412
00413
00414
00415 #define REJECT reject_used_but_not_detected
00416 #define yymore() yymore_used_but_not_detected
00417 #define YY_MORE_ADJ 0
00418 #define YY_RESTORE_YY_MORE_OFFSET
00419 char *yytext;
00420 #line 1 "lex.l"
00421 #define INITIAL 0
00422 #line 2 "lex.l"
00423
00424 #define USE_PURE_PARSER
00425
00426 #ifdef USE_PURE_PARSER
00427 #define YY_DECL int yylex (YYSTYPE *lvalp)
00428 #define YY_LVALP lvalp
00429 #else
00430 #define YY_LVALP (&yylval)
00431 #endif
00432
00433
00434 #define YY_USER_ACTION lex_pos=yy_bp - YY_CURRENT_BUFFER->yy_ch_buf;
00435
00436 #include <stdio.h>
00437 #include <string.h>
00438 #include <stdlib.h>
00439
00440 #include "eval.h"
00441 #include "evaltype.h"
00442 #include "evalparse.h"
00443
00444 static int lex_pos;
00445
00446 static int char2int(char a, int base)
00447 {
00448 int i;
00449 if ((a>='A') && (a<='Z')) {
00450 i=a-'A'+10;
00451 } else if ((a>='a') && (a<='z')) {
00452 i=a-'a'+10;
00453 } else if ((a>='0') && (a<='9')) {
00454 i=a-'0';
00455 } else return -1;
00456 if (i>=base) return -1;
00457 return i;
00458 }
00459
00460 static int parse_float(eval_scalar *f, char *fpn)
00461 {
00462 char *end;
00463 double d;
00464 d=strtod(fpn, &end);
00465 if (*end==0) {
00466 f->type=SCALAR_FLOAT;
00467 f->scalar.floatnum.value=d;
00468 return 1;
00469 }
00470 return 0;
00471 }
00472
00473 static int parse_integer(eval_scalar *i, char *num, int base, int lenmod)
00474 {
00475 qword k=int_to_qword(0);
00476 int l=strlen(num)+lenmod;
00477 while (l--) {
00478 int c=char2int(*num, base);
00479 if (c==-1) return 0;
00480 k=qword_mul(k, int_to_qword(base));
00481 k=qword_add(k, int_to_qword(c));
00482 num++;
00483 }
00484 i->type=SCALAR_INT;
00485 i->scalar.integer.value=k;
00486 i->scalar.integer.type=TYPE_UNKNOWN;
00487 return 1;
00488 }
00489
00490 static int parse_cstring(eval_scalar *r, char *s, int len)
00491 {
00492 char *result;
00493
00494 int alloclen = len;
00495 if (alloclen < 1) alloclen = 1;
00496
00497 r->type = SCALAR_STR;
00498 r->scalar.str.value = (char*)malloc(alloclen);
00499 if (!r->scalar.str.value) return 0;
00500
00501 result = r->scalar.str.value;
00502
00503
00504 if (len && s[len-1] == '\\') return 0;
00505
00506 while (s && *s && len) {
00507 if (*s == '\\') {
00508 s++;len--;if (!len) break;
00509 switch (*s) {
00510 case '0':
00511 *result++='\0';
00512 break;
00513 case 'a':
00514 *result++='\a';
00515 break;
00516 case 'b':
00517 *result++='\b';
00518 break;
00519 case 'e':
00520 *result++='\e';
00521 break;
00522 case 'f':
00523 *result++='\f';
00524 break;
00525 case 'n':
00526 *result++='\n';
00527 break;
00528 case 'r':
00529 *result++='\r';
00530 break;
00531 case 't':
00532 *result++='\t';
00533 break;
00534 case 'v':
00535 *result++='\v';
00536 break;
00537 case '\"':
00538 *result++='"';
00539 break;
00540 case '\\':
00541 *result++='\\';
00542 break;
00543 case 'x': {
00544 int p, q;
00545 s++;len--;if (!len) break;
00546 p=char2int(*s, 16);
00547 if (p==-1) return 0;
00548 s++;len--;if (!len) break;
00549 q=char2int(*s, 16);
00550 if (q==-1) return 0;
00551 *result++=(char)p*16+q;
00552 break;
00553 }
00554 default:
00555 *result++='\\';
00556 if (len) *result++=*s;
00557 break;
00558 }
00559 } else {
00560 *result++ = *s;
00561 }
00562 s++;len--;
00563 }
00564
00565 r->scalar.str.len=result-r->scalar.str.value;
00566
00567 return 1;
00568 }
00569
00570 static int parse_pstring(eval_scalar *s, char *cstr, int len)
00571 {
00572 int alloclen=len;
00573 if (!len) alloclen=1;
00574
00575 s->type=SCALAR_STR;
00576 s->scalar.str.value=(char*)malloc(alloclen);
00577 memmove(s->scalar.str.value, cstr, len);
00578 s->scalar.str.len=len;
00579 return 1;
00580 }
00581
00582 void *lex_current_buffer()
00583 {
00584 return (void*)YY_CURRENT_BUFFER;
00585 }
00586
00587 int lex_current_buffer_pos()
00588 {
00589 return lex_pos;
00590 }
00591
00592 void lex_switch_buffer(void *buffer)
00593 {
00594 yy_switch_to_buffer(buffer);
00595 }
00596
00597 void lex_delete_buffer(void *buffer)
00598 {
00599 yy_delete_buffer(buffer);
00600 }
00601
00602 void *lex_scan_string_buffer(const char *str)
00603 {
00604 return yy_scan_string(str);
00605 }
00606
00607
00608
00609 #line 610 "lex.yy.c"
00610
00611
00612
00613
00614
00615 #ifndef YY_SKIP_YYWRAP
00616 #ifdef __cplusplus
00617 extern "C" int yywrap YY_PROTO(( void ));
00618 #else
00619 extern int yywrap YY_PROTO(( void ));
00620 #endif
00621 #endif
00622
00623 #ifndef YY_NO_UNPUT
00624 static void yyunput YY_PROTO(( int c, char *buf_ptr ));
00625 #endif
00626
00627 #ifndef yytext_ptr
00628 static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));
00629 #endif
00630
00631 #ifdef YY_NEED_STRLEN
00632 static int yy_flex_strlen YY_PROTO(( yyconst char * ));
00633 #endif
00634
00635 #ifndef YY_NO_INPUT
00636 #ifdef __cplusplus
00637 static int yyinput YY_PROTO(( void ));
00638 #else
00639 static int input YY_PROTO(( void ));
00640 #endif
00641 #endif
00642
00643 #if YY_STACK_USED
00644 static int yy_start_stack_ptr = 0;
00645 static int yy_start_stack_depth = 0;
00646 static int *yy_start_stack = 0;
00647 #ifndef YY_NO_PUSH_STATE
00648 static void yy_push_state YY_PROTO(( int new_state ));
00649 #endif
00650 #ifndef YY_NO_POP_STATE
00651 static void yy_pop_state YY_PROTO(( void ));
00652 #endif
00653 #ifndef YY_NO_TOP_STATE
00654 static int yy_top_state YY_PROTO(( void ));
00655 #endif
00656
00657 #else
00658 #define YY_NO_PUSH_STATE 1
00659 #define YY_NO_POP_STATE 1
00660 #define YY_NO_TOP_STATE 1
00661 #endif
00662
00663 #ifdef YY_MALLOC_DECL
00664 YY_MALLOC_DECL
00665 #else
00666 #if __STDC__
00667 #ifndef __cplusplus
00668 #include <stdlib.h>
00669 #endif
00670 #else
00671
00672
00673
00674
00675 #endif
00676 #endif
00677
00678
00679 #ifndef YY_READ_BUF_SIZE
00680 #define YY_READ_BUF_SIZE 8192
00681 #endif
00682
00683
00684
00685 #ifndef ECHO
00686
00687
00688
00689 #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
00690 #endif
00691
00692
00693
00694
00695 #ifndef YY_INPUT
00696 #define YY_INPUT(buf,result,max_size) \
00697 if ( yy_current_buffer->yy_is_interactive ) \
00698 { \
00699 int c = '*', n; \
00700 for ( n = 0; n < max_size && \
00701 (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
00702 buf[n] = (char) c; \
00703 if ( c == '\n' ) \
00704 buf[n++] = (char) c; \
00705 if ( c == EOF && ferror( yyin ) ) \
00706 YY_FATAL_ERROR( "input in flex scanner failed" ); \
00707 result = n; \
00708 } \
00709 else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
00710 && ferror( yyin ) ) \
00711 YY_FATAL_ERROR( "input in flex scanner failed" );
00712 #endif
00713
00714
00715
00716
00717
00718 #ifndef yyterminate
00719 #define yyterminate() return YY_NULL
00720 #endif
00721
00722
00723 #ifndef YY_START_STACK_INCR
00724 #define YY_START_STACK_INCR 25
00725 #endif
00726
00727
00728 #ifndef YY_FATAL_ERROR
00729 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
00730 #endif
00731
00732
00733
00734
00735 #ifndef YY_DECL
00736 #define YY_DECL int yylex YY_PROTO(( void ))
00737 #endif
00738
00739
00740
00741
00742 #ifndef YY_USER_ACTION
00743 #define YY_USER_ACTION
00744 #endif
00745
00746
00747 #ifndef YY_BREAK
00748 #define YY_BREAK break;
00749 #endif
00750
00751 #define YY_RULE_SETUP \
00752 YY_USER_ACTION
00753
00754 YY_DECL
00755 {
00756 register yy_state_type yy_current_state;
00757 register char *yy_cp = NULL, *yy_bp = NULL;
00758 register int yy_act;
00759
00760 #line 192 "lex.l"
00761
00762
00763 #line 764 "lex.yy.c"
00764
00765 if ( yy_init )
00766 {
00767 yy_init = 0;
00768
00769 #ifdef YY_USER_INIT
00770 YY_USER_INIT;
00771 #endif
00772
00773 if ( ! yy_start )
00774 yy_start = 1;
00775
00776 if ( ! yyin )
00777 yyin = stdin;
00778
00779 if ( ! yyout )
00780 yyout = stdout;
00781
00782 if ( ! yy_current_buffer )
00783 yy_current_buffer =
00784 yy_create_buffer( yyin, YY_BUF_SIZE );
00785
00786 yy_load_buffer_state();
00787 }
00788
00789 while ( 1 )
00790 {
00791 yy_cp = yy_c_buf_p;
00792
00793
00794 *yy_cp = yy_hold_char;
00795
00796
00797
00798
00799 yy_bp = yy_cp;
00800
00801 yy_current_state = yy_start;
00802 yy_match:
00803 do
00804 {
00805 register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
00806 if ( yy_accept[yy_current_state] )
00807 {
00808 yy_last_accepting_state = yy_current_state;
00809 yy_last_accepting_cpos = yy_cp;
00810 }
00811 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
00812 {
00813 yy_current_state = (int) yy_def[yy_current_state];
00814 if ( yy_current_state >= 66 )
00815 yy_c = yy_meta[(unsigned int) yy_c];
00816 }
00817 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
00818 ++yy_cp;
00819 }
00820 while ( yy_base[yy_current_state] != 130 );
00821
00822 yy_find_action:
00823 yy_act = yy_accept[yy_current_state];
00824 if ( yy_act == 0 )
00825 {
00826 yy_cp = yy_last_accepting_cpos;
00827 yy_current_state = yy_last_accepting_state;
00828 yy_act = yy_accept[yy_current_state];
00829 }
00830
00831 YY_DO_BEFORE_ACTION;
00832
00833
00834 do_action:
00835
00836
00837 switch ( yy_act )
00838 {
00839 case 0:
00840
00841 *yy_cp = yy_hold_char;
00842 yy_cp = yy_last_accepting_cpos;
00843 yy_current_state = yy_last_accepting_state;
00844 goto yy_find_action;
00845
00846 case 1:
00847 YY_RULE_SETUP
00848 #line 194 "lex.l"
00849
00850 YY_BREAK
00851 case 2:
00852 YY_RULE_SETUP
00853 #line 195 "lex.l"
00854 if (parse_cstring(&YY_LVALP->scalar, yytext+1, strlen(yytext+1)-1)) return EVAL_STR;
00855 YY_BREAK
00856 case 3:
00857 YY_RULE_SETUP
00858 #line 196 "lex.l"
00859 if (parse_pstring(&YY_LVALP->scalar, yytext+1, strlen(yytext+1)-1)) return EVAL_STR;
00860 YY_BREAK
00861 case 4:
00862 YY_RULE_SETUP
00863 #line 197 "lex.l"
00864 return EVAL_STR_LT;
00865 YY_BREAK
00866 case 5:
00867 YY_RULE_SETUP
00868 #line 198 "lex.l"
00869 return EVAL_STR_LE;
00870 YY_BREAK
00871 case 6:
00872 YY_RULE_SETUP
00873 #line 199 "lex.l"
00874 return EVAL_STR_GT;
00875 YY_BREAK
00876 case 7:
00877 YY_RULE_SETUP
00878 #line 200 "lex.l"
00879 return EVAL_STR_GE;
00880 YY_BREAK
00881 case 8:
00882 YY_RULE_SETUP
00883 #line 201 "lex.l"
00884 return EVAL_STR_EQ;
00885 YY_BREAK
00886 case 9:
00887 YY_RULE_SETUP
00888 #line 202 "lex.l"
00889 return EVAL_STR_NE;
00890 YY_BREAK
00891 case 10:
00892 YY_RULE_SETUP
00893 #line 203 "lex.l"
00894 return EVAL_POW;
00895 YY_BREAK
00896 case 11:
00897 YY_RULE_SETUP
00898 #line 204 "lex.l"
00899 return EVAL_SHL;
00900 YY_BREAK
00901 case 12:
00902 YY_RULE_SETUP
00903 #line 205 "lex.l"
00904 return EVAL_SHR;
00905 YY_BREAK
00906 case 13:
00907 YY_RULE_SETUP
00908 #line 206 "lex.l"
00909 return EVAL_LT;
00910 YY_BREAK
00911 case 14:
00912 YY_RULE_SETUP
00913 #line 207 "lex.l"
00914 return EVAL_LE;
00915 YY_BREAK
00916 case 15:
00917 YY_RULE_SETUP
00918 #line 208 "lex.l"
00919 return EVAL_GT;
00920 YY_BREAK
00921 case 16:
00922 YY_RULE_SETUP
00923 #line 209 "lex.l"
00924 return EVAL_GE;
00925 YY_BREAK
00926 case 17:
00927 YY_RULE_SETUP
00928 #line 210 "lex.l"
00929 return EVAL_EQ;
00930 YY_BREAK
00931 case 18:
00932 YY_RULE_SETUP
00933 #line 211 "lex.l"
00934 return EVAL_NE;
00935 YY_BREAK
00936 case 19:
00937 YY_RULE_SETUP
00938 #line 212 "lex.l"
00939 return EVAL_LAND;
00940 YY_BREAK
00941 case 20:
00942 YY_RULE_SETUP
00943 #line 213 "lex.l"
00944 return EVAL_LOR;
00945 YY_BREAK
00946 case 21:
00947 YY_RULE_SETUP
00948 #line 214 "lex.l"
00949 return EVAL_LXOR;
00950 YY_BREAK
00951 case 22:
00952 YY_RULE_SETUP
00953 #line 215 "lex.l"
00954 YY_LVALP->ident=strdup(yytext); return EVAL_IDENT;
00955 YY_BREAK
00956 case 23:
00957 YY_RULE_SETUP
00958 #line 216 "lex.l"
00959 if (parse_float(&YY_LVALP->scalar, yytext)) return EVAL_FLOAT;
00960 YY_BREAK
00961 case 24:
00962 YY_RULE_SETUP
00963 #line 217 "lex.l"
00964 if (parse_integer(&YY_LVALP->scalar, yytext, 10, 0)) return EVAL_INT;
00965 YY_BREAK
00966 case 25:
00967 YY_RULE_SETUP
00968 #line 218 "lex.l"
00969 if (parse_integer(&YY_LVALP->scalar, yytext+2, 16, 0)) return EVAL_INT;
00970 YY_BREAK
00971 case 26:
00972 YY_RULE_SETUP
00973 #line 219 "lex.l"
00974 if (parse_integer(&YY_LVALP->scalar, yytext, 16, -1)) return EVAL_INT;
00975 YY_BREAK
00976 case 27:
00977 YY_RULE_SETUP
00978 #line 220 "lex.l"
00979 if (parse_integer(&YY_LVALP->scalar, yytext, 10, -1)) return EVAL_INT;
00980 YY_BREAK
00981 case 28:
00982 YY_RULE_SETUP
00983 #line 221 "lex.l"
00984 if (parse_integer(&YY_LVALP->scalar, yytext, 8, -1)) return EVAL_INT;
00985 YY_BREAK
00986 case 29:
00987 YY_RULE_SETUP
00988 #line 222 "lex.l"
00989 if (parse_integer(&YY_LVALP->scalar, yytext, 2, -1)) return EVAL_INT;
00990 YY_BREAK
00991 case 30:
00992 YY_RULE_SETUP
00993 #line 223 "lex.l"
00994 return *yytext;
00995 YY_BREAK
00996 case 31:
00997 YY_RULE_SETUP
00998 #line 224 "lex.l"
00999 return '\n';
01000 YY_BREAK
01001 case 32:
01002 YY_RULE_SETUP
01003 #line 226 "lex.l"
01004 ECHO;
01005 YY_BREAK
01006 #line 1007 "lex.yy.c"
01007 case YY_STATE_EOF(INITIAL):
01008 yyterminate();
01009
01010 case YY_END_OF_BUFFER:
01011 {
01012
01013 int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1;
01014
01015
01016 *yy_cp = yy_hold_char;
01017 YY_RESTORE_YY_MORE_OFFSET
01018
01019 if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW )
01020 {
01021
01022
01023
01024
01025
01026
01027
01028
01029
01030 yy_n_chars = yy_current_buffer->yy_n_chars;
01031 yy_current_buffer->yy_input_file = yyin;
01032 yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL;
01033 }
01034
01035
01036
01037
01038
01039
01040
01041
01042 if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
01043 {
01044 yy_state_type yy_next_state;
01045
01046 yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text;
01047
01048 yy_current_state = yy_get_previous_state();
01049
01050
01051
01052
01053
01054
01055
01056
01057
01058
01059 yy_next_state = yy_try_NUL_trans( yy_current_state );
01060
01061 yy_bp = yytext_ptr + YY_MORE_ADJ;
01062
01063 if ( yy_next_state )
01064 {
01065
01066 yy_cp = ++yy_c_buf_p;
01067 yy_current_state = yy_next_state;
01068 goto yy_match;
01069 }
01070
01071 else
01072 {
01073 yy_cp = yy_c_buf_p;
01074 goto yy_find_action;
01075 }
01076 }
01077
01078 else switch ( yy_get_next_buffer() )
01079 {
01080 case EOB_ACT_END_OF_FILE:
01081 {
01082 yy_did_buffer_switch_on_eof = 0;
01083
01084 if ( yywrap() )
01085 {
01086
01087
01088
01089
01090
01091
01092
01093
01094
01095 yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
01096
01097 yy_act = YY_STATE_EOF(YY_START);
01098 goto do_action;
01099 }
01100
01101 else
01102 {
01103 if ( ! yy_did_buffer_switch_on_eof )
01104 YY_NEW_FILE;
01105 }
01106 break;
01107 }
01108
01109 case EOB_ACT_CONTINUE_SCAN:
01110 yy_c_buf_p =
01111 yytext_ptr + yy_amount_of_matched_text;
01112
01113 yy_current_state = yy_get_previous_state();
01114
01115 yy_cp = yy_c_buf_p;
01116 yy_bp = yytext_ptr + YY_MORE_ADJ;
01117 goto yy_match;
01118
01119 case EOB_ACT_LAST_MATCH:
01120 yy_c_buf_p =
01121 &yy_current_buffer->yy_ch_buf[yy_n_chars];
01122
01123 yy_current_state = yy_get_previous_state();
01124
01125 yy_cp = yy_c_buf_p;
01126 yy_bp = yytext_ptr + YY_MORE_ADJ;
01127 goto yy_find_action;
01128 }
01129 break;
01130 }
01131
01132 default:
01133 YY_FATAL_ERROR(
01134 "fatal flex scanner internal error--no action found" );
01135 }
01136 }
01137 }
01138
01139
01140
01141
01142
01143
01144
01145
01146
01147
01148 static int yy_get_next_buffer()
01149 {
01150 register char *dest = yy_current_buffer->yy_ch_buf;
01151 register char *source = yytext_ptr;
01152 register int number_to_move, i;
01153 int ret_val;
01154
01155 if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
01156 YY_FATAL_ERROR(
01157 "fatal flex scanner internal error--end of buffer missed" );
01158
01159 if ( yy_current_buffer->yy_fill_buffer == 0 )
01160 {
01161 if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 )
01162 {
01163
01164
01165
01166 return EOB_ACT_END_OF_FILE;
01167 }
01168
01169 else
01170 {
01171
01172
01173
01174 return EOB_ACT_LAST_MATCH;
01175 }
01176 }
01177
01178
01179
01180
01181 number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1;
01182
01183 for ( i = 0; i < number_to_move; ++i )
01184 *(dest++) = *(source++);
01185
01186 if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING )
01187
01188
01189
01190 yy_current_buffer->yy_n_chars = yy_n_chars = 0;
01191
01192 else
01193 {
01194 int num_to_read =
01195 yy_current_buffer->yy_buf_size - number_to_move - 1;
01196
01197 while ( num_to_read <= 0 )
01198 {
01199 #ifdef YY_USES_REJECT
01200 YY_FATAL_ERROR(
01201 "input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
01202 #else
01203
01204
01205 YY_BUFFER_STATE b = yy_current_buffer;
01206
01207 int yy_c_buf_p_offset =
01208 (int) (yy_c_buf_p - b->yy_ch_buf);
01209
01210 if ( b->yy_is_our_buffer )
01211 {
01212 int new_size = b->yy_buf_size * 2;
01213
01214 if ( new_size <= 0 )
01215 b->yy_buf_size += b->yy_buf_size / 8;
01216 else
01217 b->yy_buf_size *= 2;
01218
01219 b->yy_ch_buf = (char *)
01220
01221 yy_flex_realloc( (void *) b->yy_ch_buf,
01222 b->yy_buf_size + 2 );
01223 }
01224 else
01225
01226 b->yy_ch_buf = 0;
01227
01228 if ( ! b->yy_ch_buf )
01229 YY_FATAL_ERROR(
01230 "fatal error - scanner input buffer overflow" );
01231
01232 yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
01233
01234 num_to_read = yy_current_buffer->yy_buf_size -
01235 number_to_move - 1;
01236 #endif
01237 }
01238
01239 if ( num_to_read > YY_READ_BUF_SIZE )
01240 num_to_read = YY_READ_BUF_SIZE;
01241
01242
01243 YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
01244 yy_n_chars, num_to_read );
01245
01246 yy_current_buffer->yy_n_chars = yy_n_chars;
01247 }
01248
01249 if ( yy_n_chars == 0 )
01250 {
01251 if ( number_to_move == YY_MORE_ADJ )
01252 {
01253 ret_val = EOB_ACT_END_OF_FILE;
01254 yyrestart( yyin );
01255 }
01256
01257 else
01258 {
01259 ret_val = EOB_ACT_LAST_MATCH;
01260 yy_current_buffer->yy_buffer_status =
01261 YY_BUFFER_EOF_PENDING;
01262 }
01263 }
01264
01265 else
01266 ret_val = EOB_ACT_CONTINUE_SCAN;
01267
01268 yy_n_chars += number_to_move;
01269 yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
01270 yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
01271
01272 yytext_ptr = &yy_current_buffer->yy_ch_buf[0];
01273
01274 return ret_val;
01275 }
01276
01277
01278
01279
01280 static yy_state_type yy_get_previous_state()
01281 {
01282 register yy_state_type yy_current_state;
01283 register char *yy_cp;
01284
01285 yy_current_state = yy_start;
01286
01287 for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
01288 {
01289 register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
01290 if ( yy_accept[yy_current_state] )
01291 {
01292 yy_last_accepting_state = yy_current_state;
01293 yy_last_accepting_cpos = yy_cp;
01294 }
01295 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
01296 {
01297 yy_current_state = (int) yy_def[yy_current_state];
01298 if ( yy_current_state >= 66 )
01299 yy_c = yy_meta[(unsigned int) yy_c];
01300 }
01301 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
01302 }
01303
01304 return yy_current_state;
01305 }
01306
01307
01308
01309
01310
01311
01312
01313
01314 #ifdef YY_USE_PROTOS
01315 static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state )
01316 #else
01317 static yy_state_type yy_try_NUL_trans( yy_current_state )
01318 yy_state_type yy_current_state;
01319 #endif
01320 {
01321 register int yy_is_jam;
01322 register char *yy_cp = yy_c_buf_p;
01323
01324 register YY_CHAR yy_c = 1;
01325 if ( yy_accept[yy_current_state] )
01326 {
01327 yy_last_accepting_state = yy_current_state;
01328 yy_last_accepting_cpos = yy_cp;
01329 }
01330 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
01331 {
01332 yy_current_state = (int) yy_def[yy_current_state];
01333 if ( yy_current_state >= 66 )
01334 yy_c = yy_meta[(unsigned int) yy_c];
01335 }
01336 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
01337 yy_is_jam = (yy_current_state == 65);
01338
01339 return yy_is_jam ? 0 : yy_current_state;
01340 }
01341
01342
01343 #ifndef YY_NO_UNPUT
01344 #ifdef YY_USE_PROTOS
01345 static void yyunput( int c, register char *yy_bp )
01346 #else
01347 static void yyunput( c, yy_bp )
01348 int c;
01349 register char *yy_bp;
01350 #endif
01351 {
01352 register char *yy_cp = yy_c_buf_p;
01353
01354
01355 *yy_cp = yy_hold_char;
01356
01357 if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
01358 {
01359
01360 register int number_to_move = yy_n_chars + 2;
01361 register char *dest = &yy_current_buffer->yy_ch_buf[
01362 yy_current_buffer->yy_buf_size + 2];
01363 register char *source =
01364 &yy_current_buffer->yy_ch_buf[number_to_move];
01365
01366 while ( source > yy_current_buffer->yy_ch_buf )
01367 *--dest = *--source;
01368
01369 yy_cp += (int) (dest - source);
01370 yy_bp += (int) (dest - source);
01371 yy_current_buffer->yy_n_chars =
01372 yy_n_chars = yy_current_buffer->yy_buf_size;
01373
01374 if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
01375 YY_FATAL_ERROR( "flex scanner push-back overflow" );
01376 }
01377
01378 *--yy_cp = (char) c;
01379
01380
01381 yytext_ptr = yy_bp;
01382 yy_hold_char = *yy_cp;
01383 yy_c_buf_p = yy_cp;
01384 }
01385 #endif
01386
01387
01388 #ifdef __cplusplus
01389 static int yyinput()
01390 #else
01391 static int input()
01392 #endif
01393 {
01394 int c;
01395
01396 *yy_c_buf_p = yy_hold_char;
01397
01398 if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
01399 {
01400
01401
01402
01403
01404 if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
01405
01406 *yy_c_buf_p = '\0';
01407
01408 else
01409 {
01410 int offset = yy_c_buf_p - yytext_ptr;
01411 ++yy_c_buf_p;
01412
01413 switch ( yy_get_next_buffer() )
01414 {
01415 case EOB_ACT_LAST_MATCH:
01416
01417
01418
01419
01420
01421
01422
01423
01424
01425
01426
01427 yyrestart( yyin );
01428
01429
01430
01431 case EOB_ACT_END_OF_FILE:
01432 {
01433 if ( yywrap() )
01434 return EOF;
01435
01436 if ( ! yy_did_buffer_switch_on_eof )
01437 YY_NEW_FILE;
01438 #ifdef __cplusplus
01439 return yyinput();
01440 #else
01441 return input();
01442 #endif
01443 }
01444
01445 case EOB_ACT_CONTINUE_SCAN:
01446 yy_c_buf_p = yytext_ptr + offset;
01447 break;
01448 }
01449 }
01450 }
01451
01452 c = *(unsigned char *) yy_c_buf_p;
01453 *yy_c_buf_p = '\0';
01454 yy_hold_char = *++yy_c_buf_p;
01455
01456
01457 return c;
01458 }
01459
01460
01461 #ifdef YY_USE_PROTOS
01462 void yyrestart( FILE *input_file )
01463 #else
01464 void yyrestart( input_file )
01465 FILE *input_file;
01466 #endif
01467 {
01468 if ( ! yy_current_buffer )
01469 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );
01470
01471 yy_init_buffer( yy_current_buffer, input_file );
01472 yy_load_buffer_state();
01473 }
01474
01475
01476 #ifdef YY_USE_PROTOS
01477 void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
01478 #else
01479 void yy_switch_to_buffer( new_buffer )
01480 YY_BUFFER_STATE new_buffer;
01481 #endif
01482 {
01483 if ( yy_current_buffer == new_buffer )
01484 return;
01485
01486 if ( yy_current_buffer )
01487 {
01488
01489 *yy_c_buf_p = yy_hold_char;
01490 yy_current_buffer->yy_buf_pos = yy_c_buf_p;
01491 yy_current_buffer->yy_n_chars = yy_n_chars;
01492 }
01493
01494 yy_current_buffer = new_buffer;
01495 yy_load_buffer_state();
01496
01497
01498
01499
01500
01501
01502 yy_did_buffer_switch_on_eof = 1;
01503 }
01504
01505
01506 #ifdef YY_USE_PROTOS
01507 void yy_load_buffer_state( void )
01508 #else
01509 void yy_load_buffer_state()
01510 #endif
01511 {
01512 yy_n_chars = yy_current_buffer->yy_n_chars;
01513 yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
01514 yyin = yy_current_buffer->yy_input_file;
01515 yy_hold_char = *yy_c_buf_p;
01516 }
01517
01518
01519 #ifdef YY_USE_PROTOS
01520 YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
01521 #else
01522 YY_BUFFER_STATE yy_create_buffer( file, size )
01523 FILE *file;
01524 int size;
01525 #endif
01526 {
01527 YY_BUFFER_STATE b;
01528
01529 b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
01530 if ( ! b )
01531 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
01532
01533 b->yy_buf_size = size;
01534
01535
01536
01537
01538 b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 );
01539 if ( ! b->yy_ch_buf )
01540 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
01541
01542 b->yy_is_our_buffer = 1;
01543
01544 yy_init_buffer( b, file );
01545
01546 return b;
01547 }
01548
01549
01550 #ifdef YY_USE_PROTOS
01551 void yy_delete_buffer( YY_BUFFER_STATE b )
01552 #else
01553 void yy_delete_buffer( b )
01554 YY_BUFFER_STATE b;
01555 #endif
01556 {
01557 if ( ! b )
01558 return;
01559
01560 if ( b == yy_current_buffer )
01561 yy_current_buffer = (YY_BUFFER_STATE) 0;
01562
01563 if ( b->yy_is_our_buffer )
01564 yy_flex_free( (void *) b->yy_ch_buf );
01565
01566 yy_flex_free( (void *) b );
01567 }
01568
01569
01570
01571 #ifdef YY_USE_PROTOS
01572 void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
01573 #else
01574 void yy_init_buffer( b, file )
01575 YY_BUFFER_STATE b;
01576 FILE *file;
01577 #endif
01578
01579
01580 {
01581 yy_flush_buffer( b );
01582
01583 b->yy_input_file = file;
01584 b->yy_fill_buffer = 1;
01585
01586 #if YY_ALWAYS_INTERACTIVE
01587 b->yy_is_interactive = 1;
01588 #else
01589 #if YY_NEVER_INTERACTIVE
01590 b->yy_is_interactive = 0;
01591 #else
01592 b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
01593 #endif
01594 #endif
01595 }
01596
01597
01598 #ifdef YY_USE_PROTOS
01599 void yy_flush_buffer( YY_BUFFER_STATE b )
01600 #else
01601 void yy_flush_buffer( b )
01602 YY_BUFFER_STATE b;
01603 #endif
01604
01605 {
01606 if ( ! b )
01607 return;
01608
01609 b->yy_n_chars = 0;
01610
01611
01612
01613
01614
01615 b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
01616 b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
01617
01618 b->yy_buf_pos = &b->yy_ch_buf[0];
01619
01620 b->yy_at_bol = 1;
01621 b->yy_buffer_status = YY_BUFFER_NEW;
01622
01623 if ( b == yy_current_buffer )
01624 yy_load_buffer_state();
01625 }
01626
01627
01628 #ifndef YY_NO_SCAN_BUFFER
01629 #ifdef YY_USE_PROTOS
01630 YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size )
01631 #else
01632 YY_BUFFER_STATE yy_scan_buffer( base, size )
01633 char *base;
01634 yy_size_t size;
01635 #endif
01636 {
01637 YY_BUFFER_STATE b;
01638
01639 if ( size < 2 ||
01640 base[size-2] != YY_END_OF_BUFFER_CHAR ||
01641 base[size-1] != YY_END_OF_BUFFER_CHAR )
01642
01643 return 0;
01644
01645 b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
01646 if ( ! b )
01647 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
01648
01649 b->yy_buf_size = size - 2;
01650 b->yy_buf_pos = b->yy_ch_buf = base;
01651 b->yy_is_our_buffer = 0;
01652 b->yy_input_file = 0;
01653 b->yy_n_chars = b->yy_buf_size;
01654 b->yy_is_interactive = 0;
01655 b->yy_at_bol = 1;
01656 b->yy_fill_buffer = 0;
01657 b->yy_buffer_status = YY_BUFFER_NEW;
01658
01659 yy_switch_to_buffer( b );
01660
01661 return b;
01662 }
01663 #endif
01664
01665
01666 #ifndef YY_NO_SCAN_STRING
01667 #ifdef YY_USE_PROTOS
01668 YY_BUFFER_STATE yy_scan_string( yyconst char *yy_str )
01669 #else
01670 YY_BUFFER_STATE yy_scan_string( yy_str )
01671 yyconst char *yy_str;
01672 #endif
01673 {
01674 int len;
01675 for ( len = 0; yy_str[len]; ++len )
01676 ;
01677
01678 return yy_scan_bytes( yy_str, len );
01679 }
01680 #endif
01681
01682
01683 #ifndef YY_NO_SCAN_BYTES
01684 #ifdef YY_USE_PROTOS
01685 YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len )
01686 #else
01687 YY_BUFFER_STATE yy_scan_bytes( bytes, len )
01688 yyconst char *bytes;
01689 int len;
01690 #endif
01691 {
01692 YY_BUFFER_STATE b;
01693 char *buf;
01694 yy_size_t n;
01695 int i;
01696
01697
01698 n = len + 2;
01699 buf = (char *) yy_flex_alloc( n );
01700 if ( ! buf )
01701 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
01702
01703 for ( i = 0; i < len; ++i )
01704 buf[i] = bytes[i];
01705
01706 buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR;
01707
01708 b = yy_scan_buffer( buf, n );
01709 if ( ! b )
01710 YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
01711
01712
01713
01714
01715 b->yy_is_our_buffer = 1;
01716
01717 return b;
01718 }
01719 #endif
01720
01721
01722 #ifndef YY_NO_PUSH_STATE
01723 #ifdef YY_USE_PROTOS
01724 static void yy_push_state( int new_state )
01725 #else
01726 static void yy_push_state( new_state )
01727 int new_state;
01728 #endif
01729 {
01730 if ( yy_start_stack_ptr >= yy_start_stack_depth )
01731 {
01732 yy_size_t new_size;
01733
01734 yy_start_stack_depth += YY_START_STACK_INCR;
01735 new_size = yy_start_stack_depth * sizeof( int );
01736
01737 if ( ! yy_start_stack )
01738 yy_start_stack = (int *) yy_flex_alloc( new_size );
01739
01740 else
01741 yy_start_stack = (int *) yy_flex_realloc(
01742 (void *) yy_start_stack, new_size );
01743
01744 if ( ! yy_start_stack )
01745 YY_FATAL_ERROR(
01746 "out of memory expanding start-condition stack" );
01747 }
01748
01749 yy_start_stack[yy_start_stack_ptr++] = YY_START;
01750
01751 BEGIN(new_state);
01752 }
01753 #endif
01754
01755
01756 #ifndef YY_NO_POP_STATE
01757 static void yy_pop_state()
01758 {
01759 if ( --yy_start_stack_ptr < 0 )
01760 YY_FATAL_ERROR( "start-condition stack underflow" );
01761
01762 BEGIN(yy_start_stack[yy_start_stack_ptr]);
01763 }
01764 #endif
01765
01766
01767 #ifndef YY_NO_TOP_STATE
01768 static int yy_top_state()
01769 {
01770 return yy_start_stack[yy_start_stack_ptr - 1];
01771 }
01772 #endif
01773
01774 #ifndef YY_EXIT_FAILURE
01775 #define YY_EXIT_FAILURE 2
01776 #endif
01777
01778 #ifdef YY_USE_PROTOS
01779 static void yy_fatal_error( yyconst char msg[] )
01780 #else
01781 static void yy_fatal_error( msg )
01782 char msg[];
01783 #endif
01784 {
01785 (void) fprintf( stderr, "%s\n", msg );
01786 exit( YY_EXIT_FAILURE );
01787 }
01788
01789
01790
01791
01792
01793 #undef yyless
01794 #define yyless(n) \
01795 do \
01796 { \
01797 \
01798 yytext[yyleng] = yy_hold_char; \
01799 yy_c_buf_p = yytext + n; \
01800 yy_hold_char = *yy_c_buf_p; \
01801 *yy_c_buf_p = '\0'; \
01802 yyleng = n; \
01803 } \
01804 while ( 0 )
01805
01806
01807
01808
01809 #ifndef yytext_ptr
01810 #ifdef YY_USE_PROTOS
01811 static void yy_flex_strncpy( char *s1, yyconst char *s2, int n )
01812 #else
01813 static void yy_flex_strncpy( s1, s2, n )
01814 char *s1;
01815 yyconst char *s2;
01816 int n;
01817 #endif
01818 {
01819 register int i;
01820 for ( i = 0; i < n; ++i )
01821 s1[i] = s2[i];
01822 }
01823 #endif
01824
01825 #ifdef YY_NEED_STRLEN
01826 #ifdef YY_USE_PROTOS
01827 static int yy_flex_strlen( yyconst char *s )
01828 #else
01829 static int yy_flex_strlen( s )
01830 yyconst char *s;
01831 #endif
01832 {
01833 register int n;
01834 for ( n = 0; s[n]; ++n )
01835 ;
01836
01837 return n;
01838 }
01839 #endif
01840
01841
01842 #ifdef YY_USE_PROTOS
01843 static void *yy_flex_alloc( yy_size_t size )
01844 #else
01845 static void *yy_flex_alloc( size )
01846 yy_size_t size;
01847 #endif
01848 {
01849 return (void *) malloc( size );
01850 }
01851
01852 #ifdef YY_USE_PROTOS
01853 static void *yy_flex_realloc( void *ptr, yy_size_t size )
01854 #else
01855 static void *yy_flex_realloc( ptr, size )
01856 void *ptr;
01857 yy_size_t size;
01858 #endif
01859 {
01860
01861
01862
01863
01864
01865
01866
01867 return (void *) realloc( (char *) ptr, size );
01868 }
01869
01870 #ifdef YY_USE_PROTOS
01871 static void yy_flex_free( void *ptr )
01872 #else
01873 static void yy_flex_free( ptr )
01874 void *ptr;
01875 #endif
01876 {
01877 free( ptr );
01878 }
01879
01880 #if YY_MAIN
01881 int main()
01882 {
01883 yylex();
01884 return 0;
01885 }
01886 #endif
01887 #line 226 "lex.l"
01888