fix clang++ errror report
This commit is contained in:
parent
7da22a8bb1
commit
bdc9a4b939
File diff suppressed because it is too large
Load Diff
|
@ -237,7 +237,6 @@ union HSQL_STYPE
|
|||
hsql::ExecuteStatement* exec_stmt;
|
||||
hsql::ShowStatement* show_stmt;
|
||||
|
||||
hsql::TableName table_n;
|
||||
hsql::TableRef* table;
|
||||
hsql::Expr* expr;
|
||||
hsql::OrderDescription* order;
|
||||
|
@ -256,7 +255,7 @@ union HSQL_STYPE
|
|||
std::vector<hsql::Expr*>* expr_vec;
|
||||
std::vector<hsql::OrderDescription*>* order_vec;
|
||||
|
||||
#line 260 "bison_parser.h" /* yacc.c:1909 */
|
||||
#line 259 "bison_parser.h" /* yacc.c:1909 */
|
||||
};
|
||||
|
||||
typedef union HSQL_STYPE HSQL_STYPE;
|
||||
|
|
|
@ -8,8 +8,8 @@
|
|||
|
||||
#define FLEX_SCANNER
|
||||
#define YY_FLEX_MAJOR_VERSION 2
|
||||
#define YY_FLEX_MINOR_VERSION 5
|
||||
#define YY_FLEX_SUBMINOR_VERSION 37
|
||||
#define YY_FLEX_MINOR_VERSION 6
|
||||
#define YY_FLEX_SUBMINOR_VERSION 1
|
||||
#if YY_FLEX_SUBMINOR_VERSION > 0
|
||||
#define FLEX_BETA
|
||||
#endif
|
||||
|
@ -88,25 +88,13 @@ typedef unsigned int flex_uint32_t;
|
|||
|
||||
#endif /* ! FLEXINT_H */
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
/* The "const" storage-class-modifier is valid. */
|
||||
#define YY_USE_CONST
|
||||
|
||||
#else /* ! __cplusplus */
|
||||
|
||||
/* C99 requires __STDC__ to be defined as 1. */
|
||||
#if defined (__STDC__)
|
||||
|
||||
#define YY_USE_CONST
|
||||
|
||||
#endif /* defined (__STDC__) */
|
||||
#endif /* ! __cplusplus */
|
||||
|
||||
#ifdef YY_USE_CONST
|
||||
/* TODO: this is always defined, so inline it */
|
||||
#define yyconst const
|
||||
|
||||
#if defined(__GNUC__) && __GNUC__ >= 3
|
||||
#define yynoreturn __attribute__((__noreturn__))
|
||||
#else
|
||||
#define yyconst
|
||||
#define yynoreturn
|
||||
#endif
|
||||
|
||||
/* Returned upon end-of-file. */
|
||||
|
@ -159,7 +147,15 @@ typedef void* yyscan_t;
|
|||
|
||||
/* Size of default input buffer. */
|
||||
#ifndef YY_BUF_SIZE
|
||||
#ifdef __ia64__
|
||||
/* On IA-64, the buffer size is 16k, not 8k.
|
||||
* Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
|
||||
* Ditto for the __ia64__ case accordingly.
|
||||
*/
|
||||
#define YY_BUF_SIZE 32768
|
||||
#else
|
||||
#define YY_BUF_SIZE 16384
|
||||
#endif /* __ia64__ */
|
||||
#endif
|
||||
|
||||
/* The state buf must be large enough to hold one state per character in the main buffer.
|
||||
|
@ -181,6 +177,7 @@ typedef size_t yy_size_t;
|
|||
#define EOB_ACT_LAST_MATCH 2
|
||||
|
||||
#define YY_LESS_LINENO(n)
|
||||
#define YY_LINENO_REWIND_TO(ptr)
|
||||
|
||||
/* Return all but the first "n" matched characters back to the input stream. */
|
||||
#define yyless(n) \
|
||||
|
@ -210,12 +207,12 @@ struct yy_buffer_state
|
|||
/* Size of input buffer in bytes, not including room for EOB
|
||||
* characters.
|
||||
*/
|
||||
yy_size_t yy_buf_size;
|
||||
int yy_buf_size;
|
||||
|
||||
/* Number of characters read into yy_ch_buf, not including EOB
|
||||
* characters.
|
||||
*/
|
||||
yy_size_t yy_n_chars;
|
||||
int yy_n_chars;
|
||||
|
||||
/* Whether we "own" the buffer - i.e., we know we created it,
|
||||
* and can realloc() it to grow it, and should free() it to
|
||||
|
@ -294,7 +291,7 @@ static void hsql__init_buffer (YY_BUFFER_STATE b,FILE *file ,yyscan_t yyscanner
|
|||
|
||||
YY_BUFFER_STATE hsql__scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner );
|
||||
YY_BUFFER_STATE hsql__scan_string (yyconst char *yy_str ,yyscan_t yyscanner );
|
||||
YY_BUFFER_STATE hsql__scan_bytes (yyconst char *bytes,yy_size_t len ,yyscan_t yyscanner );
|
||||
YY_BUFFER_STATE hsql__scan_bytes (yyconst char *bytes,int len ,yyscan_t yyscanner );
|
||||
|
||||
void *hsql_alloc (yy_size_t ,yyscan_t yyscanner );
|
||||
void *hsql_realloc (void *,yy_size_t ,yyscan_t yyscanner );
|
||||
|
@ -326,7 +323,7 @@ void hsql_free (void * ,yyscan_t yyscanner );
|
|||
|
||||
/* Begin user sect3 */
|
||||
|
||||
#define hsql_wrap(yyscanner) 1
|
||||
#define hsql_wrap(yyscanner) (/*CONSTCOND*/1)
|
||||
#define YY_SKIP_YYWRAP
|
||||
|
||||
typedef unsigned char YY_CHAR;
|
||||
|
@ -338,14 +335,14 @@ typedef int yy_state_type;
|
|||
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 void yynoreturn yy_fatal_error (yyconst char* msg ,yyscan_t yyscanner );
|
||||
|
||||
/* Done after the current pattern has been matched and before the
|
||||
* corresponding action - sets up yytext.
|
||||
*/
|
||||
#define YY_DO_BEFORE_ACTION \
|
||||
yyg->yytext_ptr = yy_bp; \
|
||||
yyleng = (size_t) (yy_cp - yy_bp); \
|
||||
yyleng = (int) (yy_cp - yy_bp); \
|
||||
yyg->yy_hold_char = *yy_cp; \
|
||||
*yy_cp = '\0'; \
|
||||
yyg->yy_c_buf_p = yy_cp;
|
||||
|
@ -466,7 +463,7 @@ static yyconst flex_int16_t yy_accept[938] =
|
|||
2, 2, 5, 6, 2, 2, 0
|
||||
} ;
|
||||
|
||||
static yyconst flex_int32_t yy_ec[256] =
|
||||
static yyconst YY_CHAR yy_ec[256] =
|
||||
{ 0,
|
||||
1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
|
||||
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
|
||||
|
@ -498,7 +495,7 @@ static yyconst flex_int32_t yy_ec[256] =
|
|||
1, 1, 1, 1, 1
|
||||
} ;
|
||||
|
||||
static yyconst flex_int32_t yy_meta[68] =
|
||||
static yyconst YY_CHAR yy_meta[68] =
|
||||
{ 0,
|
||||
1, 1, 2, 1, 3, 1, 1, 1, 1, 4,
|
||||
1, 1, 1, 4, 4, 4, 4, 4, 4, 4,
|
||||
|
@ -509,7 +506,7 @@ static yyconst flex_int32_t yy_meta[68] =
|
|||
4, 4, 4, 4, 4, 4, 1
|
||||
} ;
|
||||
|
||||
static yyconst flex_int16_t yy_base[945] =
|
||||
static yyconst flex_uint16_t yy_base[945] =
|
||||
{ 0,
|
||||
0, 0, 67, 0, 433, 3713, 133, 135, 418, 0,
|
||||
3713, 410, 131, 401, 133, 132, 384, 129, 129, 137,
|
||||
|
@ -725,7 +722,7 @@ static yyconst flex_int16_t yy_def[945] =
|
|||
937, 937, 937, 937
|
||||
} ;
|
||||
|
||||
static yyconst flex_int16_t yy_nxt[3781] =
|
||||
static yyconst flex_uint16_t yy_nxt[3781] =
|
||||
{ 0,
|
||||
6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
|
||||
16, 11, 17, 18, 19, 20, 21, 22, 23, 24,
|
||||
|
@ -1599,7 +1596,7 @@ static yyconst flex_int16_t yy_chk[3781] =
|
|||
/***************************
|
||||
** Section 3: Rules
|
||||
***************************/
|
||||
#line 1603 "flex_lexer.cpp"
|
||||
#line 1600 "flex_lexer.cpp"
|
||||
|
||||
#define INITIAL 0
|
||||
#define COMMENT 1
|
||||
|
@ -1629,8 +1626,8 @@ struct yyguts_t
|
|||
size_t yy_buffer_stack_max; /**< capacity of stack. */
|
||||
YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */
|
||||
char yy_hold_char;
|
||||
yy_size_t yy_n_chars;
|
||||
yy_size_t yyleng_r;
|
||||
int yy_n_chars;
|
||||
int yyleng_r;
|
||||
char *yy_c_buf_p;
|
||||
int yy_init;
|
||||
int yy_start;
|
||||
|
@ -1681,23 +1678,23 @@ void hsql_set_extra (YY_EXTRA_TYPE user_defined ,yyscan_t yyscanner );
|
|||
|
||||
FILE *hsql_get_in (yyscan_t yyscanner );
|
||||
|
||||
void hsql_set_in (FILE * in_str ,yyscan_t yyscanner );
|
||||
void hsql_set_in (FILE * _in_str ,yyscan_t yyscanner );
|
||||
|
||||
FILE *hsql_get_out (yyscan_t yyscanner );
|
||||
|
||||
void hsql_set_out (FILE * out_str ,yyscan_t yyscanner );
|
||||
void hsql_set_out (FILE * _out_str ,yyscan_t yyscanner );
|
||||
|
||||
yy_size_t hsql_get_leng (yyscan_t yyscanner );
|
||||
int hsql_get_leng (yyscan_t yyscanner );
|
||||
|
||||
char *hsql_get_text (yyscan_t yyscanner );
|
||||
|
||||
int hsql_get_lineno (yyscan_t yyscanner );
|
||||
|
||||
void hsql_set_lineno (int line_number ,yyscan_t yyscanner );
|
||||
void hsql_set_lineno (int _line_number ,yyscan_t yyscanner );
|
||||
|
||||
int hsql_get_column (yyscan_t yyscanner );
|
||||
|
||||
void hsql_set_column (int column_no ,yyscan_t yyscanner );
|
||||
void hsql_set_column (int _column_no ,yyscan_t yyscanner );
|
||||
|
||||
YYSTYPE * hsql_get_lval (yyscan_t yyscanner );
|
||||
|
||||
|
@ -1719,6 +1716,10 @@ extern int hsql_wrap (yyscan_t yyscanner );
|
|||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef YY_NO_UNPUT
|
||||
|
||||
#endif
|
||||
|
||||
#ifndef yytext_ptr
|
||||
static void yy_flex_strncpy (char *,yyconst char *,int ,yyscan_t yyscanner);
|
||||
#endif
|
||||
|
@ -1739,7 +1740,12 @@ static int input (yyscan_t yyscanner );
|
|||
|
||||
/* Amount of stuff to slurp up with each read. */
|
||||
#ifndef YY_READ_BUF_SIZE
|
||||
#ifdef __ia64__
|
||||
/* On IA-64, the buffer size is 16k, not 8k */
|
||||
#define YY_READ_BUF_SIZE 16384
|
||||
#else
|
||||
#define YY_READ_BUF_SIZE 8192
|
||||
#endif /* __ia64__ */
|
||||
#endif
|
||||
|
||||
/* Copy whatever the last rule matched to the standard output. */
|
||||
|
@ -1747,7 +1753,7 @@ static int input (yyscan_t yyscanner );
|
|||
/* This used to be an fputs(), but since the string might contain NUL's,
|
||||
* we now use fwrite().
|
||||
*/
|
||||
#define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0)
|
||||
#define ECHO do { if (fwrite( yytext, (size_t) yyleng, 1, yyout )) {} } while (0)
|
||||
#endif
|
||||
|
||||
/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
|
||||
|
@ -1771,7 +1777,7 @@ static int input (yyscan_t yyscanner );
|
|||
else \
|
||||
{ \
|
||||
errno=0; \
|
||||
while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \
|
||||
while ( (result = (int) fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \
|
||||
{ \
|
||||
if( errno != EINTR) \
|
||||
{ \
|
||||
|
@ -1828,7 +1834,7 @@ extern int hsql_lex \
|
|||
|
||||
/* Code executed at the end of each rule. */
|
||||
#ifndef YY_BREAK
|
||||
#define YY_BREAK break;
|
||||
#define YY_BREAK /*LINTED*/break;
|
||||
#endif
|
||||
|
||||
#define YY_RULE_SETUP \
|
||||
|
@ -1838,16 +1844,11 @@ extern int hsql_lex \
|
|||
*/
|
||||
YY_DECL
|
||||
{
|
||||
register yy_state_type yy_current_state;
|
||||
register char *yy_cp, *yy_bp;
|
||||
register int yy_act;
|
||||
yy_state_type yy_current_state;
|
||||
char *yy_cp, *yy_bp;
|
||||
int yy_act;
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
|
||||
#line 51 "flex_lexer.l"
|
||||
|
||||
|
||||
#line 1850 "flex_lexer.cpp"
|
||||
|
||||
yylval = yylval_param;
|
||||
|
||||
yylloc = yylloc_param;
|
||||
|
@ -1878,7 +1879,13 @@ YY_DECL
|
|||
hsql__load_buffer_state(yyscanner );
|
||||
}
|
||||
|
||||
while ( 1 ) /* loops until end-of-file is reached */
|
||||
{
|
||||
#line 51 "flex_lexer.l"
|
||||
|
||||
|
||||
#line 1887 "flex_lexer.cpp"
|
||||
|
||||
while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */
|
||||
{
|
||||
yy_cp = yyg->yy_c_buf_p;
|
||||
|
||||
|
@ -1894,7 +1901,7 @@ YY_DECL
|
|||
yy_match:
|
||||
do
|
||||
{
|
||||
register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
|
||||
YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ;
|
||||
if ( yy_accept[yy_current_state] )
|
||||
{
|
||||
yyg->yy_last_accepting_state = yy_current_state;
|
||||
|
@ -1906,7 +1913,7 @@ yy_match:
|
|||
if ( yy_current_state >= 938 )
|
||||
yy_c = yy_meta[(unsigned int) yy_c];
|
||||
}
|
||||
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
|
||||
yy_current_state = yy_nxt[yy_base[yy_current_state] + (flex_int16_t) yy_c];
|
||||
++yy_cp;
|
||||
}
|
||||
while ( yy_current_state != 937 );
|
||||
|
@ -2625,7 +2632,7 @@ YY_RULE_SETUP
|
|||
#line 217 "flex_lexer.l"
|
||||
ECHO;
|
||||
YY_BREAK
|
||||
#line 2629 "flex_lexer.cpp"
|
||||
#line 2636 "flex_lexer.cpp"
|
||||
case YY_STATE_EOF(INITIAL):
|
||||
case YY_STATE_EOF(COMMENT):
|
||||
yyterminate();
|
||||
|
@ -2758,6 +2765,7 @@ case YY_STATE_EOF(COMMENT):
|
|||
"fatal flex scanner internal error--no action found" );
|
||||
} /* end of action switch */
|
||||
} /* end of scanning one token */
|
||||
} /* end of user's declarations */
|
||||
} /* end of hsql_lex */
|
||||
|
||||
/* yy_get_next_buffer - try to read in a new buffer
|
||||
|
@ -2770,9 +2778,9 @@ case YY_STATE_EOF(COMMENT):
|
|||
static int yy_get_next_buffer (yyscan_t yyscanner)
|
||||
{
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
|
||||
register char *source = yyg->yytext_ptr;
|
||||
register int number_to_move, i;
|
||||
char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
|
||||
char *source = yyg->yytext_ptr;
|
||||
int number_to_move, i;
|
||||
int ret_val;
|
||||
|
||||
if ( yyg->yy_c_buf_p > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] )
|
||||
|
@ -2801,7 +2809,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
|
|||
/* Try to read more data. */
|
||||
|
||||
/* First move last chars to start of buffer. */
|
||||
number_to_move = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr) - 1;
|
||||
number_to_move = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr - 1);
|
||||
|
||||
for ( i = 0; i < number_to_move; ++i )
|
||||
*(dest++) = *(source++);
|
||||
|
@ -2814,7 +2822,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
|
|||
|
||||
else
|
||||
{
|
||||
yy_size_t num_to_read =
|
||||
int num_to_read =
|
||||
YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
|
||||
|
||||
while ( num_to_read <= 0 )
|
||||
|
@ -2828,7 +2836,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
|
|||
|
||||
if ( b->yy_is_our_buffer )
|
||||
{
|
||||
yy_size_t new_size = b->yy_buf_size * 2;
|
||||
int new_size = b->yy_buf_size * 2;
|
||||
|
||||
if ( new_size <= 0 )
|
||||
b->yy_buf_size += b->yy_buf_size / 8;
|
||||
|
@ -2841,7 +2849,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
|
|||
}
|
||||
else
|
||||
/* Can't grow it, we don't own it. */
|
||||
b->yy_ch_buf = 0;
|
||||
b->yy_ch_buf = NULL;
|
||||
|
||||
if ( ! b->yy_ch_buf )
|
||||
YY_FATAL_ERROR(
|
||||
|
@ -2883,9 +2891,9 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
|
|||
else
|
||||
ret_val = EOB_ACT_CONTINUE_SCAN;
|
||||
|
||||
if ((yy_size_t) (yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
|
||||
if ((yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
|
||||
/* Extend the array by 50%, plus the number we really need. */
|
||||
yy_size_t new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
|
||||
int new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
|
||||
YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) hsql_realloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ,yyscanner );
|
||||
if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
|
||||
YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
|
||||
|
@ -2904,15 +2912,15 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
|
|||
|
||||
static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
|
||||
{
|
||||
register yy_state_type yy_current_state;
|
||||
register char *yy_cp;
|
||||
yy_state_type yy_current_state;
|
||||
char *yy_cp;
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
|
||||
yy_current_state = yyg->yy_start;
|
||||
|
||||
for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp )
|
||||
{
|
||||
register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
|
||||
YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
|
||||
if ( yy_accept[yy_current_state] )
|
||||
{
|
||||
yyg->yy_last_accepting_state = yy_current_state;
|
||||
|
@ -2924,7 +2932,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
|
|||
if ( yy_current_state >= 938 )
|
||||
yy_c = yy_meta[(unsigned int) yy_c];
|
||||
}
|
||||
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
|
||||
yy_current_state = yy_nxt[yy_base[yy_current_state] + (flex_int16_t) yy_c];
|
||||
}
|
||||
|
||||
return yy_current_state;
|
||||
|
@ -2937,11 +2945,11 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
|
|||
*/
|
||||
static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state , yyscan_t yyscanner)
|
||||
{
|
||||
register int yy_is_jam;
|
||||
int yy_is_jam;
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* This var may be unused depending upon options. */
|
||||
register char *yy_cp = yyg->yy_c_buf_p;
|
||||
char *yy_cp = yyg->yy_c_buf_p;
|
||||
|
||||
register YY_CHAR yy_c = 1;
|
||||
YY_CHAR yy_c = 1;
|
||||
if ( yy_accept[yy_current_state] )
|
||||
{
|
||||
yyg->yy_last_accepting_state = yy_current_state;
|
||||
|
@ -2953,13 +2961,17 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
|
|||
if ( yy_current_state >= 938 )
|
||||
yy_c = yy_meta[(unsigned int) yy_c];
|
||||
}
|
||||
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
|
||||
yy_current_state = yy_nxt[yy_base[yy_current_state] + (flex_int16_t) yy_c];
|
||||
yy_is_jam = (yy_current_state == 937);
|
||||
|
||||
(void)yyg;
|
||||
return yy_is_jam ? 0 : yy_current_state;
|
||||
}
|
||||
|
||||
#ifndef YY_NO_UNPUT
|
||||
|
||||
#endif
|
||||
|
||||
#ifndef YY_NO_INPUT
|
||||
#ifdef __cplusplus
|
||||
static int yyinput (yyscan_t yyscanner)
|
||||
|
@ -2985,7 +2997,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
|
|||
|
||||
else
|
||||
{ /* need more input */
|
||||
yy_size_t offset = yyg->yy_c_buf_p - yyg->yytext_ptr;
|
||||
int offset = yyg->yy_c_buf_p - yyg->yytext_ptr;
|
||||
++yyg->yy_c_buf_p;
|
||||
|
||||
switch ( yy_get_next_buffer( yyscanner ) )
|
||||
|
@ -3009,7 +3021,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
|
|||
case EOB_ACT_END_OF_FILE:
|
||||
{
|
||||
if ( hsql_wrap(yyscanner ) )
|
||||
return EOF;
|
||||
return 0;
|
||||
|
||||
if ( ! yyg->yy_did_buffer_switch_on_eof )
|
||||
YY_NEW_FILE;
|
||||
|
@ -3113,7 +3125,7 @@ static void hsql__load_buffer_state (yyscan_t yyscanner)
|
|||
if ( ! b )
|
||||
YY_FATAL_ERROR( "out of dynamic memory in hsql__create_buffer()" );
|
||||
|
||||
b->yy_buf_size = size;
|
||||
b->yy_buf_size = (yy_size_t)size;
|
||||
|
||||
/* yy_ch_buf has to be 2 characters longer than the size given because
|
||||
* we need to put in 2 end-of-buffer characters.
|
||||
|
@ -3265,7 +3277,7 @@ void hsql_pop_buffer_state (yyscan_t yyscanner)
|
|||
*/
|
||||
static void hsql_ensure_buffer_stack (yyscan_t yyscanner)
|
||||
{
|
||||
yy_size_t num_to_alloc;
|
||||
int num_to_alloc;
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
|
||||
if (!yyg->yy_buffer_stack) {
|
||||
|
@ -3274,7 +3286,7 @@ static void hsql_ensure_buffer_stack (yyscan_t yyscanner)
|
|||
* scanner will even need a stack. We use 2 instead of 1 to avoid an
|
||||
* immediate realloc on the next call.
|
||||
*/
|
||||
num_to_alloc = 1;
|
||||
num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */
|
||||
yyg->yy_buffer_stack = (struct yy_buffer_state**)hsql_alloc
|
||||
(num_to_alloc * sizeof(struct yy_buffer_state*)
|
||||
, yyscanner);
|
||||
|
@ -3291,7 +3303,7 @@ static void hsql_ensure_buffer_stack (yyscan_t yyscanner)
|
|||
if (yyg->yy_buffer_stack_top >= (yyg->yy_buffer_stack_max) - 1){
|
||||
|
||||
/* Increase the buffer to prepare for a possible push. */
|
||||
int grow_size = 8 /* arbitrary grow size */;
|
||||
yy_size_t grow_size = 8 /* arbitrary grow size */;
|
||||
|
||||
num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
|
||||
yyg->yy_buffer_stack = (struct yy_buffer_state**)hsql_realloc
|
||||
|
@ -3321,7 +3333,7 @@ YY_BUFFER_STATE hsql__scan_buffer (char * base, yy_size_t size , yyscan_t yysc
|
|||
base[size-2] != YY_END_OF_BUFFER_CHAR ||
|
||||
base[size-1] != YY_END_OF_BUFFER_CHAR )
|
||||
/* They forgot to leave room for the EOB's. */
|
||||
return 0;
|
||||
return NULL;
|
||||
|
||||
b = (YY_BUFFER_STATE) hsql_alloc(sizeof( struct yy_buffer_state ) ,yyscanner );
|
||||
if ( ! b )
|
||||
|
@ -3330,7 +3342,7 @@ YY_BUFFER_STATE hsql__scan_buffer (char * base, yy_size_t size , yyscan_t yysc
|
|||
b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
|
||||
b->yy_buf_pos = b->yy_ch_buf = base;
|
||||
b->yy_is_our_buffer = 0;
|
||||
b->yy_input_file = 0;
|
||||
b->yy_input_file = NULL;
|
||||
b->yy_n_chars = b->yy_buf_size;
|
||||
b->yy_is_interactive = 0;
|
||||
b->yy_at_bol = 1;
|
||||
|
@ -3353,7 +3365,7 @@ YY_BUFFER_STATE hsql__scan_buffer (char * base, yy_size_t size , yyscan_t yysc
|
|||
YY_BUFFER_STATE hsql__scan_string (yyconst char * yystr , yyscan_t yyscanner)
|
||||
{
|
||||
|
||||
return hsql__scan_bytes(yystr,strlen(yystr) ,yyscanner);
|
||||
return hsql__scan_bytes(yystr,(int) strlen(yystr) ,yyscanner);
|
||||
}
|
||||
|
||||
/** Setup the input buffer state to scan the given bytes. The next call to hsql_lex() will
|
||||
|
@ -3363,7 +3375,7 @@ YY_BUFFER_STATE hsql__scan_string (yyconst char * yystr , yyscan_t yyscanner)
|
|||
* @param yyscanner The scanner object.
|
||||
* @return the newly allocated buffer state object.
|
||||
*/
|
||||
YY_BUFFER_STATE hsql__scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len , yyscan_t yyscanner)
|
||||
YY_BUFFER_STATE hsql__scan_bytes (yyconst char * yybytes, int _yybytes_len , yyscan_t yyscanner)
|
||||
{
|
||||
YY_BUFFER_STATE b;
|
||||
char *buf;
|
||||
|
@ -3371,7 +3383,7 @@ YY_BUFFER_STATE hsql__scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_l
|
|||
int i;
|
||||
|
||||
/* Get memory for full buffer, including space for trailing EOB's. */
|
||||
n = _yybytes_len + 2;
|
||||
n = (yy_size_t) (_yybytes_len + 2);
|
||||
buf = (char *) hsql_alloc(n ,yyscanner );
|
||||
if ( ! buf )
|
||||
YY_FATAL_ERROR( "out of dynamic memory in hsql__scan_bytes()" );
|
||||
|
@ -3397,8 +3409,10 @@ YY_BUFFER_STATE hsql__scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_l
|
|||
#define YY_EXIT_FAILURE 2
|
||||
#endif
|
||||
|
||||
static void yy_fatal_error (yyconst char* msg , yyscan_t yyscanner)
|
||||
static void yynoreturn yy_fatal_error (yyconst char* msg , yyscan_t yyscanner)
|
||||
{
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
(void)yyg;
|
||||
(void) fprintf( stderr, "%s\n", msg );
|
||||
exit( YY_EXIT_FAILURE );
|
||||
}
|
||||
|
@ -3478,7 +3492,7 @@ FILE *hsql_get_out (yyscan_t yyscanner)
|
|||
/** Get the length of the current token.
|
||||
* @param yyscanner The scanner object.
|
||||
*/
|
||||
yy_size_t hsql_get_leng (yyscan_t yyscanner)
|
||||
int hsql_get_leng (yyscan_t yyscanner)
|
||||
{
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
return yyleng;
|
||||
|
@ -3505,10 +3519,10 @@ void hsql_set_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner)
|
|||
}
|
||||
|
||||
/** Set the current line number.
|
||||
* @param line_number
|
||||
* @param _line_number line number
|
||||
* @param yyscanner The scanner object.
|
||||
*/
|
||||
void hsql_set_lineno (int line_number , yyscan_t yyscanner)
|
||||
void hsql_set_lineno (int _line_number , yyscan_t yyscanner)
|
||||
{
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
|
||||
|
@ -3516,14 +3530,14 @@ void hsql_set_lineno (int line_number , yyscan_t yyscanner)
|
|||
if (! YY_CURRENT_BUFFER )
|
||||
YY_FATAL_ERROR( "hsql_set_lineno called with no buffer" );
|
||||
|
||||
yylineno = line_number;
|
||||
yylineno = _line_number;
|
||||
}
|
||||
|
||||
/** Set the current column.
|
||||
* @param line_number
|
||||
* @param _column_no column number
|
||||
* @param yyscanner The scanner object.
|
||||
*/
|
||||
void hsql_set_column (int column_no , yyscan_t yyscanner)
|
||||
void hsql_set_column (int _column_no , yyscan_t yyscanner)
|
||||
{
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
|
||||
|
@ -3531,25 +3545,25 @@ void hsql_set_column (int column_no , yyscan_t yyscanner)
|
|||
if (! YY_CURRENT_BUFFER )
|
||||
YY_FATAL_ERROR( "hsql_set_column called with no buffer" );
|
||||
|
||||
yycolumn = column_no;
|
||||
yycolumn = _column_no;
|
||||
}
|
||||
|
||||
/** Set the input stream. This does not discard the current
|
||||
* input buffer.
|
||||
* @param in_str A readable stream.
|
||||
* @param _in_str A readable stream.
|
||||
* @param yyscanner The scanner object.
|
||||
* @see hsql__switch_to_buffer
|
||||
*/
|
||||
void hsql_set_in (FILE * in_str , yyscan_t yyscanner)
|
||||
void hsql_set_in (FILE * _in_str , yyscan_t yyscanner)
|
||||
{
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
yyin = in_str ;
|
||||
yyin = _in_str ;
|
||||
}
|
||||
|
||||
void hsql_set_out (FILE * out_str , yyscan_t yyscanner)
|
||||
void hsql_set_out (FILE * _out_str , yyscan_t yyscanner)
|
||||
{
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
yyout = out_str ;
|
||||
yyout = _out_str ;
|
||||
}
|
||||
|
||||
int hsql_get_debug (yyscan_t yyscanner)
|
||||
|
@ -3558,10 +3572,10 @@ int hsql_get_debug (yyscan_t yyscanner)
|
|||
return yy_flex_debug;
|
||||
}
|
||||
|
||||
void hsql_set_debug (int bdebug , yyscan_t yyscanner)
|
||||
void hsql_set_debug (int _bdebug , yyscan_t yyscanner)
|
||||
{
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
yy_flex_debug = bdebug ;
|
||||
yy_flex_debug = _bdebug ;
|
||||
}
|
||||
|
||||
/* Accessor methods for yylval and yylloc */
|
||||
|
@ -3661,10 +3675,10 @@ static int yy_init_globals (yyscan_t yyscanner)
|
|||
* This function is called from hsql_lex_destroy(), so don't allocate here.
|
||||
*/
|
||||
|
||||
yyg->yy_buffer_stack = 0;
|
||||
yyg->yy_buffer_stack = NULL;
|
||||
yyg->yy_buffer_stack_top = 0;
|
||||
yyg->yy_buffer_stack_max = 0;
|
||||
yyg->yy_c_buf_p = (char *) 0;
|
||||
yyg->yy_c_buf_p = NULL;
|
||||
yyg->yy_init = 0;
|
||||
yyg->yy_start = 0;
|
||||
|
||||
|
@ -3677,8 +3691,8 @@ static int yy_init_globals (yyscan_t yyscanner)
|
|||
yyin = stdin;
|
||||
yyout = stdout;
|
||||
#else
|
||||
yyin = (FILE *) 0;
|
||||
yyout = (FILE *) 0;
|
||||
yyin = NULL;
|
||||
yyout = NULL;
|
||||
#endif
|
||||
|
||||
/* For future reference: Set errno on error, since we are called by
|
||||
|
@ -3724,7 +3738,10 @@ int hsql_lex_destroy (yyscan_t yyscanner)
|
|||
#ifndef yytext_ptr
|
||||
static void yy_flex_strncpy (char* s1, yyconst char * s2, int n , yyscan_t yyscanner)
|
||||
{
|
||||
register int i;
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
(void)yyg;
|
||||
|
||||
int i;
|
||||
for ( i = 0; i < n; ++i )
|
||||
s1[i] = s2[i];
|
||||
}
|
||||
|
@ -3733,7 +3750,7 @@ static void yy_flex_strncpy (char* s1, yyconst char * s2, int n , yyscan_t yysca
|
|||
#ifdef YY_NEED_STRLEN
|
||||
static int yy_flex_strlen (yyconst char * s , yyscan_t yyscanner)
|
||||
{
|
||||
register int n;
|
||||
int n;
|
||||
for ( n = 0; s[n]; ++n )
|
||||
;
|
||||
|
||||
|
@ -3743,11 +3760,16 @@ static int yy_flex_strlen (yyconst char * s , yyscan_t yyscanner)
|
|||
|
||||
void *hsql_alloc (yy_size_t size , yyscan_t yyscanner)
|
||||
{
|
||||
return (void *) malloc( size );
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
(void)yyg;
|
||||
return malloc(size);
|
||||
}
|
||||
|
||||
void *hsql_realloc (void * ptr, yy_size_t size , yyscan_t yyscanner)
|
||||
{
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
(void)yyg;
|
||||
|
||||
/* The cast to (char *) in the following accommodates both
|
||||
* implementations that use char* generic pointers, and those
|
||||
* that use void* generic pointers. It works with the latter
|
||||
|
@ -3755,11 +3777,13 @@ void *hsql_realloc (void * ptr, yy_size_t size , yyscan_t yyscanner)
|
|||
* any pointer type to void*, and deal with argument conversions
|
||||
* as though doing an assignment.
|
||||
*/
|
||||
return (void *) realloc( (char *) ptr, size );
|
||||
return realloc(ptr, size);
|
||||
}
|
||||
|
||||
void hsql_free (void * ptr , yyscan_t yyscanner)
|
||||
{
|
||||
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
|
||||
(void)yyg;
|
||||
free( (char *) ptr ); /* see hsql_realloc() for (char *) cast */
|
||||
}
|
||||
|
||||
|
|
|
@ -12,8 +12,8 @@
|
|||
|
||||
#define FLEX_SCANNER
|
||||
#define YY_FLEX_MAJOR_VERSION 2
|
||||
#define YY_FLEX_MINOR_VERSION 5
|
||||
#define YY_FLEX_SUBMINOR_VERSION 37
|
||||
#define YY_FLEX_MINOR_VERSION 6
|
||||
#define YY_FLEX_SUBMINOR_VERSION 1
|
||||
#if YY_FLEX_SUBMINOR_VERSION > 0
|
||||
#define FLEX_BETA
|
||||
#endif
|
||||
|
@ -92,25 +92,13 @@ typedef unsigned int flex_uint32_t;
|
|||
|
||||
#endif /* ! FLEXINT_H */
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
/* The "const" storage-class-modifier is valid. */
|
||||
#define YY_USE_CONST
|
||||
|
||||
#else /* ! __cplusplus */
|
||||
|
||||
/* C99 requires __STDC__ to be defined as 1. */
|
||||
#if defined (__STDC__)
|
||||
|
||||
#define YY_USE_CONST
|
||||
|
||||
#endif /* defined (__STDC__) */
|
||||
#endif /* ! __cplusplus */
|
||||
|
||||
#ifdef YY_USE_CONST
|
||||
/* TODO: this is always defined, so inline it */
|
||||
#define yyconst const
|
||||
|
||||
#if defined(__GNUC__) && __GNUC__ >= 3
|
||||
#define yynoreturn __attribute__((__noreturn__))
|
||||
#else
|
||||
#define yyconst
|
||||
#define yynoreturn
|
||||
#endif
|
||||
|
||||
/* An opaque pointer. */
|
||||
|
@ -132,7 +120,15 @@ typedef void* yyscan_t;
|
|||
|
||||
/* Size of default input buffer. */
|
||||
#ifndef YY_BUF_SIZE
|
||||
#ifdef __ia64__
|
||||
/* On IA-64, the buffer size is 16k, not 8k.
|
||||
* Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
|
||||
* Ditto for the __ia64__ case accordingly.
|
||||
*/
|
||||
#define YY_BUF_SIZE 32768
|
||||
#else
|
||||
#define YY_BUF_SIZE 16384
|
||||
#endif /* __ia64__ */
|
||||
#endif
|
||||
|
||||
#ifndef YY_TYPEDEF_YY_BUFFER_STATE
|
||||
|
@ -157,12 +153,12 @@ struct yy_buffer_state
|
|||
/* Size of input buffer in bytes, not including room for EOB
|
||||
* characters.
|
||||
*/
|
||||
yy_size_t yy_buf_size;
|
||||
int yy_buf_size;
|
||||
|
||||
/* Number of characters read into yy_ch_buf, not including EOB
|
||||
* characters.
|
||||
*/
|
||||
yy_size_t yy_n_chars;
|
||||
int yy_n_chars;
|
||||
|
||||
/* Whether we "own" the buffer - i.e., we know we created it,
|
||||
* and can realloc() it to grow it, and should free() it to
|
||||
|
@ -206,7 +202,7 @@ void hsql_pop_buffer_state (yyscan_t yyscanner );
|
|||
|
||||
YY_BUFFER_STATE hsql__scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner );
|
||||
YY_BUFFER_STATE hsql__scan_string (yyconst char *yy_str ,yyscan_t yyscanner );
|
||||
YY_BUFFER_STATE hsql__scan_bytes (yyconst char *bytes,yy_size_t len ,yyscan_t yyscanner );
|
||||
YY_BUFFER_STATE hsql__scan_bytes (yyconst char *bytes,int len ,yyscan_t yyscanner );
|
||||
|
||||
void *hsql_alloc (yy_size_t ,yyscan_t yyscanner );
|
||||
void *hsql_realloc (void *,yy_size_t ,yyscan_t yyscanner );
|
||||
|
@ -214,7 +210,7 @@ void hsql_free (void * ,yyscan_t yyscanner );
|
|||
|
||||
/* Begin user sect3 */
|
||||
|
||||
#define hsql_wrap(yyscanner) 1
|
||||
#define hsql_wrap(yyscanner) (/*CONSTCOND*/1)
|
||||
#define YY_SKIP_YYWRAP
|
||||
|
||||
#define yytext_ptr yytext_r
|
||||
|
@ -256,23 +252,23 @@ void hsql_set_extra (YY_EXTRA_TYPE user_defined ,yyscan_t yyscanner );
|
|||
|
||||
FILE *hsql_get_in (yyscan_t yyscanner );
|
||||
|
||||
void hsql_set_in (FILE * in_str ,yyscan_t yyscanner );
|
||||
void hsql_set_in (FILE * _in_str ,yyscan_t yyscanner );
|
||||
|
||||
FILE *hsql_get_out (yyscan_t yyscanner );
|
||||
|
||||
void hsql_set_out (FILE * out_str ,yyscan_t yyscanner );
|
||||
void hsql_set_out (FILE * _out_str ,yyscan_t yyscanner );
|
||||
|
||||
yy_size_t hsql_get_leng (yyscan_t yyscanner );
|
||||
int hsql_get_leng (yyscan_t yyscanner );
|
||||
|
||||
char *hsql_get_text (yyscan_t yyscanner );
|
||||
|
||||
int hsql_get_lineno (yyscan_t yyscanner );
|
||||
|
||||
void hsql_set_lineno (int line_number ,yyscan_t yyscanner );
|
||||
void hsql_set_lineno (int _line_number ,yyscan_t yyscanner );
|
||||
|
||||
int hsql_get_column (yyscan_t yyscanner );
|
||||
|
||||
void hsql_set_column (int column_no ,yyscan_t yyscanner );
|
||||
void hsql_set_column (int _column_no ,yyscan_t yyscanner );
|
||||
|
||||
YYSTYPE * hsql_get_lval (yyscan_t yyscanner );
|
||||
|
||||
|
@ -308,7 +304,12 @@ static int yy_flex_strlen (yyconst char * ,yyscan_t yyscanner);
|
|||
|
||||
/* Amount of stuff to slurp up with each read. */
|
||||
#ifndef YY_READ_BUF_SIZE
|
||||
#ifdef __ia64__
|
||||
/* On IA-64, the buffer size is 16k, not 8k */
|
||||
#define YY_READ_BUF_SIZE 16384
|
||||
#else
|
||||
#define YY_READ_BUF_SIZE 8192
|
||||
#endif /* __ia64__ */
|
||||
#endif
|
||||
|
||||
/* Number of entries by which start-condition stack grows. */
|
||||
|
@ -346,6 +347,6 @@ extern int hsql_lex \
|
|||
#line 217 "flex_lexer.l"
|
||||
|
||||
|
||||
#line 350 "flex_lexer.h"
|
||||
#line 351 "flex_lexer.h"
|
||||
#undef hsql_IN_HEADER
|
||||
#endif /* hsql_HEADER_H */
|
||||
|
|
Loading…
Reference in New Issue