## modules/er/lex.er_yy.c

/* [<][>][^][v][top][bottom][index][help] */

## FUNCTIONS

This source file includes following functions.

1. YY_PROTO
2. YY_PROTO
3. YY_SC_TO_UI
4. YY_STATE_EOF
5. yyless
6. unput
7. yy_set_interactive
8. yy_set_bol
9. YY_AT_BOL
10. yywrap
11. yymore
12. lexcleancurbuf
13. YY_INPUT
14. yyterminate
15. YY_FATAL_ERROR
16. yy_get_next_buffer
17. yy_get_previous_state
18. yy_try_NUL_trans
19. yyunput
20. yyinput
21. yyrestart
22. yy_switch_to_buffer
23. yy_load_buffer_state
24. yy_create_buffer
25. yy_delete_buffer
26. yy_init_buffer
27. yy_flush_buffer
28. yy_scan_buffer
29. yy_scan_string
30. yy_scan_bytes
31. yy_push_state
32. yy_pop_state
33. yy_top_state
34. yy_fatal_error
35. yyless
36. yy_flex_strncpy
37. yy_flex_strlen
38. yy_flex_alloc
39. yy_flex_realloc
40. yy_flex_free
41. main

       1 #define yy_create_buffer er_yy_create_buffer
       2 #define yy_delete_buffer er_yy_delete_buffer
       3 #define yy_scan_buffer er_yy_scan_buffer
       4 #define yy_scan_string er_yy_scan_string
       5 #define yy_scan_bytes er_yy_scan_bytes
       6 #define yy_flex_debug er_yy_flex_debug
       7 #define yy_init_buffer er_yy_init_buffer
       8 #define yy_flush_buffer er_yy_flush_buffer
       9 #define yy_load_buffer_state er_yy_load_buffer_state
      10 #define yy_switch_to_buffer er_yy_switch_to_buffer
      11 #define yyin er_yyin
      12 #define yyleng er_yyleng
      13 #define yylex er_yylex
      14 #define yyout er_yyout
      15 #define yyrestart er_yyrestart
      16 #define yytext er_yytext
      17
      18 /* A lexical scanner generated by flex */
      19
      20 /* Scanner skeleton version:
      21  * $Header: /ncc/cvsroot/ncc/RIP/modules/er/lex.er_yy.c,v 1.3 2000/12/14 15:38:38 marek Exp $
      22  */
      23
      24 #define FLEX_SCANNER
      25 #define YY_FLEX_MAJOR_VERSION 2
      26 #define YY_FLEX_MINOR_VERSION 5
      27
      28 #include <stdio.h>
      29
      30
      31 /* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */
      32 #ifdef c_plusplus
      33 #ifndef __cplusplus
      34 #define __cplusplus
      35 #endif
      36 #endif
      37
      38
      39 #ifdef __cplusplus
      40
      41 #include <stdlib.h>
      42 #include <unistd.h>
      43
      44 /* Use prototypes in function declarations. */
      45 #define YY_USE_PROTOS
      46
      47 /* The "const" storage-class-modifier is valid. */
      48 #define YY_USE_CONST
      49
      50 #else   /* ! __cplusplus */
      51
      52 #if __STDC__
      53
      54 #define YY_USE_PROTOS
      55 #define YY_USE_CONST
      56
      57 #endif  /* __STDC__ */
      58 #endif  /* ! __cplusplus */
      59
      60 #ifdef __TURBOC__
      61  #pragma warn -rch
      62  #pragma warn -use
      63 #include <io.h>
      64 #include <stdlib.h>
      65 #define YY_USE_CONST
      66 #define YY_USE_PROTOS
      67 #endif
      68
      69 #ifdef YY_USE_CONST
      70 #define yyconst const
      71 #else
      72 #define yyconst
      73 #endif
      74
      75
      76 #ifdef YY_USE_PROTOS
      77 #define YY_PROTO(proto) proto
         /* [<][>][^][v][top][bottom][index][help] */
      78 #else
      79 #define YY_PROTO(proto) ()
         /* [<][>][^][v][top][bottom][index][help] */
      80 #endif
      81
      82 /* Returned upon end-of-file. */
      83 #define YY_NULL 0
      84
      85 /* Promotes a possibly negative, possibly signed char to an unsigned
      86  * integer for use as an array index.  If the signed char is negative,
      87  * we want to instead treat it as an 8-bit unsigned char, hence the
      88  * double cast.
      89  */
      90 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
         /* [<][>][^][v][top][bottom][index][help] */
      91
      92 /* Enter a start condition.  This macro really ought to take a parameter,
      93  * but we do it the disgusting crufty way forced on us by the ()-less
      94  * definition of BEGIN.
      95  */
      96 #define BEGIN yy_start = 1 + 2 *
      97
      98 /* Translate the current start state into a value that can be later handed
      99  * to BEGIN to return to the state.  The YYSTATE alias is for lex
     100  * compatibility.
     101  */
     102 #define YY_START ((yy_start - 1) / 2)
     103 #define YYSTATE YY_START
     104
     105 /* Action number for EOF rule of a given start state. */
     106 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
         /* [<][>][^][v][top][bottom][index][help] */
     107
     108 /* Special action meaning "start processing a new file". */
     109 #define YY_NEW_FILE yyrestart( yyin )
     110
     111 #define YY_END_OF_BUFFER_CHAR 0
     112
     113 /* Size of default input buffer. */
     114 #define YY_BUF_SIZE 16384
     115
     116 typedef struct yy_buffer_state *YY_BUFFER_STATE;
     117
     118 extern int yyleng;
     119 extern FILE *yyin, *yyout;
     120
     121 #define EOB_ACT_CONTINUE_SCAN 0
     122 #define EOB_ACT_END_OF_FILE 1
     123 #define EOB_ACT_LAST_MATCH 2
     124
     125 /* The funky do-while in the following #define is used to turn the definition
     126  * int a single C statement (which needs a semi-colon terminator).  This
     127  * avoids problems with code like:
     128  *
     129  *      if ( condition_holds )
     130  *              yyless( 5 );
     131  *      else
     132  *              do_something_else();
     133  *
     134  * Prior to using the do-while the compiler would get upset at the
     135  * "else" because it interpreted the "if" statement as being all
     136  * done when it reached the ';' after the yyless() call.
     137  */
     138
     139 /* Return all but the first 'n' matched characters back to the input stream. */
     140
     141 #define yyless(n) \
         /* [<][>][^][v][top][bottom][index][help] */
     142         do \
     143                 { \
     144                 /* Undo effects of setting up yytext. */ \
     145                 *yy_cp = yy_hold_char; \
     146                 YY_RESTORE_YY_MORE_OFFSET \
     147                 yy_c_buf_p = yy_cp = yy_bp + n - YY_MORE_ADJ; \
     148                 YY_DO_BEFORE_ACTION; /* set up yytext again */ \
     149                 } \
     150         while ( 0 )
     151
     152 #define unput(c) yyunput( c, yytext_ptr )
         /* [<][>][^][v][top][bottom][index][help] */
     153
     154 /* The following is because we cannot portably get our hands on size_t
     155  * (without autoconf's help, which isn't available because we want
     156  * flex-generated scanners to compile on their own).
     157  */
     158 typedef unsigned int yy_size_t;
     159
     160
     161 struct yy_buffer_state
     162         {
     163         FILE *yy_input_file;
     164
     165         char *yy_ch_buf;                /* input buffer */
     166         char *yy_buf_pos;               /* current position in input buffer */
     167
     168         /* Size of input buffer in bytes, not including room for EOB
     169          * characters.
     170          */
     171         yy_size_t yy_buf_size;
     172
     173         /* Number of characters read into yy_ch_buf, not including EOB
     174          * characters.
     175          */
     176         int yy_n_chars;
     177
     178         /* Whether we "own" the buffer - i.e., we know we created it,
     179          * and can realloc() it to grow it, and should free() it to
     180          * delete it.
     181          */
     182         int yy_is_our_buffer;
     183
     184         /* Whether this is an "interactive" input source; if so, and
     185          * if we're using stdio for input, then we want to use getc()
     186          * instead of fread(), to make sure we stop fetching input after
     187          * each newline.
     188          */
     189         int yy_is_interactive;
     190
     191         /* Whether we're considered to be at the beginning of a line.
     192          * If so, '^' rules will be active on the next match, otherwise
     193          * not.
     194          */
     195         int yy_at_bol;
     196
     197         /* Whether to try to fill the input buffer when we reach the
     198          * end of it.
     199          */
     200         int yy_fill_buffer;
     201
     202         int yy_buffer_status;
     203 #define YY_BUFFER_NEW 0
     204 #define YY_BUFFER_NORMAL 1
     205         /* When an EOF's been seen but there's still some text to process
     206          * then we mark the buffer as YY_EOF_PENDING, to indicate that we
     207          * shouldn't try reading from the input source any more.  We might
     208          * still have a bunch of tokens to match, though, because of
     209          * possible backing-up.
     210          *
     211          * When we actually see the EOF, we change the status to "new"
     212          * (via yyrestart()), so that the user can continue scanning by
     213          * just pointing yyin at a new input file.
     214          */
     215 #define YY_BUFFER_EOF_PENDING 2
     216         };
     217
     218 static YY_BUFFER_STATE yy_current_buffer = 0;
     219
     220 /* We provide macros for accessing buffer states in case in the
     221  * future we want to put the buffer states in a more general
     222  * "scanner state".
     223  */
     224 #define YY_CURRENT_BUFFER yy_current_buffer
     225
     226
     227 /* yy_hold_char holds the character lost when yytext is formed. */
     228 static char yy_hold_char;
     229
     230 static int yy_n_chars;          /* number of characters read into yy_ch_buf */
     231
     232
     233 int yyleng;
     234
     235 /* Points to current character in buffer. */
     236 static char *yy_c_buf_p = (char *) 0;
     237 static int yy_init = 1;         /* whether we need to initialize */
     238 static int yy_start = 0;        /* start state number */
     239
     240 /* Flag which is used to allow yywrap()'s to do buffer switches
     241  * instead of setting up a fresh yyin.  A bit of a hack ...
     242  */
     243 static int yy_did_buffer_switch_on_eof;
     244
     245 void yyrestart YY_PROTO(( FILE *input_file ));
     246
     247 void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
     248 void yy_load_buffer_state YY_PROTO(( void ));
     249 YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
     250 void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
     251 void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));
     252 void yy_flush_buffer YY_PROTO(( YY_BUFFER_STATE b ));
     253 #define YY_FLUSH_BUFFER yy_flush_buffer( yy_current_buffer )
     254
     255 YY_BUFFER_STATE yy_scan_buffer YY_PROTO(( char *base, yy_size_t size ));
     256 YY_BUFFER_STATE yy_scan_string YY_PROTO(( yyconst char *yy_str ));
     257 YY_BUFFER_STATE yy_scan_bytes YY_PROTO(( yyconst char *bytes, int len ));
     258
     259 static void *yy_flex_alloc YY_PROTO(( yy_size_t ));
     260 static void *yy_flex_realloc YY_PROTO(( void *, yy_size_t ));
     261 static void yy_flex_free YY_PROTO(( void * ));
     262
     263 #define yy_new_buffer yy_create_buffer
     264
     265 #define yy_set_interactive(is_interactive) \
         /* [<][>][^][v][top][bottom][index][help] */
     266         { \
     267         if ( ! yy_current_buffer ) \
     268                 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
     269         yy_current_buffer->yy_is_interactive = is_interactive; \
     270         }
     271
     272 #define yy_set_bol(at_bol) \
         /* [<][>][^][v][top][bottom][index][help] */
     273         { \
     274         if ( ! yy_current_buffer ) \
     275                 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
     276         yy_current_buffer->yy_at_bol = at_bol; \
     277         }
     278
     279 #define YY_AT_BOL() (yy_current_buffer->yy_at_bol)
         /* [<][>][^][v][top][bottom][index][help] */
     280
     281
     282 #define yywrap() 1
         /* [<][>][^][v][top][bottom][index][help] */
     283 #define YY_SKIP_YYWRAP
     284 typedef unsigned char YY_CHAR;
     285 FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
     286 typedef int yy_state_type;
     287 extern char *yytext;
     288 #define yytext_ptr yytext
     289
     290 static yy_state_type yy_get_previous_state YY_PROTO(( void ));
     291 static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
     292 static int yy_get_next_buffer YY_PROTO(( void ));
     293 static void yy_fatal_error YY_PROTO(( yyconst char msg[] ));
     294
     295 /* Done after the current pattern has been matched and before the
     296  * corresponding action - sets up yytext.
     297  */
     298 #define YY_DO_BEFORE_ACTION \
     299         yytext_ptr = yy_bp; \
     300         yyleng = (int) (yy_cp - yy_bp); \
     301         yy_hold_char = *yy_cp; \
     302         *yy_cp = '\0'; \
     303         yy_c_buf_p = yy_cp;
     304
     305 #define YY_NUM_RULES 30
     306 #define YY_END_OF_BUFFER 31
     307 static yyconst short int yy_accept[85] =
     308     {   0,
     309         0,    0,   31,   30,   28,   29,   27,    3,    4,    6,
     310        26,   26,   27,   27,   27,   27,   27,   27,   27,   27,
     311        27,   27,   27,    1,    5,    2,   27,   26,   27,   27,
     312        27,   27,   27,   27,   27,   27,   27,   27,   27,   27,
     313        27,   27,   14,   27,   27,   27,   25,   13,   22,   11,
     314        27,   27,   27,   27,   27,    9,   27,   27,   27,   27,
     315        27,   10,   27,   12,   19,   27,   21,   27,   23,   27,
     316        27,    8,   24,   20,    7,   27,   27,   27,   27,   15,
     317        16,   18,   17,    0
     318     } ;
     319
     320 static yyconst int yy_ec[256] =
     321     {   0,
     322         1,    1,    1,    1,    1,    1,    1,    1,    2,    3,
     323         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     324         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     325         1,    2,    1,    1,    4,    1,    1,    1,    1,    5,
     326         6,    1,    1,    1,    7,    4,    4,    8,    9,    9,
     327         9,    9,    9,    9,    9,    9,    9,    1,    1,    1,
     328         1,    1,    1,    4,   10,   11,   12,   13,   14,   15,
     329         4,   16,   17,    4,   18,   19,   20,   21,   22,   23,
     330         4,   24,   25,   26,   27,   28,    4,   29,   30,    4,
     331         1,    1,    1,    1,    4,    1,   10,   11,   12,   13,
     332
     333        14,   15,    4,   16,   17,    4,   18,   19,   20,   21,
     334        22,   23,    4,   24,   25,   26,   27,   28,    4,   29,
     335        30,    4,   31,   32,   33,    1,    1,    1,    1,    1,
     336         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     337         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     338         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     339         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     340         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     341         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     342         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     343
     344         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     345         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     346         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     347         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     348         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     349         1,    1,    1,    1,    1
     350     } ;
     351
     352 static yyconst int yy_meta[34] =
     353     {   0,
     354         1,    1,    1,    2,    1,    1,    1,    2,    2,    2,
     355         2,    2,    2,    2,    2,    2,    2,    2,    2,    2,
     356         2,    2,    2,    2,    2,    2,    2,    2,    2,    2,
     357         1,    1,    1
     358     } ;
     359
     360 static yyconst short int yy_base[86] =
     361     {   0,
     362         0,    0,  103,  104,  104,  104,    0,  104,  104,  104,
     363        26,   28,   25,   78,   29,   72,   31,   78,   89,   88,
     364        77,   26,   80,  104,  104,  104,    0,   37,   48,   82,
     365        75,   70,   66,   77,   64,   70,   74,   75,   62,   72,
     366        64,   57,    0,   23,   70,   57,    0,    0,    0,    0,
     367        58,   69,   64,   63,   64,    0,   55,   57,   59,   56,
     368        56,    0,   52,    0,    0,   43,    0,   42,    0,   57,
     369        51,    0,    0,    0,    0,   51,   50,   28,   19,    0,
     370         0,    0,    0,  104,   45
     371     } ;
     372
     373 static yyconst short int yy_def[86] =
     374     {   0,
     375        84,    1,   84,   84,   84,   84,   85,   84,   84,   84,
     376        85,   85,   85,   85,   85,   85,   85,   85,   85,   85,
     377        85,   85,   85,   84,   84,   84,   85,   85,   85,   85,
     378        85,   85,   85,   85,   85,   85,   85,   85,   85,   85,
     379        85,   85,   85,   85,   85,   85,   29,   85,   85,   85,
     380        85,   85,   85,   85,   85,   85,   85,   85,   85,   85,
     381        85,   85,   85,   85,   85,   85,   85,   85,   85,   85,
     382        85,   85,   85,   85,   85,   85,   85,   85,   85,   85,
     383        85,   85,   85,    0,   84
     384     } ;
     385
     386 static yyconst short int yy_nxt[138] =
     387     {   0,
     388         4,    5,    6,    7,    8,    9,   10,   11,   12,   13,
     389         7,   14,   15,   16,   17,    7,    7,    7,    7,   18,
     390        19,    7,   20,   21,   22,   23,    7,    7,    7,    7,
     391        24,   25,   26,   28,   28,   28,   28,   30,   35,   44,
     392        38,   61,   36,   31,   28,   28,   27,   45,   83,   32,
     393        62,   33,   39,   82,   29,   47,   47,   47,   47,   47,
     394        47,   47,   47,   81,   80,   79,   78,   77,   76,   75,
     395        74,   73,   72,   71,   70,   69,   68,   67,   66,   65,
     396        64,   63,   60,   59,   58,   57,   56,   55,   54,   53,
     397        52,   51,   50,   49,   48,   46,   43,   42,   41,   40,
     398
     399        37,   34,   84,    3,   84,   84,   84,   84,   84,   84,
     400        84,   84,   84,   84,   84,   84,   84,   84,   84,   84,
     401        84,   84,   84,   84,   84,   84,   84,   84,   84,   84,
     402        84,   84,   84,   84,   84,   84,   84
     403     } ;
     404
     405 static yyconst short int yy_chk[138] =
     406     {   0,
     407         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     408         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     409         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
     410         1,    1,    1,   11,   11,   12,   12,   13,   15,   22,
     411        17,   44,   15,   13,   28,   28,   85,   22,   79,   13,
     412        44,   13,   17,   78,   11,   29,   29,   29,   29,   29,
     413        29,   29,   29,   77,   76,   71,   70,   68,   66,   63,
     414        61,   60,   59,   58,   57,   55,   54,   53,   52,   51,
     415        46,   45,   42,   41,   40,   39,   38,   37,   36,   35,
     416        34,   33,   32,   31,   30,   23,   21,   20,   19,   18,
     417
     418        16,   14,    3,   84,   84,   84,   84,   84,   84,   84,
     419        84,   84,   84,   84,   84,   84,   84,   84,   84,   84,
     420        84,   84,   84,   84,   84,   84,   84,   84,   84,   84,
     421        84,   84,   84,   84,   84,   84,   84
     422     } ;
     423
     424 static yy_state_type yy_last_accepting_state;
     425 static char *yy_last_accepting_cpos;
     426
     427 /* The intent behind this definition is that it'll catch
     428  * any uses of REJECT which flex missed.
     429  */
     430 #define REJECT reject_used_but_not_detected
     431 #define yymore() yymore_used_but_not_detected
         /* [<][>][^][v][top][bottom][index][help] */
     432 #define YY_MORE_ADJ 0
     433 #define YY_RESTORE_YY_MORE_OFFSET
     434 char *yytext;
     435 #line 1 "er.lex"
     436 #define INITIAL 0
     437 #line 6 "er.lex"
     438
     439 #include "erroutines.h"
     440
     441 #include "er.yacc.tab.h"
     442 #include "string.h"
     443 #include "er_yacc_helper.h"
     444
     445 int errorColon = 0;
     446
     447 #define YY_DECL int yylex(YYSTYPE *yylval, lexerr_t *erst)
     448 #define YY_USER_ACTION { erst->errpos += yyleng; }
     449 #define YY_NO_UNPUT
     450
     451 void lexcleancurbuf(void)  {
         /* [<][>][^][v][top][bottom][index][help] */
     452   yy_delete_buffer(yy_current_buffer);
     453 }
     454
     455 #line 456 "lex.er_yy.c"
     456
     457 /* Macros after this point can all be overridden by user definitions in
     458  * section 1.
     459  */
     460
     461 #ifndef YY_SKIP_YYWRAP
     462 #ifdef __cplusplus
     463 extern "C" int yywrap YY_PROTO(( void ));
     464 #else
     465 extern int yywrap YY_PROTO(( void ));
     466 #endif
     467 #endif
     468
     469 #ifndef YY_NO_UNPUT
     470 static void yyunput YY_PROTO(( int c, char *buf_ptr ));
     471 #endif
     472
     473 #ifndef yytext_ptr
     474 static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));
     475 #endif
     476
     477 #ifdef YY_NEED_STRLEN
     478 static int yy_flex_strlen YY_PROTO(( yyconst char * ));
     479 #endif
     480
     481 #ifndef YY_NO_INPUT
     482 #ifdef __cplusplus
     483 static int yyinput YY_PROTO(( void ));
     484 #else
     485 static int input YY_PROTO(( void ));
     486 #endif
     487 #endif
     488
     489 #if YY_STACK_USED
     490 static int yy_start_stack_ptr = 0;
     491 static int yy_start_stack_depth = 0;
     492 static int *yy_start_stack = 0;
     493 #ifndef YY_NO_PUSH_STATE
     494 static void yy_push_state YY_PROTO(( int new_state ));
     495 #endif
     496 #ifndef YY_NO_POP_STATE
     497 static void yy_pop_state YY_PROTO(( void ));
     498 #endif
     499 #ifndef YY_NO_TOP_STATE
     500 static int yy_top_state YY_PROTO(( void ));
     501 #endif
     502
     503 #else
     504 #define YY_NO_PUSH_STATE 1
     505 #define YY_NO_POP_STATE 1
     506 #define YY_NO_TOP_STATE 1
     507 #endif
     508
     509 #ifdef YY_MALLOC_DECL
     510 YY_MALLOC_DECL
     511 #else
     512 #if __STDC__
     513 #ifndef __cplusplus
     514 #include <stdlib.h>
     515 #endif
     516 #else
     517 /* Just try to get by without declaring the routines.  This will fail
     518  * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int)
     519  * or sizeof(void*) != sizeof(int).
     520  */
     521 #endif
     522 #endif
     523
     524 /* Amount of stuff to slurp up with each read. */
     525 #ifndef YY_READ_BUF_SIZE
     526 #define YY_READ_BUF_SIZE 8192
     527 #endif
     528
     529 /* Copy whatever the last rule matched to the standard output. */
     530
     531 #ifndef ECHO
     532 /* This used to be an fputs(), but since the string might contain NUL's,
     533  * we now use fwrite().
     534  */
     535 #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
     536 #endif
     537
     538 /* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
     539  * is returned in "result".
     540  */
     541 #ifndef YY_INPUT
     542 #define YY_INPUT(buf,result,max_size) \
         /* [<][>][^][v][top][bottom][index][help] */
     543         if ( yy_current_buffer->yy_is_interactive ) \
     544                 { \
     545                 int c = '*', n; \
     546                 for ( n = 0; n < max_size && \
     547                              (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
     548                         buf[n] = (char) c; \
     549                 if ( c == '\n' ) \
     550                         buf[n++] = (char) c; \
     551                 if ( c == EOF && ferror( yyin ) ) \
     552                         YY_FATAL_ERROR( "input in flex scanner failed" ); \
     553                 result = n; \
     554                 } \
     555         else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
     556                   && ferror( yyin ) ) \
     557                 YY_FATAL_ERROR( "input in flex scanner failed" );
     558 #endif
     559
     560 /* No semi-colon after return; correct usage is to write "yyterminate();" -
     561  * we don't want an extra ';' after the "return" because that will cause
     562  * some compilers to complain about unreachable statements.
     563  */
     564 #ifndef yyterminate
     565 #define yyterminate() return YY_NULL
         /* [<][>][^][v][top][bottom][index][help] */
     566 #endif
     567
     568 /* Number of entries by which start-condition stack grows. */
     569 #ifndef YY_START_STACK_INCR
     570 #define YY_START_STACK_INCR 25
     571 #endif
     572
     573 /* Report a fatal error. */
     574 #ifndef YY_FATAL_ERROR
     575 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
         /* [<][>][^][v][top][bottom][index][help] */
     576 #endif
     577
     578 /* Default declaration of generated scanner - a define so the user can
     579  * easily add parameters.
     580  */
     581 #ifndef YY_DECL
     582 #define YY_DECL int yylex YY_PROTO(( void ))
     583 #endif
     584
     585 /* Code executed at the beginning of each rule, after yytext and yyleng
     586  * have been set up.
     587  */
     588 #ifndef YY_USER_ACTION
     589 #define YY_USER_ACTION
     590 #endif
     591
     592 /* Code executed at the end of each rule. */
     593 #ifndef YY_BREAK
     594 #define YY_BREAK break;
     595 #endif
     596
     597 #define YY_RULE_SETUP \
     598         YY_USER_ACTION
     599
     600 YY_DECL
     601         {
     602         register yy_state_type yy_current_state;
     603         register char *yy_cp, *yy_bp;
     604         register int yy_act;
     605
     606 #line 29 "er.lex"
     607
     608 #line 609 "lex.er_yy.c"
     609
     610         if ( yy_init )
     611                 {
     612                 yy_init = 0;
     613
     614 #ifdef YY_USER_INIT
     615                 YY_USER_INIT;
     616 #endif
     617
     618                 if ( ! yy_start )
     619                         yy_start = 1;   /* first start state */
     620
     621                 if ( ! yyin )
     622                         yyin = stdin;
     623
     624                 if ( ! yyout )
     625                         yyout = stdout;
     626
     627                 if ( ! yy_current_buffer )
     628                         yy_current_buffer =
     629                                 yy_create_buffer( yyin, YY_BUF_SIZE );
     630
     631                 yy_load_buffer_state();
     632                 }
     633
     634         while ( 1 )             /* loops until end-of-file is reached */
     635                 {
     636                 yy_cp = yy_c_buf_p;
     637
     638                 /* Support of yytext. */
     639                 *yy_cp = yy_hold_char;
     640
     641                 /* yy_bp points to the position in yy_ch_buf of the start of
     642                  * the current run.
     643                  */
     644                 yy_bp = yy_cp;
     645
     646                 yy_current_state = yy_start;
     647 yy_match:
     648                 do
     649                         {
     650                         register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
     651                         if ( yy_accept[yy_current_state] )
     652                                 {
     653                                 yy_last_accepting_state = yy_current_state;
     654                                 yy_last_accepting_cpos = yy_cp;
     655                                 }
     656                         while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
     657                                 {
     658                                 yy_current_state = (int) yy_def[yy_current_state];
     659                                 if ( yy_current_state >= 85 )
     660                                         yy_c = yy_meta[(unsigned int) yy_c];
     661                                 }
     662                         yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
     663                         ++yy_cp;
     664                         }
     665                 while ( yy_base[yy_current_state] != 104 );
     666
     667 yy_find_action:
     668                 yy_act = yy_accept[yy_current_state];
     669                 if ( yy_act == 0 )
     670                         { /* have to back up */
     671                         yy_cp = yy_last_accepting_cpos;
     672                         yy_current_state = yy_last_accepting_state;
     673                         yy_act = yy_accept[yy_current_state];
     674                         }
     675
     676                 YY_DO_BEFORE_ACTION;
     677
     678
     679 do_action:      /* This label is used only to access EOF actions. */
     680
     681
     682                 switch ( yy_act )
     683         { /* beginning of action switch */
     684                         case 0: /* must back up */
     685                         /* undo the effects of YY_DO_BEFORE_ACTION */
     686                         *yy_cp = yy_hold_char;
     687                         yy_cp = yy_last_accepting_cpos;
     688                         yy_current_state = yy_last_accepting_state;
     689                         goto yy_find_action;
     690
     691 case 1:
     692 YY_RULE_SETUP
     693 #line 30 "er.lex"
     694 {  return '{';}
     695         YY_BREAK
     696 case 2:
     697 YY_RULE_SETUP
     698 #line 31 "er.lex"
     699 {  return '}';}
     700         YY_BREAK
     701 case 3:
     702 YY_RULE_SETUP
     703 #line 32 "er.lex"
     704 {  return '(';}
     705         YY_BREAK
     706 case 4:
     707 YY_RULE_SETUP
     708 #line 33 "er.lex"
     709 {  return ')';}
     710         YY_BREAK
     711 case 5:
     712 YY_RULE_SETUP
     713 #line 34 "er.lex"
     714 {  return '|';}
     715         YY_BREAK
     716 case 6:
     717 YY_RULE_SETUP
     718 #line 35 "er.lex"
     719 {  return '-';}
     720         YY_BREAK
     721 case 7:
     722 YY_RULE_SETUP
     723 #line 36 "er.lex"
     724 { return K_SOCK;}
     725         YY_BREAK
     726 case 8:
     727 YY_RULE_SETUP
     728 #line 37 "er.lex"
     729 { return K_NAME;}
     730         YY_BREAK
     731 case 9:
     732 YY_RULE_SETUP
     733 #line 38 "er.lex"
     734 { return K_FAC; }
     735         YY_BREAK
     736 case 10:
     737 YY_RULE_SETUP
     738 #line 39 "er.lex"
     739 { return K_SEV; }
     740         YY_BREAK
     741 case 11:
     742 YY_RULE_SETUP
     743 #line 40 "er.lex"
     744 { return K_ASP; }
     745         YY_BREAK
     746 case 12:
     747 YY_RULE_SETUP
     748 #line 41 "er.lex"
     749 { return K_THR; }
     750         YY_BREAK
     751 case 13:
     752 YY_RULE_SETUP
     753 #line 42 "er.lex"
     754 { return K_ADD; }
     755         YY_BREAK
     756 case 14:
     757 YY_RULE_SETUP
     758 #line 43 "er.lex"
     759 { return K_RM;  }
     760         YY_BREAK
     761 case 15:
     762 YY_RULE_SETUP
     763 #line 44 "er.lex"
     764 { return K_CREATE;  }
     765         YY_BREAK
     766 case 16:
     767 YY_RULE_SETUP
     768 #line 45 "er.lex"
     769 { return K_DELETE;  }
     770         YY_BREAK
     771 case 17:
     772 YY_RULE_SETUP
     773 #line 46 "er.lex"
     774 { return K_MODIFY;  }
     775         YY_BREAK
     776 case 18:
     777 YY_RULE_SETUP
     778 #line 47 "er.lex"
     779 { return K_FORMAT; }
     780         YY_BREAK
     781 case 19:
     782 YY_RULE_SETUP
     783 #line 48 "er.lex"
     784 { return K_AUTO; }
     785         YY_BREAK
     786 case 20:
     787 YY_RULE_SETUP
     788 #line 49 "er.lex"
     789 { return K_SELF; }
     790         YY_BREAK
     791 case 21:
     792 YY_RULE_SETUP
     793 #line 50 "er.lex"
     794 { return K_DATE; }
     795         YY_BREAK
     796 case 22:
     797 YY_RULE_SETUP
     798 #line 51 "er.lex"
     799 { return K_ALL; }
     800         YY_BREAK
     801 case 23:
     802 YY_RULE_SETUP
     803 #line 52 "er.lex"
     804 { return K_EXEC; }
     805         YY_BREAK
     806 case 24:
     807 YY_RULE_SETUP
     808 #line 53 "er.lex"
     809 { return K_PATH; }
     810         YY_BREAK
     811 case 25:
     812 YY_RULE_SETUP
     813 #line 55 "er.lex"
     814 { sscanf(yytext,"%x", &(yylval->inum) ); return HEXNUM; }
     815         YY_BREAK
     816 case 26:
     817 YY_RULE_SETUP
     818 #line 57 "er.lex"
     819 { yylval->inum = atoi(yytext); return NUMBER; }
     820         YY_BREAK
     821 case 27:
     822 YY_RULE_SETUP
     823 #line 59 "er.lex"
     824 { /* none of "-(){}|" because they are used by parser
     825                      as delimiting tokens */
     826
     827   yylval->text = erst->token = strdup(yytext);
     828 #if 0
     829   printf("string is %s\n", yytext);
     830 #endif
     831   return STRING;
     832 }
     833         YY_BREAK
     834 case 28:
     835 YY_RULE_SETUP
     836 #line 69 "er.lex"
     837 ;
     838         YY_BREAK
     839 case 29:
     840 YY_RULE_SETUP
     841 #line 70 "er.lex"
     842 { return EOL; }
     843         YY_BREAK
     844 case 30:
     845 YY_RULE_SETUP
     846 #line 71 "er.lex"
     847 ECHO;
     848         YY_BREAK
     849 #line 850 "lex.er_yy.c"
     850 case YY_STATE_EOF(INITIAL):
     851         yyterminate();
     852
     853         case YY_END_OF_BUFFER:
     854                 {
     855                 /* Amount of text matched not including the EOB char. */
     856                 int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1;
     857
     858                 /* Undo the effects of YY_DO_BEFORE_ACTION. */
     859                 *yy_cp = yy_hold_char;
     860                 YY_RESTORE_YY_MORE_OFFSET
     861
     862                 if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW )
     863                         {
     864                         /* We're scanning a new file or input source.  It's
     865                          * possible that this happened because the user
     866                          * just pointed yyin at a new source and called
     867                          * yylex().  If so, then we have to assure
     868                          * consistency between yy_current_buffer and our
     869                          * globals.  Here is the right place to do so, because
     870                          * this is the first action (other than possibly a
     871                          * back-up) that will match for the new input source.
     872                          */
     873                         yy_n_chars = yy_current_buffer->yy_n_chars;
     874                         yy_current_buffer->yy_input_file = yyin;
     875                         yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL;
     876                         }
     877
     878                 /* Note that here we test for yy_c_buf_p "<=" to the position
     879                  * of the first EOB in the buffer, since yy_c_buf_p will
     880                  * already have been incremented past the NUL character
     881                  * (since all states make transitions on EOB to the
     882                  * end-of-buffer state).  Contrast this with the test
     883                  * in input().
     884                  */
     885                 if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
     886                         { /* This was really a NUL. */
     887                         yy_state_type yy_next_state;
     888
     889                         yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text;
     890
     891                         yy_current_state = yy_get_previous_state();
     892
     893                         /* Okay, we're now positioned to make the NUL
     894                          * transition.  We couldn't have
     895                          * yy_get_previous_state() go ahead and do it
     896                          * for us because it doesn't know how to deal
     897                          * with the possibility of jamming (and we don't
     898                          * want to build jamming into it because then it
     899                          * will run more slowly).
     900                          */
     901
     902                         yy_next_state = yy_try_NUL_trans( yy_current_state );
     903
     904                         yy_bp = yytext_ptr + YY_MORE_ADJ;
     905
     906                         if ( yy_next_state )
     907                                 {
     908                                 /* Consume the NUL. */
     909                                 yy_cp = ++yy_c_buf_p;
     910                                 yy_current_state = yy_next_state;
     911                                 goto yy_match;
     912                                 }
     913
     914                         else
     915                                 {
     916                                 yy_cp = yy_c_buf_p;
     917                                 goto yy_find_action;
     918                                 }
     919                         }
     920
     921                 else switch ( yy_get_next_buffer() )
     922                         {
     923                         case EOB_ACT_END_OF_FILE:
     924                                 {
     925                                 yy_did_buffer_switch_on_eof = 0;
     926
     927                                 if ( yywrap() )
     928                                         {
     929                                         /* Note: because we've taken care in
     930                                          * yy_get_next_buffer() to have set up
     931                                          * yytext, we can now set up
     932                                          * yy_c_buf_p so that if some total
     933                                          * hoser (like flex itself) wants to
     934                                          * call the scanner after we return the
     935                                          * YY_NULL, it'll still work - another
     936                                          * YY_NULL will get returned.
     937                                          */
     938                                         yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
     939
     940                                         yy_act = YY_STATE_EOF(YY_START);
     941                                         goto do_action;
     942                                         }
     943
     944                                 else
     945                                         {
     946                                         if ( ! yy_did_buffer_switch_on_eof )
     947                                                 YY_NEW_FILE;
     948                                         }
     949                                 break;
     950                                 }
     951
     952                         case EOB_ACT_CONTINUE_SCAN:
     953                                 yy_c_buf_p =
     954                                         yytext_ptr + yy_amount_of_matched_text;
     955
     956                                 yy_current_state = yy_get_previous_state();
     957
     958                                 yy_cp = yy_c_buf_p;
     959                                 yy_bp = yytext_ptr + YY_MORE_ADJ;
     960                                 goto yy_match;
     961
     962                         case EOB_ACT_LAST_MATCH:
     963                                 yy_c_buf_p =
     964                                 &yy_current_buffer->yy_ch_buf[yy_n_chars];
     965
     966                                 yy_current_state = yy_get_previous_state();
     967
     968                                 yy_cp = yy_c_buf_p;
     969                                 yy_bp = yytext_ptr + YY_MORE_ADJ;
     970                                 goto yy_find_action;
     971                         }
     972                 break;
     973                 }
     974
     975         default:
     976                 YY_FATAL_ERROR(
     977                         "fatal flex scanner internal error--no action found" );
     978         } /* end of action switch */
     979                 } /* end of scanning one token */
     980         } /* end of yylex */
     981
     982
     983 /* yy_get_next_buffer - try to read in a new buffer
     984  *
     985  * Returns a code representing an action:
     986  *      EOB_ACT_LAST_MATCH -
     987  *      EOB_ACT_CONTINUE_SCAN - continue scanning from current position
     988  *      EOB_ACT_END_OF_FILE - end of file
     989  */
     990
     991 static int yy_get_next_buffer()
         /* [<][>][^][v][top][bottom][index][help] */
     992         {
     993         register char *dest = yy_current_buffer->yy_ch_buf;
     994         register char *source = yytext_ptr;
     995         register int number_to_move, i;
     996         int ret_val;
     997
     998         if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
     999                 YY_FATAL_ERROR(
    1000                 "fatal flex scanner internal error--end of buffer missed" );
    1001
    1002         if ( yy_current_buffer->yy_fill_buffer == 0 )
    1003                 { /* Don't try to fill the buffer, so this is an EOF. */
    1004                 if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 )
    1005                         {
    1006                         /* We matched a single character, the EOB, so
    1007                          * treat this as a final EOF.
    1008                          */
    1009                         return EOB_ACT_END_OF_FILE;
    1010                         }
    1011
    1012                 else
    1013                         {
    1014                         /* We matched some text prior to the EOB, first
    1015                          * process it.
    1016                          */
    1017                         return EOB_ACT_LAST_MATCH;
    1018                         }
    1019                 }
    1020
    1021         /* Try to read more data. */
    1022
    1023         /* First move last chars to start of buffer. */
    1024         number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1;
    1025
    1026         for ( i = 0; i < number_to_move; ++i )
    1027                 *(dest++) = *(source++);
    1028
    1029         if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING )
    1030                 /* don't do the read, it's not guaranteed to return an EOF,
    1031                  * just force an EOF
    1032                  */
    1033                 yy_current_buffer->yy_n_chars = yy_n_chars = 0;
    1034
    1035         else
    1036                 {
    1037                 int num_to_read =
    1038                         yy_current_buffer->yy_buf_size - number_to_move - 1;
    1039
    1040                 while ( num_to_read <= 0 )
    1041                         { /* Not enough room in the buffer - grow it. */
    1042 #ifdef YY_USES_REJECT
    1043                         YY_FATAL_ERROR(
    1044 "input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
    1045 #else
    1046
    1047                         /* just a shorter name for the current buffer */
    1048                         YY_BUFFER_STATE b = yy_current_buffer;
    1049
    1050                         int yy_c_buf_p_offset =
    1051                                 (int) (yy_c_buf_p - b->yy_ch_buf);
    1052
    1053                         if ( b->yy_is_our_buffer )
    1054                                 {
    1055                                 int new_size = b->yy_buf_size * 2;
    1056
    1057                                 if ( new_size <= 0 )
    1058                                         b->yy_buf_size += b->yy_buf_size / 8;
    1059                                 else
    1060                                         b->yy_buf_size *= 2;
    1061
    1062                                 b->yy_ch_buf = (char *)
    1063                                         /* Include room in for 2 EOB chars. */
    1064                                         yy_flex_realloc( (void *) b->yy_ch_buf,
    1065                                                          b->yy_buf_size + 2 );
    1066                                 }
    1067                         else
    1068                                 /* Can't grow it, we don't own it. */
    1069                                 b->yy_ch_buf = 0;
    1070
    1071                         if ( ! b->yy_ch_buf )
    1072                                 YY_FATAL_ERROR(
    1073                                 "fatal error - scanner input buffer overflow" );
    1074
    1075                         yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
    1076
    1077                         num_to_read = yy_current_buffer->yy_buf_size -
    1078                                                 number_to_move - 1;
    1079 #endif
    1080                         }
    1081
    1082                 if ( num_to_read > YY_READ_BUF_SIZE )
    1083                         num_to_read = YY_READ_BUF_SIZE;
    1084
    1085                 /* Read in more data. */
    1086                 YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
    1087                         yy_n_chars, num_to_read );
    1088
    1089                 yy_current_buffer->yy_n_chars = yy_n_chars;
    1090                 }
    1091
    1092         if ( yy_n_chars == 0 )
    1093                 {
    1094                 if ( number_to_move == YY_MORE_ADJ )
    1095                         {
    1096                         ret_val = EOB_ACT_END_OF_FILE;
    1097                         yyrestart( yyin );
    1098                         }
    1099
    1100                 else
    1101                         {
    1102                         ret_val = EOB_ACT_LAST_MATCH;
    1103                         yy_current_buffer->yy_buffer_status =
    1104                                 YY_BUFFER_EOF_PENDING;
    1105                         }
    1106                 }
    1107
    1108         else
    1109                 ret_val = EOB_ACT_CONTINUE_SCAN;
    1110
    1111         yy_n_chars += number_to_move;
    1112         yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
    1113         yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
    1114
    1115         yytext_ptr = &yy_current_buffer->yy_ch_buf[0];
    1116
    1117         return ret_val;
    1118         }
    1119
    1120
    1121 /* yy_get_previous_state - get the state just before the EOB char was reached */
    1122
    1123 static yy_state_type yy_get_previous_state()
         /* [<][>][^][v][top][bottom][index][help] */
    1124         {
    1125         register yy_state_type yy_current_state;
    1126         register char *yy_cp;
    1127
    1128         yy_current_state = yy_start;
    1129
    1130         for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
    1131                 {
    1132                 register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
    1133                 if ( yy_accept[yy_current_state] )
    1134                         {
    1135                         yy_last_accepting_state = yy_current_state;
    1136                         yy_last_accepting_cpos = yy_cp;
    1137                         }
    1138                 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
    1139                         {
    1140                         yy_current_state = (int) yy_def[yy_current_state];
    1141                         if ( yy_current_state >= 85 )
    1142                                 yy_c = yy_meta[(unsigned int) yy_c];
    1143                         }
    1144                 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
    1145                 }
    1146
    1147         return yy_current_state;
    1148         }
    1149
    1150
    1151 /* yy_try_NUL_trans - try to make a transition on the NUL character
    1152  *
    1153  * synopsis
    1154  *      next_state = yy_try_NUL_trans( current_state );
    1155  */
    1156
    1157 #ifdef YY_USE_PROTOS
    1158 static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state )
         /* [<][>][^][v][top][bottom][index][help] */
    1159 #else
    1160 static yy_state_type yy_try_NUL_trans( yy_current_state )
    1161 yy_state_type yy_current_state;
    1162 #endif
    1163         {
    1164         register int yy_is_jam;
    1165         register char *yy_cp = yy_c_buf_p;
    1166
    1167         register YY_CHAR yy_c = 1;
    1168         if ( yy_accept[yy_current_state] )
    1169                 {
    1170                 yy_last_accepting_state = yy_current_state;
    1171                 yy_last_accepting_cpos = yy_cp;
    1172                 }
    1173         while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
    1174                 {
    1175                 yy_current_state = (int) yy_def[yy_current_state];
    1176                 if ( yy_current_state >= 85 )
    1177                         yy_c = yy_meta[(unsigned int) yy_c];
    1178                 }
    1179         yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
    1180         yy_is_jam = (yy_current_state == 84);
    1181
    1182         return yy_is_jam ? 0 : yy_current_state;
    1183         }
    1184
    1185
    1186 #ifndef YY_NO_UNPUT
    1187 #ifdef YY_USE_PROTOS
    1188 static void yyunput( int c, register char *yy_bp )
         /* [<][>][^][v][top][bottom][index][help] */
    1189 #else
    1190 static void yyunput( c, yy_bp )
    1191 int c;
    1192 register char *yy_bp;
    1193 #endif
    1194         {
    1195         register char *yy_cp = yy_c_buf_p;
    1196
    1197         /* undo effects of setting up yytext */
    1198         *yy_cp = yy_hold_char;
    1199
    1200         if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
    1201                 { /* need to shift things up to make room */
    1202                 /* +2 for EOB chars. */
    1203                 register int number_to_move = yy_n_chars + 2;
    1204                 register char *dest = &yy_current_buffer->yy_ch_buf[
    1205                                         yy_current_buffer->yy_buf_size + 2];
    1206                 register char *source =
    1207                                 &yy_current_buffer->yy_ch_buf[number_to_move];
    1208
    1209                 while ( source > yy_current_buffer->yy_ch_buf )
    1210                         *--dest = *--source;
    1211
    1212                 yy_cp += (int) (dest - source);
    1213                 yy_bp += (int) (dest - source);
    1214                 yy_current_buffer->yy_n_chars =
    1215                         yy_n_chars = yy_current_buffer->yy_buf_size;
    1216
    1217                 if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
    1218                         YY_FATAL_ERROR( "flex scanner push-back overflow" );
    1219                 }
    1220
    1221         *--yy_cp = (char) c;
    1222
    1223
    1224         yytext_ptr = yy_bp;
    1225         yy_hold_char = *yy_cp;
    1226         yy_c_buf_p = yy_cp;
    1227         }
    1228 #endif  /* ifndef YY_NO_UNPUT */
    1229
    1230
    1231 #ifdef __cplusplus
    1232 static int yyinput()
         /* [<][>][^][v][top][bottom][index][help] */
    1233 #else
    1234 static int input()
    1235 #endif
    1236         {
    1237         int c;
    1238
    1239         *yy_c_buf_p = yy_hold_char;
    1240
    1241         if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
    1242                 {
    1243                 /* yy_c_buf_p now points to the character we want to return.
    1244                  * If this occurs *before* the EOB characters, then it's a
    1245                  * valid NUL; if not, then we've hit the end of the buffer.
    1246                  */
    1247                 if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
    1248                         /* This was really a NUL. */
    1249                         *yy_c_buf_p = '\0';
    1250
    1251                 else
    1252                         { /* need more input */
    1253                         int offset = yy_c_buf_p - yytext_ptr;
    1254                         ++yy_c_buf_p;
    1255
    1256                         switch ( yy_get_next_buffer() )
    1257                                 {
    1258                                 case EOB_ACT_LAST_MATCH:
    1259                                         /* This happens because yy_g_n_b()
    1260                                          * sees that we've accumulated a
    1261                                          * token and flags that we need to
    1262                                          * try matching the token before
    1263                                          * proceeding.  But for input(),
    1264                                          * there's no matching to consider.
    1265                                          * So convert the EOB_ACT_LAST_MATCH
    1266                                          * to EOB_ACT_END_OF_FILE.
    1267                                          */
    1268
    1269                                         /* Reset buffer status. */
    1270                                         yyrestart( yyin );
    1271
    1272                                         /* fall through */
    1273
    1274                                 case EOB_ACT_END_OF_FILE:
    1275                                         {
    1276                                         if ( yywrap() )
    1277                                                 return EOF;
    1278
    1279                                         if ( ! yy_did_buffer_switch_on_eof )
    1280                                                 YY_NEW_FILE;
    1281 #ifdef __cplusplus
    1282                                         return yyinput();
    1283 #else
    1284                                         return input();
    1285 #endif
    1286                                         }
    1287
    1288                                 case EOB_ACT_CONTINUE_SCAN:
    1289                                         yy_c_buf_p = yytext_ptr + offset;
    1290                                         break;
    1291                                 }
    1292                         }
    1293                 }
    1294
    1295         c = *(unsigned char *) yy_c_buf_p;      /* cast for 8-bit char's */
    1296         *yy_c_buf_p = '\0';     /* preserve yytext */
    1297         yy_hold_char = *++yy_c_buf_p;
    1298
    1299
    1300         return c;
    1301         }
    1302
    1303
    1304 #ifdef YY_USE_PROTOS
    1305 void yyrestart( FILE *input_file )
         /* [<][>][^][v][top][bottom][index][help] */
    1306 #else
    1307 void yyrestart( input_file )
    1308 FILE *input_file;
    1309 #endif
    1310         {
    1311         if ( ! yy_current_buffer )
    1312                 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );
    1313
    1314         yy_init_buffer( yy_current_buffer, input_file );
    1315         yy_load_buffer_state();
    1316         }
    1317
    1318
    1319 #ifdef YY_USE_PROTOS
    1320 void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
         /* [<][>][^][v][top][bottom][index][help] */
    1321 #else
    1322 void yy_switch_to_buffer( new_buffer )
    1323 YY_BUFFER_STATE new_buffer;
    1324 #endif
    1325         {
    1326         if ( yy_current_buffer == new_buffer )
    1327                 return;
    1328
    1329         if ( yy_current_buffer )
    1330                 {
    1331                 /* Flush out information for old buffer. */
    1332                 *yy_c_buf_p = yy_hold_char;
    1333                 yy_current_buffer->yy_buf_pos = yy_c_buf_p;
    1334                 yy_current_buffer->yy_n_chars = yy_n_chars;
    1335                 }
    1336
    1337         yy_current_buffer = new_buffer;
    1338         yy_load_buffer_state();
    1339
    1340         /* We don't actually know whether we did this switch during
    1341          * EOF (yywrap()) processing, but the only time this flag
    1342          * is looked at is after yywrap() is called, so it's safe
    1343          * to go ahead and always set it.
    1344          */
    1345         yy_did_buffer_switch_on_eof = 1;
    1346         }
    1347
    1348
    1349 #ifdef YY_USE_PROTOS
    1350 void yy_load_buffer_state( void )
         /* [<][>][^][v][top][bottom][index][help] */
    1351 #else
    1352 void yy_load_buffer_state()
    1353 #endif
    1354         {
    1355         yy_n_chars = yy_current_buffer->yy_n_chars;
    1356         yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
    1357         yyin = yy_current_buffer->yy_input_file;
    1358         yy_hold_char = *yy_c_buf_p;
    1359         }
    1360
    1361
    1362 #ifdef YY_USE_PROTOS
    1363 YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
         /* [<][>][^][v][top][bottom][index][help] */
    1364 #else
    1365 YY_BUFFER_STATE yy_create_buffer( file, size )
    1366 FILE *file;
    1367 int size;
    1368 #endif
    1369         {
    1370         YY_BUFFER_STATE b;
    1371
    1372         b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
    1373         if ( ! b )
    1374                 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
    1375
    1376         b->yy_buf_size = size;
    1377
    1378         /* yy_ch_buf has to be 2 characters longer than the size given because
    1379          * we need to put in 2 end-of-buffer characters.
    1380          */
    1381         b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 );
    1382         if ( ! b->yy_ch_buf )
    1383                 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
    1384
    1385         b->yy_is_our_buffer = 1;
    1386
    1387         yy_init_buffer( b, file );
    1388
    1389         return b;
    1390         }
    1391
    1392
    1393 #ifdef YY_USE_PROTOS
    1394 void yy_delete_buffer( YY_BUFFER_STATE b )
         /* [<][>][^][v][top][bottom][index][help] */
    1395 #else
    1396 void yy_delete_buffer( b )
    1397 YY_BUFFER_STATE b;
    1398 #endif
    1399         {
    1400         if ( ! b )
    1401                 return;
    1402
    1403         if ( b == yy_current_buffer )
    1404                 yy_current_buffer = (YY_BUFFER_STATE) 0;
    1405
    1406         if ( b->yy_is_our_buffer )
    1407                 yy_flex_free( (void *) b->yy_ch_buf );
    1408
    1409         yy_flex_free( (void *) b );
    1410         }
    1411
    1412
    1413 #ifndef YY_ALWAYS_INTERACTIVE
    1414 #ifndef YY_NEVER_INTERACTIVE
    1415 extern int isatty YY_PROTO(( int ));
    1416 #endif
    1417 #endif
    1418
    1419 #ifdef YY_USE_PROTOS
    1420 void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
         /* [<][>][^][v][top][bottom][index][help] */
    1421 #else
    1422 void yy_init_buffer( b, file )
    1423 YY_BUFFER_STATE b;
    1424 FILE *file;
    1425 #endif
    1426
    1427
    1428         {
    1429         yy_flush_buffer( b );
    1430
    1431         b->yy_input_file = file;
    1432         b->yy_fill_buffer = 1;
    1433
    1434 #if YY_ALWAYS_INTERACTIVE
    1435         b->yy_is_interactive = 1;
    1436 #else
    1437 #if YY_NEVER_INTERACTIVE
    1438         b->yy_is_interactive = 0;
    1439 #else
    1440         b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
    1441 #endif
    1442 #endif
    1443         }
    1444
    1445
    1446 #ifdef YY_USE_PROTOS
    1447 void yy_flush_buffer( YY_BUFFER_STATE b )
         /* [<][>][^][v][top][bottom][index][help] */
    1448 #else
    1449 void yy_flush_buffer( b )
    1450 YY_BUFFER_STATE b;
    1451 #endif
    1452
    1453         {
    1454         if ( ! b )
    1455                 return;
    1456
    1457         b->yy_n_chars = 0;
    1458
    1459         /* We always need two end-of-buffer characters.  The first causes
    1460          * a transition to the end-of-buffer state.  The second causes
    1461          * a jam in that state.
    1462          */
    1463         b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
    1464         b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
    1465
    1466         b->yy_buf_pos = &b->yy_ch_buf[0];
    1467
    1468         b->yy_at_bol = 1;
    1469         b->yy_buffer_status = YY_BUFFER_NEW;
    1470
    1471         if ( b == yy_current_buffer )
    1472                 yy_load_buffer_state();
    1473         }
    1474
    1475
    1476 #ifndef YY_NO_SCAN_BUFFER
    1477 #ifdef YY_USE_PROTOS
    1478 YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size )
         /* [<][>][^][v][top][bottom][index][help] */
    1479 #else
    1480 YY_BUFFER_STATE yy_scan_buffer( base, size )
    1481 char *base;
    1482 yy_size_t size;
    1483 #endif
    1484         {
    1485         YY_BUFFER_STATE b;
    1486
    1487         if ( size < 2 ||
    1488              base[size-2] != YY_END_OF_BUFFER_CHAR ||
    1489              base[size-1] != YY_END_OF_BUFFER_CHAR )
    1490                 /* They forgot to leave room for the EOB's. */
    1491                 return 0;
    1492
    1493         b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
    1494         if ( ! b )
    1495                 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
    1496
    1497         b->yy_buf_size = size - 2;      /* "- 2" to take care of EOB's */
    1498         b->yy_buf_pos = b->yy_ch_buf = base;
    1499         b->yy_is_our_buffer = 0;
    1500         b->yy_input_file = 0;
    1501         b->yy_n_chars = b->yy_buf_size;
    1502         b->yy_is_interactive = 0;
    1503         b->yy_at_bol = 1;
    1504         b->yy_fill_buffer = 0;
    1505         b->yy_buffer_status = YY_BUFFER_NEW;
    1506
    1507         yy_switch_to_buffer( b );
    1508
    1509         return b;
    1510         }
    1511 #endif
    1512
    1513
    1514 #ifndef YY_NO_SCAN_STRING
    1515 #ifdef YY_USE_PROTOS
    1516 YY_BUFFER_STATE yy_scan_string( yyconst char *yy_str )
         /* [<][>][^][v][top][bottom][index][help] */
    1517 #else
    1518 YY_BUFFER_STATE yy_scan_string( yy_str )
    1519 yyconst char *yy_str;
    1520 #endif
    1521         {
    1522         int len;
    1523         for ( len = 0; yy_str[len]; ++len )
    1524                 ;
    1525
    1526         return yy_scan_bytes( yy_str, len );
    1527         }
    1528 #endif
    1529
    1530
    1531 #ifndef YY_NO_SCAN_BYTES
    1532 #ifdef YY_USE_PROTOS
    1533 YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len )
         /* [<][>][^][v][top][bottom][index][help] */
    1534 #else
    1535 YY_BUFFER_STATE yy_scan_bytes( bytes, len )
    1536 yyconst char *bytes;
    1537 int len;
    1538 #endif
    1539         {
    1540         YY_BUFFER_STATE b;
    1541         char *buf;
    1542         yy_size_t n;
    1543         int i;
    1544
    1545         /* Get memory for full buffer, including space for trailing EOB's. */
    1546         n = len + 2;
    1547         buf = (char *) yy_flex_alloc( n );
    1548         if ( ! buf )
    1549                 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
    1550
    1551         for ( i = 0; i < len; ++i )
    1552                 buf[i] = bytes[i];
    1553
    1554         buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR;
    1555
    1556         b = yy_scan_buffer( buf, n );
    1557         if ( ! b )
    1558                 YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
    1559
    1560         /* It's okay to grow etc. this buffer, and we should throw it
    1561          * away when we're done.
    1562          */
    1563         b->yy_is_our_buffer = 1;
    1564
    1565         return b;
    1566         }
    1567 #endif
    1568
    1569
    1570 #ifndef YY_NO_PUSH_STATE
    1571 #ifdef YY_USE_PROTOS
    1572 static void yy_push_state( int new_state )
         /* [<][>][^][v][top][bottom][index][help] */
    1573 #else
    1574 static void yy_push_state( new_state )
    1575 int new_state;
    1576 #endif
    1577         {
    1578         if ( yy_start_stack_ptr >= yy_start_stack_depth )
    1579                 {
    1580                 yy_size_t new_size;
    1581
    1582                 yy_start_stack_depth += YY_START_STACK_INCR;
    1583                 new_size = yy_start_stack_depth * sizeof( int );
    1584
    1585                 if ( ! yy_start_stack )
    1586                         yy_start_stack = (int *) yy_flex_alloc( new_size );
    1587
    1588                 else
    1589                         yy_start_stack = (int *) yy_flex_realloc(
    1590                                         (void *) yy_start_stack, new_size );
    1591
    1592                 if ( ! yy_start_stack )
    1593                         YY_FATAL_ERROR(
    1594                         "out of memory expanding start-condition stack" );
    1595                 }
    1596
    1597         yy_start_stack[yy_start_stack_ptr++] = YY_START;
    1598
    1599         BEGIN(new_state);
    1600         }
    1601 #endif
    1602
    1603
    1604 #ifndef YY_NO_POP_STATE
    1605 static void yy_pop_state()
         /* [<][>][^][v][top][bottom][index][help] */
    1606         {
    1607         if ( --yy_start_stack_ptr < 0 )
    1608                 YY_FATAL_ERROR( "start-condition stack underflow" );
    1609
    1610         BEGIN(yy_start_stack[yy_start_stack_ptr]);
    1611         }
    1612 #endif
    1613
    1614
    1615 #ifndef YY_NO_TOP_STATE
    1616 static int yy_top_state()
         /* [<][>][^][v][top][bottom][index][help] */
    1617         {
    1618         return yy_start_stack[yy_start_stack_ptr - 1];
    1619         }
    1620 #endif
    1621
    1622 #ifndef YY_EXIT_FAILURE
    1623 #define YY_EXIT_FAILURE 2
    1624 #endif
    1625
    1626 #ifdef YY_USE_PROTOS
    1627 static void yy_fatal_error( yyconst char msg[] )
         /* [<][>][^][v][top][bottom][index][help] */
    1628 #else
    1629 static void yy_fatal_error( msg )
    1630 char msg[];
    1631 #endif
    1632         {
    1633         (void) fprintf( stderr, "%s\n", msg );
    1634         exit( YY_EXIT_FAILURE );
    1635         }
    1636
    1637
    1638
    1639 /* Redefine yyless() so it works in section 3 code. */
    1640
    1641 #undef yyless
    1642 #define yyless(n) \
         /* [<][>][^][v][top][bottom][index][help] */
    1643         do \
    1644                 { \
    1645                 /* Undo effects of setting up yytext. */ \
    1646                 yytext[yyleng] = yy_hold_char; \
    1647                 yy_c_buf_p = yytext + n; \
    1648                 yy_hold_char = *yy_c_buf_p; \
    1649                 *yy_c_buf_p = '\0'; \
    1650                 yyleng = n; \
    1651                 } \
    1652         while ( 0 )
    1653
    1654
    1655 /* Internal utility routines. */
    1656
    1657 #ifndef yytext_ptr
    1658 #ifdef YY_USE_PROTOS
    1659 static void yy_flex_strncpy( char *s1, yyconst char *s2, int n )
         /* [<][>][^][v][top][bottom][index][help] */
    1660 #else
    1661 static void yy_flex_strncpy( s1, s2, n )
    1662 char *s1;
    1663 yyconst char *s2;
    1664 int n;
    1665 #endif
    1666         {
    1667         register int i;
    1668         for ( i = 0; i < n; ++i )
    1669                 s1[i] = s2[i];
    1670         }
    1671 #endif
    1672
    1673 #ifdef YY_NEED_STRLEN
    1674 #ifdef YY_USE_PROTOS
    1675 static int yy_flex_strlen( yyconst char *s )
         /* [<][>][^][v][top][bottom][index][help] */
    1676 #else
    1677 static int yy_flex_strlen( s )
    1678 yyconst char *s;
    1679 #endif
    1680         {
    1681         register int n;
    1682         for ( n = 0; s[n]; ++n )
    1683                 ;
    1684
    1685         return n;
    1686         }
    1687 #endif
    1688
    1689
    1690 #ifdef YY_USE_PROTOS
    1691 static void *yy_flex_alloc( yy_size_t size )
         /* [<][>][^][v][top][bottom][index][help] */
    1692 #else
    1693 static void *yy_flex_alloc( size )
    1694 yy_size_t size;
    1695 #endif
    1696         {
    1697         return (void *) malloc( size );
    1698         }
    1699
    1700 #ifdef YY_USE_PROTOS
    1701 static void *yy_flex_realloc( void *ptr, yy_size_t size )
         /* [<][>][^][v][top][bottom][index][help] */
    1702 #else
    1703 static void *yy_flex_realloc( ptr, size )
    1704 void *ptr;
    1705 yy_size_t size;
    1706 #endif
    1707         {
    1708         /* The cast to (char *) in the following accommodates both
    1709          * implementations that use char* generic pointers, and those
    1710          * that use void* generic pointers.  It works with the latter
    1711          * because both ANSI C and C++ allow castless assignment from
    1712          * any pointer type to void*, and deal with argument conversions
    1713          * as though doing an assignment.
    1714          */
    1715         return (void *) realloc( (char *) ptr, size );
    1716         }
    1717
    1718 #ifdef YY_USE_PROTOS
    1719 static void yy_flex_free( void *ptr )
         /* [<][>][^][v][top][bottom][index][help] */
    1720 #else
    1721 static void yy_flex_free( ptr )
    1722 void *ptr;
    1723 #endif
    1724         {
    1725         free( ptr );
    1726         }
    1727
    1728 #if YY_MAIN
    1729 int main()
         /* [<][>][^][v][top][bottom][index][help] */
    1730         {
    1731         yylex();
    1732         return 0;
    1733         }
    1734 #endif
    1735 #line 71 "er.lex"

/* [<][>][^][v][top][bottom][index][help] */