torc-master
|
#include <iostream>
#include <errno.h>
#include <cstdlib>
#include <cstring>
#include <FlexLexer.h>
#include <string>
#include "torc/bitstream/assembler/lut/LutScanner.hpp"
Go to the source code of this file.
Data Structures | |
struct | yy_buffer_state |
Bison parser internals. More... | |
struct | yy_trans_info |
Bison parser internals. More... | |
Namespaces | |
torc | |
Implementation of class to encapsulate micro-bitstream library generation code. | |
torc::bitstream | |
Namespace for the Torc bitstream frame-level support, including packet parsing and writing. | |
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 | yyFlexLexer LutFlexLexer |
#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 | BEGIN (yy_start) = 1 + 2 * |
#define | YY_START (((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 ) |
#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, (yytext_ptr) ) |
#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 (yy_buffer_stack)[(yy_buffer_stack_top)] |
#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 | yytext_ptr yytext |
#define | YY_DO_BEFORE_ACTION |
#define | YY_NUM_RULES 12 |
#define | YY_END_OF_BUFFER 13 |
#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 | yyterminate() return token::END |
#define | YY_NO_UNISTD_H |
Disable the inclusion of unistd.h, which is not available under Visual C++ on Win32. More... | |
#define | DEBUG(a) |
#define | DEBUG1(a) printf a |
#define | YY_USER_ACTION yylloc->columns(yyleng); |
Enable C++ generation for the scanner class. More... | |
#define | INITIAL 0 |
#define | YY_EXTRA_TYPE void * |
#define | YY_READ_BUF_SIZE 8192 |
#define | ECHO LexerOutput( yytext, yyleng ) |
#define | YY_INPUT(buf, result, max_size) |
#define | YY_START_STACK_INCR 25 |
#define | YY_FATAL_ERROR(msg) LexerError( msg ) |
#define | YY_DECL_IS_OURS 1 |
#define | YY_DECL int yyFlexLexer::yylex() |
#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 |
Bison lexer internals. More... | |
typedef short int | flex_int16_t |
Bison lexer internals. More... | |
typedef int | flex_int32_t |
Bison lexer internals. More... | |
typedef unsigned char | flex_uint8_t |
Bison lexer internals. More... | |
typedef unsigned short int | flex_uint16_t |
Bison lexer internals. More... | |
typedef unsigned int | flex_uint32_t |
Bison lexer internals. More... | |
typedef struct yy_buffer_state * | YY_BUFFER_STATE |
Bison lexer internals. More... | |
typedef size_t | yy_size_t |
Bison lexer internals. More... | |
typedef unsigned char | YY_CHAR |
Bison lexer internals. More... | |
typedef torc::LutParser::token | token |
Import the parser's token types into a local typedef. More... | |
typedef torc::LutParser::token_type | token_type |
Bison lexer internals. More... | |
Functions | |
void * | Lutalloc (yy_size_t) |
void * | Lutrealloc (void *, yy_size_t) |
void | Lutfree (void *) |
yylloc | step () |
Code belonging at the beginning of yylex(). More... | |
if (!(yy_init)) | |
while (1) | |
int | isatty (int) |
Variables | |
int | yyleng |
Bison lexer internals. More... | |
static yyconst flex_int16_t | yy_accept [19] |
static yyconst flex_int32_t | yy_ec [256] |
static yyconst flex_int32_t | yy_meta [14] |
static yyconst flex_int16_t | yy_base [20] |
static yyconst flex_int16_t | yy_def [20] |
static yyconst flex_int16_t | yy_nxt [32] |
static yyconst flex_int16_t | yy_chk [32] |
YY_DECL register yy_state_type | yy_current_state |
register char * | yy_cp |
register char * | yy_bp |
register int | yy_act |
#define BEGIN (yy_start) = 1 + 2 * |
Definition at line 136 of file LutScanner.cpp.
#define DEBUG | ( | a | ) |
Definition at line 460 of file LutScanner.cpp.
#define DEBUG1 | ( | a | ) | printf a |
Definition at line 461 of file LutScanner.cpp.
#define ECHO LexerOutput( yytext, yyleng ) |
Definition at line 511 of file LutScanner.cpp.
#define EOB_ACT_CONTINUE_SCAN 0 |
Definition at line 169 of file LutScanner.cpp.
#define EOB_ACT_END_OF_FILE 1 |
Definition at line 170 of file LutScanner.cpp.
#define EOB_ACT_LAST_MATCH 2 |
Definition at line 171 of file LutScanner.cpp.
#define FLEX_BETA |
Definition at line 14 of file LutScanner.cpp.
#define FLEX_SCANNER |
Definition at line 9 of file LutScanner.cpp.
#define FLEXINT_H |
Definition at line 34 of file LutScanner.cpp.
#define INITIAL 0 |
Definition at line 478 of file LutScanner.cpp.
#define INT16_MAX (32767) |
Definition at line 77 of file LutScanner.cpp.
#define INT16_MIN (-32767-1) |
Definition at line 68 of file LutScanner.cpp.
#define INT32_MAX (2147483647) |
Definition at line 80 of file LutScanner.cpp.
#define INT32_MIN (-2147483647-1) |
Definition at line 71 of file LutScanner.cpp.
#define INT8_MAX (127) |
Definition at line 74 of file LutScanner.cpp.
#define INT8_MIN (-128) |
Definition at line 65 of file LutScanner.cpp.
#define REJECT reject_used_but_not_detected |
Definition at line 407 of file LutScanner.cpp.
#define UINT16_MAX (65535U) |
Definition at line 86 of file LutScanner.cpp.
#define UINT32_MAX (4294967295U) |
Definition at line 89 of file LutScanner.cpp.
#define UINT8_MAX (255U) |
Definition at line 83 of file LutScanner.cpp.
#define unput | ( | c | ) | yyunput( c, (yytext_ptr) ) |
Definition at line 189 of file LutScanner.cpp.
#define YY_AT_BOL | ( | ) | (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) |
Definition at line 303 of file LutScanner.cpp.
#define YY_BREAK break; |
Definition at line 562 of file LutScanner.cpp.
#define YY_BUF_SIZE 16384 |
Definition at line 155 of file LutScanner.cpp.
#define YY_BUFFER_EOF_PENDING 2 |
Definition at line 257 of file LutScanner.cpp.
#define YY_BUFFER_NEW 0 |
Definition at line 245 of file LutScanner.cpp.
#define YY_BUFFER_NORMAL 1 |
Definition at line 246 of file LutScanner.cpp.
#define YY_CURRENT_BUFFER |
Definition at line 268 of file LutScanner.cpp.
#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)] |
Definition at line 275 of file LutScanner.cpp.
#define YY_DECL int yyFlexLexer::yylex() |
Definition at line 550 of file LutScanner.cpp.
#define YY_DECL_IS_OURS 1 |
Definition at line 549 of file LutScanner.cpp.
#define YY_DO_BEFORE_ACTION |
Definition at line 316 of file LutScanner.cpp.
#define YY_END_OF_BUFFER 13 |
Definition at line 324 of file LutScanner.cpp.
#define YY_END_OF_BUFFER_CHAR 0 |
Definition at line 151 of file LutScanner.cpp.
#define YY_EXIT_FAILURE 2 |
Definition at line 1564 of file LutScanner.cpp.
#define YY_EXTRA_TYPE void * |
Definition at line 489 of file LutScanner.cpp.
#define YY_FATAL_ERROR | ( | msg | ) | LexerError( msg ) |
Definition at line 540 of file LutScanner.cpp.
#define YY_FLEX_MAJOR_VERSION 2 |
Definition at line 10 of file LutScanner.cpp.
#define YY_FLEX_MINOR_VERSION 5 |
Definition at line 11 of file LutScanner.cpp.
#define YY_FLEX_SUBMINOR_VERSION 35 |
Definition at line 12 of file LutScanner.cpp.
#define YY_INPUT | ( | buf, | |
result, | |||
max_size | |||
) |
Definition at line 518 of file LutScanner.cpp.
#define YY_INT_ALIGNED short int |
Definition at line 5 of file LutScanner.cpp.
#define YY_LESS_LINENO | ( | n | ) |
Definition at line 173 of file LutScanner.cpp.
#define YY_MORE_ADJ 0 |
Definition at line 409 of file LutScanner.cpp.
#define yy_new_buffer yy_create_buffer |
Definition at line 281 of file LutScanner.cpp.
#define YY_NEW_FILE yyrestart( yyin ) |
Definition at line 149 of file LutScanner.cpp.
#define YY_NO_UNISTD_H |
Disable the inclusion of unistd.h, which is not available under Visual C++ on Win32.
The C++ scanner uses STL streams instead.
Definition at line 457 of file LutScanner.cpp.
#define YY_NULL 0 |
Definition at line 123 of file LutScanner.cpp.
#define YY_NUM_RULES 12 |
Definition at line 323 of file LutScanner.cpp.
#define YY_READ_BUF_SIZE 8192 |
Definition at line 506 of file LutScanner.cpp.
#define YY_RESTORE_YY_MORE_OFFSET |
Definition at line 410 of file LutScanner.cpp.
#define YY_RULE_SETUP YY_USER_ACTION |
Definition at line 565 of file LutScanner.cpp.
#define YY_SC_TO_UI | ( | c | ) | ((unsigned int) (unsigned char) c) |
Definition at line 130 of file LutScanner.cpp.
#define yy_set_bol | ( | at_bol | ) |
Definition at line 293 of file LutScanner.cpp.
#define yy_set_interactive | ( | is_interactive | ) |
Definition at line 283 of file LutScanner.cpp.
#define YY_START (((yy_start) - 1) / 2) |
Definition at line 142 of file LutScanner.cpp.
#define YY_START_STACK_INCR 25 |
Definition at line 535 of file LutScanner.cpp.
#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) |
Definition at line 160 of file LutScanner.cpp.
#define YY_STATE_EOF | ( | state | ) | (YY_END_OF_BUFFER + state + 1) |
Definition at line 146 of file LutScanner.cpp.
#define YY_STRUCT_YY_BUFFER_STATE |
Definition at line 197 of file LutScanner.cpp.
#define YY_TYPEDEF_YY_BUFFER_STATE |
Definition at line 163 of file LutScanner.cpp.
#define YY_TYPEDEF_YY_SIZE_T |
Definition at line 192 of file LutScanner.cpp.
#define YY_USER_ACTION yylloc->columns(yyleng); |
Enable C++ generation for the scanner class.
Change the name of the scanner class to "LutFlexLexer". The manual says batch is "somewhat more optimized". Enable debug output from the scanner. We anticipate no included LUT files. Track location information. Each time yylex is invoked, begin is moved to end.
Definition at line 475 of file LutScanner.cpp.
#define yyconst |
Definition at line 119 of file LutScanner.cpp.
#define yyFlexLexer LutFlexLexer |
Definition at line 23 of file LutScanner.cpp.
#define yyless | ( | n | ) |
Definition at line 1576 of file LutScanner.cpp.
#define yyless | ( | n | ) |
Definition at line 1576 of file LutScanner.cpp.
#define yymore | ( | ) | yymore_used_but_not_detected |
Definition at line 408 of file LutScanner.cpp.
#define YYSTATE YY_START |
Definition at line 143 of file LutScanner.cpp.
#define YYTABLES_NAME "yytables" |
Definition at line 1638 of file LutScanner.cpp.
#define yyterminate | ( | ) | return token::END |
By default, yylex() returns int, but we want token_type instead. Unfortunately, yyterminate returns 0 by default, which is not of token_type.
Definition at line 453 of file LutScanner.cpp.
#define yytext_ptr yytext |
Definition at line 309 of file LutScanner.cpp.
Bison lexer internals.
Definition at line 56 of file LutScanner.cpp.
Bison lexer internals.
Definition at line 57 of file LutScanner.cpp.
Bison lexer internals.
Definition at line 55 of file LutScanner.cpp.
Bison lexer internals.
Definition at line 59 of file LutScanner.cpp.
Bison lexer internals.
Definition at line 60 of file LutScanner.cpp.
Bison lexer internals.
Definition at line 58 of file LutScanner.cpp.
typedef torc::LutParser::token token |
Import the parser's token types into a local typedef.
Definition at line 448 of file LutScanner.cpp.
Bison lexer internals.
Definition at line 449 of file LutScanner.cpp.
Bison lexer internals.
Definition at line 164 of file LutScanner.cpp.
Bison lexer internals.
Definition at line 307 of file LutScanner.cpp.
Bison lexer internals.
Definition at line 193 of file LutScanner.cpp.
if | ( | ! | yy_init | ) |
Definition at line 598 of file LutScanner.cpp.
int isatty | ( | int | ) |
void * Lutalloc | ( | yy_size_t | size | ) |
void Lutfree | ( | void * | ptr | ) |
void * Lutrealloc | ( | void * | ptr, |
yy_size_t | size | ||
) |
yylloc step | ( | ) |
Code belonging at the beginning of yylex().
while | ( | 1 | ) |
Definition at line 624 of file LutScanner.cpp.
|
static |
Definition at line 332 of file LutScanner.cpp.
register int yy_act |
Definition at line 574 of file LutScanner.cpp.
|
static |
Definition at line 376 of file LutScanner.cpp.
register char * yy_bp |
Definition at line 573 of file LutScanner.cpp.
|
static |
Definition at line 396 of file LutScanner.cpp.
register char* yy_cp |
Definition at line 573 of file LutScanner.cpp.
YY_DECL register yy_state_type yy_current_state |
The main scanner function which does all the work.
Definition at line 572 of file LutScanner.cpp.
|
static |
Definition at line 382 of file LutScanner.cpp.
|
static |
Definition at line 338 of file LutScanner.cpp.
|
static |
Definition at line 370 of file LutScanner.cpp.
|
static |
Definition at line 388 of file LutScanner.cpp.
int yyleng |
Bison lexer internals.