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 typedef unsigned char YY_CHAR;
00265 FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
00266 typedef int yy_state_type;
00267 extern char yytext[];
00268
00269
00270 static yy_state_type yy_get_previous_state YY_PROTO(( void ));
00271 static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
00272 static int yy_get_next_buffer YY_PROTO(( void ));
00273 static void yy_fatal_error YY_PROTO(( yyconst char msg[] ));
00274
00275
00276
00277
00278 #define YY_DO_BEFORE_ACTION \
00279 yytext_ptr = yy_bp; \
00280 yyleng = (int) (yy_cp - yy_bp); \
00281 yy_hold_char = *yy_cp; \
00282 *yy_cp = '\0'; \
00283 if ( yyleng >= YYLMAX ) \
00284 YY_FATAL_ERROR( "token too large, exceeds YYLMAX" ); \
00285 yy_flex_strncpy( yytext, yytext_ptr, yyleng + 1 ); \
00286 yy_c_buf_p = yy_cp;
00287
00288 #define YY_NUM_RULES 17
00289 #define YY_END_OF_BUFFER 18
00290 static yyconst short int yy_accept[64] =
00291 { 0,
00292 0, 0, 18, 16, 11, 11, 16, 16, 12, 16,
00293 9, 16, 16, 5, 16, 6, 1, 1, 1, 10,
00294 5, 5, 11, 1, 0, 4, 12, 0, 3, 0,
00295 6, 14, 5, 5, 0, 13, 7, 6, 8, 8,
00296 5, 0, 2, 7, 0, 14, 5, 0, 0, 0,
00297 13, 7, 0, 7, 7, 5, 0, 0, 15, 0,
00298 0, 15, 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, 6, 7, 7, 7, 8, 7,
00307 7, 9, 10, 7, 11, 12, 13, 14, 14, 14,
00308 14, 14, 14, 14, 14, 14, 14, 7, 7, 15,
00309 16, 17, 18, 7, 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 7, 7, 7, 7, 21, 7, 19, 19, 19, 19,
00313
00314 20, 19, 21, 21, 21, 21, 21, 21, 21, 21,
00315 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
00316 21, 21, 7, 7, 7, 7, 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[22] =
00334 { 0,
00335 1, 2, 3, 2, 2, 2, 2, 2, 2, 2,
00336 2, 4, 2, 4, 2, 2, 2, 2, 4, 4,
00337 4
00338 } ;
00339
00340 static yyconst short int yy_base[73] =
00341 { 0,
00342 0, 0, 129, 130, 20, 22, 112, 122, 0, 118,
00343 130, 14, 18, 111, 18, 21, 20, 130, 103, 130,
00344 22, 0, 36, 130, 106, 130, 0, 96, 42, 86,
00345 34, 0, 0, 33, 42, 0, 38, 0, 42, 53,
00346 45, 57, 130, 51, 64, 0, 66, 86, 70, 72,
00347 0, 68, 80, 70, 72, 56, 78, 83, 130, 84,
00348 56, 55, 130, 97, 101, 104, 45, 38, 108, 112,
00349 116, 120
00350 } ;
00351
00352 static yyconst short int yy_def[73] =
00353 { 0,
00354 63, 1, 63, 63, 63, 63, 63, 64, 65, 66,
00355 63, 63, 63, 67, 63, 63, 63, 63, 63, 63,
00356 68, 67, 63, 63, 64, 63, 65, 66, 63, 63,
00357 63, 69, 67, 67, 70, 71, 63, 16, 63, 63,
00358 68, 63, 63, 63, 63, 69, 67, 70, 72, 70,
00359 71, 63, 63, 63, 63, 67, 70, 70, 63, 70,
00360 63, 63, 0, 63, 63, 63, 63, 63, 63, 63,
00361 63, 63
00362 } ;
00363
00364 static yyconst short int yy_nxt[152] =
00365 { 0,
00366 4, 5, 6, 7, 8, 9, 4, 10, 11, 12,
00367 13, 14, 15, 16, 17, 18, 19, 20, 21, 21,
00368 22, 23, 23, 23, 23, 30, 35, 31, 32, 30,
00369 36, 31, 37, 33, 38, 24, 24, 23, 23, 39,
00370 40, 41, 33, 42, 43, 37, 34, 31, 33, 28,
00371 49, 52, 47, 45, 50, 39, 33, 45, 42, 43,
00372 39, 39, 53, 53, 44, 33, 54, 57, 57, 56,
00373 45, 39, 39, 53, 53, 53, 53, 55, 58, 56,
00374 49, 52, 59, 54, 60, 55, 49, 45, 39, 39,
00375 61, 49, 49, 55, 49, 62, 60, 25, 25, 44,
00376
00377 25, 27, 27, 29, 27, 28, 28, 28, 46, 46,
00378 26, 46, 48, 48, 48, 48, 51, 51, 24, 51,
00379 57, 57, 57, 57, 34, 29, 26, 24, 63, 3,
00380 63, 63, 63, 63, 63, 63, 63, 63, 63, 63,
00381 63, 63, 63, 63, 63, 63, 63, 63, 63, 63,
00382 63
00383 } ;
00384
00385 static yyconst short int yy_chk[152] =
00386 { 0,
00387 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00388 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
00389 1, 5, 5, 6, 6, 12, 15, 12, 13, 13,
00390 15, 13, 16, 21, 16, 17, 17, 23, 23, 16,
00391 16, 68, 21, 29, 29, 31, 34, 31, 67, 29,
00392 35, 37, 34, 31, 35, 39, 41, 37, 42, 42,
00393 39, 39, 40, 40, 44, 41, 40, 62, 61, 56,
00394 44, 40, 40, 45, 45, 47, 47, 45, 49, 47,
00395 50, 52, 49, 54, 50, 55, 57, 52, 54, 54,
00396 57, 58, 60, 53, 48, 58, 60, 64, 64, 30,
00397
00398 64, 65, 65, 28, 65, 66, 66, 66, 69, 69,
00399 25, 69, 70, 70, 70, 70, 71, 71, 19, 71,
00400 72, 72, 72, 72, 14, 10, 8, 7, 3, 63,
00401 63, 63, 63, 63, 63, 63, 63, 63, 63, 63,
00402 63, 63, 63, 63, 63, 63, 63, 63, 63, 63,
00403 63
00404 } ;
00405
00406 static yy_state_type yy_last_accepting_state;
00407 static char *yy_last_accepting_cpos;
00408
00409
00410
00411
00412 #define REJECT reject_used_but_not_detected
00413 #define yymore() yymore_used_but_not_detected
00414 #define YY_MORE_ADJ 0
00415 #define YY_RESTORE_YY_MORE_OFFSET
00416 #ifndef YYLMAX
00417 #define YYLMAX 8192
00418 #endif
00419
00420 char yytext[YYLMAX];
00421 char *yytext_ptr;
00422 #line 1 "dmllex.lxx"
00423 #define INITIAL 0
00424
00425
00426
00427
00428
00429
00430
00431
00432
00433
00434
00435
00436
00437
00438
00439 #line 18 "dmllex.lxx"
00440 #include "dmlyacc.h"
00441 #include <stdlib.h>
00442 #include <string.h>
00443
00444 int echo_on=0;
00445 int lexEof=0;
00446 extern char *lexInput;
00447
00448 #undef ECHO
00449 #define ECHO { if(echo_on) printf("%s",yytext); }
00450
00451
00452
00453 #line 454 "dmllex.cxx"
00454
00455
00456
00457
00458
00459 #ifndef YY_SKIP_YYWRAP
00460 #ifdef __cplusplus
00461 extern "C" int yywrap YY_PROTO(( void ));
00462 #else
00463 extern int yywrap YY_PROTO(( void ));
00464 #endif
00465 #endif
00466
00467 #ifndef YY_NO_UNPUT
00468 static void yyunput YY_PROTO(( int c, char *buf_ptr ));
00469 #endif
00470
00471 #ifndef yytext_ptr
00472 static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));
00473 #endif
00474
00475 #ifdef YY_NEED_STRLEN
00476 static int yy_flex_strlen YY_PROTO(( yyconst char * ));
00477 #endif
00478
00479 #ifndef YY_NO_INPUT
00480 #ifdef __cplusplus
00481 static int yyinput YY_PROTO(( void ));
00482 #else
00483 static int input YY_PROTO(( void ));
00484 #endif
00485 #endif
00486
00487 #if YY_STACK_USED
00488 static int yy_start_stack_ptr = 0;
00489 static int yy_start_stack_depth = 0;
00490 static int *yy_start_stack = 0;
00491 #ifndef YY_NO_PUSH_STATE
00492 static void yy_push_state YY_PROTO(( int new_state ));
00493 #endif
00494 #ifndef YY_NO_POP_STATE
00495 static void yy_pop_state YY_PROTO(( void ));
00496 #endif
00497 #ifndef YY_NO_TOP_STATE
00498 static int yy_top_state YY_PROTO(( void ));
00499 #endif
00500
00501 #else
00502 #define YY_NO_PUSH_STATE 1
00503 #define YY_NO_POP_STATE 1
00504 #define YY_NO_TOP_STATE 1
00505 #endif
00506
00507 #ifdef YY_MALLOC_DECL
00508 YY_MALLOC_DECL
00509 #else
00510 #if __STDC__
00511 #ifndef __cplusplus
00512 #include <stdlib.h>
00513 #endif
00514 #else
00515
00516
00517
00518
00519 #endif
00520 #endif
00521
00522
00523 #ifndef YY_READ_BUF_SIZE
00524 #define YY_READ_BUF_SIZE 8192
00525 #endif
00526
00527
00528
00529 #ifndef ECHO
00530
00531
00532
00533 #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
00534 #endif
00535
00536
00537
00538
00539 #ifndef YY_INPUT
00540 #define YY_INPUT(buf,result,max_size) \
00541 if ( yy_current_buffer->yy_is_interactive ) \
00542 { \
00543 int c = '*', n; \
00544 for ( n = 0; n < max_size && \
00545 (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
00546 buf[n] = (char) c; \
00547 if ( c == '\n' ) \
00548 buf[n++] = (char) c; \
00549 if ( c == EOF && ferror( yyin ) ) \
00550 YY_FATAL_ERROR( "input in flex scanner failed" ); \
00551 result = n; \
00552 } \
00553 else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
00554 && ferror( yyin ) ) \
00555 YY_FATAL_ERROR( "input in flex scanner failed" );
00556 #endif
00557
00558
00559
00560
00561
00562 #ifndef yyterminate
00563 #define yyterminate() return YY_NULL
00564 #endif
00565
00566
00567 #ifndef YY_START_STACK_INCR
00568 #define YY_START_STACK_INCR 25
00569 #endif
00570
00571
00572 #ifndef YY_FATAL_ERROR
00573 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
00574 #endif
00575
00576
00577
00578
00579 #ifndef YY_DECL
00580 #define YY_DECL int yylex YY_PROTO(( void ))
00581 #endif
00582
00583
00584
00585
00586 #ifndef YY_USER_ACTION
00587 #define YY_USER_ACTION
00588 #endif
00589
00590
00591 #ifndef YY_BREAK
00592 #define YY_BREAK break;
00593 #endif
00594
00595 #define YY_RULE_SETUP \
00596 YY_USER_ACTION
00597
00598 YY_DECL
00599 {
00600 register yy_state_type yy_current_state;
00601 register char *yy_cp = NULL, *yy_bp = NULL;
00602 register int yy_act;
00603
00604 #line 48 "dmllex.lxx"
00605
00606 #line 607 "dmllex.cxx"
00607
00608 if ( yy_init )
00609 {
00610 yy_init = 0;
00611
00612 #ifdef YY_USER_INIT
00613 YY_USER_INIT;
00614 #endif
00615
00616 if ( ! yy_start )
00617 yy_start = 1;
00618
00619 if ( ! yyin )
00620 yyin = stdin;
00621
00622 if ( ! yyout )
00623 yyout = stdout;
00624
00625 if ( ! yy_current_buffer )
00626 yy_current_buffer =
00627 yy_create_buffer( yyin, YY_BUF_SIZE );
00628
00629 yy_load_buffer_state();
00630 }
00631
00632 while ( 1 )
00633 {
00634 yy_cp = yy_c_buf_p;
00635
00636
00637 *yy_cp = yy_hold_char;
00638
00639
00640
00641
00642 yy_bp = yy_cp;
00643
00644 yy_current_state = yy_start;
00645 yy_match:
00646 do
00647 {
00648 register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
00649 if ( yy_accept[yy_current_state] )
00650 {
00651 yy_last_accepting_state = yy_current_state;
00652 yy_last_accepting_cpos = yy_cp;
00653 }
00654 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
00655 {
00656 yy_current_state = (int) yy_def[yy_current_state];
00657 if ( yy_current_state >= 64 )
00658 yy_c = yy_meta[(unsigned int) yy_c];
00659 }
00660 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
00661 ++yy_cp;
00662 }
00663 while ( yy_base[yy_current_state] != 130 );
00664
00665 yy_find_action:
00666 yy_act = yy_accept[yy_current_state];
00667 if ( yy_act == 0 )
00668 {
00669 yy_cp = yy_last_accepting_cpos;
00670 yy_current_state = yy_last_accepting_state;
00671 yy_act = yy_accept[yy_current_state];
00672 }
00673
00674 YY_DO_BEFORE_ACTION;
00675
00676
00677 do_action:
00678
00679
00680 switch ( yy_act )
00681 {
00682 case 0:
00683
00684 *yy_cp = yy_hold_char;
00685 yy_cp = yy_last_accepting_cpos;
00686 yy_current_state = yy_last_accepting_state;
00687 goto yy_find_action;
00688
00689 case 1:
00690 YY_RULE_SETUP
00691 #line 49 "dmllex.lxx"
00692 {
00693 yylval.stringval = strdup((const char*)yytext);
00694 return(OPERATOR);
00695 }
00696 YY_BREAK
00697 case 2:
00698 *yy_cp = yy_hold_char;
00699 yy_c_buf_p = yy_cp -= 1;
00700 YY_DO_BEFORE_ACTION;
00701 YY_RULE_SETUP
00702 #line 54 "dmllex.lxx"
00703 {
00704 int len; ECHO;
00705 if(*yytext != '\'')
00706 printf("ERROR: wanted a string, got: %s\n",yytext);
00707 len = yyleng - 1;
00708 while (yytext[len] == ' ' || yytext[len] == '\t')
00709 {
00710 yytext[len] = '\0';
00711 len--;
00712 }
00713 yylval.stringval = strdup((const char*)yytext + 1);
00714
00715 return (STRING);
00716 }
00717 YY_BREAK
00718 case 3:
00719 YY_RULE_SETUP
00720 #line 69 "dmllex.lxx"
00721 { ECHO;
00722 if(*yytext != '\'')
00723 printf("ERROR: wanted a string, got: %s\n",yytext);
00724 yytext[yyleng-1]='\0';
00725 yylval.stringval = strdup((const char*)yytext + 1);
00726
00727 return (STRING);
00728 }
00729 YY_BREAK
00730 case 4:
00731 YY_RULE_SETUP
00732 #line 78 "dmllex.lxx"
00733 { ECHO;
00734 yytext[yyleng-1] = '\0';
00735 yytext[0]=' ';
00736 yylval.stringval = strdup((const char*)yytext + 1);
00737 return (STRING);
00738 }
00739 YY_BREAK
00740 case 5:
00741 YY_RULE_SETUP
00742 #line 85 "dmllex.lxx"
00743 {
00744 int token;
00745 char *fieldname;
00746 token = FIELD;
00747 ECHO;
00748
00749 if(strcasecmp(yytext,"SELECT") == 0) token = SELECT;
00750 if(strcasecmp(yytext,"FROM") == 0) token = FROM;
00751 if(strcasecmp(yytext,"WHERE") == 0) token = WHERE;
00752 if(strcasecmp(yytext,"BETWEEN") == 0) token = BETWEEN;
00753 if(strcasecmp(yytext,"IN") == 0) token = IN;
00754 if(strcasecmp(yytext,"AND") == 0) token = AND;
00755 if(strcasecmp(yytext,"OR") == 0) token = OR;
00756 if(strcasecmp(yytext,"NOT") == 0) token = NOT;
00757 if(strcasecmp(yytext,"INSERT") == 0) token = INSERT;
00758 if(strcasecmp(yytext,"INTO") == 0) token = INTO;
00759 if(strcasecmp(yytext,"VALUES") == 0) token = VALUES;
00760 if(strcasecmp(yytext,"DELETE") == 0) token = DELETE;
00761 if(strcasecmp(yytext,"UPDATE") == 0) token = UPDATE;
00762 if(strcasecmp(yytext,"SET") == 0) token = SET;
00763 if(strcasecmp(yytext,"NULL") == 0) token = NULL_VALUE;
00764 if(strcasecmp(yytext,"UNIQUE") == 0) token = UNIQUE;
00765 if(strcasecmp(yytext,"CREATE") == 0) token = CREATE;
00766 if(strcasecmp(yytext,"DROP") == 0) token = DROP;
00767 if(strcasecmp(yytext,"TABLE") == 0) token = TABLE;
00768 if(strcasecmp(yytext,"PRIMARY") == 0) token = PRIMARY;
00769 if(strcasecmp(yytext,"INDEX") == 0) token = INDEX;
00770 if(strcasecmp(yytext,"ON") == 0) token = ON;
00771 if(strcasecmp(yytext,"HASH") == 0) token = HASH;
00772 if(strcasecmp(yytext,"TREE") == 0) token = TREE;
00773 if(strcasecmp(yytext,"UNIQUE") == 0) token = UNIQUE;
00774
00775 if(strcasecmp(yytext,"KEY") == 0) token = KEY;
00776 if(strcasecmp(yytext,"DEFAULT") == 0) token = DEFAULT;
00777 if(strcasecmp(yytext,"INT") ==0) token = INT_TYPE;
00778 if(strcasecmp(yytext,"INTEGER") ==0) token = INT_TYPE;
00779 if(strcasecmp(yytext,"LONG") ==0) token = LONG_TYPE;
00780 if(strcasecmp(yytext,"DOUBLE") ==0) token = DOUBLE_TYPE;
00781 if(strcasecmp(yytext,"SHORT") ==0) token = SHORT_TYPE;
00782 if(strcasecmp(yytext,"SMALLINT") ==0) token = SHORT_TYPE;
00783 if(strcasecmp(yytext,"DATE") ==0) token = DATE_TYPE;
00784 if(strcasecmp(yytext,"TIME") ==0) token = TIME_TYPE;
00785 if(strcasecmp(yytext,"TIMESTAMP") ==0) token = TIMESTAMP_TYPE;
00786 if(strcasecmp(yytext,"CHAR") ==0) token = CHAR_TYPE;
00787 if(strcasecmp(yytext,"BIGINT") ==0) token = BIGINT_TYPE;
00788 if(strcasecmp(yytext,"TINYINT") ==0) token = TINYINT_TYPE;
00789 if(strcasecmp(yytext,"FLOAT") ==0) token = FLOAT_TYPE;
00790
00791 if( token == FIELD )
00792 yylval.stringval = strdup((const char*)yytext);
00793 else
00794 yylval.stringval = 0;
00795
00796 return(token);
00797 }
00798 YY_BREAK
00799 case 6:
00800 YY_RULE_SETUP
00801 #line 141 "dmllex.lxx"
00802 { ECHO;
00803 yylval.stringval = strdup((const char*)yytext);
00804 return (NUMBER_STRING);
00805 }
00806 YY_BREAK
00807 case 7:
00808 YY_RULE_SETUP
00809 #line 146 "dmllex.lxx"
00810 { ECHO;
00811 yylval.stringval = strdup((const char*)yytext);
00812 return (DOUBLE);
00813 }
00814 YY_BREAK
00815 case 8:
00816 YY_RULE_SETUP
00817 #line 151 "dmllex.lxx"
00818 { ECHO;
00819 yylval.stringval = strdup((const char*)yytext);
00820 return (BINARY_STRING);
00821 }
00822 YY_BREAK
00823 case 9:
00824 YY_RULE_SETUP
00825 #line 155 "dmllex.lxx"
00826 {
00827 yylval.stringval = strdup((const char*)yytext);
00828 return(STAR);
00829 }
00830 YY_BREAK
00831 case 10:
00832 YY_RULE_SETUP
00833 #line 159 "dmllex.lxx"
00834 {
00835 yylval.stringval = strdup((const char*)yytext);
00836 return(PARAMETER);
00837 }
00838 YY_BREAK
00839 case 11:
00840 YY_RULE_SETUP
00841 #line 163 "dmllex.lxx"
00842 { ECHO; }
00843 YY_BREAK
00844 case 12:
00845 YY_RULE_SETUP
00846 #line 164 "dmllex.lxx"
00847 { ECHO; }
00848 YY_BREAK
00849 case 13:
00850 YY_RULE_SETUP
00851 #line 165 "dmllex.lxx"
00852 { ECHO; }
00853 YY_BREAK
00854 case 14:
00855 YY_RULE_SETUP
00856 #line 166 "dmllex.lxx"
00857 { ECHO; }
00858 YY_BREAK
00859
00860
00861
00862 case 15:
00863 YY_RULE_SETUP
00864 #line 171 "dmllex.lxx"
00865 { ECHO; }
00866 YY_BREAK
00867 case 16:
00868 YY_RULE_SETUP
00869 #line 173 "dmllex.lxx"
00870 { ECHO; return yytext[0]; }
00871 YY_BREAK
00872 case 17:
00873 YY_RULE_SETUP
00874 #line 176 "dmllex.lxx"
00875 ECHO;
00876 YY_BREAK
00877 #line 878 "dmllex.cxx"
00878 case YY_STATE_EOF(INITIAL):
00879 yyterminate();
00880
00881 case YY_END_OF_BUFFER:
00882 {
00883
00884 int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1;
00885
00886
00887 *yy_cp = yy_hold_char;
00888 YY_RESTORE_YY_MORE_OFFSET
00889
00890 if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW )
00891 {
00892
00893
00894
00895
00896
00897
00898
00899
00900
00901 yy_n_chars = yy_current_buffer->yy_n_chars;
00902 yy_current_buffer->yy_input_file = yyin;
00903 yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL;
00904 }
00905
00906
00907
00908
00909
00910
00911
00912
00913 if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
00914 {
00915 yy_state_type yy_next_state;
00916
00917 yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text;
00918
00919 yy_current_state = yy_get_previous_state();
00920
00921
00922
00923
00924
00925
00926
00927
00928
00929
00930 yy_next_state = yy_try_NUL_trans( yy_current_state );
00931
00932 yy_bp = yytext_ptr + YY_MORE_ADJ;
00933
00934 if ( yy_next_state )
00935 {
00936
00937 yy_cp = ++yy_c_buf_p;
00938 yy_current_state = yy_next_state;
00939 goto yy_match;
00940 }
00941
00942 else
00943 {
00944 yy_cp = yy_c_buf_p;
00945 goto yy_find_action;
00946 }
00947 }
00948
00949 else switch ( yy_get_next_buffer() )
00950 {
00951 case EOB_ACT_END_OF_FILE:
00952 {
00953 yy_did_buffer_switch_on_eof = 0;
00954
00955 if ( yywrap() )
00956 {
00957
00958
00959
00960
00961
00962
00963
00964
00965
00966 yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
00967
00968 yy_act = YY_STATE_EOF(YY_START);
00969 goto do_action;
00970 }
00971
00972 else
00973 {
00974 if ( ! yy_did_buffer_switch_on_eof )
00975 YY_NEW_FILE;
00976 }
00977 break;
00978 }
00979
00980 case EOB_ACT_CONTINUE_SCAN:
00981 yy_c_buf_p =
00982 yytext_ptr + yy_amount_of_matched_text;
00983
00984 yy_current_state = yy_get_previous_state();
00985
00986 yy_cp = yy_c_buf_p;
00987 yy_bp = yytext_ptr + YY_MORE_ADJ;
00988 goto yy_match;
00989
00990 case EOB_ACT_LAST_MATCH:
00991 yy_c_buf_p =
00992 &yy_current_buffer->yy_ch_buf[yy_n_chars];
00993
00994 yy_current_state = yy_get_previous_state();
00995
00996 yy_cp = yy_c_buf_p;
00997 yy_bp = yytext_ptr + YY_MORE_ADJ;
00998 goto yy_find_action;
00999 }
01000 break;
01001 }
01002
01003 default:
01004 YY_FATAL_ERROR(
01005 "fatal flex scanner internal error--no action found" );
01006 }
01007 }
01008 }
01009
01010
01011
01012
01013
01014
01015
01016
01017
01018
01019 static int yy_get_next_buffer()
01020 {
01021 register char *dest = yy_current_buffer->yy_ch_buf;
01022 register char *source = yytext_ptr;
01023 register int number_to_move, i;
01024 int ret_val;
01025
01026 if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
01027 YY_FATAL_ERROR(
01028 "fatal flex scanner internal error--end of buffer missed" );
01029
01030 if ( yy_current_buffer->yy_fill_buffer == 0 )
01031 {
01032 if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 )
01033 {
01034
01035
01036
01037 return EOB_ACT_END_OF_FILE;
01038 }
01039
01040 else
01041 {
01042
01043
01044
01045 return EOB_ACT_LAST_MATCH;
01046 }
01047 }
01048
01049
01050
01051
01052 number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1;
01053
01054 for ( i = 0; i < number_to_move; ++i )
01055 *(dest++) = *(source++);
01056
01057 if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING )
01058
01059
01060
01061 yy_current_buffer->yy_n_chars = yy_n_chars = 0;
01062
01063 else
01064 {
01065 int num_to_read =
01066 yy_current_buffer->yy_buf_size - number_to_move - 1;
01067
01068 while ( num_to_read <= 0 )
01069 {
01070 #ifdef YY_USES_REJECT
01071 YY_FATAL_ERROR(
01072 "input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
01073 #else
01074
01075
01076 YY_BUFFER_STATE b = yy_current_buffer;
01077
01078 int yy_c_buf_p_offset =
01079 (int) (yy_c_buf_p - b->yy_ch_buf);
01080
01081 if ( b->yy_is_our_buffer )
01082 {
01083 int new_size = b->yy_buf_size * 2;
01084
01085 if ( new_size <= 0 )
01086 b->yy_buf_size += b->yy_buf_size / 8;
01087 else
01088 b->yy_buf_size *= 2;
01089
01090 b->yy_ch_buf = (char *)
01091
01092 yy_flex_realloc( (void *) b->yy_ch_buf,
01093 b->yy_buf_size + 2 );
01094 }
01095 else
01096
01097 b->yy_ch_buf = 0;
01098
01099 if ( ! b->yy_ch_buf )
01100 YY_FATAL_ERROR(
01101 "fatal error - scanner input buffer overflow" );
01102
01103 yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
01104
01105 num_to_read = yy_current_buffer->yy_buf_size -
01106 number_to_move - 1;
01107 #endif
01108 }
01109
01110 if ( num_to_read > YY_READ_BUF_SIZE )
01111 num_to_read = YY_READ_BUF_SIZE;
01112
01113
01114 YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
01115 yy_n_chars, num_to_read );
01116
01117 yy_current_buffer->yy_n_chars = yy_n_chars;
01118 }
01119
01120 if ( yy_n_chars == 0 )
01121 {
01122 if ( number_to_move == YY_MORE_ADJ )
01123 {
01124 ret_val = EOB_ACT_END_OF_FILE;
01125 yyrestart( yyin );
01126 }
01127
01128 else
01129 {
01130 ret_val = EOB_ACT_LAST_MATCH;
01131 yy_current_buffer->yy_buffer_status =
01132 YY_BUFFER_EOF_PENDING;
01133 }
01134 }
01135
01136 else
01137 ret_val = EOB_ACT_CONTINUE_SCAN;
01138
01139 yy_n_chars += number_to_move;
01140 yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
01141 yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
01142
01143 yytext_ptr = &yy_current_buffer->yy_ch_buf[0];
01144
01145 return ret_val;
01146 }
01147
01148
01149
01150
01151 static yy_state_type yy_get_previous_state()
01152 {
01153 register yy_state_type yy_current_state;
01154 register char *yy_cp;
01155
01156 yy_current_state = yy_start;
01157
01158 for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
01159 {
01160 register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
01161 if ( yy_accept[yy_current_state] )
01162 {
01163 yy_last_accepting_state = yy_current_state;
01164 yy_last_accepting_cpos = yy_cp;
01165 }
01166 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
01167 {
01168 yy_current_state = (int) yy_def[yy_current_state];
01169 if ( yy_current_state >= 64 )
01170 yy_c = yy_meta[(unsigned int) yy_c];
01171 }
01172 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
01173 }
01174
01175 return yy_current_state;
01176 }
01177
01178
01179
01180
01181
01182
01183
01184
01185 #ifdef YY_USE_PROTOS
01186 static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state )
01187 #else
01188 static yy_state_type yy_try_NUL_trans( yy_current_state )
01189 yy_state_type yy_current_state;
01190 #endif
01191 {
01192 register int yy_is_jam;
01193 register char *yy_cp = yy_c_buf_p;
01194
01195 register YY_CHAR yy_c = 1;
01196 if ( yy_accept[yy_current_state] )
01197 {
01198 yy_last_accepting_state = yy_current_state;
01199 yy_last_accepting_cpos = yy_cp;
01200 }
01201 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
01202 {
01203 yy_current_state = (int) yy_def[yy_current_state];
01204 if ( yy_current_state >= 64 )
01205 yy_c = yy_meta[(unsigned int) yy_c];
01206 }
01207 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
01208 yy_is_jam = (yy_current_state == 63);
01209
01210 return yy_is_jam ? 0 : yy_current_state;
01211 }
01212
01213
01214 #ifndef YY_NO_UNPUT
01215 #ifdef YY_USE_PROTOS
01216 static void yyunput( int c, register char *yy_bp )
01217 #else
01218 static void yyunput( c, yy_bp )
01219 int c;
01220 register char *yy_bp;
01221 #endif
01222 {
01223 register char *yy_cp = yy_c_buf_p;
01224
01225
01226 *yy_cp = yy_hold_char;
01227
01228 if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
01229 {
01230
01231 register int number_to_move = yy_n_chars + 2;
01232 register char *dest = &yy_current_buffer->yy_ch_buf[
01233 yy_current_buffer->yy_buf_size + 2];
01234 register char *source =
01235 &yy_current_buffer->yy_ch_buf[number_to_move];
01236
01237 while ( source > yy_current_buffer->yy_ch_buf )
01238 *--dest = *--source;
01239
01240 yy_cp += (int) (dest - source);
01241 yy_bp += (int) (dest - source);
01242 yy_current_buffer->yy_n_chars =
01243 yy_n_chars = yy_current_buffer->yy_buf_size;
01244
01245 if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
01246 YY_FATAL_ERROR( "flex scanner push-back overflow" );
01247 }
01248
01249 *--yy_cp = (char) c;
01250
01251
01252 yytext_ptr = yy_bp;
01253 yy_hold_char = *yy_cp;
01254 yy_c_buf_p = yy_cp;
01255 }
01256 #endif
01257
01258
01259 #ifndef YY_NO_INPUT
01260 #ifdef __cplusplus
01261 static int yyinput()
01262 #else
01263 static int input()
01264 #endif
01265 {
01266 int c;
01267
01268 *yy_c_buf_p = yy_hold_char;
01269
01270 if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
01271 {
01272
01273
01274
01275
01276 if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
01277
01278 *yy_c_buf_p = '\0';
01279
01280 else
01281 {
01282 int offset = yy_c_buf_p - yytext_ptr;
01283 ++yy_c_buf_p;
01284
01285 switch ( yy_get_next_buffer() )
01286 {
01287 case EOB_ACT_LAST_MATCH:
01288
01289
01290
01291
01292
01293
01294
01295
01296
01297
01298
01299 yyrestart( yyin );
01300
01301
01302
01303 case EOB_ACT_END_OF_FILE:
01304 {
01305 if ( yywrap() )
01306 return EOF;
01307
01308 if ( ! yy_did_buffer_switch_on_eof )
01309 YY_NEW_FILE;
01310 #ifdef __cplusplus
01311 return yyinput();
01312 #else
01313 return input();
01314 #endif
01315 }
01316
01317 case EOB_ACT_CONTINUE_SCAN:
01318 yy_c_buf_p = yytext_ptr + offset;
01319 break;
01320 }
01321 }
01322 }
01323
01324 c = *(unsigned char *) yy_c_buf_p;
01325 *yy_c_buf_p = '\0';
01326 yy_hold_char = *++yy_c_buf_p;
01327
01328
01329 return c;
01330 }
01331 #endif
01332
01333 #ifdef YY_USE_PROTOS
01334 void yyrestart( FILE *input_file )
01335 #else
01336 void yyrestart( input_file )
01337 FILE *input_file;
01338 #endif
01339 {
01340 if ( ! yy_current_buffer )
01341 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );
01342
01343 yy_init_buffer( yy_current_buffer, input_file );
01344 yy_load_buffer_state();
01345 }
01346
01347
01348 #ifdef YY_USE_PROTOS
01349 void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
01350 #else
01351 void yy_switch_to_buffer( new_buffer )
01352 YY_BUFFER_STATE new_buffer;
01353 #endif
01354 {
01355 if ( yy_current_buffer == new_buffer )
01356 return;
01357
01358 if ( yy_current_buffer )
01359 {
01360
01361 *yy_c_buf_p = yy_hold_char;
01362 yy_current_buffer->yy_buf_pos = yy_c_buf_p;
01363 yy_current_buffer->yy_n_chars = yy_n_chars;
01364 }
01365
01366 yy_current_buffer = new_buffer;
01367 yy_load_buffer_state();
01368
01369
01370
01371
01372
01373
01374 yy_did_buffer_switch_on_eof = 1;
01375 }
01376
01377
01378 #ifdef YY_USE_PROTOS
01379 void yy_load_buffer_state( void )
01380 #else
01381 void yy_load_buffer_state()
01382 #endif
01383 {
01384 yy_n_chars = yy_current_buffer->yy_n_chars;
01385 yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
01386 yyin = yy_current_buffer->yy_input_file;
01387 yy_hold_char = *yy_c_buf_p;
01388 }
01389
01390
01391 #ifdef YY_USE_PROTOS
01392 YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
01393 #else
01394 YY_BUFFER_STATE yy_create_buffer( file, size )
01395 FILE *file;
01396 int size;
01397 #endif
01398 {
01399 YY_BUFFER_STATE b;
01400
01401 b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
01402 if ( ! b )
01403 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
01404
01405 b->yy_buf_size = size;
01406
01407
01408
01409
01410 b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 );
01411 if ( ! b->yy_ch_buf )
01412 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
01413
01414 b->yy_is_our_buffer = 1;
01415
01416 yy_init_buffer( b, file );
01417
01418 return b;
01419 }
01420
01421
01422 #ifdef YY_USE_PROTOS
01423 void yy_delete_buffer( YY_BUFFER_STATE b )
01424 #else
01425 void yy_delete_buffer( b )
01426 YY_BUFFER_STATE b;
01427 #endif
01428 {
01429 if ( ! b )
01430 return;
01431
01432 if ( b == yy_current_buffer )
01433 yy_current_buffer = (YY_BUFFER_STATE) 0;
01434
01435 if ( b->yy_is_our_buffer )
01436 yy_flex_free( (void *) b->yy_ch_buf );
01437
01438 yy_flex_free( (void *) b );
01439 }
01440
01441
01442
01443 #ifdef YY_USE_PROTOS
01444 void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
01445 #else
01446 void yy_init_buffer( b, file )
01447 YY_BUFFER_STATE b;
01448 FILE *file;
01449 #endif
01450
01451
01452 {
01453 yy_flush_buffer( b );
01454
01455 b->yy_input_file = file;
01456 b->yy_fill_buffer = 1;
01457
01458 #if YY_ALWAYS_INTERACTIVE
01459 b->yy_is_interactive = 1;
01460 #else
01461 #if YY_NEVER_INTERACTIVE
01462 b->yy_is_interactive = 0;
01463 #else
01464 b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
01465 #endif
01466 #endif
01467 }
01468
01469
01470 #ifdef YY_USE_PROTOS
01471 void yy_flush_buffer( YY_BUFFER_STATE b )
01472 #else
01473 void yy_flush_buffer( b )
01474 YY_BUFFER_STATE b;
01475 #endif
01476
01477 {
01478 if ( ! b )
01479 return;
01480
01481 b->yy_n_chars = 0;
01482
01483
01484
01485
01486
01487 b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
01488 b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
01489
01490 b->yy_buf_pos = &b->yy_ch_buf[0];
01491
01492 b->yy_at_bol = 1;
01493 b->yy_buffer_status = YY_BUFFER_NEW;
01494
01495 if ( b == yy_current_buffer )
01496 yy_load_buffer_state();
01497 }
01498
01499
01500 #ifndef YY_NO_SCAN_BUFFER
01501 #ifdef YY_USE_PROTOS
01502 YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size )
01503 #else
01504 YY_BUFFER_STATE yy_scan_buffer( base, size )
01505 char *base;
01506 yy_size_t size;
01507 #endif
01508 {
01509 YY_BUFFER_STATE b;
01510
01511 if ( size < 2 ||
01512 base[size-2] != YY_END_OF_BUFFER_CHAR ||
01513 base[size-1] != YY_END_OF_BUFFER_CHAR )
01514
01515 return 0;
01516
01517 b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
01518 if ( ! b )
01519 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
01520
01521 b->yy_buf_size = size - 2;
01522 b->yy_buf_pos = b->yy_ch_buf = base;
01523 b->yy_is_our_buffer = 0;
01524 b->yy_input_file = 0;
01525 b->yy_n_chars = b->yy_buf_size;
01526 b->yy_is_interactive = 0;
01527 b->yy_at_bol = 1;
01528 b->yy_fill_buffer = 0;
01529 b->yy_buffer_status = YY_BUFFER_NEW;
01530
01531 yy_switch_to_buffer( b );
01532
01533 return b;
01534 }
01535 #endif
01536
01537
01538 #ifndef YY_NO_SCAN_STRING
01539 #ifdef YY_USE_PROTOS
01540 YY_BUFFER_STATE yy_scan_string( yyconst char *yy_str )
01541 #else
01542 YY_BUFFER_STATE yy_scan_string( yy_str )
01543 yyconst char *yy_str;
01544 #endif
01545 {
01546 int len;
01547 for ( len = 0; yy_str[len]; ++len )
01548 ;
01549
01550 return yy_scan_bytes( yy_str, len );
01551 }
01552 #endif
01553
01554
01555 #ifndef YY_NO_SCAN_BYTES
01556 #ifdef YY_USE_PROTOS
01557 YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len )
01558 #else
01559 YY_BUFFER_STATE yy_scan_bytes( bytes, len )
01560 yyconst char *bytes;
01561 int len;
01562 #endif
01563 {
01564 YY_BUFFER_STATE b;
01565 char *buf;
01566 yy_size_t n;
01567 int i;
01568
01569
01570 n = len + 2;
01571 buf = (char *) yy_flex_alloc( n );
01572 if ( ! buf )
01573 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
01574
01575 for ( i = 0; i < len; ++i )
01576 buf[i] = bytes[i];
01577
01578 buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR;
01579
01580 b = yy_scan_buffer( buf, n );
01581 if ( ! b )
01582 YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
01583
01584
01585
01586
01587 b->yy_is_our_buffer = 1;
01588
01589 return b;
01590 }
01591 #endif
01592
01593
01594 #ifndef YY_NO_PUSH_STATE
01595 #ifdef YY_USE_PROTOS
01596 static void yy_push_state( int new_state )
01597 #else
01598 static void yy_push_state( new_state )
01599 int new_state;
01600 #endif
01601 {
01602 if ( yy_start_stack_ptr >= yy_start_stack_depth )
01603 {
01604 yy_size_t new_size;
01605
01606 yy_start_stack_depth += YY_START_STACK_INCR;
01607 new_size = yy_start_stack_depth * sizeof( int );
01608
01609 if ( ! yy_start_stack )
01610 yy_start_stack = (int *) yy_flex_alloc( new_size );
01611
01612 else
01613 yy_start_stack = (int *) yy_flex_realloc(
01614 (void *) yy_start_stack, new_size );
01615
01616 if ( ! yy_start_stack )
01617 YY_FATAL_ERROR(
01618 "out of memory expanding start-condition stack" );
01619 }
01620
01621 yy_start_stack[yy_start_stack_ptr++] = YY_START;
01622
01623 BEGIN(new_state);
01624 }
01625 #endif
01626
01627
01628 #ifndef YY_NO_POP_STATE
01629 static void yy_pop_state()
01630 {
01631 if ( --yy_start_stack_ptr < 0 )
01632 YY_FATAL_ERROR( "start-condition stack underflow" );
01633
01634 BEGIN(yy_start_stack[yy_start_stack_ptr]);
01635 }
01636 #endif
01637
01638
01639 #ifndef YY_NO_TOP_STATE
01640 static int yy_top_state()
01641 {
01642 return yy_start_stack[yy_start_stack_ptr - 1];
01643 }
01644 #endif
01645
01646 #ifndef YY_EXIT_FAILURE
01647 #define YY_EXIT_FAILURE 2
01648 #endif
01649
01650 #ifdef YY_USE_PROTOS
01651 static void yy_fatal_error( yyconst char msg[] )
01652 #else
01653 static void yy_fatal_error( msg )
01654 char msg[];
01655 #endif
01656 {
01657 (void) fprintf( stderr, "%s\n", msg );
01658 exit( YY_EXIT_FAILURE );
01659 }
01660
01661
01662
01663
01664
01665 #undef yyless
01666 #define yyless(n) \
01667 do \
01668 { \
01669 \
01670 yytext[yyleng] = yy_hold_char; \
01671 yy_c_buf_p = yytext + n; \
01672 yy_hold_char = *yy_c_buf_p; \
01673 *yy_c_buf_p = '\0'; \
01674 yyleng = n; \
01675 } \
01676 while ( 0 )
01677
01678
01679
01680
01681 #ifndef yytext_ptr
01682 #ifdef YY_USE_PROTOS
01683 static void yy_flex_strncpy( char *s1, yyconst char *s2, int n )
01684 #else
01685 static void yy_flex_strncpy( s1, s2, n )
01686 char *s1;
01687 yyconst char *s2;
01688 int n;
01689 #endif
01690 {
01691 register int i;
01692 for ( i = 0; i < n; ++i )
01693 s1[i] = s2[i];
01694 }
01695 #endif
01696
01697 #ifdef YY_NEED_STRLEN
01698 #ifdef YY_USE_PROTOS
01699 static int yy_flex_strlen( yyconst char *s )
01700 #else
01701 static int yy_flex_strlen( s )
01702 yyconst char *s;
01703 #endif
01704 {
01705 register int n;
01706 for ( n = 0; s[n]; ++n )
01707 ;
01708
01709 return n;
01710 }
01711 #endif
01712
01713
01714 #ifdef YY_USE_PROTOS
01715 static void *yy_flex_alloc( yy_size_t size )
01716 #else
01717 static void *yy_flex_alloc( size )
01718 yy_size_t size;
01719 #endif
01720 {
01721 return (void *) malloc( size );
01722 }
01723
01724 #ifdef YY_USE_PROTOS
01725 static void *yy_flex_realloc( void *ptr, yy_size_t size )
01726 #else
01727 static void *yy_flex_realloc( ptr, size )
01728 void *ptr;
01729 yy_size_t size;
01730 #endif
01731 {
01732
01733
01734
01735
01736
01737
01738
01739 return (void *) realloc( (char *) ptr, size );
01740 }
01741
01742 #ifdef YY_USE_PROTOS
01743 static void yy_flex_free( void *ptr )
01744 #else
01745 static void yy_flex_free( ptr )
01746 void *ptr;
01747 #endif
01748 {
01749 free( ptr );
01750 }
01751
01752 #if YY_MAIN
01753 int main()
01754 {
01755 yylex();
01756 return 0;
01757 }
01758 #endif
01759 #line 176 "dmllex.lxx"
01760
01761
01762 int yywrap()
01763 {
01764 lexEof = 1;
01765 return 1;
01766 }
01767