/* This file is part of web2w. Copyright 2017 Martin Ruckert web2w is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. web2w is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with web2w. If not, see . Martin Ruckert, Hochschule Muenchen, Lothstrasse 64, 80336 Muenchen */ #line 2 "web.lex.c" #line 4 "web.lex.c" #define YY_INT_ALIGNED short int /* A lexical scanner generated by flex */ /* %not-for-header */ /* %if-c-only */ /* %if-not-reentrant */ #define yy_create_buffer ww_create_buffer #define yy_delete_buffer ww_delete_buffer #define yy_flex_debug ww_flex_debug #define yy_init_buffer ww_init_buffer #define yy_flush_buffer ww_flush_buffer #define yy_load_buffer_state ww_load_buffer_state #define yy_switch_to_buffer ww_switch_to_buffer #define yyin wwin #define yyleng wwleng #define yylex wwlex #define yylineno wwlineno #define yyout wwout #define yyrestart wwrestart #define yytext wwtext #define yywrap wwwrap #define yyalloc wwalloc #define yyrealloc wwrealloc #define yyfree wwfree /* %endif */ /* %endif */ /* %ok-for-header */ #define FLEX_SCANNER #define YY_FLEX_MAJOR_VERSION 2 #define YY_FLEX_MINOR_VERSION 5 #define YY_FLEX_SUBMINOR_VERSION 37 #if YY_FLEX_SUBMINOR_VERSION > 0 #define FLEX_BETA #endif /* %if-c++-only */ /* %endif */ /* %if-c-only */ /* %endif */ /* %if-c-only */ /* %endif */ /* First, we deal with platform-specific or compiler-specific issues. */ /* begin standard C headers. */ /* %if-c-only */ #include #include #include #include /* %endif */ /* %if-tables-serialization */ /* %endif */ /* end standard C headers. */ /* %if-c-or-c++ */ /* flex integer type definitions */ #ifndef FLEXINT_H #define FLEXINT_H /* C99 systems have . Non-C99 systems may or may not. */ #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L /* C99 says to define __STDC_LIMIT_MACROS before including stdint.h, * if you want the limit (max/min) macros for int types. */ #ifndef __STDC_LIMIT_MACROS #define __STDC_LIMIT_MACROS 1 #endif #include typedef int8_t flex_int8_t; typedef uint8_t flex_uint8_t; typedef int16_t flex_int16_t; typedef uint16_t flex_uint16_t; typedef int32_t flex_int32_t; typedef uint32_t flex_uint32_t; #else typedef signed char flex_int8_t; typedef short int flex_int16_t; typedef int flex_int32_t; typedef unsigned char flex_uint8_t; typedef unsigned short int flex_uint16_t; typedef unsigned int flex_uint32_t; /* Limits of integral types. */ #ifndef INT8_MIN #define INT8_MIN (-128) #endif #ifndef INT16_MIN #define INT16_MIN (-32767-1) #endif #ifndef INT32_MIN #define INT32_MIN (-2147483647-1) #endif #ifndef INT8_MAX #define INT8_MAX (127) #endif #ifndef INT16_MAX #define INT16_MAX (32767) #endif #ifndef INT32_MAX #define INT32_MAX (2147483647) #endif #ifndef UINT8_MAX #define UINT8_MAX (255U) #endif #ifndef UINT16_MAX #define UINT16_MAX (65535U) #endif #ifndef UINT32_MAX #define UINT32_MAX (4294967295U) #endif #endif /* ! C99 */ #endif /* ! FLEXINT_H */ /* %endif */ /* %if-c++-only */ /* %endif */ #ifdef __cplusplus /* The "const" storage-class-modifier is valid. */ #define YY_USE_CONST #else /* ! __cplusplus */ /* C99 requires __STDC__ to be defined as 1. */ #if defined (__STDC__) #define YY_USE_CONST #endif /* defined (__STDC__) */ #endif /* ! __cplusplus */ #ifdef YY_USE_CONST #define yyconst const #else #define yyconst #endif /* %not-for-header */ /* Returned upon end-of-file. */ #define YY_NULL 0 /* %ok-for-header */ /* %not-for-header */ /* Promotes a possibly negative, possibly signed char to an unsigned * integer for use as an array index. If the signed char is negative, * we want to instead treat it as an 8-bit unsigned char, hence the * double cast. */ #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c) /* %ok-for-header */ /* %if-reentrant */ /* %endif */ /* %if-not-reentrant */ /* %endif */ /* Enter a start condition. This macro really ought to take a parameter, * but we do it the disgusting crufty way forced on us by the ()-less * definition of BEGIN. */ #define BEGIN (yy_start) = 1 + 2 * /* Translate the current start state into a value that can be later handed * to BEGIN to return to the state. The YYSTATE alias is for lex * compatibility. */ #define YY_START (((yy_start) - 1) / 2) #define YYSTATE YY_START /* Action number for EOF rule of a given start state. */ #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) /* Special action meaning "start processing a new file". */ #define YY_NEW_FILE wwrestart(wwin ) #define YY_END_OF_BUFFER_CHAR 0 /* Size of default input buffer. */ #ifndef YY_BUF_SIZE #define YY_BUF_SIZE 16384 #endif /* The state buf must be large enough to hold one state per character in the main buffer. */ #define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) #ifndef YY_TYPEDEF_YY_BUFFER_STATE #define YY_TYPEDEF_YY_BUFFER_STATE typedef struct yy_buffer_state *YY_BUFFER_STATE; #endif #ifndef YY_TYPEDEF_YY_SIZE_T #define YY_TYPEDEF_YY_SIZE_T typedef size_t yy_size_t; #endif /* %if-not-reentrant */ extern yy_size_t wwleng; /* %endif */ /* %if-c-only */ /* %if-not-reentrant */ extern FILE *wwin, *wwout; /* %endif */ /* %endif */ #define EOB_ACT_CONTINUE_SCAN 0 #define EOB_ACT_END_OF_FILE 1 #define EOB_ACT_LAST_MATCH 2 /* Note: We specifically omit the test for yy_rule_can_match_eol because it requires * access to the local variable yy_act. Since yyless() is a macro, it would break * existing scanners that call yyless() from OUTSIDE wwlex. * One obvious solution it to make yy_act a global. I tried that, and saw * a 5% performance hit in a non-wwlineno scanner, because yy_act is * normally declared as a register variable-- so it is not worth it. */ #define YY_LESS_LINENO(n) \ do { \ int yyl;\ for ( yyl = n; yyl < wwleng; ++yyl )\ if ( wwtext[yyl] == '\n' )\ --wwlineno;\ }while(0) /* Return all but the first "n" matched characters back to the input stream. */ #define yyless(n) \ do \ { \ /* Undo effects of setting up wwtext. */ \ int yyless_macro_arg = (n); \ YY_LESS_LINENO(yyless_macro_arg);\ *yy_cp = (yy_hold_char); \ YY_RESTORE_YY_MORE_OFFSET \ (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \ YY_DO_BEFORE_ACTION; /* set up wwtext again */ \ } \ while ( 0 ) #define unput(c) yyunput( c, (yytext_ptr) ) #ifndef YY_STRUCT_YY_BUFFER_STATE #define YY_STRUCT_YY_BUFFER_STATE struct yy_buffer_state { /* %if-c-only */ FILE *yy_input_file; /* %endif */ /* %if-c++-only */ /* %endif */ char *yy_ch_buf; /* input buffer */ char *yy_buf_pos; /* current position in input buffer */ /* Size of input buffer in bytes, not including room for EOB * characters. */ yy_size_t yy_buf_size; /* Number of characters read into yy_ch_buf, not including EOB * characters. */ yy_size_t yy_n_chars; /* Whether we "own" the buffer - i.e., we know we created it, * and can realloc() it to grow it, and should free() it to * delete it. */ int yy_is_our_buffer; /* Whether this is an "interactive" input source; if so, and * if we're using stdio for input, then we want to use getc() * instead of fread(), to make sure we stop fetching input after * each newline. */ int yy_is_interactive; /* Whether we're considered to be at the beginning of a line. * If so, '^' rules will be active on the next match, otherwise * not. */ int yy_at_bol; int yy_bs_lineno; /**< The line count. */ int yy_bs_column; /**< The column count. */ /* Whether to try to fill the input buffer when we reach the * end of it. */ int yy_fill_buffer; int yy_buffer_status; #define YY_BUFFER_NEW 0 #define YY_BUFFER_NORMAL 1 /* When an EOF's been seen but there's still some text to process * then we mark the buffer as YY_EOF_PENDING, to indicate that we * shouldn't try reading from the input source any more. We might * still have a bunch of tokens to match, though, because of * possible backing-up. * * When we actually see the EOF, we change the status to "new" * (via wwrestart()), so that the user can continue scanning by * just pointing wwin at a new input file. */ #define YY_BUFFER_EOF_PENDING 2 }; #endif /* !YY_STRUCT_YY_BUFFER_STATE */ /* %if-c-only Standard (non-C++) definition */ /* %not-for-header */ /* %if-not-reentrant */ /* Stack of input buffers. */ static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */ static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */ static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */ /* %endif */ /* %ok-for-header */ /* %endif */ /* We provide macros for accessing buffer states in case in the * future we want to put the buffer states in a more general * "scanner state". * * Returns the top of the stack, or NULL. */ #define YY_CURRENT_BUFFER ( (yy_buffer_stack) \ ? (yy_buffer_stack)[(yy_buffer_stack_top)] \ : NULL) /* Same as previous macro, but useful when we know that the buffer stack is not * NULL or when we need an lvalue. For internal use only. */ #define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)] /* %if-c-only Standard (non-C++) definition */ /* %if-not-reentrant */ /* %not-for-header */ /* yy_hold_char holds the character lost when wwtext is formed. */ static char yy_hold_char; static yy_size_t yy_n_chars; /* number of characters read into yy_ch_buf */ yy_size_t wwleng; /* Points to current character in buffer. */ static char *yy_c_buf_p = (char *) 0; static int yy_init = 0; /* whether we need to initialize */ static int yy_start = 0; /* start state number */ /* Flag which is used to allow wwwrap()'s to do buffer switches * instead of setting up a fresh wwin. A bit of a hack ... */ static int yy_did_buffer_switch_on_eof; /* %ok-for-header */ /* %endif */ void wwrestart (FILE *input_file ); void ww_switch_to_buffer (YY_BUFFER_STATE new_buffer ); YY_BUFFER_STATE ww_create_buffer (FILE *file,int size ); void ww_delete_buffer (YY_BUFFER_STATE b ); void ww_flush_buffer (YY_BUFFER_STATE b ); void wwpush_buffer_state (YY_BUFFER_STATE new_buffer ); void wwpop_buffer_state (void ); static void wwensure_buffer_stack (void ); static void ww_load_buffer_state (void ); static void ww_init_buffer (YY_BUFFER_STATE b,FILE *file ); #define YY_FLUSH_BUFFER ww_flush_buffer(YY_CURRENT_BUFFER ) YY_BUFFER_STATE ww_scan_buffer (char *base,yy_size_t size ); YY_BUFFER_STATE ww_scan_string (yyconst char *yy_str ); YY_BUFFER_STATE ww_scan_bytes (yyconst char *bytes,yy_size_t len ); /* %endif */ void *wwalloc (yy_size_t ); void *wwrealloc (void *,yy_size_t ); void wwfree (void * ); #define yy_new_buffer ww_create_buffer #define yy_set_interactive(is_interactive) \ { \ if ( ! YY_CURRENT_BUFFER ){ \ wwensure_buffer_stack (); \ YY_CURRENT_BUFFER_LVALUE = \ ww_create_buffer(wwin,YY_BUF_SIZE ); \ } \ YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \ } #define yy_set_bol(at_bol) \ { \ if ( ! YY_CURRENT_BUFFER ){\ wwensure_buffer_stack (); \ YY_CURRENT_BUFFER_LVALUE = \ ww_create_buffer(wwin,YY_BUF_SIZE ); \ } \ YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ } #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) /* %% [1.0] wwtext/wwin/wwout/yy_state_type/wwlineno etc. def's & init go here */ /* Begin user sect3 */ #define wwwrap() 1 #define YY_SKIP_YYWRAP #define FLEX_DEBUG typedef unsigned char YY_CHAR; FILE *wwin = (FILE *) 0, *wwout = (FILE *) 0; typedef int yy_state_type; extern int wwlineno; int wwlineno = 1; extern char *wwtext; #define yytext_ptr wwtext /* %if-c-only Standard (non-C++) definition */ static yy_state_type yy_get_previous_state (void ); static yy_state_type yy_try_NUL_trans (yy_state_type current_state ); static int yy_get_next_buffer (void ); static void yy_fatal_error (yyconst char msg[] ); /* %endif */ /* Done after the current pattern has been matched and before the * corresponding action - sets up wwtext. */ #define YY_DO_BEFORE_ACTION \ (yytext_ptr) = yy_bp; \ /* %% [2.0] code to fiddle wwtext and wwleng for yymore() goes here \ */\ wwleng = (size_t) (yy_cp - yy_bp); \ (yy_hold_char) = *yy_cp; \ *yy_cp = '\0'; \ /* %% [3.0] code to copy yytext_ptr to wwtext[] goes here, if %array \ */\ (yy_c_buf_p) = yy_cp; /* %% [4.0] data tables for the DFA and the user's section 1 definitions go here */ #define YY_NUM_RULES 161 #define YY_END_OF_BUFFER 162 /* This struct is not used in this scanner, but its presence is necessary. */ struct yy_trans_info { flex_int32_t yy_verify; flex_int32_t yy_nxt; }; static yyconst flex_int16_t yy_accept[425] = { 0, 19, 19, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 162, 19, 18, 22, 23, 23, 21, 7, 9, 8, 160, 159, 64, 160, 63, 160, 61, 62, 83, 81, 95, 82, 93, 84, 156, 97, 96, 86, 80, 87, 160, 151, 90, 91, 98, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 52, 57, 60, 158, 64, 160, 30, 35, 35, 160, 33, 31, 42, 41, 160, 38, 38, 38, 40, 48, 47, 47, 47, 48, 48, 19, 22, 1, 15, 0, 0, 2, 0, 0, 6, 16, 17, 3, 4, 5, 0, 20, 0, 153, 0, 155, 0, 94, 0, 156, 0, 92, 88, 85, 89, 49, 55, 0, 77, 68, 72, 0, 50, 78, 74, 0, 75, 0, 79, 51, 0, 56, 73, 0, 0, 69, 76, 70, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 117, 151, 151, 151, 151, 151, 151, 151, 107, 103, 151, 151, 151, 151, 151, 111, 104, 151, 151, 151, 151, 151, 151, 0, 151, 151, 151, 119, 151, 151, 151, 151, 158, 24, 25, 29, 26, 27, 28, 0, 34, 31, 39, 38, 38, 38, 47, 47, 0, 0, 0, 43, 1, 11, 10, 2, 0, 0, 0, 0, 0, 6, 0, 0, 0, 152, 0, 154, 157, 0, 157, 49, 54, 53, 50, 0, 0, 0, 0, 0, 51, 0, 0, 0, 0, 0, 0, 0, 0, 105, 151, 151, 151, 151, 151, 151, 151, 101, 151, 151, 122, 151, 151, 118, 151, 151, 151, 151, 151, 151, 100, 151, 102, 106, 151, 151, 151, 151, 151, 151, 151, 129, 151, 0, 151, 151, 151, 151, 126, 151, 151, 24, 25, 0, 29, 32, 38, 37, 0, 0, 45, 0, 13, 14, 12, 153, 155, 0, 0, 66, 67, 59, 65, 58, 71, 151, 151, 151, 110, 136, 151, 151, 151, 109, 151, 130, 151, 151, 151, 124, 151, 149, 151, 151, 151, 151, 151, 151, 151, 138, 151, 151, 151, 147, 0, 148, 108, 150, 151, 151, 123, 0, 38, 0, 0, 0, 0, 157, 0, 127, 121, 151, 125, 145, 151, 151, 151, 151, 151, 146, 151, 133, 142, 151, 151, 151, 151, 151, 151, 151, 0, 115, 116, 0, 36, 44, 2, 50, 151, 120, 151, 151, 151, 151, 151, 151, 112, 134, 151, 151, 128, 114, 144, 0, 25, 0, 46, 139, 151, 151, 113, 151, 137, 151, 151, 135, 0, 140, 151, 131, 151, 151, 0, 143, 151, 132, 0, 141, 99, 0 } ; static yyconst flex_int32_t yy_ec[256] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, 4, 4, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 20, 20, 20, 20, 20, 20, 20, 21, 21, 22, 23, 24, 25, 26, 27, 28, 29, 29, 29, 30, 31, 32, 33, 33, 33, 33, 33, 33, 33, 33, 33, 34, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 35, 36, 37, 38, 39, 1, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 49, 56, 57, 58, 59, 60, 61, 49, 62, 49, 63, 64, 65, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 } ; static yyconst flex_int32_t yy_meta[66] = { 0, 1, 1, 2, 1, 1, 1, 1, 1, 3, 1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 4, 4, 1, 1, 1, 1, 1, 1, 3, 5, 5, 5, 5, 6, 6, 1, 3, 1, 1, 6, 4, 4, 4, 4, 4, 4, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 3, 3, 3 } ; static yyconst flex_int16_t yy_base[450] = { 0, 0, 3, 68, 11, 106, 133, 196, 0, 261, 0, 20, 23, 776, 0, 777, 0, 777, 325, 129, 777, 777, 777, 777, 777, 777, 769, 777, 5, 777, 777, 777, 777, 777, 777, 756, 777, 14, 748, 777, 4, 777, 747, 379, 0, 777, 777, 777, 0, 0, 3, 95, 7, 92, 88, 2, 731, 87, 96, 108, 6, 726, 104, 127, 716, 728, 111, 777, 777, 777, 168, 174, 443, 777, 777, 777, 760, 741, 0, 777, 777, 740, 0, 720, 710, 777, 777, 330, 180, 183, 744, 735, 0, 0, 758, 777, 0, 739, 6, 730, 729, 754, 777, 777, 777, 777, 777, 727, 777, 748, 747, 741, 740, 9, 777, 159, 320, 345, 777, 777, 777, 777, 748, 777, 0, 777, 777, 777, 729, 152, 777, 777, 720, 777, 719, 777, 744, 717, 777, 777, 716, 715, 714, 777, 777, 0, 698, 684, 693, 684, 680, 696, 682, 693, 673, 671, 674, 687, 8, 673, 675, 669, 685, 0, 115, 684, 681, 661, 671, 663, 0, 0, 673, 677, 664, 314, 659, 676, 705, 656, 669, 659, 0, 653, 654, 661, 650, 187, 705, 335, 704, 777, 777, 777, 692, 777, 0, 777, 0, 658, 660, 405, 342, 684, 675, 682, 15, 697, 0, 678, 340, 662, 668, 669, 666, 667, 690, 663, 664, 683, 682, 676, 675, 357, 353, 371, 683, 0, 664, 377, 648, 654, 655, 652, 653, 676, 649, 650, 647, 648, 645, 646, 643, 347, 0, 630, 621, 617, 623, 610, 608, 605, 0, 610, 618, 619, 616, 619, 597, 615, 602, 611, 596, 609, 608, 0, 596, 0, 0, 606, 599, 110, 597, 593, 602, 585, 0, 585, 578, 582, 583, 587, 580, 0, 570, 567, 605, 394, 565, 591, 777, 536, 0, 333, 397, 777, 0, 777, 777, 777, 571, 559, 399, 0, 777, 777, 777, 777, 777, 535, 494, 482, 484, 0, 0, 463, 469, 456, 0, 457, 0, 445, 455, 436, 0, 450, 0, 446, 440, 446, 433, 443, 441, 428, 0, 427, 442, 425, 0, 452, 0, 0, 0, 428, 434, 0, 0, 423, 398, 448, 435, 390, 404, 434, 0, 0, 430, 0, 0, 415, 411, 427, 409, 416, 0, 419, 0, 0, 379, 419, 418, 420, 416, 400, 403, 445, 0, 0, 417, 0, 403, 777, 777, 400, 0, 408, 407, 407, 395, 392, 400, 0, 0, 380, 386, 0, 0, 0, 380, 777, 416, 777, 0, 377, 379, 0, 378, 0, 372, 371, 0, 339, 0, 321, 0, 306, 151, 158, 0, 103, 0, 5, 0, 777, 777, 498, 505, 512, 519, 526, 533, 537, 541, 545, 549, 554, 561, 568, 575, 582, 586, 591, 598, 605, 612, 619, 626, 630, 634, 638 } ; static yyconst flex_int16_t yy_def[450] = { 0, 425, 425, 424, 3, 3, 3, 424, 7, 424, 9, 426, 426, 424, 427, 424, 428, 424, 424, 424, 424, 424, 424, 424, 424, 424, 429, 424, 430, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 431, 424, 424, 424, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 424, 424, 424, 424, 424, 43, 424, 424, 424, 424, 424, 432, 424, 424, 424, 433, 433, 433, 424, 424, 424, 424, 424, 424, 424, 427, 428, 424, 424, 434, 424, 424, 435, 436, 424, 424, 424, 424, 424, 424, 437, 424, 438, 424, 439, 424, 439, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 440, 424, 424, 424, 424, 424, 424, 424, 441, 424, 442, 424, 424, 443, 424, 424, 444, 445, 446, 424, 424, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 424, 431, 431, 431, 431, 431, 431, 431, 431, 424, 424, 424, 424, 424, 424, 424, 424, 424, 432, 424, 433, 433, 433, 424, 424, 424, 424, 424, 424, 424, 434, 424, 424, 424, 435, 424, 436, 424, 424, 437, 424, 438, 424, 439, 424, 424, 424, 424, 424, 440, 424, 424, 424, 441, 424, 442, 424, 424, 443, 424, 444, 424, 445, 424, 446, 446, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 424, 431, 431, 431, 431, 431, 431, 431, 424, 424, 424, 424, 424, 433, 433, 424, 424, 424, 447, 424, 424, 424, 424, 424, 424, 448, 424, 424, 424, 424, 424, 446, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 424, 431, 431, 431, 431, 431, 431, 449, 433, 424, 424, 447, 424, 424, 448, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 424, 431, 431, 449, 433, 424, 424, 424, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, 424, 424, 424, 424, 431, 431, 431, 431, 431, 431, 431, 431, 431, 424, 431, 431, 431, 431, 431, 424, 431, 431, 431, 424, 431, 424, 0, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424 } ; static yyconst flex_int16_t yy_nxt[843] = { 0, 424, 424, 15, 424, 424, 15, 424, 210, 16, 424, 424, 16, 70, 71, 70, 112, 294, 17, 424, 222, 17, 87, 88, 89, 87, 88, 89, 18, 119, 120, 18, 115, 113, 116, 116, 19, 111, 90, 19, 295, 90, 211, 150, 148, 117, 173, 163, 91, 423, 151, 91, 424, 146, 149, 164, 147, 152, 156, 256, 157, 257, 174, 20, 21, 22, 20, 21, 22, 23, 24, 25, 24, 23, 26, 27, 23, 23, 23, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 37, 38, 39, 40, 41, 42, 23, 43, 44, 44, 44, 44, 44, 44, 45, 23, 46, 47, 23, 48, 49, 50, 51, 52, 53, 54, 44, 55, 44, 44, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 44, 67, 68, 69, 72, 70, 71, 70, 108, 153, 158, 166, 161, 154, 168, 167, 159, 162, 176, 155, 169, 160, 332, 170, 229, 178, 333, 108, 185, 186, 422, 72, 177, 262, 171, 108, 172, 179, 421, 73, 187, 187, 187, 263, 180, 181, 187, 187, 187, 223, 223, 182, 202, 202, 202, 202, 202, 202, 230, 187, 187, 187, 108, 108, 108, 420, 73, 23, 74, 75, 74, 23, 23, 23, 23, 23, 23, 23, 76, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 77, 23, 23, 23, 78, 78, 78, 78, 78, 78, 23, 23, 23, 23, 23, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, 23, 23, 23, 23, 79, 80, 79, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 81, 23, 23, 23, 82, 82, 82, 82, 82, 82, 23, 23, 23, 23, 23, 82, 83, 82, 82, 84, 82, 82, 82, 82, 82, 82, 82, 82, 82, 82, 82, 82, 82, 82, 82, 82, 82, 82, 85, 23, 23, 94, 94, 94, 95, 96, 201, 202, 202, 348, 97, 287, 115, 98, 116, 116, 210, 99, 202, 202, 202, 100, 203, 101, 419, 117, 102, 103, 272, 104, 273, 105, 204, 106, 224, 349, 224, 107, 418, 225, 225, 417, 104, 274, 105, 288, 275, 225, 225, 243, 211, 223, 223, 229, 106, 122, 122, 122, 123, 124, 125, 126, 302, 127, 128, 225, 225, 129, 130, 131, 287, 132, 133, 294, 348, 134, 135, 136, 137, 400, 138, 201, 202, 202, 352, 352, 309, 230, 351, 139, 351, 140, 400, 352, 352, 390, 295, 203, 352, 352, 349, 416, 401, 415, 288, 414, 413, 204, 412, 411, 391, 141, 410, 409, 408, 401, 142, 143, 144, 188, 188, 188, 407, 406, 405, 404, 403, 402, 399, 398, 397, 189, 396, 395, 394, 393, 392, 389, 388, 387, 386, 190, 385, 384, 383, 382, 381, 191, 380, 192, 379, 193, 377, 376, 375, 374, 373, 372, 371, 370, 191, 369, 192, 368, 367, 366, 365, 364, 363, 362, 361, 360, 193, 14, 14, 14, 14, 14, 14, 14, 86, 86, 86, 86, 86, 86, 86, 92, 359, 358, 92, 92, 92, 92, 93, 357, 93, 93, 93, 93, 93, 109, 356, 109, 109, 109, 109, 109, 111, 355, 111, 111, 111, 111, 111, 145, 145, 145, 145, 196, 196, 196, 196, 198, 198, 198, 198, 208, 208, 212, 354, 212, 212, 212, 212, 212, 214, 243, 214, 214, 214, 214, 214, 217, 221, 217, 217, 217, 217, 217, 219, 219, 219, 219, 219, 219, 219, 221, 347, 221, 221, 221, 221, 221, 227, 227, 231, 289, 231, 231, 231, 231, 231, 233, 346, 233, 233, 233, 233, 233, 236, 286, 236, 236, 236, 236, 236, 238, 345, 238, 238, 238, 238, 238, 240, 344, 240, 240, 240, 240, 240, 242, 343, 242, 242, 242, 242, 242, 350, 342, 341, 350, 353, 340, 339, 353, 378, 338, 337, 378, 336, 335, 334, 331, 330, 329, 328, 327, 326, 325, 324, 323, 322, 321, 320, 319, 318, 317, 316, 315, 314, 313, 312, 311, 310, 243, 308, 241, 307, 239, 306, 237, 235, 305, 234, 304, 232, 303, 228, 226, 221, 301, 219, 300, 299, 218, 216, 298, 215, 297, 213, 296, 209, 207, 293, 206, 205, 292, 291, 290, 289, 286, 285, 284, 283, 282, 281, 280, 279, 278, 277, 276, 271, 270, 269, 268, 267, 266, 265, 264, 261, 260, 259, 258, 255, 254, 253, 252, 251, 250, 249, 248, 247, 246, 245, 244, 243, 241, 239, 237, 235, 234, 232, 228, 226, 111, 222, 109, 220, 218, 216, 215, 213, 209, 207, 206, 205, 200, 199, 197, 195, 194, 184, 183, 175, 165, 121, 118, 114, 110, 424, 13, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424 } ; static yyconst flex_int16_t yy_chk[843] = { 0, 0, 0, 1, 0, 0, 2, 0, 98, 1, 0, 0, 2, 4, 4, 4, 28, 206, 1, 0, 113, 2, 11, 11, 11, 12, 12, 12, 1, 40, 40, 2, 37, 28, 37, 37, 1, 113, 11, 2, 206, 12, 98, 50, 49, 37, 60, 55, 11, 421, 50, 12, 0, 48, 49, 55, 48, 50, 52, 158, 52, 158, 60, 1, 1, 1, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 5, 6, 6, 6, 19, 51, 53, 57, 54, 51, 58, 57, 53, 54, 62, 51, 58, 53, 271, 59, 129, 63, 271, 19, 66, 66, 419, 6, 62, 164, 59, 19, 59, 63, 417, 5, 70, 70, 70, 164, 63, 63, 71, 71, 71, 115, 115, 63, 88, 88, 88, 89, 89, 89, 129, 187, 187, 187, 19, 19, 19, 416, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 18, 18, 18, 18, 18, 87, 87, 87, 293, 18, 189, 116, 18, 116, 116, 210, 18, 202, 202, 202, 18, 87, 18, 415, 116, 18, 18, 175, 18, 175, 18, 87, 18, 117, 293, 117, 18, 413, 117, 117, 411, 18, 175, 18, 189, 175, 224, 224, 243, 210, 223, 223, 229, 18, 43, 43, 43, 43, 43, 43, 43, 223, 43, 43, 225, 225, 43, 43, 43, 287, 43, 43, 294, 348, 43, 43, 43, 43, 380, 43, 201, 201, 201, 351, 351, 243, 229, 302, 43, 302, 43, 400, 302, 302, 368, 294, 201, 352, 352, 348, 409, 380, 408, 287, 406, 404, 201, 403, 398, 368, 43, 394, 393, 390, 400, 43, 43, 43, 72, 72, 72, 389, 388, 387, 386, 385, 383, 378, 375, 374, 72, 373, 372, 371, 370, 369, 365, 363, 362, 361, 72, 360, 359, 356, 353, 350, 72, 349, 72, 347, 72, 344, 343, 339, 337, 336, 335, 333, 332, 72, 331, 72, 330, 329, 328, 327, 325, 323, 322, 321, 319, 72, 425, 425, 425, 425, 425, 425, 425, 426, 426, 426, 426, 426, 426, 426, 427, 317, 316, 427, 427, 427, 427, 428, 315, 428, 428, 428, 428, 428, 429, 312, 429, 429, 429, 429, 429, 430, 311, 430, 430, 430, 430, 430, 431, 431, 431, 431, 432, 432, 432, 432, 433, 433, 433, 433, 434, 434, 435, 310, 435, 435, 435, 435, 435, 436, 309, 436, 436, 436, 436, 436, 437, 301, 437, 437, 437, 437, 437, 438, 300, 438, 438, 438, 438, 438, 439, 291, 439, 439, 439, 439, 439, 440, 440, 441, 289, 441, 441, 441, 441, 441, 442, 288, 442, 442, 442, 442, 442, 443, 286, 443, 443, 443, 443, 443, 444, 285, 444, 444, 444, 444, 444, 445, 284, 445, 445, 445, 445, 445, 446, 282, 446, 446, 446, 446, 446, 447, 281, 280, 447, 448, 279, 278, 448, 449, 277, 275, 449, 274, 273, 272, 270, 269, 266, 264, 263, 262, 261, 260, 259, 258, 257, 256, 255, 254, 253, 251, 250, 249, 248, 247, 246, 245, 242, 241, 240, 239, 238, 237, 236, 235, 234, 233, 232, 231, 230, 228, 226, 222, 221, 220, 219, 218, 217, 216, 215, 214, 213, 212, 211, 209, 207, 205, 204, 203, 200, 199, 194, 190, 188, 186, 185, 184, 183, 181, 180, 179, 178, 177, 176, 174, 173, 172, 169, 168, 167, 166, 165, 162, 161, 160, 159, 157, 156, 155, 154, 153, 152, 151, 150, 149, 148, 147, 146, 142, 141, 140, 137, 136, 134, 132, 128, 122, 112, 111, 110, 109, 107, 101, 100, 99, 97, 94, 91, 90, 84, 83, 81, 77, 76, 65, 64, 61, 56, 42, 38, 35, 26, 13, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424 } ; /* Table of booleans, true if rule could match eol. */ static yyconst flex_int32_t yy_rule_can_match_eol[162] = { 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, }; static yy_state_type yy_last_accepting_state; static char *yy_last_accepting_cpos; extern int ww_flex_debug; int ww_flex_debug = 1; static yyconst flex_int16_t yy_rule_linenum[161] = { 0, 41, 42, 43, 44, 45, 46, 48, 49, 51, 54, 55, 56, 57, 58, 59, 60, 61, 64, 65, 66, 67, 68, 69, 75, 76, 77, 78, 79, 80, 81, 85, 86, 87, 88, 89, 93, 94, 95, 96, 97, 98, 99, 103, 104, 105, 106, 107, 108, 113, 114, 115, 116, 122, 123, 124, 125, 126, 127, 128, 131, 132, 133, 134, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 157, 158, 159, 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, 178, 181, 182, 183, 184, 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, 220, 222, 223, 224, 225, 227, 229, 230, 231, 232, 233, 234, 236, 237, 238, 239, 240, 241, 242, 244, 245, 256 } ; /* The intent behind this definition is that it'll catch * any uses of REJECT which flex missed. */ #define REJECT reject_used_but_not_detected #define yymore() yymore_used_but_not_detected #define YY_MORE_ADJ 0 #define YY_RESTORE_YY_MORE_OFFSET char *wwtext; #line 1 "web.l" #line 2 "web.l" /* This file is part of web2w. Copyright 2017 Martin Ruckert web2w is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. web2w is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with web2w. If not, see . Martin Ruckert, Hochschule Muenchen, Lothstrasse 64, 80336 Muenchen */ #include "web2w.h" #include "pascal.tab.h" #define YY_NO_INPUT 1 #line 958 "web.lex.c" #define INITIAL 0 #define PASCAL 1 #define MIDDLE 2 #define DEFINITION 3 #define FORMAT 4 #define NAME 5 #ifndef YY_NO_UNISTD_H /* Special case for "unistd.h", since it is non-ANSI. We include it way * down here because we want the user's section 1 to have been scanned first. * The user has a chance to override it with an option. */ /* %if-c-only */ #include /* %endif */ /* %if-c++-only */ /* %endif */ #endif #ifndef YY_EXTRA_TYPE #define YY_EXTRA_TYPE void * #endif /* %if-c-only Reentrant structure and macros (non-C++). */ /* %if-reentrant */ /* %if-c-only */ static int yy_init_globals (void ); /* %endif */ /* %if-reentrant */ /* %endif */ /* %endif End reentrant structures and macros. */ /* Accessor methods to globals. These are made visible to non-reentrant scanners for convenience. */ int wwlex_destroy (void ); int wwget_debug (void ); void wwset_debug (int debug_flag ); YY_EXTRA_TYPE wwget_extra (void ); void wwset_extra (YY_EXTRA_TYPE user_defined ); FILE *wwget_in (void ); void wwset_in (FILE * in_str ); FILE *wwget_out (void ); void wwset_out (FILE * out_str ); yy_size_t wwget_leng (void ); char *wwget_text (void ); int wwget_lineno (void ); void wwset_lineno (int line_number ); /* %if-bison-bridge */ /* %endif */ /* Macros after this point can all be overridden by user definitions in * section 1. */ #ifndef YY_SKIP_YYWRAP #ifdef __cplusplus extern "C" int wwwrap (void ); #else extern int wwwrap (void ); #endif #endif /* %not-for-header */ /* %ok-for-header */ /* %endif */ #ifndef yytext_ptr static void yy_flex_strncpy (char *,yyconst char *,int ); #endif #ifdef YY_NEED_STRLEN static int yy_flex_strlen (yyconst char * ); #endif #ifndef YY_NO_INPUT /* %if-c-only Standard (non-C++) definition */ /* %not-for-header */ #ifdef __cplusplus static int yyinput (void ); #else static int input (void ); #endif /* %ok-for-header */ /* %endif */ #endif /* %if-c-only */ /* %endif */ /* Amount of stuff to slurp up with each read. */ #ifndef YY_READ_BUF_SIZE #define YY_READ_BUF_SIZE 8192 #endif /* Copy whatever the last rule matched to the standard output. */ #ifndef ECHO /* %if-c-only Standard (non-C++) definition */ /* This used to be an fputs(), but since the string might contain NUL's, * we now use fwrite(). */ #define ECHO do { if (fwrite( wwtext, wwleng, 1, wwout )) {} } while (0) /* %endif */ /* %if-c++-only C++ definition */ /* %endif */ #endif /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, * is returned in "result". */ #ifndef YY_INPUT #define YY_INPUT(buf,result,max_size) \ /* %% [5.0] fread()/read() definition of YY_INPUT goes here unless we're doing C++ \ */\ if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ { \ int c = '*'; \ size_t n; \ for ( n = 0; n < max_size && \ (c = getc( wwin )) != EOF && c != '\n'; ++n ) \ buf[n] = (char) c; \ if ( c == '\n' ) \ buf[n++] = (char) c; \ if ( c == EOF && ferror( wwin ) ) \ YY_FATAL_ERROR( "input in flex scanner failed" ); \ result = n; \ } \ else \ { \ errno=0; \ while ( (result = fread(buf, 1, max_size, wwin))==0 && ferror(wwin)) \ { \ if( errno != EINTR) \ { \ YY_FATAL_ERROR( "input in flex scanner failed" ); \ break; \ } \ errno=0; \ clearerr(wwin); \ } \ }\ \ /* %if-c++-only C++ definition \ */\ /* %endif */ #endif /* No semi-colon after return; correct usage is to write "yyterminate();" - * we don't want an extra ';' after the "return" because that will cause * some compilers to complain about unreachable statements. */ #ifndef yyterminate #define yyterminate() return YY_NULL #endif /* Number of entries by which start-condition stack grows. */ #ifndef YY_START_STACK_INCR #define YY_START_STACK_INCR 25 #endif /* Report a fatal error. */ #ifndef YY_FATAL_ERROR /* %if-c-only */ #define YY_FATAL_ERROR(msg) yy_fatal_error( msg ) /* %endif */ /* %if-c++-only */ /* %endif */ #endif /* %if-tables-serialization structures and prototypes */ /* %not-for-header */ /* %ok-for-header */ /* %not-for-header */ /* %tables-yydmap generated elements */ /* %endif */ /* end tables serialization structures and prototypes */ /* %ok-for-header */ /* Default declaration of generated scanner - a define so the user can * easily add parameters. */ #ifndef YY_DECL #define YY_DECL_IS_OURS 1 /* %if-c-only Standard (non-C++) definition */ extern int wwlex (void); #define YY_DECL int wwlex (void) /* %endif */ /* %if-c++-only C++ definition */ /* %endif */ #endif /* !YY_DECL */ /* Code executed at the beginning of each rule, after wwtext and wwleng * have been set up. */ #ifndef YY_USER_ACTION #define YY_USER_ACTION #endif /* Code executed at the end of each rule. */ #ifndef YY_BREAK #define YY_BREAK break; #endif /* %% [6.0] YY_RULE_SETUP definition goes here */ #define YY_RULE_SETUP \ if ( wwleng > 0 ) \ YY_CURRENT_BUFFER_LVALUE->yy_at_bol = \ (wwtext[wwleng - 1] == '\n'); \ YY_USER_ACTION /* %not-for-header */ /** The main scanner function which does all the work. */ YY_DECL { register yy_state_type yy_current_state; register char *yy_cp, *yy_bp; register int yy_act; /* %% [7.0] user's declarations go here */ #line 38 "web.l" /* WEB codes, see WEB User Manual page 7 ff*/ #line 1209 "web.lex.c" if ( !(yy_init) ) { (yy_init) = 1; #ifdef YY_USER_INIT YY_USER_INIT; #endif if ( ! (yy_start) ) (yy_start) = 1; /* first start state */ if ( ! wwin ) /* %if-c-only */ wwin = stdin; /* %endif */ /* %if-c++-only */ /* %endif */ if ( ! wwout ) /* %if-c-only */ wwout = stdout; /* %endif */ /* %if-c++-only */ /* %endif */ if ( ! YY_CURRENT_BUFFER ) { wwensure_buffer_stack (); YY_CURRENT_BUFFER_LVALUE = ww_create_buffer(wwin,YY_BUF_SIZE ); } ww_load_buffer_state( ); } while ( 1 ) /* loops until end-of-file is reached */ { /* %% [8.0] yymore()-related code goes here */ yy_cp = (yy_c_buf_p); /* Support of wwtext. */ *yy_cp = (yy_hold_char); /* yy_bp points to the position in yy_ch_buf of the start of * the current run. */ yy_bp = yy_cp; /* %% [9.0] code to set up and find next match goes here */ yy_current_state = (yy_start); yy_current_state += YY_AT_BOL(); yy_match: do { register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)]; if ( yy_accept[yy_current_state] ) { (yy_last_accepting_state) = yy_current_state; (yy_last_accepting_cpos) = yy_cp; } while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; if ( yy_current_state >= 425 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; ++yy_cp; } while ( yy_current_state != 424 ); yy_cp = (yy_last_accepting_cpos); yy_current_state = (yy_last_accepting_state); yy_find_action: /* %% [10.0] code to find the action number goes here */ yy_act = yy_accept[yy_current_state]; YY_DO_BEFORE_ACTION; /* %% [11.0] code for wwlineno update goes here */ if ( yy_act != YY_END_OF_BUFFER && yy_rule_can_match_eol[yy_act] ) { int yyl; for ( yyl = 0; yyl < wwleng; ++yyl ) if ( wwtext[yyl] == '\n' ) wwlineno++; ; } do_action: /* This label is used only to access EOF actions. */ /* %% [12.0] debug code goes here */ if ( ww_flex_debug ) { if ( yy_act == 0 ) fprintf( stderr, "--scanner backing up\n" ); else if ( yy_act < 161 ) fprintf( stderr, "--accepting rule at line %ld (\"%s\")\n", (long)yy_rule_linenum[yy_act], wwtext ); else if ( yy_act == 161 ) fprintf( stderr, "--accepting default rule (\"%s\")\n", wwtext ); else if ( yy_act == 162 ) fprintf( stderr, "--(end of buffer or a NUL)\n" ); else fprintf( stderr, "--EOF (start condition %d)\n", YY_START ); } switch ( yy_act ) { /* beginning of action switch */ /* %% [13.0] actions go here */ case 0: /* must back up */ /* undo the effects of YY_DO_BEFORE_ACTION */ *yy_cp = (yy_hold_char); yy_cp = (yy_last_accepting_cpos); yy_current_state = (yy_last_accepting_state); goto yy_find_action; case 1: /* rule 1 can match eol */ YY_RULE_SETUP #line 41 "web.l" EOS;TOK("@ ",ATSPACE);BOS; YY_BREAK case 2: YY_RULE_SETUP #line 42 "web.l" EOS;TOK("@*",ATSTAR); BOS; YY_BREAK case 3: YY_RULE_SETUP #line 43 "web.l" EOS;TOK("@d ",ATD);BEGIN(DEFINITION); YY_BREAK case 4: YY_RULE_SETUP #line 44 "web.l" EOS;TOK("@f ",ATF);BEGIN(FORMAT); YY_BREAK case 5: YY_RULE_SETUP #line 45 "web.l" EOS;TOK("@p",ATP);PROGRAM;PUSH;SEQ;BEGIN(PASCAL); YY_BREAK case 6: YY_RULE_SETUP #line 46 "web.l" EOS;TOK("@<",ATLESS);PUSH;BOS;BEGIN(NAME); YY_BREAK case 7: YY_RULE_SETUP #line 48 "web.l" ADD;PUSH_NULL; YY_BREAK case 8: YY_RULE_SETUP #line 49 "web.l" POP_LEFT; YY_BREAK case 9: YY_RULE_SETUP #line 51 "web.l" EOS;TOK("|",BAR);PUSH;BEGIN(PASCAL); YY_BREAK case 10: YY_RULE_SETUP #line 54 "web.l" EOS;TOK(COPY,OCTAL);BOS; YY_BREAK case 11: YY_RULE_SETUP #line 55 "web.l" EOS;TOK(COPY,HEX);BOS; YY_BREAK case 12: YY_RULE_SETUP #line 56 "web.l" EOS;TOK(COPY,ATINDEX); BOS; YY_BREAK case 13: YY_RULE_SETUP #line 57 "web.l" EOS;TOK(COPY,ATINDEXTT); BOS; YY_BREAK case 14: YY_RULE_SETUP #line 58 "web.l" EOS;TOK(COPY,ATINDEX9); BOS; YY_BREAK case 15: YY_RULE_SETUP #line 59 "web.l" EOS;TOK("@!",ATEX); BOS; YY_BREAK case 16: YY_RULE_SETUP #line 60 "web.l" EOS;TOK("@?",ATQM); BOS; YY_BREAK case 17: YY_RULE_SETUP #line 61 "web.l" EOS;TOK("@@",ATAT);BOS; YY_BREAK case 18: /* rule 18 can match eol */ YY_RULE_SETUP #line 64 "web.l" ADD; YY_BREAK case 19: YY_RULE_SETUP #line 65 "web.l" ADD; /* we do not analyze TEX parts any further */ YY_BREAK case 20: YY_RULE_SETUP #line 66 "web.l" ADD; YY_BREAK case 21: YY_RULE_SETUP #line 67 "web.l" ADD; YY_BREAK case 22: YY_RULE_SETUP #line 68 "web.l" ADD; YY_BREAK case 23: YY_RULE_SETUP #line 69 "web.l" ADD; YY_BREAK case YY_STATE_EOF(INITIAL): #line 71 "web.l" EOS;TOK("",WEBEOF);return 0; YY_BREAK case 24: /* rule 24 can match eol */ YY_RULE_SETUP #line 75 "web.l" TOK("@ ",ATSPACE);POP;BOS;BEGIN(TEX); YY_BREAK case 25: YY_RULE_SETUP #line 76 "web.l" TOK("@*",ATSTAR); POP;BOS;BEGIN(TEX); YY_BREAK case 26: YY_RULE_SETUP #line 77 "web.l" TOK("@d ",ATD);POP;BEGIN(DEFINITION); YY_BREAK case 27: YY_RULE_SETUP #line 78 "web.l" TOK("@f ",ATF);POP;BEGIN(FORMAT); YY_BREAK case 28: YY_RULE_SETUP #line 79 "web.l" TOK("@p",ATP);POP;PROGRAM;PUSH;SEQ;BEGIN(PASCAL); YY_BREAK case 29: YY_RULE_SETUP #line 80 "web.l" TOK("@<",ATLESS);POP;PUSH;BOS;BEGIN(NAME); YY_BREAK case 30: YY_RULE_SETUP #line 81 "web.l" TOK(" {",MLEFT);PUSH;BEGIN(TEX);BOS; YY_BREAK case 31: YY_RULE_SETUP #line 85 "web.l" SYMBOL; YY_BREAK case 32: YY_RULE_SETUP #line 86 "web.l" TOK("(#)",PARAM); YY_BREAK case 33: YY_RULE_SETUP #line 87 "web.l" TOK("=",EQEQ);PUSH;DEF_MACRO(NMACRO);BEGIN(MIDDLE); YY_BREAK case 34: YY_RULE_SETUP #line 88 "web.l" TOK("==",EQEQ);PUSH;DEF_MACRO(OMACRO);BEGIN(MIDDLE); YY_BREAK case 35: /* rule 35 can match eol */ YY_RULE_SETUP #line 89 "web.l" ; YY_BREAK case 36: YY_RULE_SETUP #line 93 "web.l" TOK("if",PIF); YY_BREAK case 37: YY_RULE_SETUP #line 94 "web.l" TOK("if",PIF); YY_BREAK case 38: YY_RULE_SETUP #line 95 "web.l" SYMBOL; YY_BREAK case 39: YY_RULE_SETUP #line 96 "web.l" TOK("==",EQEQ);PUSH; YY_BREAK case 40: YY_RULE_SETUP #line 97 "web.l" TOK(" {",MLEFT);PUSH;BEGIN(TEX);BOS; YY_BREAK case 41: /* rule 41 can match eol */ YY_RULE_SETUP #line 98 "web.l" TOK("\n",NL);BEGIN(MIDDLE); YY_BREAK case 42: /* rule 42 can match eol */ YY_RULE_SETUP #line 99 "web.l" ; YY_BREAK case 43: YY_RULE_SETUP #line 103 "web.l" EOS;AT_GREATER;BEGIN(PASCAL); YY_BREAK case 44: YY_RULE_SETUP #line 104 "web.l" EOS;TOK("...",ELIPSIS);AT_GREATER;BEGIN(PASCAL); YY_BREAK case 45: YY_RULE_SETUP #line 105 "web.l" EOS;AT_GREATER_EQ;BEGIN(PASCAL); YY_BREAK case 46: YY_RULE_SETUP #line 106 "web.l" EOS;TOK("...",ELIPSIS);AT_GREATER_EQ;BEGIN(PASCAL); YY_BREAK case 47: /* rule 47 can match eol */ YY_RULE_SETUP #line 107 "web.l" add_string(" "); YY_BREAK case 48: YY_RULE_SETUP #line 108 "web.l" ADD; YY_BREAK case 49: /* rule 49 can match eol */ YY_RULE_SETUP #line 113 "web.l" TOK("@ ",ATSPACE);POP;BOS;BEGIN(TEX); YY_BREAK case 50: YY_RULE_SETUP #line 114 "web.l" TOK("@*",ATSTAR);POP;BOS;BEGIN(TEX); YY_BREAK case 51: YY_RULE_SETUP #line 115 "web.l" TOK("@<",ATLESS);PUSH;BOS;BEGIN(NAME); YY_BREAK case 52: YY_RULE_SETUP #line 116 "web.l" TOK(" {",PLEFT);PUSH;BEGIN(TEX);BOS; YY_BREAK case YY_STATE_EOF(MIDDLE): case YY_STATE_EOF(PASCAL): #line 120 "web.l" TOK("",WEBEOF);POP;return 0; YY_BREAK case 53: YY_RULE_SETUP #line 122 "web.l" TOK(COPY,OCTAL); YY_BREAK case 54: YY_RULE_SETUP #line 123 "web.l" TOK(COPY,HEX); YY_BREAK case 55: YY_RULE_SETUP #line 124 "web.l" TOK("@!",ATEX); YY_BREAK case 56: YY_RULE_SETUP #line 125 "web.l" TOK("@?",ATQM); YY_BREAK case 57: YY_RULE_SETUP #line 126 "web.l" TOK("|",BAR);POP;BEGIN(TEX);BOS; YY_BREAK case 58: YY_RULE_SETUP #line 127 "web.l" TOK(COPY,ATT); YY_BREAK case 59: YY_RULE_SETUP #line 128 "web.l" TOK(COPY,ATEQ); YY_BREAK case 60: YY_RULE_SETUP #line 131 "web.l" ERROR("Unexpected }"); YY_BREAK case 61: YY_RULE_SETUP #line 132 "web.l" TOK("(",POPEN);PUSH; YY_BREAK case 62: YY_RULE_SETUP #line 133 "web.l" TOK(")",PCLOSE);POP; YY_BREAK case 63: YY_RULE_SETUP #line 134 "web.l" TOK("#",HASH);/* used in macros */ YY_BREAK /* non Pascal tokens */ case 64: /* rule 64 can match eol */ YY_RULE_SETUP #line 139 "web.l" TOK("\n",NL); YY_BREAK case 65: YY_RULE_SETUP #line 140 "web.l" TOK(COPY,ATINDEX); YY_BREAK case 66: YY_RULE_SETUP #line 141 "web.l" TOK(COPY,ATINDEXTT); YY_BREAK case 67: YY_RULE_SETUP #line 142 "web.l" TOK(COPY,ATINDEX9); YY_BREAK case 68: YY_RULE_SETUP #line 143 "web.l" TOK("@$",ATDOLLAR); YY_BREAK case 69: YY_RULE_SETUP #line 144 "web.l" TOK("@{",ATLEFT); YY_BREAK case 70: YY_RULE_SETUP #line 145 "web.l" TOK("@}",ATRIGHT); YY_BREAK case 71: YY_RULE_SETUP #line 146 "web.l" TOK(COPY,METACOMMENT); YY_BREAK case 72: YY_RULE_SETUP #line 147 "web.l" TOK("@&",ATAND); YY_BREAK case 73: YY_RULE_SETUP #line 148 "web.l" TOK("@\\",ATBACKSLASH); YY_BREAK case 74: YY_RULE_SETUP #line 149 "web.l" TOK("@,",ATCOMMA); YY_BREAK case 75: YY_RULE_SETUP #line 150 "web.l" TOK("@/",ATSLASH); YY_BREAK case 76: YY_RULE_SETUP #line 151 "web.l" TOK("@|",ATBAR); YY_BREAK case 77: YY_RULE_SETUP #line 152 "web.l" TOK("@#",ATHASH); YY_BREAK case 78: YY_RULE_SETUP #line 153 "web.l" TOK("@+",ATPLUS); YY_BREAK case 79: YY_RULE_SETUP #line 154 "web.l" TOK("@;",ATSEMICOLON); YY_BREAK /* Pascal tokens */ case 80: YY_RULE_SETUP #line 157 "web.l" TOK("=",PEQ); YY_BREAK case 81: YY_RULE_SETUP #line 158 "web.l" TOK("+",PPLUS); YY_BREAK case 82: YY_RULE_SETUP #line 159 "web.l" TOK("-",PMINUS); YY_BREAK case 83: YY_RULE_SETUP #line 160 "web.l" TOK("*",PSTAR); YY_BREAK case 84: YY_RULE_SETUP #line 161 "web.l" TOK("/",PSLASH); YY_BREAK case 85: YY_RULE_SETUP #line 162 "web.l" TOK(" <> ",PNOTEQ); YY_BREAK case 86: YY_RULE_SETUP #line 163 "web.l" TOK(" < ",PLESS); YY_BREAK case 87: YY_RULE_SETUP #line 164 "web.l" TOK(" > ",PGREATER); YY_BREAK case 88: YY_RULE_SETUP #line 165 "web.l" TOK(" <= ",PLESSEQ); YY_BREAK case 89: YY_RULE_SETUP #line 166 "web.l" TOK(" >= ",PGREATEREQ); YY_BREAK case 90: YY_RULE_SETUP #line 167 "web.l" TOK("[",PSQOPEN); YY_BREAK case 91: YY_RULE_SETUP #line 168 "web.l" TOK("]",PSQCLOSE); YY_BREAK case 92: YY_RULE_SETUP #line 169 "web.l" TOK(":=",PASSIGN); YY_BREAK case 93: YY_RULE_SETUP #line 170 "web.l" TOK(".",PDOT); YY_BREAK case 94: YY_RULE_SETUP #line 171 "web.l" TOK("..",PDOTDOT); YY_BREAK case 95: YY_RULE_SETUP #line 172 "web.l" TOK(",",PCOMMA); YY_BREAK case 96: YY_RULE_SETUP #line 173 "web.l" TOK(";",PSEMICOLON); YY_BREAK case 97: YY_RULE_SETUP #line 174 "web.l" TOK(": ",PCOLON); YY_BREAK case 98: YY_RULE_SETUP #line 175 "web.l" TOK("^",PUP); YY_BREAK /* special coding trick in line 676 of tex.web */ case 99: YY_RULE_SETUP #line 178 "web.l" TOK("type",PTYPE); YY_BREAK /* pascal keywords */ case 100: YY_RULE_SETUP #line 181 "web.l" TOK("mod",PMOD); YY_BREAK case 101: YY_RULE_SETUP #line 182 "web.l" TOK("div",PDIV); YY_BREAK case 102: YY_RULE_SETUP #line 183 "web.l" TOK("nil",PNIL); YY_BREAK case 103: YY_RULE_SETUP #line 184 "web.l" TOK("in",PIN); YY_BREAK case 104: YY_RULE_SETUP #line 185 "web.l" TOK("or",POR); YY_BREAK case 105: YY_RULE_SETUP #line 186 "web.l" TOK("and",PAND); YY_BREAK case 106: YY_RULE_SETUP #line 187 "web.l" TOK("not",PNOT); YY_BREAK case 107: YY_RULE_SETUP #line 188 "web.l" TOK("if",PIF); YY_BREAK case 108: YY_RULE_SETUP #line 189 "web.l" TOK("then",PTHEN); YY_BREAK case 109: YY_RULE_SETUP #line 190 "web.l" TOK("else",PELSE); YY_BREAK case 110: YY_RULE_SETUP #line 191 "web.l" TOK("case",PCASE); YY_BREAK case 111: YY_RULE_SETUP #line 192 "web.l" TOK("of",POF); YY_BREAK case 112: YY_RULE_SETUP #line 193 "web.l" TOK("others",POTHERS); YY_BREAK case 113: YY_RULE_SETUP #line 194 "web.l" TOK("forward",PFORWARD); YY_BREAK case 114: YY_RULE_SETUP #line 195 "web.l" TOK("repeat",PREPEAT); YY_BREAK case 115: YY_RULE_SETUP #line 196 "web.l" TOK("until",PUNTIL); YY_BREAK case 116: YY_RULE_SETUP #line 197 "web.l" TOK("while",PWHILE); YY_BREAK case 117: YY_RULE_SETUP #line 198 "web.l" TOK("do",PDO); YY_BREAK case 118: YY_RULE_SETUP #line 199 "web.l" TOK("for",PFOR); YY_BREAK case 119: YY_RULE_SETUP #line 200 "web.l" TOK("to",PTO); YY_BREAK case 120: YY_RULE_SETUP #line 201 "web.l" TOK("downto",PDOWNTO); YY_BREAK case 121: YY_RULE_SETUP #line 202 "web.l" TOK("begin",PBEGIN); YY_BREAK case 122: YY_RULE_SETUP #line 203 "web.l" TOK("end",PEND); YY_BREAK case 123: YY_RULE_SETUP #line 204 "web.l" TOK("with",PWITH); YY_BREAK case 124: YY_RULE_SETUP #line 205 "web.l" TOK("goto",PGOTO); YY_BREAK case 125: YY_RULE_SETUP #line 206 "web.l" TOK("const",PCONST); YY_BREAK case 126: YY_RULE_SETUP #line 207 "web.l" TOK("var",PVAR); YY_BREAK case 127: YY_RULE_SETUP #line 208 "web.l" TOK("array",PARRAY); YY_BREAK case 128: YY_RULE_SETUP #line 209 "web.l" TOK("record",PRECORD); YY_BREAK case 129: YY_RULE_SETUP #line 210 "web.l" TOK("set",PSET); YY_BREAK case 130: YY_RULE_SETUP #line 211 "web.l" TOK("file",PFILE); YY_BREAK case 131: YY_RULE_SETUP #line 212 "web.l" TOK("function",PFUNCTION); YY_BREAK case 132: YY_RULE_SETUP #line 213 "web.l" TOK("procedure",PPROCEDURE); YY_BREAK case 133: YY_RULE_SETUP #line 214 "web.l" TOK("label",PLABEL); YY_BREAK case 134: YY_RULE_SETUP #line 215 "web.l" TOK("packed",PPACKED); YY_BREAK case 135: YY_RULE_SETUP #line 216 "web.l" TOK("program",PPROGRAM); YY_BREAK case 136: YY_RULE_SETUP #line 217 "web.l" TOK("char",PTYPECHAR); YY_BREAK case 137: YY_RULE_SETUP #line 218 "web.l" TOK("integer",PTYPEINT); YY_BREAK case 138: YY_RULE_SETUP #line 219 "web.l" TOK("real",PTYPEREAL); YY_BREAK case 139: YY_RULE_SETUP #line 220 "web.l" TOK("boolean",PTYPEBOOL); YY_BREAK case 140: YY_RULE_SETUP #line 222 "web.l" TOK("endcases",PEND); YY_BREAK case 141: YY_RULE_SETUP #line 223 "web.l" TOK("othercases",POTHERS); YY_BREAK case 142: YY_RULE_SETUP #line 224 "web.l" TOK("type",PTYPE); YY_BREAK case 143: YY_RULE_SETUP #line 225 "web.l" TOK("final_end",PEXIT); YY_BREAK case 144: YY_RULE_SETUP #line 227 "web.l" TOK_RETURN; YY_BREAK case 145: YY_RULE_SETUP #line 229 "web.l" TOK("debug",WDEBUG); YY_BREAK case 146: YY_RULE_SETUP #line 230 "web.l" TOK("debug",WGUBED); YY_BREAK case 147: YY_RULE_SETUP #line 231 "web.l" TOK("stat",WSTAT); YY_BREAK case 148: YY_RULE_SETUP #line 232 "web.l" TOK("tats",WTATS); YY_BREAK case 149: YY_RULE_SETUP #line 233 "web.l" TOK("init",WINIT); YY_BREAK case 150: YY_RULE_SETUP #line 234 "web.l" TOK("tini",WTINI); YY_BREAK case 151: YY_RULE_SETUP #line 236 "web.l" SYMBOL; YY_BREAK case 152: YY_RULE_SETUP #line 237 "web.l" TOK(COPY,CHAR); /* single character string */ YY_BREAK case 153: YY_RULE_SETUP #line 238 "web.l" WWSTRING; /* multiple character string */ YY_BREAK case 154: YY_RULE_SETUP #line 239 "web.l" TOK(COPY,PCHAR); YY_BREAK case 155: YY_RULE_SETUP #line 240 "web.l" TOK(COPY,PSTRING); YY_BREAK case 156: YY_RULE_SETUP #line 241 "web.l" TOK(COPY,PINTEGER); YY_BREAK case 157: YY_RULE_SETUP #line 242 "web.l" TOK(COPY,PREAL); YY_BREAK case 158: /* rule 158 can match eol */ YY_RULE_SETUP #line 244 "web.l" TOK(COPY,INDENT); YY_BREAK case 159: /* rule 159 can match eol */ YY_RULE_SETUP #line 245 "web.l" ; /* in Pascal mode we ignore spaces */ YY_BREAK /* anything that gets to this line is an illegal character */ case 160: YY_RULE_SETUP #line 256 "web.l" { ERROR("Illegal %c (0x%02x) in line %d mode %d", wwtext[0],wwtext[0],wwlineno, YY_START);} YY_BREAK case 161: YY_RULE_SETUP #line 260 "web.l" ECHO; YY_BREAK #line 2175 "web.lex.c" case YY_STATE_EOF(DEFINITION): case YY_STATE_EOF(FORMAT): case YY_STATE_EOF(NAME): yyterminate(); case YY_END_OF_BUFFER: { /* Amount of text matched not including the EOB char. */ int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1; /* Undo the effects of YY_DO_BEFORE_ACTION. */ *yy_cp = (yy_hold_char); YY_RESTORE_YY_MORE_OFFSET if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW ) { /* We're scanning a new file or input source. It's * possible that this happened because the user * just pointed wwin at a new source and called * wwlex(). If so, then we have to assure * consistency between YY_CURRENT_BUFFER and our * globals. Here is the right place to do so, because * this is the first action (other than possibly a * back-up) that will match for the new input source. */ (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; YY_CURRENT_BUFFER_LVALUE->yy_input_file = wwin; YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL; } /* Note that here we test for yy_c_buf_p "<=" to the position * of the first EOB in the buffer, since yy_c_buf_p will * already have been incremented past the NUL character * (since all states make transitions on EOB to the * end-of-buffer state). Contrast this with the test * in input(). */ if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) { /* This was really a NUL. */ yy_state_type yy_next_state; (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text; yy_current_state = yy_get_previous_state( ); /* Okay, we're now positioned to make the NUL * transition. We couldn't have * yy_get_previous_state() go ahead and do it * for us because it doesn't know how to deal * with the possibility of jamming (and we don't * want to build jamming into it because then it * will run more slowly). */ yy_next_state = yy_try_NUL_trans( yy_current_state ); yy_bp = (yytext_ptr) + YY_MORE_ADJ; if ( yy_next_state ) { /* Consume the NUL. */ yy_cp = ++(yy_c_buf_p); yy_current_state = yy_next_state; goto yy_match; } else { /* %% [14.0] code to do back-up for compressed tables and set up yy_cp goes here */ yy_cp = (yy_last_accepting_cpos); yy_current_state = (yy_last_accepting_state); goto yy_find_action; } } else switch ( yy_get_next_buffer( ) ) { case EOB_ACT_END_OF_FILE: { (yy_did_buffer_switch_on_eof) = 0; if ( wwwrap( ) ) { /* Note: because we've taken care in * yy_get_next_buffer() to have set up * wwtext, we can now set up * yy_c_buf_p so that if some total * hoser (like flex itself) wants to * call the scanner after we return the * YY_NULL, it'll still work - another * YY_NULL will get returned. */ (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ; yy_act = YY_STATE_EOF(YY_START); goto do_action; } else { if ( ! (yy_did_buffer_switch_on_eof) ) YY_NEW_FILE; } break; } case EOB_ACT_CONTINUE_SCAN: (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text; yy_current_state = yy_get_previous_state( ); yy_cp = (yy_c_buf_p); yy_bp = (yytext_ptr) + YY_MORE_ADJ; goto yy_match; case EOB_ACT_LAST_MATCH: (yy_c_buf_p) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)]; yy_current_state = yy_get_previous_state( ); yy_cp = (yy_c_buf_p); yy_bp = (yytext_ptr) + YY_MORE_ADJ; goto yy_find_action; } break; } default: YY_FATAL_ERROR( "fatal flex scanner internal error--no action found" ); } /* end of action switch */ } /* end of scanning one token */ } /* end of wwlex */ /* %ok-for-header */ /* %if-c++-only */ /* %not-for-header */ /* %ok-for-header */ /* %endif */ /* yy_get_next_buffer - try to read in a new buffer * * Returns a code representing an action: * EOB_ACT_LAST_MATCH - * EOB_ACT_CONTINUE_SCAN - continue scanning from current position * EOB_ACT_END_OF_FILE - end of file */ /* %if-c-only */ static int yy_get_next_buffer (void) /* %endif */ /* %if-c++-only */ /* %endif */ { register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; register char *source = (yytext_ptr); register int number_to_move, i; int ret_val; if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] ) YY_FATAL_ERROR( "fatal flex scanner internal error--end of buffer missed" ); if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 ) { /* Don't try to fill the buffer, so this is an EOF. */ if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 ) { /* We matched a single character, the EOB, so * treat this as a final EOF. */ return EOB_ACT_END_OF_FILE; } else { /* We matched some text prior to the EOB, first * process it. */ return EOB_ACT_LAST_MATCH; } } /* Try to read more data. */ /* First move last chars to start of buffer. */ number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1; for ( i = 0; i < number_to_move; ++i ) *(dest++) = *(source++); if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING ) /* don't do the read, it's not guaranteed to return an EOF, * just force an EOF */ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0; else { yy_size_t num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; while ( num_to_read <= 0 ) { /* Not enough room in the buffer - grow it. */ /* just a shorter name for the current buffer */ YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE; int yy_c_buf_p_offset = (int) ((yy_c_buf_p) - b->yy_ch_buf); if ( b->yy_is_our_buffer ) { yy_size_t new_size = b->yy_buf_size * 2; if ( new_size <= 0 ) b->yy_buf_size += b->yy_buf_size / 8; else b->yy_buf_size *= 2; b->yy_ch_buf = (char *) /* Include room in for 2 EOB chars. */ wwrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ); } else /* Can't grow it, we don't own it. */ b->yy_ch_buf = 0; if ( ! b->yy_ch_buf ) YY_FATAL_ERROR( "fatal error - scanner input buffer overflow" ); (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset]; num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; } if ( num_to_read > YY_READ_BUF_SIZE ) num_to_read = YY_READ_BUF_SIZE; /* Read in more data. */ YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), (yy_n_chars), num_to_read ); YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); } if ( (yy_n_chars) == 0 ) { if ( number_to_move == YY_MORE_ADJ ) { ret_val = EOB_ACT_END_OF_FILE; wwrestart(wwin ); } else { ret_val = EOB_ACT_LAST_MATCH; YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_EOF_PENDING; } } else ret_val = EOB_ACT_CONTINUE_SCAN; if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) { /* Extend the array by 50%, plus the number we really need. */ yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1); YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) wwrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ); if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" ); } (yy_n_chars) += number_to_move; YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR; YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR; (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0]; return ret_val; } /* yy_get_previous_state - get the state just before the EOB char was reached */ /* %if-c-only */ /* %not-for-header */ static yy_state_type yy_get_previous_state (void) /* %endif */ /* %if-c++-only */ /* %endif */ { register yy_state_type yy_current_state; register char *yy_cp; /* %% [15.0] code to get the start state into yy_current_state goes here */ yy_current_state = (yy_start); yy_current_state += YY_AT_BOL(); for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp ) { /* %% [16.0] code to find the next state goes here */ register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1); if ( yy_accept[yy_current_state] ) { (yy_last_accepting_state) = yy_current_state; (yy_last_accepting_cpos) = yy_cp; } while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; if ( yy_current_state >= 425 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; } return yy_current_state; } /* yy_try_NUL_trans - try to make a transition on the NUL character * * synopsis * next_state = yy_try_NUL_trans( current_state ); */ /* %if-c-only */ static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state ) /* %endif */ /* %if-c++-only */ /* %endif */ { register int yy_is_jam; /* %% [17.0] code to find the next state, and perhaps do backing up, goes here */ register char *yy_cp = (yy_c_buf_p); register YY_CHAR yy_c = 1; if ( yy_accept[yy_current_state] ) { (yy_last_accepting_state) = yy_current_state; (yy_last_accepting_cpos) = yy_cp; } while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; if ( yy_current_state >= 425 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; yy_is_jam = (yy_current_state == 424); return yy_is_jam ? 0 : yy_current_state; } /* %if-c-only */ /* %endif */ /* %if-c-only */ #ifndef YY_NO_INPUT #ifdef __cplusplus static int yyinput (void) #else static int input (void) #endif /* %endif */ /* %if-c++-only */ /* %endif */ { int c; *(yy_c_buf_p) = (yy_hold_char); if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR ) { /* yy_c_buf_p now points to the character we want to return. * If this occurs *before* the EOB characters, then it's a * valid NUL; if not, then we've hit the end of the buffer. */ if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) /* This was really a NUL. */ *(yy_c_buf_p) = '\0'; else { /* need more input */ yy_size_t offset = (yy_c_buf_p) - (yytext_ptr); ++(yy_c_buf_p); switch ( yy_get_next_buffer( ) ) { case EOB_ACT_LAST_MATCH: /* This happens because yy_g_n_b() * sees that we've accumulated a * token and flags that we need to * try matching the token before * proceeding. But for input(), * there's no matching to consider. * So convert the EOB_ACT_LAST_MATCH * to EOB_ACT_END_OF_FILE. */ /* Reset buffer status. */ wwrestart(wwin ); /*FALLTHROUGH*/ case EOB_ACT_END_OF_FILE: { if ( wwwrap( ) ) return EOF; if ( ! (yy_did_buffer_switch_on_eof) ) YY_NEW_FILE; #ifdef __cplusplus return yyinput(); #else return input(); #endif } case EOB_ACT_CONTINUE_SCAN: (yy_c_buf_p) = (yytext_ptr) + offset; break; } } } c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */ *(yy_c_buf_p) = '\0'; /* preserve wwtext */ (yy_hold_char) = *++(yy_c_buf_p); /* %% [19.0] update BOL and wwlineno */ YY_CURRENT_BUFFER_LVALUE->yy_at_bol = (c == '\n'); if ( YY_CURRENT_BUFFER_LVALUE->yy_at_bol ) wwlineno++; ; return c; } /* %if-c-only */ #endif /* ifndef YY_NO_INPUT */ /* %endif */ /** Immediately switch to a different input stream. * @param input_file A readable stream. * * @note This function does not reset the start condition to @c INITIAL . */ /* %if-c-only */ void wwrestart (FILE * input_file ) /* %endif */ /* %if-c++-only */ /* %endif */ { if ( ! YY_CURRENT_BUFFER ){ wwensure_buffer_stack (); YY_CURRENT_BUFFER_LVALUE = ww_create_buffer(wwin,YY_BUF_SIZE ); } ww_init_buffer(YY_CURRENT_BUFFER,input_file ); ww_load_buffer_state( ); } /** Switch to a different input buffer. * @param new_buffer The new input buffer. * */ /* %if-c-only */ void ww_switch_to_buffer (YY_BUFFER_STATE new_buffer ) /* %endif */ /* %if-c++-only */ /* %endif */ { /* TODO. We should be able to replace this entire function body * with * wwpop_buffer_state(); * wwpush_buffer_state(new_buffer); */ wwensure_buffer_stack (); if ( YY_CURRENT_BUFFER == new_buffer ) return; if ( YY_CURRENT_BUFFER ) { /* Flush out information for old buffer. */ *(yy_c_buf_p) = (yy_hold_char); YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); } YY_CURRENT_BUFFER_LVALUE = new_buffer; ww_load_buffer_state( ); /* We don't actually know whether we did this switch during * EOF (wwwrap()) processing, but the only time this flag * is looked at is after wwwrap() is called, so it's safe * to go ahead and always set it. */ (yy_did_buffer_switch_on_eof) = 1; } /* %if-c-only */ static void ww_load_buffer_state (void) /* %endif */ /* %if-c++-only */ /* %endif */ { (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos; wwin = YY_CURRENT_BUFFER_LVALUE->yy_input_file; (yy_hold_char) = *(yy_c_buf_p); } /** Allocate and initialize an input buffer state. * @param file A readable stream. * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE. * * @return the allocated buffer state. */ /* %if-c-only */ YY_BUFFER_STATE ww_create_buffer (FILE * file, int size ) /* %endif */ /* %if-c++-only */ /* %endif */ { YY_BUFFER_STATE b; b = (YY_BUFFER_STATE) wwalloc(sizeof( struct yy_buffer_state ) ); if ( ! b ) YY_FATAL_ERROR( "out of dynamic memory in ww_create_buffer()" ); b->yy_buf_size = size; /* yy_ch_buf has to be 2 characters longer than the size given because * we need to put in 2 end-of-buffer characters. */ b->yy_ch_buf = (char *) wwalloc(b->yy_buf_size + 2 ); if ( ! b->yy_ch_buf ) YY_FATAL_ERROR( "out of dynamic memory in ww_create_buffer()" ); b->yy_is_our_buffer = 1; ww_init_buffer(b,file ); return b; } /** Destroy the buffer. * @param b a buffer created with ww_create_buffer() * */ /* %if-c-only */ void ww_delete_buffer (YY_BUFFER_STATE b ) /* %endif */ /* %if-c++-only */ /* %endif */ { if ( ! b ) return; if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */ YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0; if ( b->yy_is_our_buffer ) wwfree((void *) b->yy_ch_buf ); wwfree((void *) b ); } /* Initializes or reinitializes a buffer. * This function is sometimes called more than once on the same buffer, * such as during a wwrestart() or at EOF. */ /* %if-c-only */ static void ww_init_buffer (YY_BUFFER_STATE b, FILE * file ) /* %endif */ /* %if-c++-only */ /* %endif */ { int oerrno = errno; ww_flush_buffer(b ); b->yy_input_file = file; b->yy_fill_buffer = 1; /* If b is the current buffer, then ww_init_buffer was _probably_ * called from wwrestart() or through yy_get_next_buffer. * In that case, we don't want to reset the lineno or column. */ if (b != YY_CURRENT_BUFFER){ b->yy_bs_lineno = 1; b->yy_bs_column = 0; } /* %if-c-only */ b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0; /* %endif */ /* %if-c++-only */ /* %endif */ errno = oerrno; } /** Discard all buffered characters. On the next scan, YY_INPUT will be called. * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. * */ /* %if-c-only */ void ww_flush_buffer (YY_BUFFER_STATE b ) /* %endif */ /* %if-c++-only */ /* %endif */ { if ( ! b ) return; b->yy_n_chars = 0; /* We always need two end-of-buffer characters. The first causes * a transition to the end-of-buffer state. The second causes * a jam in that state. */ b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR; b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR; b->yy_buf_pos = &b->yy_ch_buf[0]; b->yy_at_bol = 1; b->yy_buffer_status = YY_BUFFER_NEW; if ( b == YY_CURRENT_BUFFER ) ww_load_buffer_state( ); } /* %if-c-or-c++ */ /** Pushes the new state onto the stack. The new state becomes * the current state. This function will allocate the stack * if necessary. * @param new_buffer The new state. * */ /* %if-c-only */ void wwpush_buffer_state (YY_BUFFER_STATE new_buffer ) /* %endif */ /* %if-c++-only */ /* %endif */ { if (new_buffer == NULL) return; wwensure_buffer_stack(); /* This block is copied from ww_switch_to_buffer. */ if ( YY_CURRENT_BUFFER ) { /* Flush out information for old buffer. */ *(yy_c_buf_p) = (yy_hold_char); YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); } /* Only push if top exists. Otherwise, replace top. */ if (YY_CURRENT_BUFFER) (yy_buffer_stack_top)++; YY_CURRENT_BUFFER_LVALUE = new_buffer; /* copied from ww_switch_to_buffer. */ ww_load_buffer_state( ); (yy_did_buffer_switch_on_eof) = 1; } /* %endif */ /* %if-c-or-c++ */ /** Removes and deletes the top of the stack, if present. * The next element becomes the new top. * */ /* %if-c-only */ void wwpop_buffer_state (void) /* %endif */ /* %if-c++-only */ /* %endif */ { if (!YY_CURRENT_BUFFER) return; ww_delete_buffer(YY_CURRENT_BUFFER ); YY_CURRENT_BUFFER_LVALUE = NULL; if ((yy_buffer_stack_top) > 0) --(yy_buffer_stack_top); if (YY_CURRENT_BUFFER) { ww_load_buffer_state( ); (yy_did_buffer_switch_on_eof) = 1; } } /* %endif */ /* %if-c-or-c++ */ /* Allocates the stack if it does not exist. * Guarantees space for at least one push. */ /* %if-c-only */ static void wwensure_buffer_stack (void) /* %endif */ /* %if-c++-only */ /* %endif */ { yy_size_t num_to_alloc; if (!(yy_buffer_stack)) { /* First allocation is just for 2 elements, since we don't know if this * scanner will even need a stack. We use 2 instead of 1 to avoid an * immediate realloc on the next call. */ num_to_alloc = 1; (yy_buffer_stack) = (struct yy_buffer_state**)wwalloc (num_to_alloc * sizeof(struct yy_buffer_state*) ); if ( ! (yy_buffer_stack) ) YY_FATAL_ERROR( "out of dynamic memory in wwensure_buffer_stack()" ); memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*)); (yy_buffer_stack_max) = num_to_alloc; (yy_buffer_stack_top) = 0; return; } if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){ /* Increase the buffer to prepare for a possible push. */ int grow_size = 8 /* arbitrary grow size */; num_to_alloc = (yy_buffer_stack_max) + grow_size; (yy_buffer_stack) = (struct yy_buffer_state**)wwrealloc ((yy_buffer_stack), num_to_alloc * sizeof(struct yy_buffer_state*) ); if ( ! (yy_buffer_stack) ) YY_FATAL_ERROR( "out of dynamic memory in wwensure_buffer_stack()" ); /* zero only the new slots.*/ memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*)); (yy_buffer_stack_max) = num_to_alloc; } } /* %endif */ /* %if-c-only */ /** Setup the input buffer state to scan directly from a user-specified character buffer. * @param base the character buffer * @param size the size in bytes of the character buffer * * @return the newly allocated buffer state object. */ YY_BUFFER_STATE ww_scan_buffer (char * base, yy_size_t size ) { YY_BUFFER_STATE b; if ( size < 2 || base[size-2] != YY_END_OF_BUFFER_CHAR || base[size-1] != YY_END_OF_BUFFER_CHAR ) /* They forgot to leave room for the EOB's. */ return 0; b = (YY_BUFFER_STATE) wwalloc(sizeof( struct yy_buffer_state ) ); if ( ! b ) YY_FATAL_ERROR( "out of dynamic memory in ww_scan_buffer()" ); b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */ b->yy_buf_pos = b->yy_ch_buf = base; b->yy_is_our_buffer = 0; b->yy_input_file = 0; b->yy_n_chars = b->yy_buf_size; b->yy_is_interactive = 0; b->yy_at_bol = 1; b->yy_fill_buffer = 0; b->yy_buffer_status = YY_BUFFER_NEW; ww_switch_to_buffer(b ); return b; } /* %endif */ /* %if-c-only */ /** Setup the input buffer state to scan a string. The next call to wwlex() will * scan from a @e copy of @a str. * @param yystr a NUL-terminated string to scan * * @return the newly allocated buffer state object. * @note If you want to scan bytes that may contain NUL values, then use * ww_scan_bytes() instead. */ YY_BUFFER_STATE ww_scan_string (yyconst char * yystr ) { return ww_scan_bytes(yystr,strlen(yystr) ); } /* %endif */ /* %if-c-only */ /** Setup the input buffer state to scan the given bytes. The next call to wwlex() will * scan from a @e copy of @a bytes. * @param yybytes the byte buffer to scan * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. * * @return the newly allocated buffer state object. */ YY_BUFFER_STATE ww_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len ) { YY_BUFFER_STATE b; char *buf; yy_size_t n; int i; /* Get memory for full buffer, including space for trailing EOB's. */ n = _yybytes_len + 2; buf = (char *) wwalloc(n ); if ( ! buf ) YY_FATAL_ERROR( "out of dynamic memory in ww_scan_bytes()" ); for ( i = 0; i < _yybytes_len; ++i ) buf[i] = yybytes[i]; buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR; b = ww_scan_buffer(buf,n ); if ( ! b ) YY_FATAL_ERROR( "bad buffer in ww_scan_bytes()" ); /* It's okay to grow etc. this buffer, and we should throw it * away when we're done. */ b->yy_is_our_buffer = 1; return b; } /* %endif */ #ifndef YY_EXIT_FAILURE #define YY_EXIT_FAILURE 2 #endif /* %if-c-only */ static void yy_fatal_error (yyconst char* msg ) { (void) fprintf( stderr, "%s\n", msg ); exit( YY_EXIT_FAILURE ); } /* %endif */ /* %if-c++-only */ /* %endif */ /* Redefine yyless() so it works in section 3 code. */ #undef yyless #define yyless(n) \ do \ { \ /* Undo effects of setting up wwtext. */ \ int yyless_macro_arg = (n); \ YY_LESS_LINENO(yyless_macro_arg);\ wwtext[wwleng] = (yy_hold_char); \ (yy_c_buf_p) = wwtext + yyless_macro_arg; \ (yy_hold_char) = *(yy_c_buf_p); \ *(yy_c_buf_p) = '\0'; \ wwleng = yyless_macro_arg; \ } \ while ( 0 ) /* Accessor methods (get/set functions) to struct members. */ /* %if-c-only */ /* %if-reentrant */ /* %endif */ /** Get the current line number. * */ int wwget_lineno (void) { return wwlineno; } /** Get the input stream. * */ FILE *wwget_in (void) { return wwin; } /** Get the output stream. * */ FILE *wwget_out (void) { return wwout; } /** Get the length of the current token. * */ yy_size_t wwget_leng (void) { return wwleng; } /** Get the current token. * */ char *wwget_text (void) { return wwtext; } /* %if-reentrant */ /* %endif */ /** Set the current line number. * @param line_number * */ void wwset_lineno (int line_number ) { wwlineno = line_number; } /** Set the input stream. This does not discard the current * input buffer. * @param in_str A readable stream. * * @see ww_switch_to_buffer */ void wwset_in (FILE * in_str ) { wwin = in_str ; } void wwset_out (FILE * out_str ) { wwout = out_str ; } int wwget_debug (void) { return ww_flex_debug; } void wwset_debug (int bdebug ) { ww_flex_debug = bdebug ; } /* %endif */ /* %if-reentrant */ /* %if-bison-bridge */ /* %endif */ /* %endif if-c-only */ /* %if-c-only */ static int yy_init_globals (void) { /* Initialization is the same as for the non-reentrant scanner. * This function is called from wwlex_destroy(), so don't allocate here. */ /* We do not touch wwlineno unless the option is enabled. */ wwlineno = 1; (yy_buffer_stack) = 0; (yy_buffer_stack_top) = 0; (yy_buffer_stack_max) = 0; (yy_c_buf_p) = (char *) 0; (yy_init) = 0; (yy_start) = 0; /* Defined in main.c */ #ifdef YY_STDINIT wwin = stdin; wwout = stdout; #else wwin = (FILE *) 0; wwout = (FILE *) 0; #endif /* For future reference: Set errno on error, since we are called by * wwlex_init() */ return 0; } /* %endif */ /* %if-c-only SNIP! this currently causes conflicts with the c++ scanner */ /* wwlex_destroy is for both reentrant and non-reentrant scanners. */ int wwlex_destroy (void) { /* Pop the buffer stack, destroying each element. */ while(YY_CURRENT_BUFFER){ ww_delete_buffer(YY_CURRENT_BUFFER ); YY_CURRENT_BUFFER_LVALUE = NULL; wwpop_buffer_state(); } /* Destroy the stack itself. */ wwfree((yy_buffer_stack) ); (yy_buffer_stack) = NULL; /* Reset the globals. This is important in a non-reentrant scanner so the next time * wwlex() is called, initialization will occur. */ yy_init_globals( ); /* %if-reentrant */ /* %endif */ return 0; } /* %endif */ /* * Internal utility routines. */ #ifndef yytext_ptr static void yy_flex_strncpy (char* s1, yyconst char * s2, int n ) { register int i; for ( i = 0; i < n; ++i ) s1[i] = s2[i]; } #endif #ifdef YY_NEED_STRLEN static int yy_flex_strlen (yyconst char * s ) { register int n; for ( n = 0; s[n]; ++n ) ; return n; } #endif void *wwalloc (yy_size_t size ) { return (void *) malloc( size ); } void *wwrealloc (void * ptr, yy_size_t size ) { /* The cast to (char *) in the following accommodates both * implementations that use char* generic pointers, and those * that use void* generic pointers. It works with the latter * because both ANSI C and C++ allow castless assignment from * any pointer type to void*, and deal with argument conversions * as though doing an assignment. */ return (void *) realloc( (char *) ptr, size ); } void wwfree (void * ptr ) { free( (char *) ptr ); /* see wwrealloc() for (char *) cast */ } /* %if-tables-serialization definitions */ /* %define-yytables The name for this specific scanner's tables. */ #define YYTABLES_NAME "yytables" /* %endif */ /* %ok-for-header */ #line 260 "web.l"