Main Page | Class Hierarchy | Compound List | File List | Compound Members | File Members

dotty_scanner.cc

Go to the documentation of this file.
00001 /* A lexical scanner generated by flex */
00002 
00003 /* Scanner skeleton version:
00004  * $Header: /cvsroot/y-api/yapi/src/dotty/dotty_scanner.cc,v 1.2 2006/02/06 12:58:07 kock Exp $
00005  */
00006 
00007 #define FLEX_SCANNER
00008 #define YY_FLEX_MAJOR_VERSION 2
00009 #define YY_FLEX_MINOR_VERSION 5
00010 
00011 #include <stdio.h>
00012 #include <unistd.h>
00013 
00014 
00015 /* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */
00016 #ifdef c_plusplus
00017 #ifndef __cplusplus
00018 #define __cplusplus
00019 #endif
00020 #endif
00021 
00022 
00023 #ifdef __cplusplus
00024 
00025 #include <stdlib.h>
00026 
00027 /* Use prototypes in function declarations. */
00028 #define YY_USE_PROTOS
00029 
00030 /* The "const" storage-class-modifier is valid. */
00031 #define YY_USE_CONST
00032 
00033 #else   /* ! __cplusplus */
00034 
00035 #if __STDC__
00036 
00037 #define YY_USE_PROTOS
00038 #define YY_USE_CONST
00039 
00040 #endif  /* __STDC__ */
00041 #endif  /* ! __cplusplus */
00042 
00043 #ifdef __TURBOC__
00044  #pragma warn -rch
00045  #pragma warn -use
00046 #include <io.h>
00047 #include <stdlib.h>
00048 #define YY_USE_CONST
00049 #define YY_USE_PROTOS
00050 #endif
00051 
00052 #ifdef YY_USE_CONST
00053 #define yyconst const
00054 #else
00055 #define yyconst
00056 #endif
00057 
00058 
00059 #ifdef YY_USE_PROTOS
00060 #define YY_PROTO(proto) proto
00061 #else
00062 #define YY_PROTO(proto) ()
00063 #endif
00064 
00065 /* Returned upon end-of-file. */
00066 #define YY_NULL 0
00067 
00068 /* Promotes a possibly negative, possibly signed char to an unsigned
00069  * integer for use as an array index.  If the signed char is negative,
00070  * we want to instead treat it as an 8-bit unsigned char, hence the
00071  * double cast.
00072  */
00073 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
00074 
00075 /* Enter a start condition.  This macro really ought to take a parameter,
00076  * but we do it the disgusting crufty way forced on us by the ()-less
00077  * definition of BEGIN.
00078  */
00079 #define BEGIN yy_start = 1 + 2 *
00080 
00081 /* Translate the current start state into a value that can be later handed
00082  * to BEGIN to return to the state.  The YYSTATE alias is for lex
00083  * compatibility.
00084  */
00085 #define YY_START ((yy_start - 1) / 2)
00086 #define YYSTATE YY_START
00087 
00088 /* Action number for EOF rule of a given start state. */
00089 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
00090 
00091 /* Special action meaning "start processing a new file". */
00092 #define YY_NEW_FILE yyrestart( yyin )
00093 
00094 #define YY_END_OF_BUFFER_CHAR 0
00095 
00096 /* Size of default input buffer. */
00097 #define YY_BUF_SIZE 16384
00098 
00099 typedef struct yy_buffer_state *YY_BUFFER_STATE;
00100 
00101 extern int yyleng;
00102 extern FILE *yyin, *yyout;
00103 
00104 #define EOB_ACT_CONTINUE_SCAN 0
00105 #define EOB_ACT_END_OF_FILE 1
00106 #define EOB_ACT_LAST_MATCH 2
00107 
00108 /* The funky do-while in the following #define is used to turn the definition
00109  * int a single C statement (which needs a semi-colon terminator).  This
00110  * avoids problems with code like:
00111  *
00112  *      if ( condition_holds )
00113  *              yyless( 5 );
00114  *      else
00115  *              do_something_else();
00116  *
00117  * Prior to using the do-while the compiler would get upset at the
00118  * "else" because it interpreted the "if" statement as being all
00119  * done when it reached the ';' after the yyless() call.
00120  */
00121 
00122 /* Return all but the first 'n' matched characters back to the input stream. */
00123 
00124 #define yyless(n) \
00125         do \
00126                 { \
00127                 /* Undo effects of setting up yytext. */ \
00128                 *yy_cp = yy_hold_char; \
00129                 YY_RESTORE_YY_MORE_OFFSET \
00130                 yy_c_buf_p = yy_cp = yy_bp + n - YY_MORE_ADJ; \
00131                 YY_DO_BEFORE_ACTION; /* set up yytext again */ \
00132                 } \
00133         while ( 0 )
00134 
00135 #define unput(c) yyunput( c, yytext_ptr )
00136 
00137 /* The following is because we cannot portably get our hands on size_t
00138  * (without autoconf's help, which isn't available because we want
00139  * flex-generated scanners to compile on their own).
00140  */
00141 typedef unsigned int yy_size_t;
00142 
00143 
00144 struct yy_buffer_state
00145         {
00146         FILE *yy_input_file;
00147 
00148         char *yy_ch_buf;                /* input buffer */
00149         char *yy_buf_pos;               /* current position in input buffer */
00150 
00151         /* Size of input buffer in bytes, not including room for EOB
00152          * characters.
00153          */
00154         yy_size_t yy_buf_size;
00155 
00156         /* Number of characters read into yy_ch_buf, not including EOB
00157          * characters.
00158          */
00159         int yy_n_chars;
00160 
00161         /* Whether we "own" the buffer - i.e., we know we created it,
00162          * and can realloc() it to grow it, and should free() it to
00163          * delete it.
00164          */
00165         int yy_is_our_buffer;
00166 
00167         /* Whether this is an "interactive" input source; if so, and
00168          * if we're using stdio for input, then we want to use getc()
00169          * instead of fread(), to make sure we stop fetching input after
00170          * each newline.
00171          */
00172         int yy_is_interactive;
00173 
00174         /* Whether we're considered to be at the beginning of a line.
00175          * If so, '^' rules will be active on the next match, otherwise
00176          * not.
00177          */
00178         int yy_at_bol;
00179 
00180         /* Whether to try to fill the input buffer when we reach the
00181          * end of it.
00182          */
00183         int yy_fill_buffer;
00184 
00185         int yy_buffer_status;
00186 #define YY_BUFFER_NEW 0
00187 #define YY_BUFFER_NORMAL 1
00188         /* When an EOF's been seen but there's still some text to process
00189          * then we mark the buffer as YY_EOF_PENDING, to indicate that we
00190          * shouldn't try reading from the input source any more.  We might
00191          * still have a bunch of tokens to match, though, because of
00192          * possible backing-up.
00193          *
00194          * When we actually see the EOF, we change the status to "new"
00195          * (via yyrestart()), so that the user can continue scanning by
00196          * just pointing yyin at a new input file.
00197          */
00198 #define YY_BUFFER_EOF_PENDING 2
00199         };
00200 
00201 static YY_BUFFER_STATE yy_current_buffer = 0;
00202 
00203 /* We provide macros for accessing buffer states in case in the
00204  * future we want to put the buffer states in a more general
00205  * "scanner state".
00206  */
00207 #define YY_CURRENT_BUFFER yy_current_buffer
00208 
00209 
00210 /* yy_hold_char holds the character lost when yytext is formed. */
00211 static char yy_hold_char;
00212 
00213 static int yy_n_chars;          /* number of characters read into yy_ch_buf */
00214 
00215 
00216 int yyleng;
00217 
00218 /* Points to current character in buffer. */
00219 static char *yy_c_buf_p = (char *) 0;
00220 static int yy_init = 1;         /* whether we need to initialize */
00221 static int yy_start = 0;        /* start state number */
00222 
00223 /* Flag which is used to allow yywrap()'s to do buffer switches
00224  * instead of setting up a fresh yyin.  A bit of a hack ...
00225  */
00226 static int yy_did_buffer_switch_on_eof;
00227 
00228 void yyrestart YY_PROTO(( FILE *input_file ));
00229 
00230 void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
00231 void yy_load_buffer_state YY_PROTO(( void ));
00232 YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
00233 void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
00234 void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));
00235 void yy_flush_buffer YY_PROTO(( YY_BUFFER_STATE b ));
00236 #define YY_FLUSH_BUFFER yy_flush_buffer( yy_current_buffer )
00237 
00238 YY_BUFFER_STATE yy_scan_buffer YY_PROTO(( char *base, yy_size_t size ));
00239 YY_BUFFER_STATE yy_scan_string YY_PROTO(( yyconst char *yy_str ));
00240 YY_BUFFER_STATE yy_scan_bytes YY_PROTO(( yyconst char *bytes, int len ));
00241 
00242 static void *yy_flex_alloc YY_PROTO(( yy_size_t ));
00243 static void *yy_flex_realloc YY_PROTO(( void *, yy_size_t ));
00244 static void yy_flex_free YY_PROTO(( void * ));
00245 
00246 #define yy_new_buffer yy_create_buffer
00247 
00248 #define yy_set_interactive(is_interactive) \
00249         { \
00250         if ( ! yy_current_buffer ) \
00251                 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
00252         yy_current_buffer->yy_is_interactive = is_interactive; \
00253         }
00254 
00255 #define yy_set_bol(at_bol) \
00256         { \
00257         if ( ! yy_current_buffer ) \
00258                 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
00259         yy_current_buffer->yy_at_bol = at_bol; \
00260         }
00261 
00262 #define YY_AT_BOL() (yy_current_buffer->yy_at_bol)
00263 
00264 typedef unsigned char YY_CHAR;
00265 FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
00266 typedef int yy_state_type;
00267 extern char *yytext;
00268 #define yytext_ptr yytext
00269 
00270 static yy_state_type yy_get_previous_state YY_PROTO(( void ));
00271 static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
00272 static int yy_get_next_buffer YY_PROTO(( void ));
00273 static void yy_fatal_error YY_PROTO(( yyconst char msg[] ));
00274 
00275 /* Done after the current pattern has been matched and before the
00276  * corresponding action - sets up yytext.
00277  */
00278 #define YY_DO_BEFORE_ACTION \
00279         yytext_ptr = yy_bp; \
00280         yyleng = (int) (yy_cp - yy_bp); \
00281         yy_hold_char = *yy_cp; \
00282         *yy_cp = '\0'; \
00283         yy_c_buf_p = yy_cp;
00284 
00285 #define YY_NUM_RULES 8
00286 #define YY_END_OF_BUFFER 9
00287 static yyconst short int yy_accept[24] =
00288     {   0,
00289         0,    0,    9,    7,    4,    3,    7,    2,    1,    0,
00290         5,    2,    0,    1,    0,    0,    5,    0,    2,    1,
00291         1,    6,    0
00292     } ;
00293 
00294 static yyconst int yy_ec[256] =
00295     {   0,
00296         1,    1,    1,    1,    1,    1,    1,    1,    2,    3,
00297         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00298         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00299         1,    2,    1,    1,    1,    1,    1,    1,    1,    1,
00300         1,    4,    5,    1,    6,    1,    7,    8,    8,    8,
00301         8,    8,    8,    8,    8,    8,    8,    1,    1,    1,
00302         1,    1,    1,    1,    9,    9,    9,    9,   10,    9,
00303         9,    9,    9,    9,    9,    9,    9,    9,    9,    9,
00304         9,    9,    9,    9,    9,    9,    9,    9,    9,    9,
00305         1,    1,    1,    1,    9,    1,    9,    9,    9,    9,
00306 
00307        10,    9,    9,    9,    9,    9,    9,    9,    9,    9,
00308         9,    9,    9,    9,    9,    9,    9,    9,    9,    9,
00309         9,    9,    1,    1,    1,    1,    1,    1,    1,    1,
00310         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00311         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00312         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00313         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00314         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00315         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00316         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00317 
00318         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00319         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00320         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00321         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00322         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00323         1,    1,    1,    1,    1
00324     } ;
00325 
00326 static yyconst int yy_meta[11] =
00327     {   0,
00328         1,    1,    2,    1,    3,    4,    1,    5,    6,    6
00329     } ;
00330 
00331 static yyconst short int yy_base[29] =
00332     {   0,
00333         0,    0,   42,   43,   43,   43,    7,    7,    0,   37,
00334         0,    0,   32,   33,   34,   20,    0,    8,    5,    6,
00335         0,   43,   43,   13,   19,   25,   29,   31
00336     } ;
00337 
00338 static yyconst short int yy_def[29] =
00339     {   0,
00340        23,    1,   23,   23,   23,   23,   23,   23,   24,   25,
00341        26,    8,   27,   28,   25,   25,   26,   23,   23,   28,
00342        20,   23,    0,   23,   23,   23,   23,   23
00343     } ;
00344 
00345 static yyconst short int yy_nxt[54] =
00346     {   0,
00347         4,    5,    6,    4,    4,    4,    7,    8,    9,    9,
00348        10,   20,   19,   11,   12,   19,   13,   14,   14,   15,
00349        15,   15,   15,   15,   15,   17,   22,   17,   17,   17,
00350        17,   18,   18,   18,   21,   21,   21,   16,   20,   19,
00351        16,   23,    3,   23,   23,   23,   23,   23,   23,   23,
00352        23,   23,   23
00353     } ;
00354 
00355 static yyconst short int yy_chk[54] =
00356     {   0,
00357         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00358         7,   20,   19,    7,    8,   18,    8,   24,   24,   25,
00359        25,   25,   25,   25,   25,   26,   16,   26,   26,   26,
00360        26,   27,   27,   27,   28,   28,   28,   15,   14,   13,
00361        10,    3,   23,   23,   23,   23,   23,   23,   23,   23,
00362        23,   23,   23
00363     } ;
00364 
00365 static yy_state_type yy_last_accepting_state;
00366 static char *yy_last_accepting_cpos;
00367 
00368 /* The intent behind this definition is that it'll catch
00369  * any uses of REJECT which flex missed.
00370  */
00371 #define REJECT reject_used_but_not_detected
00372 #define yymore() yymore_used_but_not_detected
00373 #define YY_MORE_ADJ 0
00374 #define YY_RESTORE_YY_MORE_OFFSET
00375 char *yytext;
00376 #line 1 "dotty_scanner.l"
00377 #define INITIAL 0
00378 /*--------------------------------------------------------------------
00379  *
00380  * (C) Copyright Koninklijke Philips Electronics NV 2006. 
00381  * All rights reserved. This software is licensed under the terms of
00382  * version 2.1 of the GNU Lesser General Public License as published 
00383  * by the Free Software Foundation. For licensing and warranty
00384  * information, see the file COPYING in the main directory.
00385  *
00386  *------------------------------------------------------------------*/
00387 #define YY_NEVER_INTERACTIVE 1
00388 #line 13 "dotty_scanner.l"
00389 #include "dotty_parser.h"
00390 #include "strdup.h"
00391 #include <string>
00392 
00393 //extern int fileno(FILE*);
00394 extern char* yyfilename;
00395 extern int yylineno;
00396 #line 397 "lex.yy.c"
00397 
00398 /* Macros after this point can all be overridden by user definitions in
00399  * section 1.
00400  */
00401 
00402 #ifndef YY_SKIP_YYWRAP
00403 #ifdef __cplusplus
00404 extern "C" int yywrap YY_PROTO(( void ));
00405 #else
00406 extern int yywrap YY_PROTO(( void ));
00407 #endif
00408 #endif
00409 
00410 #ifndef YY_NO_UNPUT
00411 static void yyunput YY_PROTO(( int c, char *buf_ptr ));
00412 #endif
00413 
00414 #ifndef yytext_ptr
00415 static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));
00416 #endif
00417 
00418 #ifdef YY_NEED_STRLEN
00419 static int yy_flex_strlen YY_PROTO(( yyconst char * ));
00420 #endif
00421 
00422 #ifndef YY_NO_INPUT
00423 #ifdef __cplusplus
00424 static int yyinput YY_PROTO(( void ));
00425 #else
00426 static int input YY_PROTO(( void ));
00427 #endif
00428 #endif
00429 
00430 #if YY_STACK_USED
00431 static int yy_start_stack_ptr = 0;
00432 static int yy_start_stack_depth = 0;
00433 static int *yy_start_stack = 0;
00434 #ifndef YY_NO_PUSH_STATE
00435 static void yy_push_state YY_PROTO(( int new_state ));
00436 #endif
00437 #ifndef YY_NO_POP_STATE
00438 static void yy_pop_state YY_PROTO(( void ));
00439 #endif
00440 #ifndef YY_NO_TOP_STATE
00441 static int yy_top_state YY_PROTO(( void ));
00442 #endif
00443 
00444 #else
00445 #define YY_NO_PUSH_STATE 1
00446 #define YY_NO_POP_STATE 1
00447 #define YY_NO_TOP_STATE 1
00448 #endif
00449 
00450 #ifdef YY_MALLOC_DECL
00451 YY_MALLOC_DECL
00452 #else
00453 #if __STDC__
00454 #ifndef __cplusplus
00455 #include <stdlib.h>
00456 #endif
00457 #else
00458 /* Just try to get by without declaring the routines.  This will fail
00459  * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int)
00460  * or sizeof(void*) != sizeof(int).
00461  */
00462 #endif
00463 #endif
00464 
00465 /* Amount of stuff to slurp up with each read. */
00466 #ifndef YY_READ_BUF_SIZE
00467 #define YY_READ_BUF_SIZE 8192
00468 #endif
00469 
00470 /* Copy whatever the last rule matched to the standard output. */
00471 
00472 #ifndef ECHO
00473 /* This used to be an fputs(), but since the string might contain NUL's,
00474  * we now use fwrite().
00475  */
00476 #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
00477 #endif
00478 
00479 /* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
00480  * is returned in "result".
00481  */
00482 #ifndef YY_INPUT
00483 #define YY_INPUT(buf,result,max_size) \
00484         if ( yy_current_buffer->yy_is_interactive ) \
00485                 { \
00486                 int c = '*', n; \
00487                 for ( n = 0; n < max_size && \
00488                              (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
00489                         buf[n] = (char) c; \
00490                 if ( c == '\n' ) \
00491                         buf[n++] = (char) c; \
00492                 if ( c == EOF && ferror( yyin ) ) \
00493                         YY_FATAL_ERROR( "input in flex scanner failed" ); \
00494                 result = n; \
00495                 } \
00496         else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
00497                   && ferror( yyin ) ) \
00498                 YY_FATAL_ERROR( "input in flex scanner failed" );
00499 #endif
00500 
00501 /* No semi-colon after return; correct usage is to write "yyterminate();" -
00502  * we don't want an extra ';' after the "return" because that will cause
00503  * some compilers to complain about unreachable statements.
00504  */
00505 #ifndef yyterminate
00506 #define yyterminate() return YY_NULL
00507 #endif
00508 
00509 /* Number of entries by which start-condition stack grows. */
00510 #ifndef YY_START_STACK_INCR
00511 #define YY_START_STACK_INCR 25
00512 #endif
00513 
00514 /* Report a fatal error. */
00515 #ifndef YY_FATAL_ERROR
00516 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
00517 #endif
00518 
00519 /* Default declaration of generated scanner - a define so the user can
00520  * easily add parameters.
00521  */
00522 #ifndef YY_DECL
00523 #define YY_DECL int yylex YY_PROTO(( void ))
00524 #endif
00525 
00526 /* Code executed at the beginning of each rule, after yytext and yyleng
00527  * have been set up.
00528  */
00529 #ifndef YY_USER_ACTION
00530 #define YY_USER_ACTION
00531 #endif
00532 
00533 /* Code executed at the end of each rule. */
00534 #ifndef YY_BREAK
00535 #define YY_BREAK break;
00536 #endif
00537 
00538 #define YY_RULE_SETUP \
00539         YY_USER_ACTION
00540 
00541 YY_DECL
00542         {
00543         register yy_state_type yy_current_state;
00544         register char *yy_cp = NULL, *yy_bp = NULL;
00545         register int yy_act;
00546 
00547 #line 29 "dotty_scanner.l"
00548 
00549 #line 550 "lex.yy.c"
00550 
00551         if ( yy_init )
00552                 {
00553                 yy_init = 0;
00554 
00555 #ifdef YY_USER_INIT
00556                 YY_USER_INIT;
00557 #endif
00558 
00559                 if ( ! yy_start )
00560                         yy_start = 1;   /* first start state */
00561 
00562                 if ( ! yyin )
00563                         yyin = stdin;
00564 
00565                 if ( ! yyout )
00566                         yyout = stdout;
00567 
00568                 if ( ! yy_current_buffer )
00569                         yy_current_buffer =
00570                                 yy_create_buffer( yyin, YY_BUF_SIZE );
00571 
00572                 yy_load_buffer_state();
00573                 }
00574 
00575         while ( 1 )             /* loops until end-of-file is reached */
00576                 {
00577                 yy_cp = yy_c_buf_p;
00578 
00579                 /* Support of yytext. */
00580                 *yy_cp = yy_hold_char;
00581 
00582                 /* yy_bp points to the position in yy_ch_buf of the start of
00583                  * the current run.
00584                  */
00585                 yy_bp = yy_cp;
00586 
00587                 yy_current_state = yy_start;
00588 yy_match:
00589                 do
00590                         {
00591                         register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
00592                         if ( yy_accept[yy_current_state] )
00593                                 {
00594                                 yy_last_accepting_state = yy_current_state;
00595                                 yy_last_accepting_cpos = yy_cp;
00596                                 }
00597                         while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
00598                                 {
00599                                 yy_current_state = (int) yy_def[yy_current_state];
00600                                 if ( yy_current_state >= 24 )
00601                                         yy_c = yy_meta[(unsigned int) yy_c];
00602                                 }
00603                         yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
00604                         ++yy_cp;
00605                         }
00606                 while ( yy_current_state != 23 );
00607                 yy_cp = yy_last_accepting_cpos;
00608                 yy_current_state = yy_last_accepting_state;
00609 
00610 yy_find_action:
00611                 yy_act = yy_accept[yy_current_state];
00612 
00613                 YY_DO_BEFORE_ACTION;
00614 
00615 
00616 do_action:      /* This label is used only to access EOF actions. */
00617 
00618 
00619                 switch ( yy_act )
00620         { /* beginning of action switch */
00621                         case 0: /* must back up */
00622                         /* undo the effects of YY_DO_BEFORE_ACTION */
00623                         *yy_cp = yy_hold_char;
00624                         yy_cp = yy_last_accepting_cpos;
00625                         yy_current_state = yy_last_accepting_state;
00626                         goto yy_find_action;
00627 
00628 case 1:
00629 YY_RULE_SETUP
00630 #line 30 "dotty_scanner.l"
00631 { yylval.s = strDup(yytext); return STRING; }
00632         YY_BREAK
00633 case 2:
00634 YY_RULE_SETUP
00635 #line 31 "dotty_scanner.l"
00636 { yylval.n = atoi(yytext); return INTEGER; }
00637         YY_BREAK
00638 case 3:
00639 YY_RULE_SETUP
00640 #line 32 "dotty_scanner.l"
00641 yylineno++;
00642         YY_BREAK
00643 case 4:
00644 YY_RULE_SETUP
00645 #line 33 "dotty_scanner.l"
00646 ;
00647         YY_BREAK
00648 case 5:
00649 YY_RULE_SETUP
00650 #line 34 "dotty_scanner.l"
00651 ;
00652         YY_BREAK
00653 case 6:
00654 YY_RULE_SETUP
00655 #line 35 "dotty_scanner.l"
00656 ;
00657         YY_BREAK
00658 case 7:
00659 YY_RULE_SETUP
00660 #line 36 "dotty_scanner.l"
00661 return yytext[0];
00662         YY_BREAK
00663 case 8:
00664 YY_RULE_SETUP
00665 #line 37 "dotty_scanner.l"
00666 ECHO;
00667         YY_BREAK
00668 #line 669 "lex.yy.c"
00669 case YY_STATE_EOF(INITIAL):
00670         yyterminate();
00671 
00672         case YY_END_OF_BUFFER:
00673                 {
00674                 /* Amount of text matched not including the EOB char. */
00675                 int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1;
00676 
00677                 /* Undo the effects of YY_DO_BEFORE_ACTION. */
00678                 *yy_cp = yy_hold_char;
00679                 YY_RESTORE_YY_MORE_OFFSET
00680 
00681                 if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW )
00682                         {
00683                         /* We're scanning a new file or input source.  It's
00684                          * possible that this happened because the user
00685                          * just pointed yyin at a new source and called
00686                          * yylex().  If so, then we have to assure
00687                          * consistency between yy_current_buffer and our
00688                          * globals.  Here is the right place to do so, because
00689                          * this is the first action (other than possibly a
00690                          * back-up) that will match for the new input source.
00691                          */
00692                         yy_n_chars = yy_current_buffer->yy_n_chars;
00693                         yy_current_buffer->yy_input_file = yyin;
00694                         yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL;
00695                         }
00696 
00697                 /* Note that here we test for yy_c_buf_p "<=" to the position
00698                  * of the first EOB in the buffer, since yy_c_buf_p will
00699                  * already have been incremented past the NUL character
00700                  * (since all states make transitions on EOB to the
00701                  * end-of-buffer state).  Contrast this with the test
00702                  * in input().
00703                  */
00704                 if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
00705                         { /* This was really a NUL. */
00706                         yy_state_type yy_next_state;
00707 
00708                         yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text;
00709 
00710                         yy_current_state = yy_get_previous_state();
00711 
00712                         /* Okay, we're now positioned to make the NUL
00713                          * transition.  We couldn't have
00714                          * yy_get_previous_state() go ahead and do it
00715                          * for us because it doesn't know how to deal
00716                          * with the possibility of jamming (and we don't
00717                          * want to build jamming into it because then it
00718                          * will run more slowly).
00719                          */
00720 
00721                         yy_next_state = yy_try_NUL_trans( yy_current_state );
00722 
00723                         yy_bp = yytext_ptr + YY_MORE_ADJ;
00724 
00725                         if ( yy_next_state )
00726                                 {
00727                                 /* Consume the NUL. */
00728                                 yy_cp = ++yy_c_buf_p;
00729                                 yy_current_state = yy_next_state;
00730                                 goto yy_match;
00731                                 }
00732 
00733                         else
00734                                 {
00735                                 yy_cp = yy_last_accepting_cpos;
00736                                 yy_current_state = yy_last_accepting_state;
00737                                 goto yy_find_action;
00738                                 }
00739                         }
00740 
00741                 else switch ( yy_get_next_buffer() )
00742                         {
00743                         case EOB_ACT_END_OF_FILE:
00744                                 {
00745                                 yy_did_buffer_switch_on_eof = 0;
00746 
00747                                 if ( yywrap() )
00748                                         {
00749                                         /* Note: because we've taken care in
00750                                          * yy_get_next_buffer() to have set up
00751                                          * yytext, we can now set up
00752                                          * yy_c_buf_p so that if some total
00753                                          * hoser (like flex itself) wants to
00754                                          * call the scanner after we return the
00755                                          * YY_NULL, it'll still work - another
00756                                          * YY_NULL will get returned.
00757                                          */
00758                                         yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
00759 
00760                                         yy_act = YY_STATE_EOF(YY_START);
00761                                         goto do_action;
00762                                         }
00763 
00764                                 else
00765                                         {
00766                                         if ( ! yy_did_buffer_switch_on_eof )
00767                                                 YY_NEW_FILE;
00768                                         }
00769                                 break;
00770                                 }
00771 
00772                         case EOB_ACT_CONTINUE_SCAN:
00773                                 yy_c_buf_p =
00774                                         yytext_ptr + yy_amount_of_matched_text;
00775 
00776                                 yy_current_state = yy_get_previous_state();
00777 
00778                                 yy_cp = yy_c_buf_p;
00779                                 yy_bp = yytext_ptr + YY_MORE_ADJ;
00780                                 goto yy_match;
00781 
00782                         case EOB_ACT_LAST_MATCH:
00783                                 yy_c_buf_p =
00784                                 &yy_current_buffer->yy_ch_buf[yy_n_chars];
00785 
00786                                 yy_current_state = yy_get_previous_state();
00787 
00788                                 yy_cp = yy_c_buf_p;
00789                                 yy_bp = yytext_ptr + YY_MORE_ADJ;
00790                                 goto yy_find_action;
00791                         }
00792                 break;
00793                 }
00794 
00795         default:
00796                 YY_FATAL_ERROR(
00797                         "fatal flex scanner internal error--no action found" );
00798         } /* end of action switch */
00799                 } /* end of scanning one token */
00800         } /* end of yylex */
00801 
00802 
00803 /* yy_get_next_buffer - try to read in a new buffer
00804  *
00805  * Returns a code representing an action:
00806  *      EOB_ACT_LAST_MATCH -
00807  *      EOB_ACT_CONTINUE_SCAN - continue scanning from current position
00808  *      EOB_ACT_END_OF_FILE - end of file
00809  */
00810 
00811 static int yy_get_next_buffer()
00812         {
00813         register char *dest = yy_current_buffer->yy_ch_buf;
00814         register char *source = yytext_ptr;
00815         register int number_to_move, i;
00816         int ret_val;
00817 
00818         if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
00819                 YY_FATAL_ERROR(
00820                 "fatal flex scanner internal error--end of buffer missed" );
00821 
00822         if ( yy_current_buffer->yy_fill_buffer == 0 )
00823                 { /* Don't try to fill the buffer, so this is an EOF. */
00824                 if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 )
00825                         {
00826                         /* We matched a single character, the EOB, so
00827                          * treat this as a final EOF.
00828                          */
00829                         return EOB_ACT_END_OF_FILE;
00830                         }
00831 
00832                 else
00833                         {
00834                         /* We matched some text prior to the EOB, first
00835                          * process it.
00836                          */
00837                         return EOB_ACT_LAST_MATCH;
00838                         }
00839                 }
00840 
00841         /* Try to read more data. */
00842 
00843         /* First move last chars to start of buffer. */
00844         number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1;
00845 
00846         for ( i = 0; i < number_to_move; ++i )
00847                 *(dest++) = *(source++);
00848 
00849         if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING )
00850                 /* don't do the read, it's not guaranteed to return an EOF,
00851                  * just force an EOF
00852                  */
00853                 yy_current_buffer->yy_n_chars = yy_n_chars = 0;
00854 
00855         else
00856                 {
00857                 int num_to_read =
00858                         yy_current_buffer->yy_buf_size - number_to_move - 1;
00859 
00860                 while ( num_to_read <= 0 )
00861                         { /* Not enough room in the buffer - grow it. */
00862 #ifdef YY_USES_REJECT
00863                         YY_FATAL_ERROR(
00864 "input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
00865 #else
00866 
00867                         /* just a shorter name for the current buffer */
00868                         YY_BUFFER_STATE b = yy_current_buffer;
00869 
00870                         int yy_c_buf_p_offset =
00871                                 (int) (yy_c_buf_p - b->yy_ch_buf);
00872 
00873                         if ( b->yy_is_our_buffer )
00874                                 {
00875                                 int new_size = b->yy_buf_size * 2;
00876 
00877                                 if ( new_size <= 0 )
00878                                         b->yy_buf_size += b->yy_buf_size / 8;
00879                                 else
00880                                         b->yy_buf_size *= 2;
00881 
00882                                 b->yy_ch_buf = (char *)
00883                                         /* Include room in for 2 EOB chars. */
00884                                         yy_flex_realloc( (void *) b->yy_ch_buf,
00885                                                          b->yy_buf_size + 2 );
00886                                 }
00887                         else
00888                                 /* Can't grow it, we don't own it. */
00889                                 b->yy_ch_buf = 0;
00890 
00891                         if ( ! b->yy_ch_buf )
00892                                 YY_FATAL_ERROR(
00893                                 "fatal error - scanner input buffer overflow" );
00894 
00895                         yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
00896 
00897                         num_to_read = yy_current_buffer->yy_buf_size -
00898                                                 number_to_move - 1;
00899 #endif
00900                         }
00901 
00902                 if ( num_to_read > YY_READ_BUF_SIZE )
00903                         num_to_read = YY_READ_BUF_SIZE;
00904 
00905                 /* Read in more data. */
00906                 YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
00907                         yy_n_chars, num_to_read );
00908 
00909                 yy_current_buffer->yy_n_chars = yy_n_chars;
00910                 }
00911 
00912         if ( yy_n_chars == 0 )
00913                 {
00914                 if ( number_to_move == YY_MORE_ADJ )
00915                         {
00916                         ret_val = EOB_ACT_END_OF_FILE;
00917                         yyrestart( yyin );
00918                         }
00919 
00920                 else
00921                         {
00922                         ret_val = EOB_ACT_LAST_MATCH;
00923                         yy_current_buffer->yy_buffer_status =
00924                                 YY_BUFFER_EOF_PENDING;
00925                         }
00926                 }
00927 
00928         else
00929                 ret_val = EOB_ACT_CONTINUE_SCAN;
00930 
00931         yy_n_chars += number_to_move;
00932         yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
00933         yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
00934 
00935         yytext_ptr = &yy_current_buffer->yy_ch_buf[0];
00936 
00937         return ret_val;
00938         }
00939 
00940 
00941 /* yy_get_previous_state - get the state just before the EOB char was reached */
00942 
00943 static yy_state_type yy_get_previous_state()
00944         {
00945         register yy_state_type yy_current_state;
00946         register char *yy_cp;
00947 
00948         yy_current_state = yy_start;
00949 
00950         for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
00951                 {
00952                 register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
00953                 if ( yy_accept[yy_current_state] )
00954                         {
00955                         yy_last_accepting_state = yy_current_state;
00956                         yy_last_accepting_cpos = yy_cp;
00957                         }
00958                 while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
00959                         {
00960                         yy_current_state = (int) yy_def[yy_current_state];
00961                         if ( yy_current_state >= 24 )
00962                                 yy_c = yy_meta[(unsigned int) yy_c];
00963                         }
00964                 yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
00965                 }
00966 
00967         return yy_current_state;
00968         }
00969 
00970 
00971 /* yy_try_NUL_trans - try to make a transition on the NUL character
00972  *
00973  * synopsis
00974  *      next_state = yy_try_NUL_trans( current_state );
00975  */
00976 
00977 #ifdef YY_USE_PROTOS
00978 static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state )
00979 #else
00980 static yy_state_type yy_try_NUL_trans( yy_current_state )
00981 yy_state_type yy_current_state;
00982 #endif
00983         {
00984         register int yy_is_jam;
00985         register char *yy_cp = yy_c_buf_p;
00986 
00987         register YY_CHAR yy_c = 1;
00988         if ( yy_accept[yy_current_state] )
00989                 {
00990                 yy_last_accepting_state = yy_current_state;
00991                 yy_last_accepting_cpos = yy_cp;
00992                 }
00993         while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
00994                 {
00995                 yy_current_state = (int) yy_def[yy_current_state];
00996                 if ( yy_current_state >= 24 )
00997                         yy_c = yy_meta[(unsigned int) yy_c];
00998                 }
00999         yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
01000         yy_is_jam = (yy_current_state == 23);
01001 
01002         return yy_is_jam ? 0 : yy_current_state;
01003         }
01004 
01005 
01006 #ifndef YY_NO_UNPUT
01007 #ifdef YY_USE_PROTOS
01008 static void yyunput( int c, register char *yy_bp )
01009 #else
01010 static void yyunput( c, yy_bp )
01011 int c;
01012 register char *yy_bp;
01013 #endif
01014         {
01015         register char *yy_cp = yy_c_buf_p;
01016 
01017         /* undo effects of setting up yytext */
01018         *yy_cp = yy_hold_char;
01019 
01020         if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
01021                 { /* need to shift things up to make room */
01022                 /* +2 for EOB chars. */
01023                 register int number_to_move = yy_n_chars + 2;
01024                 register char *dest = &yy_current_buffer->yy_ch_buf[
01025                                         yy_current_buffer->yy_buf_size + 2];
01026                 register char *source =
01027                                 &yy_current_buffer->yy_ch_buf[number_to_move];
01028 
01029                 while ( source > yy_current_buffer->yy_ch_buf )
01030                         *--dest = *--source;
01031 
01032                 yy_cp += (int) (dest - source);
01033                 yy_bp += (int) (dest - source);
01034                 yy_current_buffer->yy_n_chars =
01035                         yy_n_chars = yy_current_buffer->yy_buf_size;
01036 
01037                 if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
01038                         YY_FATAL_ERROR( "flex scanner push-back overflow" );
01039                 }
01040 
01041         *--yy_cp = (char) c;
01042 
01043 
01044         yytext_ptr = yy_bp;
01045         yy_hold_char = *yy_cp;
01046         yy_c_buf_p = yy_cp;
01047         }
01048 #endif  /* ifndef YY_NO_UNPUT */
01049 
01050 
01051 #ifndef YY_NO_INPUT
01052 #ifdef __cplusplus
01053 static int yyinput()
01054 #else
01055 static int input()
01056 #endif
01057         {
01058         int c;
01059 
01060         *yy_c_buf_p = yy_hold_char;
01061 
01062         if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
01063                 {
01064                 /* yy_c_buf_p now points to the character we want to return.
01065                  * If this occurs *before* the EOB characters, then it's a
01066                  * valid NUL; if not, then we've hit the end of the buffer.
01067                  */
01068                 if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
01069                         /* This was really a NUL. */
01070                         *yy_c_buf_p = '\0';
01071 
01072                 else
01073                         { /* need more input */
01074                         int offset = yy_c_buf_p - yytext_ptr;
01075                         ++yy_c_buf_p;
01076 
01077                         switch ( yy_get_next_buffer() )
01078                                 {
01079                                 case EOB_ACT_LAST_MATCH:
01080                                         /* This happens because yy_g_n_b()
01081                                          * sees that we've accumulated a
01082                                          * token and flags that we need to
01083                                          * try matching the token before
01084                                          * proceeding.  But for input(),
01085                                          * there's no matching to consider.
01086                                          * So convert the EOB_ACT_LAST_MATCH
01087                                          * to EOB_ACT_END_OF_FILE.
01088                                          */
01089 
01090                                         /* Reset buffer status. */
01091                                         yyrestart( yyin );
01092 
01093                                         /* fall through */
01094 
01095                                 case EOB_ACT_END_OF_FILE:
01096                                         {
01097                                         if ( yywrap() )
01098                                                 return EOF;
01099 
01100                                         if ( ! yy_did_buffer_switch_on_eof )
01101                                                 YY_NEW_FILE;
01102 #ifdef __cplusplus
01103                                         return yyinput();
01104 #else
01105                                         return input();
01106 #endif
01107                                         }
01108 
01109                                 case EOB_ACT_CONTINUE_SCAN:
01110                                         yy_c_buf_p = yytext_ptr + offset;
01111                                         break;
01112                                 }
01113                         }
01114                 }
01115 
01116         c = *(unsigned char *) yy_c_buf_p;      /* cast for 8-bit char's */
01117         *yy_c_buf_p = '\0';     /* preserve yytext */
01118         yy_hold_char = *++yy_c_buf_p;
01119 
01120 
01121         return c;
01122         }
01123 #endif /* YY_NO_INPUT */
01124 
01125 #ifdef YY_USE_PROTOS
01126 void yyrestart( FILE *input_file )
01127 #else
01128 void yyrestart( input_file )
01129 FILE *input_file;
01130 #endif
01131         {
01132         if ( ! yy_current_buffer )
01133                 yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );
01134 
01135         yy_init_buffer( yy_current_buffer, input_file );
01136         yy_load_buffer_state();
01137         }
01138 
01139 
01140 #ifdef YY_USE_PROTOS
01141 void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
01142 #else
01143 void yy_switch_to_buffer( new_buffer )
01144 YY_BUFFER_STATE new_buffer;
01145 #endif
01146         {
01147         if ( yy_current_buffer == new_buffer )
01148                 return;
01149 
01150         if ( yy_current_buffer )
01151                 {
01152                 /* Flush out information for old buffer. */
01153                 *yy_c_buf_p = yy_hold_char;
01154                 yy_current_buffer->yy_buf_pos = yy_c_buf_p;
01155                 yy_current_buffer->yy_n_chars = yy_n_chars;
01156                 }
01157 
01158         yy_current_buffer = new_buffer;
01159         yy_load_buffer_state();
01160 
01161         /* We don't actually know whether we did this switch during
01162          * EOF (yywrap()) processing, but the only time this flag
01163          * is looked at is after yywrap() is called, so it's safe
01164          * to go ahead and always set it.
01165          */
01166         yy_did_buffer_switch_on_eof = 1;
01167         }
01168 
01169 
01170 #ifdef YY_USE_PROTOS
01171 void yy_load_buffer_state( void )
01172 #else
01173 void yy_load_buffer_state()
01174 #endif
01175         {
01176         yy_n_chars = yy_current_buffer->yy_n_chars;
01177         yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
01178         yyin = yy_current_buffer->yy_input_file;
01179         yy_hold_char = *yy_c_buf_p;
01180         }
01181 
01182 
01183 #ifdef YY_USE_PROTOS
01184 YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
01185 #else
01186 YY_BUFFER_STATE yy_create_buffer( file, size )
01187 FILE *file;
01188 int size;
01189 #endif
01190         {
01191         YY_BUFFER_STATE b;
01192 
01193         b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
01194         if ( ! b )
01195                 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
01196 
01197         b->yy_buf_size = size;
01198 
01199         /* yy_ch_buf has to be 2 characters longer than the size given because
01200          * we need to put in 2 end-of-buffer characters.
01201          */
01202         b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 );
01203         if ( ! b->yy_ch_buf )
01204                 YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
01205 
01206         b->yy_is_our_buffer = 1;
01207 
01208         yy_init_buffer( b, file );
01209 
01210         return b;
01211         }
01212 
01213 
01214 #ifdef YY_USE_PROTOS
01215 void yy_delete_buffer( YY_BUFFER_STATE b )
01216 #else
01217 void yy_delete_buffer( b )
01218 YY_BUFFER_STATE b;
01219 #endif
01220         {
01221         if ( ! b )
01222                 return;
01223 
01224         if ( b == yy_current_buffer )
01225                 yy_current_buffer = (YY_BUFFER_STATE) 0;
01226 
01227         if ( b->yy_is_our_buffer )
01228                 yy_flex_free( (void *) b->yy_ch_buf );
01229 
01230         yy_flex_free( (void *) b );
01231         }
01232 
01233 
01234 
01235 #ifdef YY_USE_PROTOS
01236 void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
01237 #else
01238 void yy_init_buffer( b, file )
01239 YY_BUFFER_STATE b;
01240 FILE *file;
01241 #endif
01242 
01243 
01244         {
01245         yy_flush_buffer( b );
01246 
01247         b->yy_input_file = file;
01248         b->yy_fill_buffer = 1;
01249 
01250 #if YY_ALWAYS_INTERACTIVE
01251         b->yy_is_interactive = 1;
01252 #else
01253 #if YY_NEVER_INTERACTIVE
01254         b->yy_is_interactive = 0;
01255 #else
01256         b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
01257 #endif
01258 #endif
01259         }
01260 
01261 
01262 #ifdef YY_USE_PROTOS
01263 void yy_flush_buffer( YY_BUFFER_STATE b )
01264 #else
01265 void yy_flush_buffer( b )
01266 YY_BUFFER_STATE b;
01267 #endif
01268 
01269         {
01270         if ( ! b )
01271                 return;
01272 
01273         b->yy_n_chars = 0;
01274 
01275         /* We always need two end-of-buffer characters.  The first causes
01276          * a transition to the end-of-buffer state.  The second causes
01277          * a jam in that state.
01278          */
01279         b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
01280         b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
01281 
01282         b->yy_buf_pos = &b->yy_ch_buf[0];
01283 
01284         b->yy_at_bol = 1;
01285         b->yy_buffer_status = YY_BUFFER_NEW;
01286 
01287         if ( b == yy_current_buffer )
01288                 yy_load_buffer_state();
01289         }
01290 
01291 
01292 #ifndef YY_NO_SCAN_BUFFER
01293 #ifdef YY_USE_PROTOS
01294 YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size )
01295 #else
01296 YY_BUFFER_STATE yy_scan_buffer( base, size )
01297 char *base;
01298 yy_size_t size;
01299 #endif
01300         {
01301         YY_BUFFER_STATE b;
01302 
01303         if ( size < 2 ||
01304              base[size-2] != YY_END_OF_BUFFER_CHAR ||
01305              base[size-1] != YY_END_OF_BUFFER_CHAR )
01306                 /* They forgot to leave room for the EOB's. */
01307                 return 0;
01308 
01309         b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
01310         if ( ! b )
01311                 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
01312 
01313         b->yy_buf_size = size - 2;      /* "- 2" to take care of EOB's */
01314         b->yy_buf_pos = b->yy_ch_buf = base;
01315         b->yy_is_our_buffer = 0;
01316         b->yy_input_file = 0;
01317         b->yy_n_chars = b->yy_buf_size;
01318         b->yy_is_interactive = 0;
01319         b->yy_at_bol = 1;
01320         b->yy_fill_buffer = 0;
01321         b->yy_buffer_status = YY_BUFFER_NEW;
01322 
01323         yy_switch_to_buffer( b );
01324 
01325         return b;
01326         }
01327 #endif
01328 
01329 
01330 #ifndef YY_NO_SCAN_STRING
01331 #ifdef YY_USE_PROTOS
01332 YY_BUFFER_STATE yy_scan_string( yyconst char *yy_str )
01333 #else
01334 YY_BUFFER_STATE yy_scan_string( yy_str )
01335 yyconst char *yy_str;
01336 #endif
01337         {
01338         int len;
01339         for ( len = 0; yy_str[len]; ++len )
01340                 ;
01341 
01342         return yy_scan_bytes( yy_str, len );
01343         }
01344 #endif
01345 
01346 
01347 #ifndef YY_NO_SCAN_BYTES
01348 #ifdef YY_USE_PROTOS
01349 YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len )
01350 #else
01351 YY_BUFFER_STATE yy_scan_bytes( bytes, len )
01352 yyconst char *bytes;
01353 int len;
01354 #endif
01355         {
01356         YY_BUFFER_STATE b;
01357         char *buf;
01358         yy_size_t n;
01359         int i;
01360 
01361         /* Get memory for full buffer, including space for trailing EOB's. */
01362         n = len + 2;
01363         buf = (char *) yy_flex_alloc( n );
01364         if ( ! buf )
01365                 YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
01366 
01367         for ( i = 0; i < len; ++i )
01368                 buf[i] = bytes[i];
01369 
01370         buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR;
01371 
01372         b = yy_scan_buffer( buf, n );
01373         if ( ! b )
01374                 YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
01375 
01376         /* It's okay to grow etc. this buffer, and we should throw it
01377          * away when we're done.
01378          */
01379         b->yy_is_our_buffer = 1;
01380 
01381         return b;
01382         }
01383 #endif
01384 
01385 
01386 #ifndef YY_NO_PUSH_STATE
01387 #ifdef YY_USE_PROTOS
01388 static void yy_push_state( int new_state )
01389 #else
01390 static void yy_push_state( new_state )
01391 int new_state;
01392 #endif
01393         {
01394         if ( yy_start_stack_ptr >= yy_start_stack_depth )
01395                 {
01396                 yy_size_t new_size;
01397 
01398                 yy_start_stack_depth += YY_START_STACK_INCR;
01399                 new_size = yy_start_stack_depth * sizeof( int );
01400 
01401                 if ( ! yy_start_stack )
01402                         yy_start_stack = (int *) yy_flex_alloc( new_size );
01403 
01404                 else
01405                         yy_start_stack = (int *) yy_flex_realloc(
01406                                         (void *) yy_start_stack, new_size );
01407 
01408                 if ( ! yy_start_stack )
01409                         YY_FATAL_ERROR(
01410                         "out of memory expanding start-condition stack" );
01411                 }
01412 
01413         yy_start_stack[yy_start_stack_ptr++] = YY_START;
01414 
01415         BEGIN(new_state);
01416         }
01417 #endif
01418 
01419 
01420 #ifndef YY_NO_POP_STATE
01421 static void yy_pop_state()
01422         {
01423         if ( --yy_start_stack_ptr < 0 )
01424                 YY_FATAL_ERROR( "start-condition stack underflow" );
01425 
01426         BEGIN(yy_start_stack[yy_start_stack_ptr]);
01427         }
01428 #endif
01429 
01430 
01431 #ifndef YY_NO_TOP_STATE
01432 static int yy_top_state()
01433         {
01434         return yy_start_stack[yy_start_stack_ptr - 1];
01435         }
01436 #endif
01437 
01438 #ifndef YY_EXIT_FAILURE
01439 #define YY_EXIT_FAILURE 2
01440 #endif
01441 
01442 #ifdef YY_USE_PROTOS
01443 static void yy_fatal_error( yyconst char msg[] )
01444 #else
01445 static void yy_fatal_error( msg )
01446 char msg[];
01447 #endif
01448         {
01449         (void) fprintf( stderr, "%s\n", msg );
01450         exit( YY_EXIT_FAILURE );
01451         }
01452 
01453 
01454 
01455 /* Redefine yyless() so it works in section 3 code. */
01456 
01457 #undef yyless
01458 #define yyless(n) \
01459         do \
01460                 { \
01461                 /* Undo effects of setting up yytext. */ \
01462                 yytext[yyleng] = yy_hold_char; \
01463                 yy_c_buf_p = yytext + n; \
01464                 yy_hold_char = *yy_c_buf_p; \
01465                 *yy_c_buf_p = '\0'; \
01466                 yyleng = n; \
01467                 } \
01468         while ( 0 )
01469 
01470 
01471 /* Internal utility routines. */
01472 
01473 #ifndef yytext_ptr
01474 #ifdef YY_USE_PROTOS
01475 static void yy_flex_strncpy( char *s1, yyconst char *s2, int n )
01476 #else
01477 static void yy_flex_strncpy( s1, s2, n )
01478 char *s1;
01479 yyconst char *s2;
01480 int n;
01481 #endif
01482         {
01483         register int i;
01484         for ( i = 0; i < n; ++i )
01485                 s1[i] = s2[i];
01486         }
01487 #endif
01488 
01489 #ifdef YY_NEED_STRLEN
01490 #ifdef YY_USE_PROTOS
01491 static int yy_flex_strlen( yyconst char *s )
01492 #else
01493 static int yy_flex_strlen( s )
01494 yyconst char *s;
01495 #endif
01496         {
01497         register int n;
01498         for ( n = 0; s[n]; ++n )
01499                 ;
01500 
01501         return n;
01502         }
01503 #endif
01504 
01505 
01506 #ifdef YY_USE_PROTOS
01507 static void *yy_flex_alloc( yy_size_t size )
01508 #else
01509 static void *yy_flex_alloc( size )
01510 yy_size_t size;
01511 #endif
01512         {
01513         return (void *) malloc( size );
01514         }
01515 
01516 #ifdef YY_USE_PROTOS
01517 static void *yy_flex_realloc( void *ptr, yy_size_t size )
01518 #else
01519 static void *yy_flex_realloc( ptr, size )
01520 void *ptr;
01521 yy_size_t size;
01522 #endif
01523         {
01524         /* The cast to (char *) in the following accommodates both
01525          * implementations that use char* generic pointers, and those
01526          * that use void* generic pointers.  It works with the latter
01527          * because both ANSI C and C++ allow castless assignment from
01528          * any pointer type to void*, and deal with argument conversions
01529          * as though doing an assignment.
01530          */
01531         return (void *) realloc( (char *) ptr, size );
01532         }
01533 
01534 #ifdef YY_USE_PROTOS
01535 static void yy_flex_free( void *ptr )
01536 #else
01537 static void yy_flex_free( ptr )
01538 void *ptr;
01539 #endif
01540         {
01541         free( ptr );
01542         }
01543 
01544 #if YY_MAIN
01545 int main()
01546         {
01547         yylex();
01548         return 0;
01549         }
01550 #endif
01551 #line 37 "dotty_scanner.l"
01552 
01553 int yywrap() { return 1; }

Generated on Wed Feb 15 14:52:38 2006 for yapi by doxygen 1.3.2