Advanced Strategic Command
Classes | Macros | Typedefs | Functions | Variables
scanner.cpp File Reference
#include <stdio.h>
#include <string.h>
#include <errno.h>
#include <stdlib.h>
#include "parserbase.h"
#include <unistd.h>
Include dependency graph for scanner.cpp:

Go to the source code of this file.

Classes

struct  yy_buffer_state
 
struct  yy_trans_info
 
struct  yyguts_t
 

Macros

#define YY_INT_ALIGNED   short int
 
#define FLEX_SCANNER
 
#define YY_FLEX_MAJOR_VERSION   2
 
#define YY_FLEX_MINOR_VERSION   5
 
#define YY_FLEX_SUBMINOR_VERSION   35
 
#define FLEX_BETA
 
#define FLEXINT_H
 
#define INT8_MIN   (-128)
 
#define INT16_MIN   (-32767-1)
 
#define INT32_MIN   (-2147483647-1)
 
#define INT8_MAX   (127)
 
#define INT16_MAX   (32767)
 
#define INT32_MAX   (2147483647)
 
#define UINT8_MAX   (255U)
 
#define UINT16_MAX   (65535U)
 
#define UINT32_MAX   (4294967295U)
 
#define yyconst
 
#define YY_NULL   0
 
#define YY_SC_TO_UI(c)   ((unsigned int) (unsigned char) c)
 
#define YY_TYPEDEF_YY_SCANNER_T
 
#define yyin   yyg->yyin_r
 
#define yyout   yyg->yyout_r
 
#define yyextra   yyg->yyextra_r
 
#define yyleng   yyg->yyleng_r
 
#define yytext   yyg->yytext_r
 
#define yylineno   (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
 
#define yycolumn   (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
 
#define yy_flex_debug   yyg->yy_flex_debug_r
 
#define BEGIN   yyg->yy_start = 1 + 2 *
 
#define YY_START   ((yyg->yy_start - 1) / 2)
 
#define YYSTATE   YY_START
 
#define YY_STATE_EOF(state)   (YY_END_OF_BUFFER + state + 1)
 
#define YY_NEW_FILE   yyrestart(yyin ,yyscanner )
 
#define YY_END_OF_BUFFER_CHAR   0
 
#define YY_BUF_SIZE   16384
 
#define YY_STATE_BUF_SIZE   ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
 
#define YY_TYPEDEF_YY_BUFFER_STATE
 
#define EOB_ACT_CONTINUE_SCAN   0
 
#define EOB_ACT_END_OF_FILE   1
 
#define EOB_ACT_LAST_MATCH   2
 
#define YY_LESS_LINENO(n)
 
#define yyless(n)
 
#define unput(c)   yyunput( c, yyg->yytext_ptr , yyscanner )
 
#define YY_TYPEDEF_YY_SIZE_T
 
#define YY_STRUCT_YY_BUFFER_STATE
 
#define YY_BUFFER_NEW   0
 
#define YY_BUFFER_NORMAL   1
 
#define YY_BUFFER_EOF_PENDING   2
 
#define YY_CURRENT_BUFFER
 
#define YY_CURRENT_BUFFER_LVALUE   yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
 
#define YY_FLUSH_BUFFER   yy_flush_buffer(YY_CURRENT_BUFFER ,yyscanner)
 
#define yy_new_buffer   yy_create_buffer
 
#define yy_set_interactive(is_interactive)
 
#define yy_set_bol(at_bol)
 
#define YY_AT_BOL()   (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
 
#define yywrap(n)   1
 
#define YY_SKIP_YYWRAP
 
#define yytext_ptr   yytext_r
 
#define YY_DO_BEFORE_ACTION
 
#define YY_NUM_RULES   6
 
#define YY_END_OF_BUFFER   7
 
#define REJECT   reject_used_but_not_detected
 
#define yymore()   yymore_used_but_not_detected
 
#define YY_MORE_ADJ   0
 
#define YY_RESTORE_YY_MORE_OFFSET
 
#define ECHO
 
#define INITIAL   0
 
#define YY_EXTRA_TYPE   void *
 
#define YY_READ_BUF_SIZE   8192
 
#define YY_INPUT(buf, result, max_size)
 
#define yyterminate()   return YY_NULL
 
#define YY_START_STACK_INCR   25
 
#define YY_FATAL_ERROR(msg)   yy_fatal_error( msg , yyscanner)
 
#define YY_DECL_IS_OURS   1
 
#define YY_DECL   int yylex (yyscan_t yyscanner)
 
#define YY_USER_ACTION
 
#define YY_BREAK   break;
 
#define YY_RULE_SETUP   YY_USER_ACTION
 
#define YY_EXIT_FAILURE   2
 
#define yyless(n)
 
#define YYTABLES_NAME   "yytables"
 

Typedefs

typedef signed char flex_int8_t
 
typedef short int flex_int16_t
 
typedef int flex_int32_t
 
typedef unsigned char flex_uint8_t
 
typedef unsigned short int flex_uint16_t
 
typedef unsigned int flex_uint32_t
 
typedef void * yyscan_t
 
typedef struct yy_buffer_stateYY_BUFFER_STATE
 
typedef size_t yy_size_t
 
typedef unsigned char YY_CHAR
 
typedef int yy_state_type
 

Functions

void yyrestart (FILE *input_file, yyscan_t yyscanner)
 Immediately switch to a different input stream. More...
 
void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer, yyscan_t yyscanner)
 Switch to a different input buffer. More...
 
YY_BUFFER_STATE yy_create_buffer (FILE *file, int size, yyscan_t yyscanner)
 Allocate and initialize an input buffer state. More...
 
void yy_delete_buffer (YY_BUFFER_STATE b, yyscan_t yyscanner)
 Destroy the buffer. More...
 
void yy_flush_buffer (YY_BUFFER_STATE b, yyscan_t yyscanner)
 Discard all buffered characters. More...
 
void yypush_buffer_state (YY_BUFFER_STATE new_buffer, yyscan_t yyscanner)
 Pushes the new state onto the stack. More...
 
void yypop_buffer_state (yyscan_t yyscanner)
 Removes and deletes the top of the stack, if present. More...
 
static void yyensure_buffer_stack (yyscan_t yyscanner)
 
static void yy_load_buffer_state (yyscan_t yyscanner)
 
static void yy_init_buffer (YY_BUFFER_STATE b, FILE *file, yyscan_t yyscanner)
 
YY_BUFFER_STATE yy_scan_buffer (char *base, yy_size_t size, yyscan_t yyscanner)
 Setup the input buffer state to scan directly from a user-specified character buffer. More...
 
YY_BUFFER_STATE yy_scan_string (yyconst char *yystr, yyscan_t yyscanner)
 Setup the input buffer state to scan a string. More...
 
YY_BUFFER_STATE yy_scan_bytes (yyconst char *yybytes, int _yybytes_len, yyscan_t yyscanner)
 Setup the input buffer state to scan the given bytes. More...
 
void * yyalloc (yy_size_t, yyscan_t yyscanner)
 
void * yyrealloc (void *, yy_size_t, yyscan_t yyscanner)
 
void yyfree (void *, yyscan_t yyscanner)
 
static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
 
static yy_state_type yy_try_NUL_trans (yy_state_type current_state, yyscan_t yyscanner)
 
static int yy_get_next_buffer (yyscan_t yyscanner)
 
static void yy_fatal_error (yyconst char msg[], yyscan_t yyscanner)
 
static int yy_init_globals (yyscan_t yyscanner)
 
int yylex_init (yyscan_t *scanner)
 
int yylex_init_extra (YY_EXTRA_TYPE user_defined, yyscan_t *scanner)
 
int yylex_destroy (yyscan_t yyscanner)
 
int yyget_debug (yyscan_t yyscanner)
 
void yyset_debug (int debug_flag, yyscan_t yyscanner)
 
YY_EXTRA_TYPE yyget_extra (yyscan_t yyscanner)
 Get the user-defined data for this scanner. More...
 
void yyset_extra (YY_EXTRA_TYPE user_defined, yyscan_t yyscanner)
 Set the user-defined data. More...
 
FILE * yyget_in (yyscan_t yyscanner)
 Get the input stream. More...
 
void yyset_in (FILE *in_str, yyscan_t yyscanner)
 Set the input stream. More...
 
FILE * yyget_out (yyscan_t yyscanner)
 Get the output stream. More...
 
void yyset_out (FILE *out_str, yyscan_t yyscanner)
 
int yyget_leng (yyscan_t yyscanner)
 Get the length of the current token. More...
 
char * yyget_text (yyscan_t yyscanner)
 Get the current token. More...
 
int yyget_lineno (yyscan_t yyscanner)
 Get the current line number. More...
 
void yyset_lineno (int line_number, yyscan_t yyscanner)
 Set the current line number. More...
 
static void yyunput (int c, char *buf_ptr, yyscan_t yyscanner)
 
static int input (yyscan_t yyscanner)
 
int yylex (yyscan_t yyscanner)
 
 if (!yyg->yy_init)
 
 while (1)
 
static void yyunput (int c, register char *yy_bp, yyscan_t yyscanner)
 
int isatty (int)
 
static void yy_fatal_error (yyconst char *msg, yyscan_t yyscanner)
 
int yyget_column (yyscan_t yyscanner)
 Get the current column number. More...
 
void yyset_column (int column_no, yyscan_t yyscanner)
 Set the current column. More...
 

Variables

static yyconst flex_int16_t yy_accept [32]
 
static yyconst flex_int32_t yy_ec [256]
 
static yyconst flex_int32_t yy_meta [32]
 
static yyconst flex_int16_t yy_base [33]
 
static yyconst flex_int16_t yy_def [33]
 
static yyconst flex_int16_t yy_nxt [113]
 
static yyconst flex_int16_t yy_chk [113]
 
YY_DECL register yy_state_type yy_current_state
 The main scanner function which does all the work. More...
 
register char * yy_cp
 
register char * yy_bp
 
register int yy_act
 
struct yyguts_tyyg = (struct yyguts_t*)yyscanner
 

Macro Definition Documentation

#define BEGIN   yyg->yy_start = 1 + 2 *

Definition at line 143 of file scanner.cpp.

#define ECHO

Definition at line 468 of file scanner.cpp.

Referenced by while().

#define EOB_ACT_CONTINUE_SCAN   0

Definition at line 174 of file scanner.cpp.

Referenced by input(), while(), and yy_get_next_buffer().

#define EOB_ACT_END_OF_FILE   1

Definition at line 175 of file scanner.cpp.

Referenced by input(), while(), and yy_get_next_buffer().

#define EOB_ACT_LAST_MATCH   2

Definition at line 176 of file scanner.cpp.

Referenced by input(), while(), and yy_get_next_buffer().

#define FLEX_BETA

Definition at line 14 of file scanner.cpp.

#define FLEX_SCANNER

Definition at line 9 of file scanner.cpp.

#define FLEXINT_H

Definition at line 30 of file scanner.cpp.

#define INITIAL   0

Definition at line 471 of file scanner.cpp.

Referenced by while().

#define INT16_MAX   (32767)

Definition at line 72 of file scanner.cpp.

#define INT16_MIN   (-32767-1)

Definition at line 63 of file scanner.cpp.

#define INT32_MAX   (2147483647)

Definition at line 75 of file scanner.cpp.

#define INT32_MIN   (-2147483647-1)

Definition at line 66 of file scanner.cpp.

#define INT8_MAX   (127)

Definition at line 69 of file scanner.cpp.

#define INT8_MIN   (-128)

Definition at line 60 of file scanner.cpp.

#define REJECT   reject_used_but_not_detected

Definition at line 461 of file scanner.cpp.

#define UINT16_MAX   (65535U)

Definition at line 81 of file scanner.cpp.

#define UINT32_MAX   (4294967295U)

Definition at line 84 of file scanner.cpp.

#define UINT8_MAX   (255U)

Definition at line 78 of file scanner.cpp.

#define unput (   c)    yyunput( c, yyg->yytext_ptr , yyscanner )

Definition at line 194 of file scanner.cpp.

#define YY_AT_BOL ( )    (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)

Definition at line 325 of file scanner.cpp.

#define YY_BREAK   break;

Definition at line 675 of file scanner.cpp.

Referenced by while().

#define YY_BUF_SIZE   16384

Definition at line 162 of file scanner.cpp.

Referenced by if(), and yyrestart().

#define YY_BUFFER_EOF_PENDING   2

Definition at line 261 of file scanner.cpp.

Referenced by yy_get_next_buffer().

#define YY_BUFFER_NEW   0

Definition at line 249 of file scanner.cpp.

Referenced by while(), yy_flush_buffer(), and yy_scan_buffer().

#define YY_BUFFER_NORMAL   1

Definition at line 250 of file scanner.cpp.

Referenced by while().

#define YY_CURRENT_BUFFER
Value:
: NULL)
size_t yy_buffer_stack_top
index of top of stack.
Definition: scanner.cpp:494
struct yyguts_t * yyg
Definition: scanner.cpp:688
YY_BUFFER_STATE * yy_buffer_stack
Stack as an array.
Definition: scanner.cpp:496

Definition at line 272 of file scanner.cpp.

Referenced by if(), yy_delete_buffer(), yy_flush_buffer(), yy_get_next_buffer(), yy_init_buffer(), yy_switch_to_buffer(), yyget_column(), yyget_lineno(), yylex_destroy(), yypop_buffer_state(), yypush_buffer_state(), yyrestart(), yyset_column(), and yyset_lineno().

#define YY_CURRENT_BUFFER_LVALUE   yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
#define YY_DECL   int yylex (yyscan_t yyscanner)

Definition at line 663 of file scanner.cpp.

#define YY_DECL_IS_OURS   1

Definition at line 659 of file scanner.cpp.

#define YY_DO_BEFORE_ACTION
Value:
yyg->yytext_ptr = yy_bp; \
yyleng = (size_t) (yy_cp - yy_bp); \
*yy_cp = '\0'; \
struct yyguts_t * yyg
Definition: scanner.cpp:688
register char * yy_cp
Definition: scanner.cpp:686
char yy_hold_char
Definition: scanner.cpp:497
char * yy_c_buf_p
Definition: scanner.cpp:500
#define yyleng
Definition: scanner.cpp:133
register char * yy_bp
Definition: scanner.cpp:686

Definition at line 344 of file scanner.cpp.

Referenced by while().

#define YY_END_OF_BUFFER   7

Definition at line 352 of file scanner.cpp.

Referenced by while().

#define YY_END_OF_BUFFER_CHAR   0
#define YY_EXIT_FAILURE   2

Definition at line 1626 of file scanner.cpp.

Referenced by yy_fatal_error().

#define YY_EXTRA_TYPE   void *

Definition at line 482 of file scanner.cpp.

#define YY_FATAL_ERROR (   msg)    yy_fatal_error( msg , yyscanner)
#define yy_flex_debug   yyg->yy_flex_debug_r

Definition at line 137 of file scanner.cpp.

Referenced by yyget_debug(), and yyset_debug().

#define YY_FLEX_MAJOR_VERSION   2

Definition at line 10 of file scanner.cpp.

#define YY_FLEX_MINOR_VERSION   5

Definition at line 11 of file scanner.cpp.

#define YY_FLEX_SUBMINOR_VERSION   35

Definition at line 12 of file scanner.cpp.

#define YY_FLUSH_BUFFER   yy_flush_buffer(YY_CURRENT_BUFFER ,yyscanner)

Definition at line 293 of file scanner.cpp.

#define YY_INPUT (   buf,
  result,
  max_size 
)
Value:
if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
{ \
int c = '*'; \
size_t n; \
for ( n = 0; n < max_size && \
(c = getc( yyin )) != EOF && c != '\n'; ++n ) \
buf[n] = (char) c; \
if ( c == '\n' ) \
buf[n++] = (char) c; \
if ( c == EOF && ferror( yyin ) ) \
YY_FATAL_ERROR( "input in flex scanner failed" ); \
result = n; \
} \
else \
{ \
errno=0; \
while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \
{ \
if( errno != EINTR) \
{ \
YY_FATAL_ERROR( "input in flex scanner failed" ); \
break; \
} \
errno=0; \
clearerr(yyin); \
} \
}\
\
#define YY_CURRENT_BUFFER_LVALUE
Definition: scanner.cpp:279
#define YY_FATAL_ERROR(msg)
Definition: scanner.cpp:650
static int input(yyscan_t yyscanner)
Definition: scanner.cpp:1192
if(!yyg->yy_init)
Definition: scanner.cpp:695
#define yyin
Definition: scanner.cpp:130
while(1)
Definition: scanner.cpp:721

Definition at line 603 of file scanner.cpp.

Referenced by yy_get_next_buffer().

#define YY_INT_ALIGNED   short int

Definition at line 5 of file scanner.cpp.

#define YY_LESS_LINENO (   n)

Definition at line 178 of file scanner.cpp.

#define YY_MORE_ADJ   0

Definition at line 463 of file scanner.cpp.

Referenced by while(), yy_get_next_buffer(), and yy_get_previous_state().

#define yy_new_buffer   yy_create_buffer

Definition at line 303 of file scanner.cpp.

#define YY_NEW_FILE   yyrestart(yyin ,yyscanner )

Definition at line 156 of file scanner.cpp.

Referenced by input(), and while().

#define YY_NULL   0

Definition at line 113 of file scanner.cpp.

#define YY_NUM_RULES   6

Definition at line 351 of file scanner.cpp.

#define YY_READ_BUF_SIZE   8192

Definition at line 588 of file scanner.cpp.

Referenced by yy_get_next_buffer().

#define YY_RESTORE_YY_MORE_OFFSET

Definition at line 464 of file scanner.cpp.

Referenced by while().

#define YY_RULE_SETUP   YY_USER_ACTION

Definition at line 678 of file scanner.cpp.

Referenced by while().

#define YY_SC_TO_UI (   c)    ((unsigned int) (unsigned char) c)

Definition at line 120 of file scanner.cpp.

Referenced by while(), and yy_get_previous_state().

#define yy_set_bol (   at_bol)
Value:
{ \
} \
YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
}
#define YY_CURRENT_BUFFER
Definition: scanner.cpp:272
static void yyensure_buffer_stack(yyscan_t yyscanner)
Definition: scanner.cpp:1495
#define YY_CURRENT_BUFFER_LVALUE
Definition: scanner.cpp:279
YY_BUFFER_STATE yy_create_buffer(FILE *file, int size, yyscan_t yyscanner)
Allocate and initialize an input buffer state.
Definition: scanner.cpp:1333
#define YY_BUF_SIZE
Definition: scanner.cpp:162
if(!yyg->yy_init)
Definition: scanner.cpp:695
#define yyin
Definition: scanner.cpp:130

Definition at line 315 of file scanner.cpp.

#define yy_set_interactive (   is_interactive)
Value:
{ \
} \
YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
}
#define YY_CURRENT_BUFFER
Definition: scanner.cpp:272
static void yyensure_buffer_stack(yyscan_t yyscanner)
Definition: scanner.cpp:1495
#define YY_CURRENT_BUFFER_LVALUE
Definition: scanner.cpp:279
YY_BUFFER_STATE yy_create_buffer(FILE *file, int size, yyscan_t yyscanner)
Allocate and initialize an input buffer state.
Definition: scanner.cpp:1333
#define YY_BUF_SIZE
Definition: scanner.cpp:162
if(!yyg->yy_init)
Definition: scanner.cpp:695
#define yyin
Definition: scanner.cpp:130

Definition at line 305 of file scanner.cpp.

#define YY_SKIP_YYWRAP

Definition at line 328 of file scanner.cpp.

#define YY_START   ((yyg->yy_start - 1) / 2)

Definition at line 149 of file scanner.cpp.

Referenced by while().

#define YY_START_STACK_INCR   25

Definition at line 645 of file scanner.cpp.

#define YY_STATE_BUF_SIZE   ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))

Definition at line 167 of file scanner.cpp.

#define YY_STATE_EOF (   state)    (YY_END_OF_BUFFER + state + 1)

Definition at line 153 of file scanner.cpp.

Referenced by while().

#define YY_STRUCT_YY_BUFFER_STATE

Definition at line 202 of file scanner.cpp.

#define YY_TYPEDEF_YY_BUFFER_STATE

Definition at line 170 of file scanner.cpp.

#define YY_TYPEDEF_YY_SCANNER_T

Definition at line 124 of file scanner.cpp.

#define YY_TYPEDEF_YY_SIZE_T

Definition at line 197 of file scanner.cpp.

#define YY_USER_ACTION

Definition at line 670 of file scanner.cpp.

#define yycolumn   (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)

Definition at line 136 of file scanner.cpp.

Referenced by yyget_column(), and yyset_column().

#define yyconst

Definition at line 109 of file scanner.cpp.

#define yyextra   yyg->yyextra_r

Definition at line 132 of file scanner.cpp.

Referenced by yyget_extra(), and yyset_extra().

#define yyin   yyg->yyin_r
#define yyleng   yyg->yyleng_r

Definition at line 133 of file scanner.cpp.

Referenced by yyget_leng().

#define yyless (   n)
Value:
do \
{ \
/* Undo effects of setting up yytext. */ \
int yyless_macro_arg = (n); \
YY_LESS_LINENO(yyless_macro_arg);\
yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
YY_DO_BEFORE_ACTION; /* set up yytext again */ \
} \
while ( 0 )
#define YY_DO_BEFORE_ACTION
Definition: scanner.cpp:344
struct yyguts_t * yyg
Definition: scanner.cpp:688
register char * yy_cp
Definition: scanner.cpp:686
char yy_hold_char
Definition: scanner.cpp:497
#define YY_MORE_ADJ
Definition: scanner.cpp:463
char * yy_c_buf_p
Definition: scanner.cpp:500
register char * yy_bp
Definition: scanner.cpp:686
#define YY_LESS_LINENO(n)
Definition: scanner.cpp:178
while(1)
Definition: scanner.cpp:721

Definition at line 1638 of file scanner.cpp.

#define yyless (   n)
Value:
do \
{ \
/* Undo effects of setting up yytext. */ \
int yyless_macro_arg = (n); \
YY_LESS_LINENO(yyless_macro_arg);\
yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
*yyg->yy_c_buf_p = '\0'; \
yyleng = yyless_macro_arg; \
} \
while ( 0 )
struct yyguts_t * yyg
Definition: scanner.cpp:688
char yy_hold_char
Definition: scanner.cpp:497
char * yy_c_buf_p
Definition: scanner.cpp:500
#define yyleng
Definition: scanner.cpp:133
#define yytext
Definition: scanner.cpp:134
#define YY_LESS_LINENO(n)
Definition: scanner.cpp:178
while(1)
Definition: scanner.cpp:721

Definition at line 1638 of file scanner.cpp.

#define yylineno   (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)

Definition at line 135 of file scanner.cpp.

Referenced by yyget_lineno(), and yyset_lineno().

#define yymore ( )    yymore_used_but_not_detected

Definition at line 462 of file scanner.cpp.

#define yyout   yyg->yyout_r

Definition at line 131 of file scanner.cpp.

Referenced by if(), yy_init_globals(), yyget_out(), and yyset_out().

#define YYSTATE   YY_START

Definition at line 150 of file scanner.cpp.

#define YYTABLES_NAME   "yytables"

Definition at line 1971 of file scanner.cpp.

#define yyterminate ( )    return YY_NULL

Definition at line 640 of file scanner.cpp.

Referenced by while().

#define yytext   yyg->yytext_r

Definition at line 134 of file scanner.cpp.

Referenced by while(), and yyget_text().

#define yytext_ptr   yytext_r

Definition at line 334 of file scanner.cpp.

#define yywrap (   n)    1

Definition at line 327 of file scanner.cpp.

Referenced by input(), and while().

Typedef Documentation

typedef short int flex_int16_t

Definition at line 52 of file scanner.cpp.

typedef int flex_int32_t

Definition at line 53 of file scanner.cpp.

typedef signed char flex_int8_t

Definition at line 51 of file scanner.cpp.

typedef unsigned short int flex_uint16_t

Definition at line 55 of file scanner.cpp.

typedef unsigned int flex_uint32_t

Definition at line 56 of file scanner.cpp.

typedef unsigned char flex_uint8_t

Definition at line 54 of file scanner.cpp.

Definition at line 171 of file scanner.cpp.

typedef unsigned char YY_CHAR

Definition at line 330 of file scanner.cpp.

typedef size_t yy_size_t

Definition at line 198 of file scanner.cpp.

typedef int yy_state_type

Definition at line 332 of file scanner.cpp.

typedef void* yyscan_t

Definition at line 125 of file scanner.cpp.

Function Documentation

if ( !yyg->  yy_init)
static int input ( yyscan_t  yyscanner)
static
int isatty ( int  )

Referenced by yy_init_buffer().

while ( )
YY_BUFFER_STATE yy_create_buffer ( FILE *  file,
int  size,
yyscan_t  yyscanner 
)

Allocate and initialize an input buffer state.

Parameters
fileA readable stream.
sizeThe character buffer size in bytes. When in doubt, use YY_BUF_SIZE.
yyscannerThe scanner object.
Returns
the allocated buffer state.

Definition at line 1333 of file scanner.cpp.

References yy_buffer_state::yy_buf_size, yy_buffer_state::yy_ch_buf, YY_FATAL_ERROR, yy_init_buffer(), yy_buffer_state::yy_is_our_buffer, and yyalloc().

Referenced by if(), and yyrestart().

void yy_delete_buffer ( YY_BUFFER_STATE  b,
yyscan_t  yyscanner 
)

Destroy the buffer.

Parameters
ba buffer created with yy_create_buffer()
yyscannerThe scanner object.

Definition at line 1361 of file scanner.cpp.

References yy_buffer_state::yy_ch_buf, YY_CURRENT_BUFFER, YY_CURRENT_BUFFER_LVALUE, yy_buffer_state::yy_is_our_buffer, and yyfree().

Referenced by yylex_destroy(), and yypop_buffer_state().

static void yy_fatal_error ( yyconst char  msg[],
yyscan_t  yyscanner 
)
static

Referenced by yyset_column(), and yyset_lineno().

static void yy_fatal_error ( yyconst char *  msg,
yyscan_t  yyscanner 
)
static

Definition at line 1629 of file scanner.cpp.

References YY_EXIT_FAILURE.

void yy_flush_buffer ( YY_BUFFER_STATE  b,
yyscan_t  yyscanner 
)

Discard all buffered characters.

On the next scan, YY_INPUT will be called.

Parameters
bthe buffer state to be flushed, usually YY_CURRENT_BUFFER.
yyscannerThe scanner object.

Definition at line 1414 of file scanner.cpp.

References yy_buffer_state::yy_at_bol, yy_buffer_state::yy_buf_pos, YY_BUFFER_NEW, yy_buffer_state::yy_buffer_status, yy_buffer_state::yy_ch_buf, YY_CURRENT_BUFFER, YY_END_OF_BUFFER_CHAR, yy_load_buffer_state(), and yy_buffer_state::yy_n_chars.

Referenced by yy_init_buffer().

static int yy_get_next_buffer ( yyscan_t  yyscanner)
static
static yy_state_type yy_get_previous_state ( yyscan_t  yyscanner)
static
static void yy_init_buffer ( YY_BUFFER_STATE  b,
FILE *  file,
yyscan_t  yyscanner 
)
static
static int yy_init_globals ( yyscan_t  yyscanner)
static
static void yy_load_buffer_state ( yyscan_t  yyscanner)
static
YY_BUFFER_STATE yy_scan_buffer ( char *  base,
yy_size_t  size,
yyscan_t  yyscanner 
)

Setup the input buffer state to scan directly from a user-specified character buffer.

Parameters
basethe character buffer
sizethe size in bytes of the character buffer
yyscannerThe scanner object.
Returns
the newly allocated buffer state object.

Definition at line 1545 of file scanner.cpp.

References yy_buffer_state::yy_at_bol, yy_buffer_state::yy_buf_pos, yy_buffer_state::yy_buf_size, YY_BUFFER_NEW, yy_buffer_state::yy_buffer_status, yy_buffer_state::yy_ch_buf, YY_END_OF_BUFFER_CHAR, YY_FATAL_ERROR, yy_buffer_state::yy_fill_buffer, yy_buffer_state::yy_input_file, yy_buffer_state::yy_is_interactive, yy_buffer_state::yy_is_our_buffer, yy_buffer_state::yy_n_chars, yy_switch_to_buffer(), and yyalloc().

Referenced by yy_scan_bytes().

YY_BUFFER_STATE yy_scan_bytes ( yyconst char *  yybytes,
int  _yybytes_len,
yyscan_t  yyscanner 
)

Setup the input buffer state to scan the given bytes.

The next call to yylex() will scan from a copy of bytes.

Parameters
bytesthe byte buffer to scan
lenthe number of bytes in the buffer pointed to by bytes.
yyscannerThe scanner object.
Returns
the newly allocated buffer state object.

Definition at line 1595 of file scanner.cpp.

References YY_END_OF_BUFFER_CHAR, YY_FATAL_ERROR, yy_buffer_state::yy_is_our_buffer, yy_scan_buffer(), and yyalloc().

Referenced by yy_scan_string().

YY_BUFFER_STATE yy_scan_string ( yyconst char *  yystr,
yyscan_t  yyscanner 
)

Setup the input buffer state to scan a string.

The next call to yylex() will scan from a copy of str.

Parameters
yystra NUL-terminated string to scan
yyscannerThe scanner object.
Returns
the newly allocated buffer state object.
Note
If you want to scan bytes that may contain NUL values, then use yy_scan_bytes() instead.

Definition at line 1582 of file scanner.cpp.

References yy_scan_bytes().

void yy_switch_to_buffer ( YY_BUFFER_STATE  new_buffer,
yyscan_t  yyscanner 
)

Switch to a different input buffer.

Parameters
new_bufferThe new input buffer.
yyscannerThe scanner object.

Definition at line 1286 of file scanner.cpp.

References yyguts_t::yy_c_buf_p, YY_CURRENT_BUFFER, YY_CURRENT_BUFFER_LVALUE, yyguts_t::yy_did_buffer_switch_on_eof, yyguts_t::yy_hold_char, yy_load_buffer_state(), yyguts_t::yy_n_chars, and yyensure_buffer_stack().

Referenced by yy_scan_buffer().

static yy_state_type yy_try_NUL_trans ( yy_state_type  current_state,
yyscan_t  yyscanner 
)
static
void * yyalloc ( yy_size_t  size,
yyscan_t  yyscanner 
)
static void yyensure_buffer_stack ( yyscan_t  yyscanner)
static
void yyfree ( void *  ptr,
yyscan_t  yyscanner 
)

Definition at line 1966 of file scanner.cpp.

Referenced by yy_delete_buffer(), and yylex_destroy().

int yyget_column ( yyscan_t  yyscanner)

Get the current column number.

Parameters
yyscannerThe scanner object.

Definition at line 1679 of file scanner.cpp.

References YY_CURRENT_BUFFER, and yycolumn.

int yyget_debug ( yyscan_t  yyscanner)

Definition at line 1784 of file scanner.cpp.

References yy_flex_debug.

YY_EXTRA_TYPE yyget_extra ( yyscan_t  yyscanner)

Get the user-defined data for this scanner.

Parameters
yyscannerThe scanner object.

Definition at line 1657 of file scanner.cpp.

References yyextra.

FILE * yyget_in ( yyscan_t  yyscanner)

Get the input stream.

Parameters
yyscannerThe scanner object.

Definition at line 1692 of file scanner.cpp.

References yyin.

int yyget_leng ( yyscan_t  yyscanner)

Get the length of the current token.

Parameters
yyscannerThe scanner object.

Definition at line 1710 of file scanner.cpp.

References yyleng.

int yyget_lineno ( yyscan_t  yyscanner)

Get the current line number.

Parameters
yyscannerThe scanner object.

Definition at line 1666 of file scanner.cpp.

References YY_CURRENT_BUFFER, and yylineno.

FILE * yyget_out ( yyscan_t  yyscanner)

Get the output stream.

Parameters
yyscannerThe scanner object.

Definition at line 1701 of file scanner.cpp.

References yyout.

char * yyget_text ( yyscan_t  yyscanner)

Get the current token.

Parameters
yyscannerThe scanner object.

Definition at line 1720 of file scanner.cpp.

References yytext.

int yylex ( yyscan_t  yyscanner)

Referenced by Scanner::yylex().

int yylex_destroy ( yyscan_t  yyscanner)
int yylex_init ( yyscan_t scanner)

Definition at line 1805 of file scanner.cpp.

References yy_init_globals(), and yyalloc().

Referenced by Scanner::Scanner().

int yylex_init_extra ( YY_EXTRA_TYPE  user_defined,
yyscan_t scanner 
)

Definition at line 1834 of file scanner.cpp.

References yy_init_globals(), yyalloc(), and yyset_extra().

void yypop_buffer_state ( yyscan_t  yyscanner)

Removes and deletes the top of the stack, if present.

The next element becomes the new top.

Parameters
yyscannerThe scanner object.

Definition at line 1475 of file scanner.cpp.

References yyguts_t::yy_buffer_stack_top, YY_CURRENT_BUFFER, YY_CURRENT_BUFFER_LVALUE, yy_delete_buffer(), yyguts_t::yy_did_buffer_switch_on_eof, and yy_load_buffer_state().

Referenced by yylex_destroy().

void yypush_buffer_state ( YY_BUFFER_STATE  new_buffer,
yyscan_t  yyscanner 
)

Pushes the new state onto the stack.

The new state becomes the current state. This function will allocate the stack if necessary.

Parameters
new_bufferThe new state.
yyscannerThe scanner object.

Definition at line 1444 of file scanner.cpp.

References yyguts_t::yy_buffer_stack_top, yyguts_t::yy_c_buf_p, YY_CURRENT_BUFFER, YY_CURRENT_BUFFER_LVALUE, yyguts_t::yy_did_buffer_switch_on_eof, yyguts_t::yy_hold_char, yy_load_buffer_state(), yyguts_t::yy_n_chars, and yyensure_buffer_stack().

void * yyrealloc ( void *  ptr,
yy_size_t  size,
yyscan_t  yyscanner 
)

Definition at line 1954 of file scanner.cpp.

Referenced by yy_get_next_buffer(), and yyensure_buffer_stack().

void yyrestart ( FILE *  input_file,
yyscan_t  yyscanner 
)

Immediately switch to a different input stream.

Parameters
input_fileA readable stream.
yyscannerThe scanner object.
Note
This function does not reset the start condition to INITIAL .

Definition at line 1268 of file scanner.cpp.

References YY_BUF_SIZE, yy_create_buffer(), YY_CURRENT_BUFFER, YY_CURRENT_BUFFER_LVALUE, yy_init_buffer(), yy_load_buffer_state(), yyensure_buffer_stack(), and yyin.

Referenced by input(), and yy_get_next_buffer().

void yyset_column ( int  column_no,
yyscan_t  yyscanner 
)

Set the current column.

Parameters
line_number
yyscannerThe scanner object.

Definition at line 1755 of file scanner.cpp.

References YY_CURRENT_BUFFER, yy_fatal_error(), and yycolumn.

void yyset_debug ( int  debug_flag,
yyscan_t  yyscanner 
)

Definition at line 1790 of file scanner.cpp.

References yy_flex_debug.

void yyset_extra ( YY_EXTRA_TYPE  user_defined,
yyscan_t  yyscanner 
)

Set the user-defined data.

This data is never touched by the scanner.

Parameters
user_definedThe data to be associated with this scanner.
yyscannerThe scanner object.

Definition at line 1730 of file scanner.cpp.

References yyextra.

Referenced by yylex_init_extra().

void yyset_in ( FILE *  in_str,
yyscan_t  yyscanner 
)

Set the input stream.

This does not discard the current input buffer.

Parameters
in_strA readable stream.
yyscannerThe scanner object.
See Also
yy_switch_to_buffer

Definition at line 1772 of file scanner.cpp.

References yyin.

void yyset_lineno ( int  line_number,
yyscan_t  yyscanner 
)

Set the current line number.

Parameters
line_number
yyscannerThe scanner object.

Definition at line 1740 of file scanner.cpp.

References YY_CURRENT_BUFFER, yy_fatal_error(), and yylineno.

void yyset_out ( FILE *  out_str,
yyscan_t  yyscanner 
)

Definition at line 1778 of file scanner.cpp.

References yyout.

Referenced by Scanner::Scanner().

static void yyunput ( int  c,
char *  buf_ptr,
yyscan_t  yyscanner 
)
static
static void yyunput ( int  c,
register char *  yy_bp,
yyscan_t  yyscanner 
)
static

Variable Documentation

yyconst flex_int16_t yy_accept[32]
static
Initial value:
=
{ 0,
0, 0, 7, 5, 1, 6, 5, 5, 5, 1,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 4, 0, 0, 3, 2,
0
}

Definition at line 360 of file scanner.cpp.

Referenced by while(), yy_get_previous_state(), and yy_try_NUL_trans().

register int yy_act

Definition at line 687 of file scanner.cpp.

yyconst flex_int16_t yy_base[33]
static
Initial value:
=
{ 0,
0, 28, 4, 81, 4, 81, 0, 1, 0, 6,
1, 5, 11, 27, 28, 25, 31, 28, 40, 42,
37, 46, 40, 53, 49, 81, 50, 59, 81, 81,
81, 0
}

Definition at line 408 of file scanner.cpp.

Referenced by while(), yy_get_previous_state(), and yy_try_NUL_trans().

register char * yy_bp

Definition at line 686 of file scanner.cpp.

Referenced by yyunput().

yyconst flex_int16_t yy_chk[113]
static
Initial value:
=
{ 0,
32, 1, 1, 3, 11, 5, 9, 10, 1, 1,
0, 7, 8, 1, 1, 0, 0, 5, 11, 10,
9, 12, 1, 1, 13, 7, 8, 1, 1, 2,
2, 5, 14, 10, 15, 12, 2, 2, 13, 16,
17, 2, 2, 18, 19, 20, 14, 21, 15, 22,
2, 2, 23, 16, 17, 2, 2, 18, 19, 20,
24, 21, 25, 22, 27, 28, 23, 0, 0, 0,
0, 0, 0, 0, 24, 0, 25, 0, 27, 28,
31, 31, 31, 31, 31, 31, 31, 31, 31, 31,
31, 31, 31, 31, 31, 31, 31, 31, 31, 31,
31, 31, 31, 31, 31, 31, 31, 31, 31, 31,
31, 31
}

Definition at line 441 of file scanner.cpp.

Referenced by while(), yy_get_previous_state(), and yy_try_NUL_trans().

register char* yy_cp

Definition at line 686 of file scanner.cpp.

Referenced by while(), yy_get_previous_state(), yy_try_NUL_trans(), and yyunput().

YY_DECL register yy_state_type yy_current_state

The main scanner function which does all the work.

Definition at line 685 of file scanner.cpp.

Referenced by while(), yy_get_previous_state(), and yy_try_NUL_trans().

yyconst flex_int16_t yy_def[33]
static
Initial value:
=
{ 0,
32, 32, 31, 31, 31, 31, 31, 31, 31, 31,
31, 31, 31, 31, 31, 31, 31, 31, 31, 31,
31, 31, 31, 31, 31, 31, 31, 31, 31, 31,
0, 31
}

Definition at line 416 of file scanner.cpp.

Referenced by while(), yy_get_previous_state(), and yy_try_NUL_trans().

yyconst flex_int32_t yy_ec[256]
static

Definition at line 368 of file scanner.cpp.

Referenced by while(), and yy_get_previous_state().

yyconst flex_int32_t yy_meta[32]
static
Initial value:
=
{ 0,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1
}

Definition at line 400 of file scanner.cpp.

Referenced by while(), yy_get_previous_state(), and yy_try_NUL_trans().

yyconst flex_int16_t yy_nxt[113]
static
Initial value:
=
{ 0,
4, 5, 6, 31, 14, 10, 13, 10, 7, 8,
31, 11, 12, 5, 9, 31, 31, 10, 14, 10,
13, 15, 7, 8, 16, 11, 12, 5, 9, 5,
6, 10, 17, 10, 18, 15, 7, 8, 16, 19,
20, 5, 9, 21, 22, 23, 17, 24, 18, 25,
7, 8, 26, 19, 20, 5, 9, 21, 22, 23,
27, 24, 28, 25, 29, 30, 26, 31, 31, 31,
31, 31, 31, 31, 27, 31, 28, 31, 29, 30,
3, 31, 31, 31, 31, 31, 31, 31, 31, 31,
31, 31, 31, 31, 31, 31, 31, 31, 31, 31,
31, 31, 31, 31, 31, 31, 31, 31, 31, 31,
31, 31
}

Definition at line 424 of file scanner.cpp.

Referenced by while(), yy_get_previous_state(), and yy_try_NUL_trans().

struct yyguts_t* yyg = (struct yyguts_t*)yyscanner

Definition at line 688 of file scanner.cpp.