From c72ed135e4f1b5a02a8fb3f6cd46f27513ecab2a Mon Sep 17 00:00:00 2001 From: Nicolas Williams Date: Thu, 21 Mar 2019 23:58:55 -0500 Subject: [PATCH] Allow keywords in more places (fix #1868) --- src/lexer.c | 774 ++++++++++++------- src/lexer.h | 495 ++++++++++-- src/parser.c | 1989 +++++++++++++++++++++++++------------------------ src/parser.h | 12 +- src/parser.y | 26 +- tests/jq.test | 11 + 6 files changed, 1985 insertions(+), 1322 deletions(-) diff --git a/src/lexer.c b/src/lexer.c index b9baf3abb3..cd2012f1ab 100644 --- a/src/lexer.c +++ b/src/lexer.c @@ -9,11 +9,245 @@ #define FLEX_SCANNER #define YY_FLEX_MAJOR_VERSION 2 #define YY_FLEX_MINOR_VERSION 6 -#define YY_FLEX_SUBMINOR_VERSION 0 +#define YY_FLEX_SUBMINOR_VERSION 4 #if YY_FLEX_SUBMINOR_VERSION > 0 #define FLEX_BETA #endif +#ifdef yy_create_buffer +#define jq_yy_create_buffer_ALREADY_DEFINED +#else +#define yy_create_buffer jq_yy_create_buffer +#endif + +#ifdef yy_delete_buffer +#define jq_yy_delete_buffer_ALREADY_DEFINED +#else +#define yy_delete_buffer jq_yy_delete_buffer +#endif + +#ifdef yy_scan_buffer +#define jq_yy_scan_buffer_ALREADY_DEFINED +#else +#define yy_scan_buffer jq_yy_scan_buffer +#endif + +#ifdef yy_scan_string +#define jq_yy_scan_string_ALREADY_DEFINED +#else +#define yy_scan_string jq_yy_scan_string +#endif + +#ifdef yy_scan_bytes +#define jq_yy_scan_bytes_ALREADY_DEFINED +#else +#define yy_scan_bytes jq_yy_scan_bytes +#endif + +#ifdef yy_init_buffer +#define jq_yy_init_buffer_ALREADY_DEFINED +#else +#define yy_init_buffer jq_yy_init_buffer +#endif + +#ifdef yy_flush_buffer +#define jq_yy_flush_buffer_ALREADY_DEFINED +#else +#define yy_flush_buffer jq_yy_flush_buffer +#endif + +#ifdef yy_load_buffer_state +#define jq_yy_load_buffer_state_ALREADY_DEFINED +#else +#define yy_load_buffer_state jq_yy_load_buffer_state +#endif + +#ifdef yy_switch_to_buffer +#define jq_yy_switch_to_buffer_ALREADY_DEFINED +#else +#define yy_switch_to_buffer jq_yy_switch_to_buffer +#endif + +#ifdef yypush_buffer_state +#define jq_yypush_buffer_state_ALREADY_DEFINED +#else +#define yypush_buffer_state jq_yypush_buffer_state +#endif + +#ifdef yypop_buffer_state +#define jq_yypop_buffer_state_ALREADY_DEFINED +#else +#define yypop_buffer_state jq_yypop_buffer_state +#endif + +#ifdef yyensure_buffer_stack +#define jq_yyensure_buffer_stack_ALREADY_DEFINED +#else +#define yyensure_buffer_stack jq_yyensure_buffer_stack +#endif + +#ifdef yylex +#define jq_yylex_ALREADY_DEFINED +#else +#define yylex jq_yylex +#endif + +#ifdef yyrestart +#define jq_yyrestart_ALREADY_DEFINED +#else +#define yyrestart jq_yyrestart +#endif + +#ifdef yylex_init +#define jq_yylex_init_ALREADY_DEFINED +#else +#define yylex_init jq_yylex_init +#endif + +#ifdef yylex_init_extra +#define jq_yylex_init_extra_ALREADY_DEFINED +#else +#define yylex_init_extra jq_yylex_init_extra +#endif + +#ifdef yylex_destroy +#define jq_yylex_destroy_ALREADY_DEFINED +#else +#define yylex_destroy jq_yylex_destroy +#endif + +#ifdef yyget_debug +#define jq_yyget_debug_ALREADY_DEFINED +#else +#define yyget_debug jq_yyget_debug +#endif + +#ifdef yyset_debug +#define jq_yyset_debug_ALREADY_DEFINED +#else +#define yyset_debug jq_yyset_debug +#endif + +#ifdef yyget_extra +#define jq_yyget_extra_ALREADY_DEFINED +#else +#define yyget_extra jq_yyget_extra +#endif + +#ifdef yyset_extra +#define jq_yyset_extra_ALREADY_DEFINED +#else +#define yyset_extra jq_yyset_extra +#endif + +#ifdef yyget_in +#define jq_yyget_in_ALREADY_DEFINED +#else +#define yyget_in jq_yyget_in +#endif + +#ifdef yyset_in +#define jq_yyset_in_ALREADY_DEFINED +#else +#define yyset_in jq_yyset_in +#endif + +#ifdef yyget_out +#define jq_yyget_out_ALREADY_DEFINED +#else +#define yyget_out jq_yyget_out +#endif + +#ifdef yyset_out +#define jq_yyset_out_ALREADY_DEFINED +#else +#define yyset_out jq_yyset_out +#endif + +#ifdef yyget_leng +#define jq_yyget_leng_ALREADY_DEFINED +#else +#define yyget_leng jq_yyget_leng +#endif + +#ifdef yyget_text +#define jq_yyget_text_ALREADY_DEFINED +#else +#define yyget_text jq_yyget_text +#endif + +#ifdef yyget_lineno +#define jq_yyget_lineno_ALREADY_DEFINED +#else +#define yyget_lineno jq_yyget_lineno +#endif + +#ifdef yyset_lineno +#define jq_yyset_lineno_ALREADY_DEFINED +#else +#define yyset_lineno jq_yyset_lineno +#endif + +#ifdef yyget_column +#define jq_yyget_column_ALREADY_DEFINED +#else +#define yyget_column jq_yyget_column +#endif + +#ifdef yyset_column +#define jq_yyset_column_ALREADY_DEFINED +#else +#define yyset_column jq_yyset_column +#endif + +#ifdef yywrap +#define jq_yywrap_ALREADY_DEFINED +#else +#define yywrap jq_yywrap +#endif + +#ifdef yyget_lval +#define jq_yyget_lval_ALREADY_DEFINED +#else +#define yyget_lval jq_yyget_lval +#endif + +#ifdef yyset_lval +#define jq_yyset_lval_ALREADY_DEFINED +#else +#define yyset_lval jq_yyset_lval +#endif + +#ifdef yyget_lloc +#define jq_yyget_lloc_ALREADY_DEFINED +#else +#define yyget_lloc jq_yyget_lloc +#endif + +#ifdef yyset_lloc +#define jq_yyset_lloc_ALREADY_DEFINED +#else +#define yyset_lloc jq_yyset_lloc +#endif + +#ifdef yyalloc +#define jq_yyalloc_ALREADY_DEFINED +#else +#define yyalloc jq_yyalloc +#endif + +#ifdef yyrealloc +#define jq_yyrealloc_ALREADY_DEFINED +#else +#define yyrealloc jq_yyrealloc +#endif + +#ifdef yyfree +#define jq_yyfree_ALREADY_DEFINED +#else +#define yyfree jq_yyfree +#endif + /* First, we deal with platform-specific or compiler-specific issues. */ /* begin standard C headers. */ @@ -84,40 +318,32 @@ typedef unsigned int flex_uint32_t; #define UINT32_MAX (4294967295U) #endif +#ifndef SIZE_MAX +#define SIZE_MAX (~(size_t)0) +#endif + #endif /* ! C99 */ #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 +/* begin standard C++ headers. */ -#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. */ #define YY_NULL 0 -/* Promotes a possibly negative, possibly signed char to an unsigned - * integer for use as an array index. If the signed char is negative, - * we want to instead treat it as an 8-bit unsigned char, hence the - * double cast. +/* Promotes a possibly negative, possibly signed char to an + * integer in range [0..255] for use as an array index. */ -#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c) +#define YY_SC_TO_UI(c) ((YY_CHAR) (c)) /* An opaque pointer. */ #ifndef YY_TYPEDEF_YY_SCANNER_T @@ -141,20 +367,16 @@ typedef void* yyscan_t; * definition of BEGIN. */ #define BEGIN yyg->yy_start = 1 + 2 * - /* Translate the current start state into a value that can be later handed * to BEGIN to return to the state. The YYSTATE alias is for lex * compatibility. */ #define YY_START ((yyg->yy_start - 1) / 2) #define YYSTATE YY_START - /* Action number for EOF rule of a given start state. */ #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) - /* Special action meaning "start processing a new file". */ -#define YY_NEW_FILE jq_yyrestart(yyin ,yyscanner ) - +#define YY_NEW_FILE yyrestart( yyin , yyscanner ) #define YY_END_OF_BUFFER_CHAR 0 /* Size of default input buffer. */ @@ -187,7 +409,7 @@ typedef size_t yy_size_t; #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 YY_LINENO_REWIND_TO(ptr) @@ -204,7 +426,6 @@ typedef size_t yy_size_t; YY_DO_BEFORE_ACTION; /* set up yytext again */ \ } \ while ( 0 ) - #define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner ) #ifndef YY_STRUCT_YY_BUFFER_STATE @@ -219,7 +440,7 @@ 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. @@ -247,7 +468,7 @@ struct yy_buffer_state int yy_bs_lineno; /**< The line count. */ int yy_bs_column; /**< The column count. */ - + /* Whether to try to fill the input buffer when we reach the * end of it. */ @@ -264,7 +485,7 @@ struct yy_buffer_state * possible backing-up. * * When we actually see the EOF, we change the status to "new" - * (via jq_yyrestart()), so that the user can continue scanning by + * (via yyrestart()), so that the user can continue scanning by * just pointing yyin at a new input file. */ #define YY_BUFFER_EOF_PENDING 2 @@ -281,87 +502,77 @@ struct yy_buffer_state #define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \ ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \ : NULL) - /* Same as previous macro, but useful when we know that the buffer stack is not * NULL or when we need an lvalue. For internal use only. */ #define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] -void jq_yyrestart (FILE *input_file ,yyscan_t yyscanner ); -void jq_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner ); -YY_BUFFER_STATE jq_yy_create_buffer (FILE *file,int size ,yyscan_t yyscanner ); -void jq_yy_delete_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner ); -void jq_yy_flush_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner ); -void jq_yypush_buffer_state (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner ); -void jq_yypop_buffer_state (yyscan_t yyscanner ); - -static void jq_yyensure_buffer_stack (yyscan_t yyscanner ); -static void jq_yy_load_buffer_state (yyscan_t yyscanner ); -static void jq_yy_init_buffer (YY_BUFFER_STATE b,FILE *file ,yyscan_t yyscanner ); +void yyrestart ( FILE *input_file , yyscan_t yyscanner ); +void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner ); +YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size , yyscan_t yyscanner ); +void yy_delete_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner ); +void yy_flush_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner ); +void yypush_buffer_state ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner ); +void yypop_buffer_state ( yyscan_t yyscanner ); -#define YY_FLUSH_BUFFER jq_yy_flush_buffer(YY_CURRENT_BUFFER ,yyscanner) +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 ); +#define YY_FLUSH_BUFFER yy_flush_buffer( YY_CURRENT_BUFFER , yyscanner) -YY_BUFFER_STATE jq_yy_scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner ); -YY_BUFFER_STATE jq_yy_scan_string (yyconst char *yy_str ,yyscan_t yyscanner ); -YY_BUFFER_STATE jq_yy_scan_bytes (yyconst char *bytes,yy_size_t len ,yyscan_t yyscanner ); +YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size , yyscan_t yyscanner ); +YY_BUFFER_STATE yy_scan_string ( const char *yy_str , yyscan_t yyscanner ); +YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, int len , yyscan_t yyscanner ); -void *jq_yyalloc (yy_size_t ,yyscan_t yyscanner ); -void *jq_yyrealloc (void *,yy_size_t ,yyscan_t yyscanner ); -void jq_yyfree (void * ,yyscan_t yyscanner ); - -#define yy_new_buffer jq_yy_create_buffer +void *yyalloc ( yy_size_t , yyscan_t yyscanner ); +void *yyrealloc ( void *, yy_size_t , yyscan_t yyscanner ); +void yyfree ( void * , yyscan_t yyscanner ); +#define yy_new_buffer yy_create_buffer #define yy_set_interactive(is_interactive) \ { \ if ( ! YY_CURRENT_BUFFER ){ \ - jq_yyensure_buffer_stack (yyscanner); \ + yyensure_buffer_stack (yyscanner); \ YY_CURRENT_BUFFER_LVALUE = \ - jq_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \ + yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); \ } \ YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \ } - #define yy_set_bol(at_bol) \ { \ if ( ! YY_CURRENT_BUFFER ){\ - jq_yyensure_buffer_stack (yyscanner); \ + yyensure_buffer_stack (yyscanner); \ YY_CURRENT_BUFFER_LVALUE = \ - jq_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \ + yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); \ } \ YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ } - #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) /* Begin user sect3 */ #define jq_yywrap(yyscanner) (/*CONSTCOND*/1) #define YY_SKIP_YYWRAP - -typedef unsigned char YY_CHAR; +typedef flex_uint8_t YY_CHAR; typedef int yy_state_type; #define yytext_ptr yytext_r -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 ); -#if defined(__GNUC__) && __GNUC__ >= 3 -__attribute__((__noreturn__)) -#endif -static void yy_fatal_error (yyconst char msg[] ,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 yynoreturn yy_fatal_error ( const 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; - #define YY_NUM_RULES 50 #define YY_END_OF_BUFFER 51 /* This struct is not used in this scanner, @@ -371,7 +582,7 @@ struct yy_trans_info flex_int32_t yy_verify; flex_int32_t yy_nxt; }; -static yyconst flex_int16_t yy_accept[157] = +static const flex_int16_t yy_accept[157] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 51, 49, 48, 48, 49, 40, 1, 35, @@ -392,7 +603,7 @@ static yyconst flex_int16_t yy_accept[157] = 7, 16, 23, 17, 6, 0 } ; -static yyconst YY_CHAR yy_ec[256] = +static const YY_CHAR yy_ec[256] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, @@ -424,7 +635,7 @@ static yyconst YY_CHAR yy_ec[256] = 1, 1, 1, 1, 1 } ; -static yyconst YY_CHAR yy_meta[54] = +static const YY_CHAR yy_meta[54] = { 0, 1, 1, 2, 2, 1, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 4, 1, 5, 6, 1, @@ -434,7 +645,7 @@ static yyconst YY_CHAR yy_meta[54] = 1, 1, 1 } ; -static yyconst flex_uint16_t yy_base[170] = +static const flex_int16_t yy_base[170] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 51, 52, 320, 321, 57, 59, 297, 321, 0, 321, @@ -456,7 +667,7 @@ static yyconst flex_uint16_t yy_base[170] = 255, 264, 273, 278, 283, 285, 290, 294, 298 } ; -static yyconst flex_int16_t yy_def[170] = +static const flex_int16_t yy_def[170] = { 0, 156, 1, 1, 1, 1, 1, 1, 1, 1, 1, 157, 157, 156, 156, 156, 156, 156, 156, 158, 156, @@ -478,7 +689,7 @@ static yyconst flex_int16_t yy_def[170] = 156, 156, 156, 156, 156, 156, 156, 156, 156 } ; -static yyconst flex_uint16_t yy_nxt[375] = +static const flex_int16_t yy_nxt[375] = { 0, 14, 15, 16, 14, 17, 18, 19, 20, 21, 22, 23, 24, 25, 20, 26, 27, 28, 29, 20, 20, @@ -523,7 +734,7 @@ static yyconst flex_uint16_t yy_nxt[375] = 156, 156, 156, 156 } ; -static yyconst flex_int16_t yy_chk[375] = +static const flex_int16_t yy_chk[375] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, @@ -587,21 +798,19 @@ struct lexer_param; #define YY_USER_ACTION \ do { \ - yylloc->start = jq_yyget_extra(yyscanner); \ + yylloc->start = yyget_extra(yyscanner); \ yylloc->end = yylloc->start + yyleng; \ - jq_yyset_extra(yylloc->end,yyscanner); \ + yyset_extra(yylloc->end, yyscanner); \ } while (0); - - - - +#line 807 "src/lexer.c" #line 25 "src/lexer.l" static int enter(int opening, int state, yyscan_t yyscanner); static int try_exit(int closing, int state, yyscan_t yyscanner); +#line 812 "src/lexer.c" #define YY_NO_INPUT 1 -#line 605 "src/lexer.c" +#line 814 "src/lexer.c" #define INITIAL 0 #define IN_PAREN 1 @@ -634,7 +843,7 @@ struct yyguts_t YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */ char yy_hold_char; int yy_n_chars; - yy_size_t yyleng_r; + int yyleng_r; char *yy_c_buf_p; int yy_init; int yy_start; @@ -658,7 +867,7 @@ struct yyguts_t }; /* end struct yyguts_t */ -static int yy_init_globals (yyscan_t yyscanner ); +static int yy_init_globals ( yyscan_t yyscanner ); /* This must go here because YYSTYPE and YYLTYPE are included * from bison output in section 1.*/ @@ -666,50 +875,50 @@ static int yy_init_globals (yyscan_t yyscanner ); # define yylloc yyg->yylloc_r -int jq_yylex_init (yyscan_t* scanner); +int yylex_init (yyscan_t* scanner); -int jq_yylex_init_extra (YY_EXTRA_TYPE user_defined,yyscan_t* scanner); +int yylex_init_extra ( YY_EXTRA_TYPE user_defined, yyscan_t* scanner); /* Accessor methods to globals. These are made visible to non-reentrant scanners for convenience. */ -int jq_yylex_destroy (yyscan_t yyscanner ); +int yylex_destroy ( yyscan_t yyscanner ); -int jq_yyget_debug (yyscan_t yyscanner ); +int yyget_debug ( yyscan_t yyscanner ); -void jq_yyset_debug (int debug_flag ,yyscan_t yyscanner ); +void yyset_debug ( int debug_flag , yyscan_t yyscanner ); -YY_EXTRA_TYPE jq_yyget_extra (yyscan_t yyscanner ); +YY_EXTRA_TYPE yyget_extra ( yyscan_t yyscanner ); -void jq_yyset_extra (YY_EXTRA_TYPE user_defined ,yyscan_t yyscanner ); +void yyset_extra ( YY_EXTRA_TYPE user_defined , yyscan_t yyscanner ); -FILE *jq_yyget_in (yyscan_t yyscanner ); +FILE *yyget_in ( yyscan_t yyscanner ); -void jq_yyset_in (FILE * _in_str ,yyscan_t yyscanner ); +void yyset_in ( FILE * _in_str , yyscan_t yyscanner ); -FILE *jq_yyget_out (yyscan_t yyscanner ); +FILE *yyget_out ( yyscan_t yyscanner ); -void jq_yyset_out (FILE * _out_str ,yyscan_t yyscanner ); +void yyset_out ( FILE * _out_str , yyscan_t yyscanner ); -yy_size_t jq_yyget_leng (yyscan_t yyscanner ); + int yyget_leng ( yyscan_t yyscanner ); -char *jq_yyget_text (yyscan_t yyscanner ); +char *yyget_text ( yyscan_t yyscanner ); -int jq_yyget_lineno (yyscan_t yyscanner ); +int yyget_lineno ( yyscan_t yyscanner ); -void jq_yyset_lineno (int _line_number ,yyscan_t yyscanner ); +void yyset_lineno ( int _line_number , yyscan_t yyscanner ); -int jq_yyget_column (yyscan_t yyscanner ); +int yyget_column ( yyscan_t yyscanner ); -void jq_yyset_column (int _column_no ,yyscan_t yyscanner ); +void yyset_column ( int _column_no , yyscan_t yyscanner ); -YYSTYPE * jq_yyget_lval (yyscan_t yyscanner ); +YYSTYPE * yyget_lval ( yyscan_t yyscanner ); -void jq_yyset_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner ); +void yyset_lval ( YYSTYPE * yylval_param , yyscan_t yyscanner ); - YYLTYPE *jq_yyget_lloc (yyscan_t yyscanner ); + YYLTYPE *yyget_lloc ( yyscan_t yyscanner ); - void jq_yyset_lloc (YYLTYPE * yylloc_param ,yyscan_t yyscanner ); + void yyset_lloc ( YYLTYPE * yylloc_param , yyscan_t yyscanner ); /* Macros after this point can all be overridden by user definitions in * section 1. @@ -717,9 +926,9 @@ void jq_yyset_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner ); #ifndef YY_SKIP_YYWRAP #ifdef __cplusplus -extern "C" int jq_yywrap (yyscan_t yyscanner ); +extern "C" int yywrap ( yyscan_t yyscanner ); #else -extern int jq_yywrap (yyscan_t yyscanner ); +extern int yywrap ( yyscan_t yyscanner ); #endif #endif @@ -728,28 +937,27 @@ extern int jq_yywrap (yyscan_t yyscanner ); #endif #ifndef yytext_ptr -static void yy_flex_strncpy (char *,yyconst char *,int ,yyscan_t yyscanner); +static void yy_flex_strncpy ( char *, const char *, int , yyscan_t yyscanner); #endif #ifdef YY_NEED_STRLEN -static int yy_flex_strlen (yyconst char * ,yyscan_t yyscanner); +static int yy_flex_strlen ( const char * , yyscan_t yyscanner); #endif #ifndef YY_NO_INPUT - #ifdef __cplusplus -static int yyinput (yyscan_t yyscanner ); +static int yyinput ( yyscan_t yyscanner ); #else -static int input (yyscan_t yyscanner ); +static int input ( yyscan_t yyscanner ); #endif #endif - static void yy_push_state (int _new_state ,yyscan_t yyscanner); + static void yy_push_state ( int _new_state , yyscan_t yyscanner); - static void yy_pop_state (yyscan_t yyscanner ); + static void yy_pop_state ( yyscan_t yyscanner ); - static int yy_top_state (yyscan_t yyscanner ); + static int yy_top_state ( yyscan_t yyscanner ); /* Amount of stuff to slurp up with each read. */ #ifndef YY_READ_BUF_SIZE @@ -766,7 +974,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, @@ -777,7 +985,7 @@ static int input (yyscan_t yyscanner ); if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ { \ int c = '*'; \ - size_t n; \ + int n; \ for ( n = 0; n < max_size && \ (c = getc( yyin )) != EOF && c != '\n'; ++n ) \ buf[n] = (char) c; \ @@ -790,7 +998,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, (yy_size_t) max_size, yyin)) == 0 && ferror(yyin)) \ { \ if( errno != EINTR) \ { \ @@ -831,10 +1039,10 @@ static int input (yyscan_t yyscanner ); #ifndef YY_DECL #define YY_DECL_IS_OURS 1 -extern int jq_yylex \ - (YYSTYPE * yylval_param,YYLTYPE * yylloc_param ,yyscan_t yyscanner); +extern int yylex \ + (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner); -#define YY_DECL int jq_yylex \ +#define YY_DECL int yylex \ (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner) #endif /* !YY_DECL */ @@ -884,19 +1092,19 @@ YY_DECL yyout = stdout; if ( ! YY_CURRENT_BUFFER ) { - jq_yyensure_buffer_stack (yyscanner); + yyensure_buffer_stack (yyscanner); YY_CURRENT_BUFFER_LVALUE = - jq_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); + yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); } - jq_yy_load_buffer_state(yyscanner ); + yy_load_buffer_state( yyscanner ); } { #line 38 "src/lexer.l" -#line 900 "src/lexer.c" +#line 1108 "src/lexer.c" while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */ { @@ -924,9 +1132,9 @@ YY_DECL { yy_current_state = (int) yy_def[yy_current_state]; if ( yy_current_state >= 157 ) - yy_c = yy_meta[(unsigned int) yy_c]; + yy_c = yy_meta[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] + yy_c]; ++yy_cp; } while ( yy_base[yy_current_state] != 321 ); @@ -1235,7 +1443,7 @@ YY_RULE_SETUP #line 130 "src/lexer.l" YY_FATAL_ERROR( "flex scanner jammed" ); YY_BREAK -#line 1239 "src/lexer.c" +#line 1447 "src/lexer.c" case YY_STATE_EOF(INITIAL): case YY_STATE_EOF(IN_PAREN): case YY_STATE_EOF(IN_BRACKET): @@ -1258,7 +1466,7 @@ case YY_STATE_EOF(IN_QQSTRING): /* We're scanning a new file or input source. It's * possible that this happened because the user * just pointed yyin at a new source and called - * jq_yylex(). If so, then we have to assure + * yylex(). If so, then we have to assure * consistency between YY_CURRENT_BUFFER and our * globals. Here is the right place to do so, because * this is the first action (other than possibly a @@ -1318,7 +1526,7 @@ case YY_STATE_EOF(IN_QQSTRING): { yyg->yy_did_buffer_switch_on_eof = 0; - if ( jq_yywrap(yyscanner ) ) + if ( yywrap( yyscanner ) ) { /* Note: because we've taken care in * yy_get_next_buffer() to have set up @@ -1372,7 +1580,7 @@ case YY_STATE_EOF(IN_QQSTRING): } /* end of action switch */ } /* end of scanning one token */ } /* end of user's declarations */ -} /* end of jq_yylex */ +} /* end of yylex */ /* yy_get_next_buffer - try to read in a new buffer * @@ -1386,7 +1594,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner) struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; char *source = yyg->yytext_ptr; - yy_size_t number_to_move, i; + 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] ) @@ -1415,7 +1623,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 = (yy_size_t) (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++); @@ -1428,7 +1636,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 ) @@ -1442,7 +1650,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; @@ -1451,11 +1659,12 @@ static int yy_get_next_buffer (yyscan_t yyscanner) b->yy_ch_buf = (char *) /* Include room in for 2 EOB chars. */ - jq_yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ,yyscanner ); + yyrealloc( (void *) b->yy_ch_buf, + (yy_size_t) (b->yy_buf_size + 2) , 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( @@ -1483,7 +1692,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner) if ( number_to_move == YY_MORE_ADJ ) { ret_val = EOB_ACT_END_OF_FILE; - jq_yyrestart(yyin ,yyscanner); + yyrestart( yyin , yyscanner); } else @@ -1497,12 +1706,15 @@ static int yy_get_next_buffer (yyscan_t yyscanner) else ret_val = EOB_ACT_CONTINUE_SCAN; - if ((int) (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. */ int new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1); - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) jq_yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ,yyscanner ); + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc( + (void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf, (yy_size_t) new_size , yyscanner ); if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" ); + /* "- 2" to take care of EOB's */ + YY_CURRENT_BUFFER_LVALUE->yy_buf_size = (int) (new_size - 2); } yyg->yy_n_chars += number_to_move; @@ -1536,9 +1748,9 @@ static int yy_get_next_buffer (yyscan_t yyscanner) { yy_current_state = (int) yy_def[yy_current_state]; if ( yy_current_state >= 157 ) - yy_c = yy_meta[(unsigned int) yy_c]; + yy_c = yy_meta[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] + yy_c]; } return yy_current_state; @@ -1565,9 +1777,9 @@ static int yy_get_next_buffer (yyscan_t yyscanner) { yy_current_state = (int) yy_def[yy_current_state]; if ( yy_current_state >= 157 ) - yy_c = yy_meta[(unsigned int) yy_c]; + yy_c = yy_meta[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] + yy_c]; yy_is_jam = (yy_current_state == 156); (void)yyg; @@ -1603,7 +1815,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 = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr); ++yyg->yy_c_buf_p; switch ( yy_get_next_buffer( yyscanner ) ) @@ -1620,14 +1832,14 @@ static int yy_get_next_buffer (yyscan_t yyscanner) */ /* Reset buffer status. */ - jq_yyrestart(yyin ,yyscanner); + yyrestart( yyin , yyscanner); /*FALLTHROUGH*/ case EOB_ACT_END_OF_FILE: { - if ( jq_yywrap(yyscanner ) ) - return EOF; + if ( yywrap( yyscanner ) ) + return 0; if ( ! yyg->yy_did_buffer_switch_on_eof ) YY_NEW_FILE; @@ -1658,34 +1870,34 @@ static int yy_get_next_buffer (yyscan_t yyscanner) * @param yyscanner The scanner object. * @note This function does not reset the start condition to @c INITIAL . */ - void jq_yyrestart (FILE * input_file , yyscan_t yyscanner) + void yyrestart (FILE * input_file , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; if ( ! YY_CURRENT_BUFFER ){ - jq_yyensure_buffer_stack (yyscanner); + yyensure_buffer_stack (yyscanner); YY_CURRENT_BUFFER_LVALUE = - jq_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); + yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); } - jq_yy_init_buffer(YY_CURRENT_BUFFER,input_file ,yyscanner); - jq_yy_load_buffer_state(yyscanner ); + yy_init_buffer( YY_CURRENT_BUFFER, input_file , yyscanner); + yy_load_buffer_state( yyscanner ); } /** Switch to a different input buffer. * @param new_buffer The new input buffer. * @param yyscanner The scanner object. */ - void jq_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner) + void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* TODO. We should be able to replace this entire function body * with - * jq_yypop_buffer_state(); - * jq_yypush_buffer_state(new_buffer); + * yypop_buffer_state(); + * yypush_buffer_state(new_buffer); */ - jq_yyensure_buffer_stack (yyscanner); + yyensure_buffer_stack (yyscanner); if ( YY_CURRENT_BUFFER == new_buffer ) return; @@ -1698,17 +1910,17 @@ static int yy_get_next_buffer (yyscan_t yyscanner) } YY_CURRENT_BUFFER_LVALUE = new_buffer; - jq_yy_load_buffer_state(yyscanner ); + yy_load_buffer_state( yyscanner ); /* We don't actually know whether we did this switch during - * EOF (jq_yywrap()) processing, but the only time this flag - * is looked at is after jq_yywrap() is called, so it's safe + * EOF (yywrap()) processing, but the only time this flag + * is looked at is after yywrap() is called, so it's safe * to go ahead and always set it. */ yyg->yy_did_buffer_switch_on_eof = 1; } -static void jq_yy_load_buffer_state (yyscan_t yyscanner) +static void yy_load_buffer_state (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; @@ -1723,35 +1935,35 @@ static void jq_yy_load_buffer_state (yyscan_t yyscanner) * @param yyscanner The scanner object. * @return the allocated buffer state. */ - YY_BUFFER_STATE jq_yy_create_buffer (FILE * file, int size , yyscan_t yyscanner) + YY_BUFFER_STATE yy_create_buffer (FILE * file, int size , yyscan_t yyscanner) { YY_BUFFER_STATE b; - b = (YY_BUFFER_STATE) jq_yyalloc(sizeof( struct yy_buffer_state ) ,yyscanner ); + b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner ); if ( ! b ) - YY_FATAL_ERROR( "out of dynamic memory in jq_yy_create_buffer()" ); + YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" ); - b->yy_buf_size = (yy_size_t)size; + b->yy_buf_size = 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. */ - b->yy_ch_buf = (char *) jq_yyalloc(b->yy_buf_size + 2 ,yyscanner ); + b->yy_ch_buf = (char *) yyalloc( (yy_size_t) (b->yy_buf_size + 2) , yyscanner ); if ( ! b->yy_ch_buf ) - YY_FATAL_ERROR( "out of dynamic memory in jq_yy_create_buffer()" ); + YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" ); b->yy_is_our_buffer = 1; - jq_yy_init_buffer(b,file ,yyscanner); + yy_init_buffer( b, file , yyscanner); return b; } /** Destroy the buffer. - * @param b a buffer created with jq_yy_create_buffer() + * @param b a buffer created with yy_create_buffer() * @param yyscanner The scanner object. */ - void jq_yy_delete_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner) + void yy_delete_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; @@ -1762,28 +1974,28 @@ static void jq_yy_load_buffer_state (yyscan_t yyscanner) YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0; if ( b->yy_is_our_buffer ) - jq_yyfree((void *) b->yy_ch_buf ,yyscanner ); + yyfree( (void *) b->yy_ch_buf , yyscanner ); - jq_yyfree((void *) b ,yyscanner ); + yyfree( (void *) b , yyscanner ); } /* Initializes or reinitializes a buffer. * This function is sometimes called more than once on the same buffer, - * such as during a jq_yyrestart() or at EOF. + * such as during a yyrestart() or at EOF. */ - static void jq_yy_init_buffer (YY_BUFFER_STATE b, FILE * file , yyscan_t yyscanner) + static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file , yyscan_t yyscanner) { int oerrno = errno; struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; - jq_yy_flush_buffer(b ,yyscanner); + yy_flush_buffer( b , yyscanner); b->yy_input_file = file; b->yy_fill_buffer = 1; - /* If b is the current buffer, then jq_yy_init_buffer was _probably_ - * called from jq_yyrestart() or through yy_get_next_buffer. + /* If b is the current buffer, then yy_init_buffer was _probably_ + * called from yyrestart() or through yy_get_next_buffer. * In that case, we don't want to reset the lineno or column. */ if (b != YY_CURRENT_BUFFER){ @@ -1800,7 +2012,7 @@ static void jq_yy_load_buffer_state (yyscan_t yyscanner) * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. * @param yyscanner The scanner object. */ - void jq_yy_flush_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner) + void yy_flush_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; if ( ! b ) @@ -1821,7 +2033,7 @@ static void jq_yy_load_buffer_state (yyscan_t yyscanner) b->yy_buffer_status = YY_BUFFER_NEW; if ( b == YY_CURRENT_BUFFER ) - jq_yy_load_buffer_state(yyscanner ); + yy_load_buffer_state( yyscanner ); } /** Pushes the new state onto the stack. The new state becomes @@ -1830,15 +2042,15 @@ static void jq_yy_load_buffer_state (yyscan_t yyscanner) * @param new_buffer The new state. * @param yyscanner The scanner object. */ -void jq_yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner) +void yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; if (new_buffer == NULL) return; - jq_yyensure_buffer_stack(yyscanner); + yyensure_buffer_stack(yyscanner); - /* This block is copied from jq_yy_switch_to_buffer. */ + /* This block is copied from yy_switch_to_buffer. */ if ( YY_CURRENT_BUFFER ) { /* Flush out information for old buffer. */ @@ -1852,8 +2064,8 @@ void jq_yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner) yyg->yy_buffer_stack_top++; YY_CURRENT_BUFFER_LVALUE = new_buffer; - /* copied from jq_yy_switch_to_buffer. */ - jq_yy_load_buffer_state(yyscanner ); + /* copied from yy_switch_to_buffer. */ + yy_load_buffer_state( yyscanner ); yyg->yy_did_buffer_switch_on_eof = 1; } @@ -1861,19 +2073,19 @@ void jq_yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner) * The next element becomes the new top. * @param yyscanner The scanner object. */ -void jq_yypop_buffer_state (yyscan_t yyscanner) +void yypop_buffer_state (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; if (!YY_CURRENT_BUFFER) return; - jq_yy_delete_buffer(YY_CURRENT_BUFFER ,yyscanner); + yy_delete_buffer(YY_CURRENT_BUFFER , yyscanner); YY_CURRENT_BUFFER_LVALUE = NULL; if (yyg->yy_buffer_stack_top > 0) --yyg->yy_buffer_stack_top; if (YY_CURRENT_BUFFER) { - jq_yy_load_buffer_state(yyscanner ); + yy_load_buffer_state( yyscanner ); yyg->yy_did_buffer_switch_on_eof = 1; } } @@ -1881,7 +2093,7 @@ void jq_yypop_buffer_state (yyscan_t yyscanner) /* Allocates the stack if it does not exist. * Guarantees space for at least one push. */ -static void jq_yyensure_buffer_stack (yyscan_t yyscanner) +static void yyensure_buffer_stack (yyscan_t yyscanner) { yy_size_t num_to_alloc; struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; @@ -1892,15 +2104,15 @@ static void jq_yyensure_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; /* After all that talk, this was set to 1 anyways... */ - yyg->yy_buffer_stack = (struct yy_buffer_state**)jq_yyalloc + num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */ + yyg->yy_buffer_stack = (struct yy_buffer_state**)yyalloc (num_to_alloc * sizeof(struct yy_buffer_state*) , yyscanner); if ( ! yyg->yy_buffer_stack ) - YY_FATAL_ERROR( "out of dynamic memory in jq_yyensure_buffer_stack()" ); - + YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" ); + memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*)); - + yyg->yy_buffer_stack_max = num_to_alloc; yyg->yy_buffer_stack_top = 0; return; @@ -1912,12 +2124,12 @@ static void jq_yyensure_buffer_stack (yyscan_t yyscanner) 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**)jq_yyrealloc + yyg->yy_buffer_stack = (struct yy_buffer_state**)yyrealloc (yyg->yy_buffer_stack, num_to_alloc * sizeof(struct yy_buffer_state*) , yyscanner); if ( ! yyg->yy_buffer_stack ) - YY_FATAL_ERROR( "out of dynamic memory in jq_yyensure_buffer_stack()" ); + YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" ); /* zero only the new slots.*/ memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*)); @@ -1929,9 +2141,9 @@ static void jq_yyensure_buffer_stack (yyscan_t yyscanner) * @param base the character buffer * @param size the size in bytes of the character buffer * @param yyscanner The scanner object. - * @return the newly allocated buffer state object. + * @return the newly allocated buffer state object. */ -YY_BUFFER_STATE jq_yy_scan_buffer (char * base, yy_size_t size , yyscan_t yyscanner) +YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size , yyscan_t yyscanner) { YY_BUFFER_STATE b; @@ -1939,69 +2151,69 @@ YY_BUFFER_STATE jq_yy_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) jq_yyalloc(sizeof( struct yy_buffer_state ) ,yyscanner ); + b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner ); if ( ! b ) - YY_FATAL_ERROR( "out of dynamic memory in jq_yy_scan_buffer()" ); + YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" ); - b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */ + b->yy_buf_size = (int) (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; b->yy_fill_buffer = 0; b->yy_buffer_status = YY_BUFFER_NEW; - jq_yy_switch_to_buffer(b ,yyscanner ); + yy_switch_to_buffer( b , yyscanner ); return b; } -/** Setup the input buffer state to scan a string. The next call to jq_yylex() will +/** Setup the input buffer state to scan a string. The next call to yylex() will * scan from a @e copy of @a str. * @param yystr a NUL-terminated string to scan * @param yyscanner The scanner object. * @return the newly allocated buffer state object. * @note If you want to scan bytes that may contain NUL values, then use - * jq_yy_scan_bytes() instead. + * yy_scan_bytes() instead. */ -YY_BUFFER_STATE jq_yy_scan_string (yyconst char * yystr , yyscan_t yyscanner) +YY_BUFFER_STATE yy_scan_string (const char * yystr , yyscan_t yyscanner) { - return jq_yy_scan_bytes(yystr,strlen(yystr) ,yyscanner); + return yy_scan_bytes( yystr, (int) strlen(yystr) , yyscanner); } -/** Setup the input buffer state to scan the given bytes. The next call to jq_yylex() will +/** Setup the input buffer state to scan the given bytes. The next call to yylex() will * scan from a @e copy of @a bytes. * @param yybytes the byte buffer to scan * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. * @param yyscanner The scanner object. * @return the newly allocated buffer state object. */ -YY_BUFFER_STATE jq_yy_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len , yyscan_t yyscanner) +YY_BUFFER_STATE yy_scan_bytes (const char * yybytes, int _yybytes_len , yyscan_t yyscanner) { YY_BUFFER_STATE b; char *buf; yy_size_t n; - yy_size_t i; + int i; /* Get memory for full buffer, including space for trailing EOB's. */ - n = _yybytes_len + 2; - buf = (char *) jq_yyalloc(n ,yyscanner ); + n = (yy_size_t) (_yybytes_len + 2); + buf = (char *) yyalloc( n , yyscanner ); if ( ! buf ) - YY_FATAL_ERROR( "out of dynamic memory in jq_yy_scan_bytes()" ); + YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" ); for ( i = 0; i < _yybytes_len; ++i ) buf[i] = yybytes[i]; buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR; - b = jq_yy_scan_buffer(buf,n ,yyscanner); + b = yy_scan_buffer( buf, n , yyscanner); if ( ! b ) - YY_FATAL_ERROR( "bad buffer in jq_yy_scan_bytes()" ); + YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" ); /* It's okay to grow etc. this buffer, and we should throw it * away when we're done. @@ -2019,13 +2231,14 @@ YY_BUFFER_STATE jq_yy_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_l yy_size_t new_size; yyg->yy_start_stack_depth += YY_START_STACK_INCR; - new_size = yyg->yy_start_stack_depth * sizeof( int ); + new_size = (yy_size_t) yyg->yy_start_stack_depth * sizeof( int ); if ( ! yyg->yy_start_stack ) - yyg->yy_start_stack = (int *) jq_yyalloc(new_size ,yyscanner ); + yyg->yy_start_stack = (int *) yyalloc( new_size , yyscanner ); else - yyg->yy_start_stack = (int *) jq_yyrealloc((void *) yyg->yy_start_stack,new_size ,yyscanner ); + yyg->yy_start_stack = (int *) yyrealloc( + (void *) yyg->yy_start_stack, new_size , yyscanner ); if ( ! yyg->yy_start_stack ) YY_FATAL_ERROR( "out of memory expanding start-condition stack" ); @@ -2055,11 +2268,11 @@ YY_BUFFER_STATE jq_yy_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 (const char* msg , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; (void)yyg; - (void) fprintf( stderr, "%s\n", msg ); + fprintf( stderr, "%s\n", msg ); exit( YY_EXIT_FAILURE ); } @@ -2085,7 +2298,7 @@ static void yy_fatal_error (yyconst char* msg , yyscan_t yyscanner) /** Get the user-defined data for this scanner. * @param yyscanner The scanner object. */ -YY_EXTRA_TYPE jq_yyget_extra (yyscan_t yyscanner) +YY_EXTRA_TYPE yyget_extra (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; return yyextra; @@ -2094,10 +2307,10 @@ YY_EXTRA_TYPE jq_yyget_extra (yyscan_t yyscanner) /** Get the current line number. * @param yyscanner The scanner object. */ -int jq_yyget_lineno (yyscan_t yyscanner) +int yyget_lineno (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; - + if (! YY_CURRENT_BUFFER) return 0; @@ -2107,10 +2320,10 @@ int jq_yyget_lineno (yyscan_t yyscanner) /** Get the current column number. * @param yyscanner The scanner object. */ -int jq_yyget_column (yyscan_t yyscanner) +int yyget_column (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; - + if (! YY_CURRENT_BUFFER) return 0; @@ -2120,7 +2333,7 @@ int jq_yyget_column (yyscan_t yyscanner) /** Get the input stream. * @param yyscanner The scanner object. */ -FILE *jq_yyget_in (yyscan_t yyscanner) +FILE *yyget_in (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; return yyin; @@ -2129,7 +2342,7 @@ FILE *jq_yyget_in (yyscan_t yyscanner) /** Get the output stream. * @param yyscanner The scanner object. */ -FILE *jq_yyget_out (yyscan_t yyscanner) +FILE *yyget_out (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; return yyout; @@ -2138,7 +2351,7 @@ FILE *jq_yyget_out (yyscan_t yyscanner) /** Get the length of the current token. * @param yyscanner The scanner object. */ -yy_size_t jq_yyget_leng (yyscan_t yyscanner) +int yyget_leng (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; return yyleng; @@ -2148,7 +2361,7 @@ yy_size_t jq_yyget_leng (yyscan_t yyscanner) * @param yyscanner The scanner object. */ -char *jq_yyget_text (yyscan_t yyscanner) +char *yyget_text (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; return yytext; @@ -2158,7 +2371,7 @@ char *jq_yyget_text (yyscan_t yyscanner) * @param user_defined The data to be associated with this scanner. * @param yyscanner The scanner object. */ -void jq_yyset_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner) +void yyset_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; yyextra = user_defined ; @@ -2168,13 +2381,13 @@ void jq_yyset_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner) * @param _line_number line number * @param yyscanner The scanner object. */ -void jq_yyset_lineno (int _line_number , yyscan_t yyscanner) +void yyset_lineno (int _line_number , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* lineno is only valid if an input buffer exists. */ if (! YY_CURRENT_BUFFER ) - YY_FATAL_ERROR( "jq_yyset_lineno called with no buffer" ); + YY_FATAL_ERROR( "yyset_lineno called with no buffer" ); yylineno = _line_number; } @@ -2183,13 +2396,13 @@ void jq_yyset_lineno (int _line_number , yyscan_t yyscanner) * @param _column_no column number * @param yyscanner The scanner object. */ -void jq_yyset_column (int _column_no , yyscan_t yyscanner) +void yyset_column (int _column_no , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* column is only valid if an input buffer exists. */ if (! YY_CURRENT_BUFFER ) - YY_FATAL_ERROR( "jq_yyset_column called with no buffer" ); + YY_FATAL_ERROR( "yyset_column called with no buffer" ); yycolumn = _column_no; } @@ -2198,27 +2411,27 @@ void jq_yyset_column (int _column_no , yyscan_t yyscanner) * input buffer. * @param _in_str A readable stream. * @param yyscanner The scanner object. - * @see jq_yy_switch_to_buffer + * @see yy_switch_to_buffer */ -void jq_yyset_in (FILE * _in_str , yyscan_t yyscanner) +void yyset_in (FILE * _in_str , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; yyin = _in_str ; } -void jq_yyset_out (FILE * _out_str , yyscan_t yyscanner) +void yyset_out (FILE * _out_str , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; yyout = _out_str ; } -int jq_yyget_debug (yyscan_t yyscanner) +int yyget_debug (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; return yy_flex_debug; } -void jq_yyset_debug (int _bdebug , yyscan_t yyscanner) +void yyset_debug (int _bdebug , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; yy_flex_debug = _bdebug ; @@ -2226,25 +2439,25 @@ void jq_yyset_debug (int _bdebug , yyscan_t yyscanner) /* Accessor methods for yylval and yylloc */ -YYSTYPE * jq_yyget_lval (yyscan_t yyscanner) +YYSTYPE * yyget_lval (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; return yylval; } -void jq_yyset_lval (YYSTYPE * yylval_param , yyscan_t yyscanner) +void yyset_lval (YYSTYPE * yylval_param , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; yylval = yylval_param; } -YYLTYPE *jq_yyget_lloc (yyscan_t yyscanner) +YYLTYPE *yyget_lloc (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; return yylloc; } -void jq_yyset_lloc (YYLTYPE * yylloc_param , yyscan_t yyscanner) +void yyset_lloc (YYLTYPE * yylloc_param , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; yylloc = yylloc_param; @@ -2252,20 +2465,18 @@ void jq_yyset_lloc (YYLTYPE * yylloc_param , yyscan_t yyscanner) /* User-visible API */ -/* jq_yylex_init is special because it creates the scanner itself, so it is +/* yylex_init is special because it creates the scanner itself, so it is * the ONLY reentrant function that doesn't take the scanner as the last argument. * That's why we explicitly handle the declaration, instead of using our macros. */ - -int jq_yylex_init(yyscan_t* ptr_yy_globals) - +int yylex_init(yyscan_t* ptr_yy_globals) { if (ptr_yy_globals == NULL){ errno = EINVAL; return 1; } - *ptr_yy_globals = (yyscan_t) jq_yyalloc ( sizeof( struct yyguts_t ), NULL ); + *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), NULL ); if (*ptr_yy_globals == NULL){ errno = ENOMEM; @@ -2278,39 +2489,37 @@ int jq_yylex_init(yyscan_t* ptr_yy_globals) return yy_init_globals ( *ptr_yy_globals ); } -/* jq_yylex_init_extra has the same functionality as jq_yylex_init, but follows the +/* yylex_init_extra has the same functionality as yylex_init, but follows the * convention of taking the scanner as the last argument. Note however, that * this is a *pointer* to a scanner, as it will be allocated by this call (and * is the reason, too, why this function also must handle its own declaration). - * The user defined value in the first argument will be available to jq_yyalloc in + * The user defined value in the first argument will be available to yyalloc in * the yyextra field. */ - -int jq_yylex_init_extra(YY_EXTRA_TYPE yy_user_defined,yyscan_t* ptr_yy_globals ) - +int yylex_init_extra( YY_EXTRA_TYPE yy_user_defined, yyscan_t* ptr_yy_globals ) { struct yyguts_t dummy_yyguts; - jq_yyset_extra (yy_user_defined, &dummy_yyguts); + yyset_extra (yy_user_defined, &dummy_yyguts); if (ptr_yy_globals == NULL){ errno = EINVAL; return 1; } - - *ptr_yy_globals = (yyscan_t) jq_yyalloc ( sizeof( struct yyguts_t ), &dummy_yyguts ); - + + *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), &dummy_yyguts ); + if (*ptr_yy_globals == NULL){ errno = ENOMEM; return 1; } - + /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */ memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t)); - - jq_yyset_extra (yy_user_defined, *ptr_yy_globals); - + + yyset_extra (yy_user_defined, *ptr_yy_globals); + return yy_init_globals ( *ptr_yy_globals ); } @@ -2318,13 +2527,13 @@ static int yy_init_globals (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* Initialization is the same as for the non-reentrant scanner. - * This function is called from jq_yylex_destroy(), so don't allocate here. + * This function is called from yylex_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; @@ -2337,42 +2546,42 @@ 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 - * jq_yylex_init() + * yylex_init() */ return 0; } -/* jq_yylex_destroy is for both reentrant and non-reentrant scanners. */ -int jq_yylex_destroy (yyscan_t yyscanner) +/* yylex_destroy is for both reentrant and non-reentrant scanners. */ +int yylex_destroy (yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* Pop the buffer stack, destroying each element. */ while(YY_CURRENT_BUFFER){ - jq_yy_delete_buffer(YY_CURRENT_BUFFER ,yyscanner ); + yy_delete_buffer( YY_CURRENT_BUFFER , yyscanner ); YY_CURRENT_BUFFER_LVALUE = NULL; - jq_yypop_buffer_state(yyscanner); + yypop_buffer_state(yyscanner); } /* Destroy the stack itself. */ - jq_yyfree(yyg->yy_buffer_stack ,yyscanner); + yyfree(yyg->yy_buffer_stack , yyscanner); yyg->yy_buffer_stack = NULL; /* Destroy the start condition stack. */ - jq_yyfree(yyg->yy_start_stack ,yyscanner ); + yyfree( yyg->yy_start_stack , yyscanner ); yyg->yy_start_stack = NULL; /* Reset the globals. This is important in a non-reentrant scanner so the next time - * jq_yylex() is called, initialization will occur. */ + * yylex() is called, initialization will occur. */ yy_init_globals( yyscanner); /* Destroy the main struct (reentrant only). */ - jq_yyfree ( yyscanner , yyscanner ); + yyfree ( yyscanner , yyscanner ); yyscanner = NULL; return 0; } @@ -2382,7 +2591,7 @@ int jq_yylex_destroy (yyscan_t yyscanner) */ #ifndef yytext_ptr -static void yy_flex_strncpy (char* s1, yyconst char * s2, int n , yyscan_t yyscanner) +static void yy_flex_strncpy (char* s1, const char * s2, int n , yyscan_t yyscanner) { struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; (void)yyg; @@ -2394,7 +2603,7 @@ static void yy_flex_strncpy (char* s1, yyconst char * s2, int n , yyscan_t yysca #endif #ifdef YY_NEED_STRLEN -static int yy_flex_strlen (yyconst char * s , yyscan_t yyscanner) +static int yy_flex_strlen (const char * s , yyscan_t yyscanner) { int n; for ( n = 0; s[n]; ++n ) @@ -2408,7 +2617,6 @@ static int yy_flex_strlen (yyconst char * s , yyscan_t yyscanner) #line 130 "src/lexer.l" - /* perhaps these should be calls... */ /* "true" { return TRUE; } @@ -2455,13 +2663,13 @@ static int enter(int c, int currstate, yyscan_t yyscanner) { return c; } -void* jq_yyalloc(size_t sz,void* extra) { +void* yyalloc(size_t sz, void* extra) { return jv_mem_alloc(sz); } -void* jq_yyrealloc(void* p,size_t sz,void* extra) { +void* yyrealloc(void* p, size_t sz, void* extra) { return jv_mem_realloc(p, sz); } -void jq_yyfree(void* p,void* extra) { +void yyfree(void* p, void* extra) { jv_mem_free(p); } diff --git a/src/lexer.h b/src/lexer.h index e095b106df..8ad2a44ba6 100644 --- a/src/lexer.h +++ b/src/lexer.h @@ -13,11 +13,245 @@ #define FLEX_SCANNER #define YY_FLEX_MAJOR_VERSION 2 #define YY_FLEX_MINOR_VERSION 6 -#define YY_FLEX_SUBMINOR_VERSION 0 +#define YY_FLEX_SUBMINOR_VERSION 4 #if YY_FLEX_SUBMINOR_VERSION > 0 #define FLEX_BETA #endif +#ifdef yy_create_buffer +#define jq_yy_create_buffer_ALREADY_DEFINED +#else +#define yy_create_buffer jq_yy_create_buffer +#endif + +#ifdef yy_delete_buffer +#define jq_yy_delete_buffer_ALREADY_DEFINED +#else +#define yy_delete_buffer jq_yy_delete_buffer +#endif + +#ifdef yy_scan_buffer +#define jq_yy_scan_buffer_ALREADY_DEFINED +#else +#define yy_scan_buffer jq_yy_scan_buffer +#endif + +#ifdef yy_scan_string +#define jq_yy_scan_string_ALREADY_DEFINED +#else +#define yy_scan_string jq_yy_scan_string +#endif + +#ifdef yy_scan_bytes +#define jq_yy_scan_bytes_ALREADY_DEFINED +#else +#define yy_scan_bytes jq_yy_scan_bytes +#endif + +#ifdef yy_init_buffer +#define jq_yy_init_buffer_ALREADY_DEFINED +#else +#define yy_init_buffer jq_yy_init_buffer +#endif + +#ifdef yy_flush_buffer +#define jq_yy_flush_buffer_ALREADY_DEFINED +#else +#define yy_flush_buffer jq_yy_flush_buffer +#endif + +#ifdef yy_load_buffer_state +#define jq_yy_load_buffer_state_ALREADY_DEFINED +#else +#define yy_load_buffer_state jq_yy_load_buffer_state +#endif + +#ifdef yy_switch_to_buffer +#define jq_yy_switch_to_buffer_ALREADY_DEFINED +#else +#define yy_switch_to_buffer jq_yy_switch_to_buffer +#endif + +#ifdef yypush_buffer_state +#define jq_yypush_buffer_state_ALREADY_DEFINED +#else +#define yypush_buffer_state jq_yypush_buffer_state +#endif + +#ifdef yypop_buffer_state +#define jq_yypop_buffer_state_ALREADY_DEFINED +#else +#define yypop_buffer_state jq_yypop_buffer_state +#endif + +#ifdef yyensure_buffer_stack +#define jq_yyensure_buffer_stack_ALREADY_DEFINED +#else +#define yyensure_buffer_stack jq_yyensure_buffer_stack +#endif + +#ifdef yylex +#define jq_yylex_ALREADY_DEFINED +#else +#define yylex jq_yylex +#endif + +#ifdef yyrestart +#define jq_yyrestart_ALREADY_DEFINED +#else +#define yyrestart jq_yyrestart +#endif + +#ifdef yylex_init +#define jq_yylex_init_ALREADY_DEFINED +#else +#define yylex_init jq_yylex_init +#endif + +#ifdef yylex_init_extra +#define jq_yylex_init_extra_ALREADY_DEFINED +#else +#define yylex_init_extra jq_yylex_init_extra +#endif + +#ifdef yylex_destroy +#define jq_yylex_destroy_ALREADY_DEFINED +#else +#define yylex_destroy jq_yylex_destroy +#endif + +#ifdef yyget_debug +#define jq_yyget_debug_ALREADY_DEFINED +#else +#define yyget_debug jq_yyget_debug +#endif + +#ifdef yyset_debug +#define jq_yyset_debug_ALREADY_DEFINED +#else +#define yyset_debug jq_yyset_debug +#endif + +#ifdef yyget_extra +#define jq_yyget_extra_ALREADY_DEFINED +#else +#define yyget_extra jq_yyget_extra +#endif + +#ifdef yyset_extra +#define jq_yyset_extra_ALREADY_DEFINED +#else +#define yyset_extra jq_yyset_extra +#endif + +#ifdef yyget_in +#define jq_yyget_in_ALREADY_DEFINED +#else +#define yyget_in jq_yyget_in +#endif + +#ifdef yyset_in +#define jq_yyset_in_ALREADY_DEFINED +#else +#define yyset_in jq_yyset_in +#endif + +#ifdef yyget_out +#define jq_yyget_out_ALREADY_DEFINED +#else +#define yyget_out jq_yyget_out +#endif + +#ifdef yyset_out +#define jq_yyset_out_ALREADY_DEFINED +#else +#define yyset_out jq_yyset_out +#endif + +#ifdef yyget_leng +#define jq_yyget_leng_ALREADY_DEFINED +#else +#define yyget_leng jq_yyget_leng +#endif + +#ifdef yyget_text +#define jq_yyget_text_ALREADY_DEFINED +#else +#define yyget_text jq_yyget_text +#endif + +#ifdef yyget_lineno +#define jq_yyget_lineno_ALREADY_DEFINED +#else +#define yyget_lineno jq_yyget_lineno +#endif + +#ifdef yyset_lineno +#define jq_yyset_lineno_ALREADY_DEFINED +#else +#define yyset_lineno jq_yyset_lineno +#endif + +#ifdef yyget_column +#define jq_yyget_column_ALREADY_DEFINED +#else +#define yyget_column jq_yyget_column +#endif + +#ifdef yyset_column +#define jq_yyset_column_ALREADY_DEFINED +#else +#define yyset_column jq_yyset_column +#endif + +#ifdef yywrap +#define jq_yywrap_ALREADY_DEFINED +#else +#define yywrap jq_yywrap +#endif + +#ifdef yyget_lval +#define jq_yyget_lval_ALREADY_DEFINED +#else +#define yyget_lval jq_yyget_lval +#endif + +#ifdef yyset_lval +#define jq_yyset_lval_ALREADY_DEFINED +#else +#define yyset_lval jq_yyset_lval +#endif + +#ifdef yyget_lloc +#define jq_yyget_lloc_ALREADY_DEFINED +#else +#define yyget_lloc jq_yyget_lloc +#endif + +#ifdef yyset_lloc +#define jq_yyset_lloc_ALREADY_DEFINED +#else +#define yyset_lloc jq_yyset_lloc +#endif + +#ifdef yyalloc +#define jq_yyalloc_ALREADY_DEFINED +#else +#define yyalloc jq_yyalloc +#endif + +#ifdef yyrealloc +#define jq_yyrealloc_ALREADY_DEFINED +#else +#define yyrealloc jq_yyrealloc +#endif + +#ifdef yyfree +#define jq_yyfree_ALREADY_DEFINED +#else +#define yyfree jq_yyfree +#endif + /* First, we deal with platform-specific or compiler-specific issues. */ /* begin standard C headers. */ @@ -88,29 +322,23 @@ typedef unsigned int flex_uint32_t; #define UINT32_MAX (4294967295U) #endif +#ifndef SIZE_MAX +#define SIZE_MAX (~(size_t)0) +#endif + #endif /* ! C99 */ #endif /* ! FLEXINT_H */ -#ifdef __cplusplus - -/* The "const" storage-class-modifier is valid. */ -#define YY_USE_CONST - -#else /* ! __cplusplus */ +/* begin standard C++ headers. */ -/* 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. */ @@ -165,7 +393,7 @@ 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. @@ -193,7 +421,7 @@ struct yy_buffer_state int yy_bs_lineno; /**< The line count. */ int yy_bs_column; /**< The column count. */ - + /* Whether to try to fill the input buffer when we reach the * end of it. */ @@ -204,21 +432,21 @@ struct yy_buffer_state }; #endif /* !YY_STRUCT_YY_BUFFER_STATE */ -void jq_yyrestart (FILE *input_file ,yyscan_t yyscanner ); -void jq_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner ); -YY_BUFFER_STATE jq_yy_create_buffer (FILE *file,int size ,yyscan_t yyscanner ); -void jq_yy_delete_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner ); -void jq_yy_flush_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner ); -void jq_yypush_buffer_state (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner ); -void jq_yypop_buffer_state (yyscan_t yyscanner ); +void yyrestart ( FILE *input_file , yyscan_t yyscanner ); +void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner ); +YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size , yyscan_t yyscanner ); +void yy_delete_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner ); +void yy_flush_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner ); +void yypush_buffer_state ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner ); +void yypop_buffer_state ( yyscan_t yyscanner ); -YY_BUFFER_STATE jq_yy_scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner ); -YY_BUFFER_STATE jq_yy_scan_string (yyconst char *yy_str ,yyscan_t yyscanner ); -YY_BUFFER_STATE jq_yy_scan_bytes (yyconst char *bytes,yy_size_t len ,yyscan_t yyscanner ); +YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size , yyscan_t yyscanner ); +YY_BUFFER_STATE yy_scan_string ( const char *yy_str , yyscan_t yyscanner ); +YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, int len , yyscan_t yyscanner ); -void *jq_yyalloc (yy_size_t ,yyscan_t yyscanner ); -void *jq_yyrealloc (void *,yy_size_t ,yyscan_t yyscanner ); -void jq_yyfree (void * ,yyscan_t yyscanner ); +void *yyalloc ( yy_size_t , yyscan_t yyscanner ); +void *yyrealloc ( void *, yy_size_t , yyscan_t yyscanner ); +void yyfree ( void * , yyscan_t yyscanner ); /* Begin user sect3 */ @@ -247,50 +475,50 @@ void jq_yyfree (void * ,yyscan_t yyscanner ); #define YY_EXTRA_TYPE int -int jq_yylex_init (yyscan_t* scanner); +int yylex_init (yyscan_t* scanner); -int jq_yylex_init_extra (YY_EXTRA_TYPE user_defined,yyscan_t* scanner); +int yylex_init_extra ( YY_EXTRA_TYPE user_defined, yyscan_t* scanner); /* Accessor methods to globals. These are made visible to non-reentrant scanners for convenience. */ -int jq_yylex_destroy (yyscan_t yyscanner ); +int yylex_destroy ( yyscan_t yyscanner ); -int jq_yyget_debug (yyscan_t yyscanner ); +int yyget_debug ( yyscan_t yyscanner ); -void jq_yyset_debug (int debug_flag ,yyscan_t yyscanner ); +void yyset_debug ( int debug_flag , yyscan_t yyscanner ); -YY_EXTRA_TYPE jq_yyget_extra (yyscan_t yyscanner ); +YY_EXTRA_TYPE yyget_extra ( yyscan_t yyscanner ); -void jq_yyset_extra (YY_EXTRA_TYPE user_defined ,yyscan_t yyscanner ); +void yyset_extra ( YY_EXTRA_TYPE user_defined , yyscan_t yyscanner ); -FILE *jq_yyget_in (yyscan_t yyscanner ); +FILE *yyget_in ( yyscan_t yyscanner ); -void jq_yyset_in (FILE * _in_str ,yyscan_t yyscanner ); +void yyset_in ( FILE * _in_str , yyscan_t yyscanner ); -FILE *jq_yyget_out (yyscan_t yyscanner ); +FILE *yyget_out ( yyscan_t yyscanner ); -void jq_yyset_out (FILE * _out_str ,yyscan_t yyscanner ); +void yyset_out ( FILE * _out_str , yyscan_t yyscanner ); -yy_size_t jq_yyget_leng (yyscan_t yyscanner ); + int yyget_leng ( yyscan_t yyscanner ); -char *jq_yyget_text (yyscan_t yyscanner ); +char *yyget_text ( yyscan_t yyscanner ); -int jq_yyget_lineno (yyscan_t yyscanner ); +int yyget_lineno ( yyscan_t yyscanner ); -void jq_yyset_lineno (int _line_number ,yyscan_t yyscanner ); +void yyset_lineno ( int _line_number , yyscan_t yyscanner ); -int jq_yyget_column (yyscan_t yyscanner ); +int yyget_column ( yyscan_t yyscanner ); -void jq_yyset_column (int _column_no ,yyscan_t yyscanner ); +void yyset_column ( int _column_no , yyscan_t yyscanner ); -YYSTYPE * jq_yyget_lval (yyscan_t yyscanner ); +YYSTYPE * yyget_lval ( yyscan_t yyscanner ); -void jq_yyset_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner ); +void yyset_lval ( YYSTYPE * yylval_param , yyscan_t yyscanner ); - YYLTYPE *jq_yyget_lloc (yyscan_t yyscanner ); + YYLTYPE *yyget_lloc ( yyscan_t yyscanner ); - void jq_yyset_lloc (YYLTYPE * yylloc_param ,yyscan_t yyscanner ); + void yyset_lloc ( YYLTYPE * yylloc_param , yyscan_t yyscanner ); /* Macros after this point can all be overridden by user definitions in * section 1. @@ -298,18 +526,18 @@ void jq_yyset_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner ); #ifndef YY_SKIP_YYWRAP #ifdef __cplusplus -extern "C" int jq_yywrap (yyscan_t yyscanner ); +extern "C" int yywrap ( yyscan_t yyscanner ); #else -extern int jq_yywrap (yyscan_t yyscanner ); +extern int yywrap ( yyscan_t yyscanner ); #endif #endif #ifndef yytext_ptr -static void yy_flex_strncpy (char *,yyconst char *,int ,yyscan_t yyscanner); +static void yy_flex_strncpy ( char *, const char *, int , yyscan_t yyscanner); #endif #ifdef YY_NEED_STRLEN -static int yy_flex_strlen (yyconst char * ,yyscan_t yyscanner); +static int yy_flex_strlen ( const char * , yyscan_t yyscanner); #endif #ifndef YY_NO_INPUT @@ -337,10 +565,10 @@ static int yy_flex_strlen (yyconst char * ,yyscan_t yyscanner); #ifndef YY_DECL #define YY_DECL_IS_OURS 1 -extern int jq_yylex \ - (YYSTYPE * yylval_param,YYLTYPE * yylloc_param ,yyscan_t yyscanner); +extern int yylex \ + (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner); -#define YY_DECL int jq_yylex \ +#define YY_DECL int yylex \ (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner) #endif /* !YY_DECL */ @@ -358,9 +586,154 @@ extern int jq_yylex \ #undef YY_DECL #endif +#ifndef jq_yy_create_buffer_ALREADY_DEFINED +#undef yy_create_buffer +#endif +#ifndef jq_yy_delete_buffer_ALREADY_DEFINED +#undef yy_delete_buffer +#endif +#ifndef jq_yy_scan_buffer_ALREADY_DEFINED +#undef yy_scan_buffer +#endif +#ifndef jq_yy_scan_string_ALREADY_DEFINED +#undef yy_scan_string +#endif +#ifndef jq_yy_scan_bytes_ALREADY_DEFINED +#undef yy_scan_bytes +#endif +#ifndef jq_yy_init_buffer_ALREADY_DEFINED +#undef yy_init_buffer +#endif +#ifndef jq_yy_flush_buffer_ALREADY_DEFINED +#undef yy_flush_buffer +#endif +#ifndef jq_yy_load_buffer_state_ALREADY_DEFINED +#undef yy_load_buffer_state +#endif +#ifndef jq_yy_switch_to_buffer_ALREADY_DEFINED +#undef yy_switch_to_buffer +#endif +#ifndef jq_yypush_buffer_state_ALREADY_DEFINED +#undef yypush_buffer_state +#endif +#ifndef jq_yypop_buffer_state_ALREADY_DEFINED +#undef yypop_buffer_state +#endif +#ifndef jq_yyensure_buffer_stack_ALREADY_DEFINED +#undef yyensure_buffer_stack +#endif +#ifndef jq_yylex_ALREADY_DEFINED +#undef yylex +#endif +#ifndef jq_yyrestart_ALREADY_DEFINED +#undef yyrestart +#endif +#ifndef jq_yylex_init_ALREADY_DEFINED +#undef yylex_init +#endif +#ifndef jq_yylex_init_extra_ALREADY_DEFINED +#undef yylex_init_extra +#endif +#ifndef jq_yylex_destroy_ALREADY_DEFINED +#undef yylex_destroy +#endif +#ifndef jq_yyget_debug_ALREADY_DEFINED +#undef yyget_debug +#endif +#ifndef jq_yyset_debug_ALREADY_DEFINED +#undef yyset_debug +#endif +#ifndef jq_yyget_extra_ALREADY_DEFINED +#undef yyget_extra +#endif +#ifndef jq_yyset_extra_ALREADY_DEFINED +#undef yyset_extra +#endif +#ifndef jq_yyget_in_ALREADY_DEFINED +#undef yyget_in +#endif +#ifndef jq_yyset_in_ALREADY_DEFINED +#undef yyset_in +#endif +#ifndef jq_yyget_out_ALREADY_DEFINED +#undef yyget_out +#endif +#ifndef jq_yyset_out_ALREADY_DEFINED +#undef yyset_out +#endif +#ifndef jq_yyget_leng_ALREADY_DEFINED +#undef yyget_leng +#endif +#ifndef jq_yyget_text_ALREADY_DEFINED +#undef yyget_text +#endif +#ifndef jq_yyget_lineno_ALREADY_DEFINED +#undef yyget_lineno +#endif +#ifndef jq_yyset_lineno_ALREADY_DEFINED +#undef yyset_lineno +#endif +#ifndef jq_yyget_column_ALREADY_DEFINED +#undef yyget_column +#endif +#ifndef jq_yyset_column_ALREADY_DEFINED +#undef yyset_column +#endif +#ifndef jq_yywrap_ALREADY_DEFINED +#undef yywrap +#endif +#ifndef jq_yyget_lval_ALREADY_DEFINED +#undef yyget_lval +#endif +#ifndef jq_yyset_lval_ALREADY_DEFINED +#undef yyset_lval +#endif +#ifndef jq_yyget_lloc_ALREADY_DEFINED +#undef yyget_lloc +#endif +#ifndef jq_yyset_lloc_ALREADY_DEFINED +#undef yyset_lloc +#endif +#ifndef jq_yyalloc_ALREADY_DEFINED +#undef yyalloc +#endif +#ifndef jq_yyrealloc_ALREADY_DEFINED +#undef yyrealloc +#endif +#ifndef jq_yyfree_ALREADY_DEFINED +#undef yyfree +#endif +#ifndef jq_yytext_ALREADY_DEFINED +#undef yytext +#endif +#ifndef jq_yyleng_ALREADY_DEFINED +#undef yyleng +#endif +#ifndef jq_yyin_ALREADY_DEFINED +#undef yyin +#endif +#ifndef jq_yyout_ALREADY_DEFINED +#undef yyout +#endif +#ifndef jq_yy_flex_debug_ALREADY_DEFINED +#undef yy_flex_debug +#endif +#ifndef jq_yylineno_ALREADY_DEFINED +#undef yylineno +#endif +#ifndef jq_yytables_fload_ALREADY_DEFINED +#undef yytables_fload +#endif +#ifndef jq_yytables_destroy_ALREADY_DEFINED +#undef yytables_destroy +#endif +#ifndef jq_yyTABLES_NAME_ALREADY_DEFINED +#undef yyTABLES_NAME +#endif + #line 130 "src/lexer.l" -#line 365 "src/lexer.h" +#line 738 "src/lexer.h" #undef jq_yyIN_HEADER #endif /* jq_yyHEADER_H */ diff --git a/src/parser.c b/src/parser.c index 93a924ae21..d6d4ba0551 100644 --- a/src/parser.c +++ b/src/parser.c @@ -678,16 +678,16 @@ union yyalloc /* YYFINAL -- State number of the termination state. */ #define YYFINAL 27 /* YYLAST -- Last index in YYTABLE. */ -#define YYLAST 2015 +#define YYLAST 2134 /* YYNTOKENS -- Number of terminals. */ #define YYNTOKENS 69 /* YYNNTS -- Number of nonterminals. */ #define YYNNTS 30 /* YYNRULES -- Number of rules. */ -#define YYNRULES 164 +#define YYNRULES 167 /* YYNSTATES -- Number of states. */ -#define YYNSTATES 316 +#define YYNSTATES 318 /* YYTRANSLATE[YYX] -- Symbol number corresponding to YYX as returned by yylex, with out-of-bounds checking. */ @@ -744,17 +744,17 @@ static const yytype_uint16 yyrline[] = 420, 424, 428, 432, 436, 440, 444, 448, 452, 458, 464, 468, 472, 476, 480, 484, 488, 492, 496, 501, 504, 521, 530, 537, 545, 556, 561, 567, 570, 575, - 580, 587, 587, 591, 591, 598, 601, 604, 610, 613, - 618, 621, 624, 630, 633, 636, 644, 648, 651, 654, - 657, 660, 663, 666, 669, 672, 676, 682, 685, 688, + 579, 583, 590, 590, 594, 594, 601, 604, 607, 613, + 616, 621, 624, 627, 633, 636, 639, 647, 651, 654, + 657, 660, 663, 666, 669, 672, 675, 679, 685, 688, 691, 694, 697, 700, 703, 706, 709, 712, 715, 718, - 721, 724, 727, 730, 737, 741, 745, 757, 762, 763, - 764, 765, 768, 771, 776, 781, 784, 789, 792, 797, - 801, 804, 809, 812, 817, 820, 825, 828, 831, 834, - 837, 840, 848, 854, 857, 860, 863, 866, 869, 872, - 875, 878, 881, 884, 887, 890, 893, 896, 899, 902, - 905, 908, 913, 916, 917, 918, 921, 924, 927, 930, - 934, 938, 942, 946, 954 + 721, 724, 727, 730, 733, 740, 744, 753, 765, 770, + 771, 772, 773, 776, 779, 784, 789, 792, 797, 800, + 805, 809, 812, 817, 820, 825, 828, 833, 836, 839, + 842, 845, 848, 856, 862, 865, 868, 871, 874, 877, + 880, 883, 886, 889, 892, 895, 898, 901, 904, 907, + 910, 913, 916, 921, 924, 925, 926, 929, 932, 935, + 938, 942, 946, 950, 954, 958, 962, 970 }; #endif @@ -797,52 +797,52 @@ static const yytype_uint16 yytoknum[] = }; # endif -#define YYPACT_NINF -158 +#define YYPACT_NINF -154 #define yypact_value_is_default(Yystate) \ - (!!((Yystate) == (-158))) + (!!((Yystate) == (-154))) -#define YYTABLE_NINF -153 +#define YYTABLE_NINF -154 #define yytable_value_is_error(Yytable_value) \ - (!!((Yytable_value) == (-153))) + (!!((Yytable_value) == (-154))) /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing STATE-NUM. */ static const yytype_int16 yypact[] = { - 18, 765, 40, 48, -6, 10, -158, 31, -158, 76, - 765, 433, 433, 765, 20, 0, -158, 765, 515, 17, - 282, 146, 348, 1283, 765, -158, 2, -158, -5, -5, - 765, 48, 673, 765, -158, -158, -10, 1689, 14, 47, - 79, 112, -158, 119, -158, 3, 63, 1113, -158, -158, - -158, 124, 31, 68, 61, -158, 910, -26, 67, -158, - -158, -158, -158, -158, -158, -158, -158, -158, -158, -158, - -158, -158, -158, -158, -158, -158, -158, -158, 765, 127, - 70, 71, 77, 87, 765, 765, 765, 765, 765, 765, - 765, 765, 765, 765, 765, 765, 765, 765, 765, 765, - 765, 765, 765, 765, 765, 765, 765, 765, -158, -158, - 1857, 86, -16, -5, 448, 135, -158, -158, -158, 1857, - 765, -158, -158, 1334, 1857, -53, -158, -158, 1, 765, - 580, -16, -16, 645, 108, -158, 28, -158, -158, -158, - -158, -158, -158, 405, 214, -158, 214, 1147, 93, 214, - 214, -158, 405, 1925, 343, 343, 1891, 496, 1957, 1925, - 1925, 1925, 1925, 1925, 1925, 343, 343, 1857, 1891, 1925, - 343, 343, 3, 3, 99, 99, 99, -158, 155, -16, - 827, 121, 115, 123, 107, 100, 765, 113, 860, 7, - -158, -158, 765, -158, 75, -158, 166, -20, -158, 1385, - -158, 1589, 114, 117, -158, -158, 765, -158, 765, -158, - -18, -158, 214, 125, 50, 125, 118, 214, 125, 125, - -158, -158, -158, -23, 120, 126, 765, 174, 129, -24, - -158, 130, -16, 765, -158, -158, 960, -158, 737, 122, - -158, 178, -158, -158, -158, 1, 131, -158, 765, 765, - -158, -158, 765, 765, 1857, 1723, -158, 214, 214, 125, - -16, -158, -16, -16, 1181, 132, -16, 827, -158, -16, - 144, 1857, 138, 139, 1010, -158, -158, -158, 765, 1773, - 1823, 1436, 1487, -158, 125, 125, -158, -158, -158, 137, - -16, -158, -158, -158, -158, -158, 140, 1538, -158, 765, - 765, 765, -16, -158, -158, -158, 1639, 1215, 1060, -158, - -158, -158, 765, -158, 1249, -158 + 24, 834, 3, 33, -45, -6, -154, 18, -154, 56, + 834, 435, 435, 834, 4, 1, -154, 834, 584, 2047, + 284, 517, 350, 1352, 834, -154, 0, -154, -3, -3, + 834, 33, 742, 834, -154, -154, -9, 1758, 9, 57, + 39, 64, -154, 67, -154, -11, 11, 1182, -154, -154, + -154, -154, -154, -154, -154, -154, -154, -154, -154, -154, + -154, -154, -154, -154, -154, -154, -154, -154, -154, -154, + 74, 18, 49, 10, -154, 979, -38, 47, 834, 2075, + 54, 72, 59, 34, 834, 834, 834, 834, 834, 834, + 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, + 834, 834, 834, 834, 834, 834, 834, 834, -154, -154, + 1926, 79, -25, -3, 450, 125, -154, -154, -154, 1926, + 834, -154, -154, 1403, 1926, 55, -154, -154, 7, 834, + 649, -25, -25, 714, 94, -154, 81, -154, -154, -154, + -154, -154, -154, 407, 170, -154, 170, 1216, 80, -154, + 170, 170, -154, 407, 1994, 207, 207, 1960, 345, 143, + 1994, 1994, 1994, 1994, 1994, 1994, 207, 207, 1926, 1960, + 1994, 207, 207, -11, -11, 86, 86, 86, -154, 141, + -25, 896, 108, 103, 112, 97, 90, 834, 99, 929, + 19, -154, -154, 834, -154, 88, -154, 2103, 75, -154, + 1454, -154, 1658, 98, 100, -154, -154, 834, -154, 834, + -154, -15, -154, 170, 114, 14, 114, 101, 170, 114, + 114, -154, -154, -154, -42, 102, 106, 834, 158, 107, + -27, -154, 109, -25, 834, -154, -154, 1029, -154, 806, + 113, -154, 169, -154, -154, -154, -154, 7, 117, -154, + 834, 834, -154, -154, 834, 834, 1926, 1792, -154, 170, + 170, 114, -25, -154, -25, -25, 1250, 120, -25, 896, + -154, -25, 144, 1926, 127, 130, 1079, -154, -154, -154, + 834, 1842, 1892, 1505, 1556, -154, 114, 114, -154, -154, + -154, 126, -25, -154, -154, -154, -154, -154, 132, 1607, + -154, 834, 834, 834, -25, -154, -154, -154, 1708, 1284, + 1129, -154, -154, -154, 834, -154, 1318, -154 }; /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM. @@ -850,54 +850,54 @@ static const yytype_int16 yypact[] = means the default is an error. */ static const yytype_uint8 yydefact[] = { - 4, 0, 0, 6, 106, 82, 97, 99, 74, 0, - 0, 0, 0, 0, 0, 0, 61, 0, 0, 0, - 0, 0, 0, 0, 0, 98, 48, 1, 0, 0, - 8, 6, 0, 0, 78, 63, 0, 0, 0, 0, - 19, 0, 76, 0, 65, 33, 0, 0, 105, 104, - 85, 0, 0, 84, 0, 102, 0, 0, 162, 133, - 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, - 144, 145, 146, 147, 148, 149, 150, 151, 0, 0, - 159, 0, 0, 153, 0, 0, 0, 0, 0, 0, + 4, 0, 0, 6, 107, 83, 98, 100, 75, 0, + 0, 0, 0, 0, 0, 0, 62, 0, 0, 0, + 0, 0, 0, 0, 0, 99, 48, 1, 0, 0, + 8, 6, 0, 0, 79, 64, 0, 0, 0, 0, + 19, 0, 77, 0, 66, 33, 0, 0, 105, 134, + 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, + 145, 146, 147, 148, 149, 150, 151, 152, 106, 86, + 0, 0, 85, 0, 103, 0, 0, 164, 0, 0, + 160, 165, 0, 154, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22, 5, - 10, 81, 0, 0, 0, 0, 54, 53, 3, 2, - 8, 7, 49, 0, 114, 0, 112, 65, 0, 0, - 0, 0, 0, 0, 0, 75, 0, 108, 100, 86, - 80, 109, 101, 0, 0, 111, 0, 0, 161, 0, - 0, 103, 0, 41, 42, 43, 26, 25, 24, 28, - 32, 35, 37, 40, 27, 46, 47, 29, 30, 23, - 44, 45, 31, 34, 36, 38, 39, 77, 0, 0, - 0, 0, 0, 118, 83, 0, 0, 90, 0, 0, - 9, 50, 0, 107, 0, 60, 0, 0, 57, 0, - 17, 0, 0, 0, 20, 18, 0, 66, 0, 62, - 0, 155, 0, 164, 72, 156, 0, 0, 158, 157, - 154, 119, 122, 0, 0, 0, 0, 0, 0, 0, - 124, 0, 0, 0, 79, 110, 0, 89, 0, 88, - 52, 0, 113, 64, 59, 0, 0, 55, 0, 0, - 16, 15, 0, 0, 21, 0, 71, 0, 0, 160, - 0, 120, 0, 0, 0, 126, 0, 0, 121, 0, - 117, 11, 96, 95, 0, 87, 51, 58, 0, 0, - 0, 0, 0, 67, 70, 163, 123, 132, 128, 0, - 0, 130, 125, 129, 93, 92, 94, 0, 69, 0, - 0, 0, 0, 127, 91, 56, 0, 0, 0, 131, - 68, 12, 0, 14, 0, 13 + 10, 82, 0, 0, 0, 0, 54, 53, 3, 2, + 8, 7, 49, 0, 115, 0, 113, 66, 0, 0, + 0, 0, 0, 0, 0, 76, 0, 109, 101, 87, + 81, 110, 102, 0, 0, 112, 0, 0, 162, 163, + 0, 0, 104, 0, 41, 42, 43, 26, 25, 24, + 28, 32, 35, 37, 40, 27, 46, 47, 29, 30, + 23, 44, 45, 31, 34, 36, 38, 39, 78, 0, + 0, 0, 0, 0, 119, 84, 0, 0, 91, 0, + 0, 9, 50, 0, 108, 0, 61, 0, 0, 57, + 0, 17, 0, 0, 0, 20, 18, 0, 67, 0, + 63, 0, 156, 0, 167, 73, 157, 0, 0, 159, + 158, 155, 120, 123, 0, 0, 0, 0, 0, 0, + 0, 125, 0, 0, 0, 80, 111, 0, 90, 0, + 89, 52, 0, 114, 65, 59, 60, 0, 0, 55, + 0, 0, 16, 15, 0, 0, 21, 0, 72, 0, + 0, 161, 0, 121, 0, 0, 0, 127, 0, 0, + 122, 0, 118, 11, 97, 96, 0, 88, 51, 58, + 0, 0, 0, 0, 0, 68, 71, 166, 124, 133, + 129, 0, 0, 131, 126, 130, 94, 93, 95, 0, + 70, 0, 0, 0, 0, 128, 92, 56, 0, 0, + 0, 132, 69, 12, 0, 14, 0, 13 }; /* YYPGOTO[NTERM-NUM]. */ static const yytype_int16 yypgoto[] = { - -158, -158, -158, 157, 81, -1, -158, -158, 161, -12, - -158, -43, 6, -158, -158, 88, -103, -136, -8, -158, - 22, -158, -57, -123, -158, -158, -51, -157, -105, -158 + -154, -154, -154, 160, 82, -1, -154, -154, 174, -12, + -154, -43, 6, -154, -154, 78, -101, -93, -4, -154, + 17, -154, -76, -153, -154, -154, -57, -18, -107, -154 }; /* YYDEFGOTO[NTERM-NUM]. */ static const yytype_int16 yydefgoto[] = { -1, 2, 3, 30, 118, 110, 31, 32, 115, 24, - 197, 198, 25, 44, 127, 136, 251, 213, 26, 125, - 126, 181, 182, 183, 223, 229, 230, 81, 82, 83 + 198, 199, 25, 44, 127, 136, 253, 214, 26, 125, + 126, 182, 183, 184, 224, 230, 231, 81, 82, 83 }; /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If @@ -905,344 +905,368 @@ static const yytype_int16 yydefgoto[] = number is the opposite. If YYTABLE_NINF, syntax error. */ static const yytype_int16 yytable[] = { - 23, 42, 52, 38, 39, 195, 192, 111, 193, 37, - 215, 240, 40, 218, 219, 112, 45, 47, 120, 111, - 56, 48, 143, 231, 267, 260, 53, 131, 80, 119, - 143, 123, 124, 1, 116, 116, 16, 144, 211, 245, - 27, 246, 145, 261, 268, 144, 178, 220, 49, 179, - 128, 180, 111, 129, 33, 111, 222, 105, 106, 107, - 132, 108, 43, 196, 28, 29, 113, 114, 34, 241, - 207, 208, 35, 209, 202, 203, 256, 147, 113, 114, - 36, 259, 41, 153, 154, 155, 156, 157, 158, 159, - 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, - 170, 171, 172, 173, 174, 175, 176, 133, 120, 270, - 231, 113, 114, 188, 113, 114, 134, 207, 208, 184, - 243, 284, 285, 135, 137, 139, 140, 141, 199, 201, - 146, 148, 205, 149, 150, 152, 214, 286, 214, 287, - 288, 214, 214, 291, 177, 151, 293, 54, 189, 80, - 4, 5, 6, 7, 8, 206, 217, 108, 80, 221, - 9, 232, 233, -116, 10, 234, 235, 303, 11, 12, - 244, 237, 257, 13, 252, 14, 15, 253, 265, 309, - 275, 258, 276, 262, -115, 236, 228, 16, 121, 263, - 117, 124, 266, 269, 278, 290, 294, 295, 304, 17, - 302, 190, 277, 310, 214, 254, 18, 255, 19, 214, - 20, 21, 55, 22, 242, 194, 292, 0, 4, 5, - 6, 7, 8, 0, 0, 264, 0, 0, 0, 0, - 0, 0, 271, 0, 0, 0, 0, 274, 0, 0, - 0, 0, 0, 0, 15, 0, 0, 279, 280, 214, - 214, 281, 282, 0, 0, 16, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 212, 0, 0, - 0, 0, 0, 228, 18, 0, 19, 297, 20, 21, - 0, 22, -73, 50, 0, 0, 51, -73, 0, 52, - 0, -73, -73, -73, -73, -73, 0, 0, 306, 307, - 308, -73, -73, -73, 0, 0, -73, -73, -73, 0, - -73, 314, 0, 0, -73, -73, -73, -73, -73, -73, - -73, -73, 0, 16, 0, 0, -73, 0, 0, -73, - -73, -73, -73, -73, -73, -73, -73, -73, -73, 0, - -73, -73, 0, -73, 0, -73, -73, -73, -73, 57, - -73, 0, 58, -153, -153, 52, 0, 0, 0, 0, - 0, 59, 60, 61, 62, 63, 64, 65, 66, 67, - 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, - 0, -153, -153, 0, 0, 0, 0, 0, 0, 16, - 0, 0, 0, -153, -153, 103, 104, 105, 106, 107, - 0, 108, 0, 0, 0, 0, 210, 0, 78, 58, - 79, 0, 52, 0, 0, 0, -152, 0, 59, 60, - 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, - 71, 72, 73, 74, 75, 76, 77, 4, 5, 6, - 7, 8, 0, 0, 0, 0, 16, 0, 0, 185, - 0, 0, 4, 5, 6, 7, 8, 0, 0, 0, - 0, 0, 9, 15, 0, 78, 10, 79, 0, 0, - 11, 12, 0, -152, 16, 13, 0, 14, 15, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, - 0, 0, 0, 18, 0, 19, 0, 20, 21, 0, - 22, 17, 0, 0, 0, 0, 85, 86, 18, 0, - 19, 186, 20, 21, 187, 22, 46, 0, 0, 4, - 5, 6, 7, 8, 0, 0, 0, 0, 0, 9, - 0, 0, 0, 10, 96, 97, 0, 11, 12, 0, - 0, 0, 13, 0, 14, 15, 101, 102, 103, 104, - 105, 106, 107, 0, 108, 0, 16, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 17, 0, - 0, 0, 0, 0, 0, 18, 0, 19, 0, 20, - 21, 200, 22, 0, 4, 5, 6, 7, 8, 0, - 0, 0, 0, 0, 9, 0, 0, 0, 10, 0, - 0, 0, 11, 12, 0, 0, 0, 13, 0, 14, + 23, 68, 42, 27, 71, 111, 262, 38, 39, 37, + 143, 196, 40, 112, 111, 33, 45, 47, 120, 111, + 75, 269, 131, 241, 263, 144, 72, 223, 80, 119, + 145, 123, 124, 143, 116, 116, 212, 179, 16, 1, + 180, 270, 181, 105, 106, 107, 221, 108, 144, 28, + 29, 128, 34, 216, 129, 203, 204, 219, 220, 35, + 36, 149, 111, 43, 113, 114, 41, 133, 134, 197, + 132, 135, 137, 113, 114, 139, 141, 147, 113, 114, + 272, 242, 153, 154, 155, 156, 157, 158, 159, 160, + 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, + 171, 172, 173, 174, 175, 176, 177, 140, 120, 288, + 146, 289, 290, 189, 193, 293, 194, 150, 295, 185, + 258, 113, 114, 208, 209, 261, 210, 152, 200, 202, + 208, 209, 206, 244, 247, 151, 248, 178, 190, 305, + 215, 207, 215, 218, 108, 222, 215, 215, 233, 80, + 234, 311, -117, 85, 86, 235, 236, 238, 254, 80, + 255, 259, 267, 232, 260, 264, 286, 287, 88, 265, + 268, 277, 271, 278, 4, 5, 6, 7, 8, 246, + 280, 96, 97, 292, -116, 296, 237, 229, 297, 304, + 306, 121, 124, 101, 102, 103, 104, 105, 106, 107, + 15, 108, 191, 117, 279, 195, 256, 312, 257, 215, + 243, 16, 294, 0, 215, 0, 0, -154, -154, 0, + 0, 0, 0, 213, 0, 0, 266, 0, 0, 0, + 18, 0, 19, 273, 20, 21, 0, 22, 276, 0, + 0, 0, 0, 0, 0, -154, -154, 0, 0, 281, + 282, 232, 0, 283, 284, 215, 215, -154, -154, 103, + 104, 105, 106, 107, 0, 108, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 229, 0, 0, 0, 299, + 0, 0, 0, 0, -74, 69, 0, 0, 70, -74, + 0, 71, 0, -74, -74, -74, -74, -74, 0, 0, + 308, 309, 310, -74, -74, -74, 0, 0, -74, -74, + -74, 0, -74, 316, 0, 0, -74, -74, -74, -74, + -74, -74, -74, -74, 0, 16, 0, 0, -74, 0, + 0, -74, -74, -74, -74, -74, -74, -74, -74, -74, + -74, 0, -74, -74, 0, -74, 0, -74, -74, -74, + -74, 76, -74, 0, 77, 85, 86, 71, 0, 0, + 0, 0, 0, 49, 50, 51, 52, 53, 54, 55, + 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, + 66, 67, 0, 96, 97, 0, 0, 0, 0, 0, + 0, 16, 0, 0, 0, 101, 102, 103, 104, 105, + 106, 107, 0, 108, 0, 0, 0, 0, 211, 0, + 78, 77, 79, 0, 71, 0, 0, 0, -153, 0, + 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, + 59, 60, 61, 62, 63, 64, 65, 66, 67, 4, + 5, 6, 7, 8, 0, 0, 0, 0, 16, 0, + 0, 186, 0, 0, 4, 5, 6, 7, 8, 0, + 0, 0, 0, 0, 9, 15, 0, 78, 10, 79, + 0, 0, 11, 12, 0, -153, 16, 13, 0, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 16, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 17, 0, 0, 0, 0, 0, 0, - 18, 0, 19, 0, 20, 21, 204, 22, 0, 4, - 5, 6, 7, 8, 0, 0, 0, 0, 0, 9, - 0, 0, 0, 10, 0, 0, 0, 11, 12, 0, - 0, 0, 13, 0, 14, 15, 0, 4, 5, 6, - 7, 8, 0, 0, 0, 0, 16, 9, 0, 0, - 0, 10, 0, 0, 0, 11, 12, 0, 17, 0, - 13, 0, 14, 15, 0, 18, 0, 19, 0, 20, - 21, 0, 22, 0, 16, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 17, 0, 0, 0, - 0, 0, 122, 18, 0, 19, 0, 20, 21, 0, - 22, 4, 5, 6, 7, 8, 0, 0, 0, 0, + 0, 16, 0, 0, 0, 18, 0, 19, 0, 20, + 21, 0, 22, 17, 0, 0, 0, 0, 0, 0, + 18, 0, 19, 187, 20, 21, 188, 22, 73, 0, + 0, 4, 5, 6, 7, 8, 0, 0, 0, 0, 0, 9, 0, 0, 0, 10, 0, 0, 0, 11, - 12, 0, 0, 0, 13, 0, 14, 15, 0, 4, - 5, 6, 7, 8, 0, 0, 0, 0, 16, 9, - 0, 0, 0, 10, 0, 0, 0, 11, 12, 0, - 17, 0, 13, 0, 14, 15, 0, 18, 0, 19, - 0, 20, 21, 273, 22, 0, 16, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 17, 0, - 0, 0, 0, 0, 0, 18, 0, 19, 224, 20, - 21, 225, 22, 0, 52, 0, 0, 0, 0, 0, - 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, - 69, 70, 71, 72, 73, 74, 75, 76, 77, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 16, 84, - 85, 86, 87, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 88, 89, 226, 0, 227, - 0, 0, 90, 91, 92, 93, 94, 95, 96, 97, - 0, 0, 0, 0, 0, 0, 0, 98, 99, 100, - 101, 102, 103, 104, 105, 106, 107, 0, 108, 84, - 85, 86, 87, 238, 0, 0, 239, 0, 0, 0, - 0, 0, 0, 0, 0, 88, 89, 0, 0, 0, - 0, 0, 90, 91, 92, 93, 94, 95, 96, 97, - 0, 0, 0, 0, 0, 0, 0, 98, 99, 100, - 101, 102, 103, 104, 105, 106, 107, 0, 108, 84, - 85, 86, 87, 0, 0, 0, 142, 0, 0, 0, - 0, 0, 0, 0, 0, 88, 89, 0, 0, 0, - 0, 0, 90, 91, 92, 93, 94, 95, 96, 97, - 0, 0, 0, 0, 0, 0, 0, 98, 99, 100, - 101, 102, 103, 104, 105, 106, 107, 0, 108, 84, - 85, 86, 87, 0, 0, 0, 272, 0, 0, 0, - 0, 0, 0, 0, 0, 88, 89, 0, 0, 0, - 0, 0, 90, 91, 92, 93, 94, 95, 96, 97, - 0, 0, 0, 0, 0, 0, 0, 98, 99, 100, - 101, 102, 103, 104, 105, 106, 107, 0, 108, 84, - 85, 86, 87, 0, 0, 0, 296, 0, 0, 0, - 0, 0, 0, 0, 0, 88, 89, 0, 0, 0, + 12, 0, 0, 0, 13, 0, 14, 15, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 17, 0, 0, 0, 0, 0, 0, 18, 0, 19, + 0, 20, 21, 74, 22, 46, 0, 0, 4, 5, + 6, 7, 8, 0, 0, 0, 0, 0, 9, 0, + 0, 0, 10, 0, 0, 0, 11, 12, 0, 0, + 0, 13, 0, 14, 15, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 17, 0, 0, + 0, 0, 0, 0, 18, 0, 19, 0, 20, 21, + 201, 22, 0, 4, 5, 6, 7, 8, 0, 0, + 0, 0, 0, 9, 0, 0, 0, 10, 0, 0, + 0, 11, 12, 0, 0, 0, 13, 0, 14, 15, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 17, 0, 0, 0, 0, 0, 0, 18, + 0, 19, 0, 20, 21, 205, 22, 0, 4, 5, + 6, 7, 8, 0, 0, 0, 0, 0, 9, 0, + 0, 0, 10, 0, 0, 0, 11, 12, 0, 0, + 0, 13, 0, 14, 15, 0, 4, 5, 6, 7, + 8, 0, 0, 0, 0, 16, 9, 0, 0, 0, + 10, 0, 0, 0, 11, 12, 0, 17, 0, 13, + 0, 14, 15, 0, 18, 0, 19, 0, 20, 21, + 0, 22, 0, 16, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 17, 0, 0, 0, 0, + 0, 122, 18, 0, 19, 0, 20, 21, 0, 22, + 4, 5, 6, 7, 8, 0, 0, 0, 0, 0, + 9, 0, 0, 0, 10, 0, 0, 0, 11, 12, + 0, 0, 0, 13, 0, 14, 15, 0, 4, 5, + 6, 7, 8, 0, 0, 0, 0, 16, 9, 0, + 0, 0, 10, 0, 0, 0, 11, 12, 0, 17, + 0, 13, 0, 14, 15, 0, 18, 0, 19, 0, + 20, 21, 275, 22, 0, 16, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 17, 0, 0, + 0, 0, 0, 0, 18, 0, 19, 225, 20, 21, + 226, 22, 0, 71, 0, 0, 0, 0, 0, 49, + 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, + 60, 61, 62, 63, 64, 65, 66, 67, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 16, 84, 85, + 86, 87, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 88, 89, 227, 0, 228, 0, + 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, + 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, + 102, 103, 104, 105, 106, 107, 0, 108, 84, 85, + 86, 87, 239, 0, 0, 240, 0, 0, 0, 0, + 0, 0, 0, 0, 88, 89, 0, 0, 0, 0, + 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, + 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, + 102, 103, 104, 105, 106, 107, 0, 108, 84, 85, + 86, 87, 0, 0, 0, 142, 0, 0, 0, 0, + 0, 0, 0, 0, 88, 89, 0, 0, 0, 0, + 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, + 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, + 102, 103, 104, 105, 106, 107, 0, 108, 84, 85, + 86, 87, 0, 0, 0, 274, 0, 0, 0, 0, + 0, 0, 0, 0, 88, 89, 0, 0, 0, 0, + 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, + 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, + 102, 103, 104, 105, 106, 107, 0, 108, 84, 85, + 86, 87, 0, 0, 0, 298, 0, 0, 0, 0, + 0, 0, 0, 0, 88, 89, 0, 0, 0, 0, + 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, + 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, + 102, 103, 104, 105, 106, 107, 0, 108, 314, 0, + 315, 84, 85, 86, 87, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 88, 89, 0, + 0, 0, 0, 0, 90, 91, 92, 93, 94, 95, + 96, 97, 0, 0, 0, 84, 85, 86, 87, 98, + 99, 100, 101, 102, 103, 104, 105, 106, 107, 0, + 108, 88, 89, 138, 0, 0, 0, 0, 90, 91, + 92, 93, 94, 95, 96, 97, 0, 0, 0, 84, + 85, 86, 87, 98, 99, 100, 101, 102, 103, 104, + 105, 106, 107, 0, 108, 88, 89, 217, 0, 0, 0, 0, 90, 91, 92, 93, 94, 95, 96, 97, - 0, 0, 0, 0, 0, 0, 0, 98, 99, 100, - 101, 102, 103, 104, 105, 106, 107, 0, 108, 312, - 0, 313, 84, 85, 86, 87, 0, 0, 0, 0, + 0, 0, 0, 84, 85, 86, 87, 98, 99, 100, + 101, 102, 103, 104, 105, 106, 107, 0, 108, 88, + 89, 291, 0, 0, 0, 0, 90, 91, 92, 93, + 94, 95, 96, 97, 0, 0, 0, 84, 85, 86, + 87, 98, 99, 100, 101, 102, 103, 104, 105, 106, + 107, 0, 108, 88, 89, 313, 0, 0, 0, 0, + 90, 91, 92, 93, 94, 95, 96, 97, 0, 0, + 0, 84, 85, 86, 87, 98, 99, 100, 101, 102, + 103, 104, 105, 106, 107, 0, 108, 88, 89, 317, + 0, 0, 0, 0, 90, 91, 92, 93, 94, 95, + 96, 97, 0, 0, 0, 0, 0, 0, 0, 98, + 99, 100, 101, 102, 103, 104, 105, 106, 107, 0, + 108, 109, 84, 85, 86, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 88, 89, 0, 0, 0, 0, 0, 90, 91, 92, 93, 94, - 95, 96, 97, 0, 0, 0, 84, 85, 86, 87, - 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, - 0, 108, 88, 89, 138, 0, 0, 0, 0, 90, - 91, 92, 93, 94, 95, 96, 97, 0, 0, 0, - 84, 85, 86, 87, 98, 99, 100, 101, 102, 103, - 104, 105, 106, 107, 0, 108, 88, 89, 216, 0, - 0, 0, 0, 90, 91, 92, 93, 94, 95, 96, - 97, 0, 0, 0, 84, 85, 86, 87, 98, 99, - 100, 101, 102, 103, 104, 105, 106, 107, 0, 108, - 88, 89, 289, 0, 0, 0, 0, 90, 91, 92, - 93, 94, 95, 96, 97, 0, 0, 0, 84, 85, - 86, 87, 98, 99, 100, 101, 102, 103, 104, 105, - 106, 107, 0, 108, 88, 89, 311, 0, 0, 0, - 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, - 0, 0, 84, 85, 86, 87, 98, 99, 100, 101, - 102, 103, 104, 105, 106, 107, 0, 108, 88, 89, - 315, 0, 0, 0, 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, - 0, 108, 109, 84, 85, 86, 87, 0, 0, 0, + 0, 108, 192, 84, 85, 86, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 88, 89, 0, 0, 0, 0, 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, 102, 103, 104, 105, 106, - 107, 0, 108, 191, 84, 85, 86, 87, 0, 0, + 107, 0, 108, 249, 84, 85, 86, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 88, 89, 0, 0, 0, 0, 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, 102, 103, 104, 105, - 106, 107, 0, 108, 247, 84, 85, 86, 87, 0, + 106, 107, 0, 108, 302, 84, 85, 86, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 88, 89, 0, 0, 0, 0, 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, 102, 103, 104, - 105, 106, 107, 0, 108, 300, 84, 85, 86, 87, + 105, 106, 107, 0, 108, 303, 84, 85, 86, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 88, 89, 0, 0, 0, 0, 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, 102, 103, - 104, 105, 106, 107, 0, 108, 301, 84, 85, 86, - 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 104, 105, 106, 107, 0, 108, 307, 84, 85, 86, + 87, 0, 0, 0, 0, 0, 0, 0, 250, 251, + 0, 0, 252, 88, 89, 0, 0, 0, 0, 0, + 90, 91, 92, 93, 94, 95, 96, 97, 0, 0, + 0, 0, 0, 0, 0, 98, 99, 100, 101, 102, + 103, 104, 105, 106, 107, 0, 108, 84, 85, 86, + 87, 0, 0, 0, 0, 0, 0, 0, 250, 251, 0, 0, 0, 88, 89, 0, 0, 0, 0, 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, 102, - 103, 104, 105, 106, 107, 0, 108, 305, 84, 85, - 86, 87, 0, 0, 0, 0, 0, 0, 0, 248, - 249, 0, 0, 250, 88, 89, 0, 0, 0, 0, - 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, - 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, - 102, 103, 104, 105, 106, 107, 0, 108, 84, 85, - 86, 87, 0, 0, 0, 0, 0, 0, 0, 248, - 249, 0, 0, 0, 88, 89, 0, 0, 0, 0, - 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, - 0, 0, 0, 0, 0, 0, 98, 99, 100, 101, - 102, 103, 104, 105, 106, 107, 0, 108, 84, 85, - 86, 87, 0, 0, 0, 0, 0, 0, 130, 0, - 0, 0, 0, 0, 88, 89, 0, 0, 0, 0, - 0, 90, 91, 92, 93, 94, 95, 96, 97, 0, - 0, 0, 84, 85, 86, 87, 98, 99, 100, 101, - 102, 103, 104, 105, 106, 107, 0, 108, 88, 89, - 0, 0, 0, 0, 0, 90, 91, 92, 93, 94, - 95, 96, 97, 0, 0, 0, 0, 283, 0, 0, - 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, - 0, 108, 84, 85, 86, 87, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 298, 88, 89, - 0, 0, 0, 0, 0, 90, 91, 92, 93, 94, - 95, 96, 97, 0, 0, 0, 0, 0, 0, 0, - 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, - 0, 108, 84, 85, 86, 87, 0, 0, 0, 0, - 0, 0, 299, 0, 0, 0, 0, 0, 88, 89, - 0, 0, 0, 0, 0, 90, 91, 92, 93, 94, - 95, 96, 97, 0, 0, 0, 84, 85, 86, 87, - 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, - 0, 108, 88, 89, 0, 0, 0, 0, 0, 90, - 91, 92, 93, 94, 95, 96, 97, 0, 0, 0, - 84, 85, 86, 87, 98, 99, 100, 101, 102, 103, - 104, 105, 106, 107, 0, 108, 88, 89, 0, 0, - 0, 0, 0, 90, 91, 92, 93, 94, 95, 96, - 97, 0, 0, 0, -153, 85, 86, 0, 0, 0, - 100, 101, 102, 103, 104, 105, 106, 107, 0, 108, - 88, 89, 0, 0, 0, 0, 0, -153, -153, -153, - -153, -153, -153, 96, 97, 0, 0, 85, 86, 0, - 0, 0, 0, 0, -153, 101, 102, 103, 104, 105, - 106, 107, 88, 108, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 96, 97, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 101, 102, 103, - 104, 105, 106, 107, 0, 108 + 103, 104, 105, 106, 107, 0, 108, 84, 85, 86, + 87, 0, 0, 0, 0, 0, 0, 130, 0, 0, + 0, 0, 0, 88, 89, 0, 0, 0, 0, 0, + 90, 91, 92, 93, 94, 95, 96, 97, 0, 0, + 0, 84, 85, 86, 87, 98, 99, 100, 101, 102, + 103, 104, 105, 106, 107, 0, 108, 88, 89, 0, + 0, 0, 0, 0, 90, 91, 92, 93, 94, 95, + 96, 97, 0, 0, 0, 0, 285, 0, 0, 98, + 99, 100, 101, 102, 103, 104, 105, 106, 107, 0, + 108, 84, 85, 86, 87, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 300, 88, 89, 0, + 0, 0, 0, 0, 90, 91, 92, 93, 94, 95, + 96, 97, 0, 0, 0, 0, 0, 0, 0, 98, + 99, 100, 101, 102, 103, 104, 105, 106, 107, 0, + 108, 84, 85, 86, 87, 0, 0, 0, 0, 0, + 0, 301, 0, 0, 0, 0, 0, 88, 89, 0, + 0, 0, 0, 0, 90, 91, 92, 93, 94, 95, + 96, 97, 0, 0, 0, 84, 85, 86, 87, 98, + 99, 100, 101, 102, 103, 104, 105, 106, 107, 0, + 108, 88, 89, 0, 0, 0, 0, 0, 90, 91, + 92, 93, 94, 95, 96, 97, 0, 0, 0, 84, + 85, 86, 87, 98, 99, 100, 101, 102, 103, 104, + 105, 106, 107, 0, 108, 88, 89, 0, 0, 0, + 0, 0, 90, 91, 92, 93, 94, 95, 96, 97, + 0, 0, 0, -154, 85, 86, 0, 0, 0, 100, + 101, 102, 103, 104, 105, 106, 107, 0, 108, 88, + 89, 0, 0, 0, 0, 0, -154, -154, -154, -154, + -154, -154, 96, 97, 0, 0, 0, 0, 0, 0, + 0, 0, 0, -154, 101, 102, 103, 104, 105, 106, + 107, 48, 108, 0, 0, 0, 0, 0, 0, 0, + 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, + 59, 60, 61, 62, 63, 64, 65, 66, 67, 148, + 0, 0, 0, 0, 0, 0, 0, 0, 49, 50, + 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, + 61, 62, 63, 64, 65, 66, 67, 245, 0, 0, + 0, 0, 0, 0, 0, 0, 49, 50, 51, 52, + 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, + 63, 64, 65, 66, 67 }; static const yytype_int16 yycheck[] = { - 1, 1, 7, 11, 12, 4, 59, 5, 61, 10, - 146, 4, 13, 149, 150, 13, 17, 18, 30, 5, - 21, 4, 48, 180, 48, 48, 20, 13, 22, 30, - 48, 32, 33, 15, 28, 29, 41, 63, 143, 59, - 0, 61, 68, 66, 68, 63, 62, 152, 31, 65, - 60, 67, 5, 63, 60, 5, 179, 54, 55, 56, - 13, 58, 62, 62, 16, 17, 64, 65, 58, 62, - 42, 43, 41, 45, 131, 132, 212, 78, 64, 65, - 4, 217, 62, 84, 85, 86, 87, 88, 89, 90, + 1, 19, 1, 0, 7, 5, 48, 11, 12, 10, + 48, 4, 13, 13, 5, 60, 17, 18, 30, 5, + 21, 48, 13, 4, 66, 63, 20, 180, 22, 30, + 68, 32, 33, 48, 28, 29, 143, 62, 41, 15, + 65, 68, 67, 54, 55, 56, 153, 58, 63, 16, + 17, 60, 58, 146, 63, 131, 132, 150, 151, 41, + 4, 79, 5, 62, 64, 65, 62, 28, 4, 62, + 13, 4, 61, 64, 65, 1, 66, 78, 64, 65, + 233, 62, 48, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, - 101, 102, 103, 104, 105, 106, 107, 28, 120, 232, - 267, 64, 65, 114, 64, 65, 4, 42, 43, 113, - 45, 257, 258, 4, 61, 1, 58, 66, 129, 130, - 63, 4, 133, 63, 63, 48, 144, 260, 146, 262, - 263, 149, 150, 266, 58, 68, 269, 1, 13, 143, - 4, 5, 6, 7, 8, 47, 63, 58, 152, 4, - 14, 40, 47, 40, 18, 58, 66, 290, 22, 23, - 4, 58, 47, 27, 60, 29, 30, 60, 4, 302, - 58, 63, 4, 63, 40, 186, 180, 41, 31, 63, - 29, 192, 63, 63, 63, 63, 58, 58, 58, 53, - 63, 120, 245, 306, 212, 206, 60, 208, 62, 217, - 64, 65, 66, 67, 192, 127, 267, -1, 4, 5, - 6, 7, 8, -1, -1, 226, -1, -1, -1, -1, - -1, -1, 233, -1, -1, -1, -1, 238, -1, -1, - -1, -1, -1, -1, 30, -1, -1, 248, 249, 257, - 258, 252, 253, -1, -1, 41, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 53, -1, -1, - -1, -1, -1, 267, 60, -1, 62, 278, 64, 65, - -1, 67, 0, 1, -1, -1, 4, 5, -1, 7, - -1, 9, 10, 11, 12, 13, -1, -1, 299, 300, - 301, 19, 20, 21, -1, -1, 24, 25, 26, -1, - 28, 312, -1, -1, 32, 33, 34, 35, 36, 37, - 38, 39, -1, 41, -1, -1, 44, -1, -1, 47, - 48, 49, 50, 51, 52, 53, 54, 55, 56, -1, - 58, 59, -1, 61, -1, 63, 64, 65, 66, 1, - 68, -1, 4, 10, 11, 7, -1, -1, -1, -1, - -1, 13, 14, 15, 16, 17, 18, 19, 20, 21, - 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, - -1, 38, 39, -1, -1, -1, -1, -1, -1, 41, - -1, -1, -1, 50, 51, 52, 53, 54, 55, 56, - -1, 58, -1, -1, -1, -1, 1, -1, 60, 4, - 62, -1, 7, -1, -1, -1, 68, -1, 13, 14, - 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, - 25, 26, 27, 28, 29, 30, 31, 4, 5, 6, - 7, 8, -1, -1, -1, -1, 41, -1, -1, 1, - -1, -1, 4, 5, 6, 7, 8, -1, -1, -1, - -1, -1, 14, 30, -1, 60, 18, 62, -1, -1, - 22, 23, -1, 68, 41, 27, -1, 29, 30, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 41, - -1, -1, -1, 60, -1, 62, -1, 64, 65, -1, - 67, 53, -1, -1, -1, -1, 10, 11, 60, -1, - 62, 63, 64, 65, 66, 67, 1, -1, -1, 4, - 5, 6, 7, 8, -1, -1, -1, -1, -1, 14, - -1, -1, -1, 18, 38, 39, -1, 22, 23, -1, - -1, -1, 27, -1, 29, 30, 50, 51, 52, 53, - 54, 55, 56, -1, 58, -1, 41, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 53, -1, - -1, -1, -1, -1, -1, 60, -1, 62, -1, 64, - 65, 1, 67, -1, 4, 5, 6, 7, 8, -1, - -1, -1, -1, -1, 14, -1, -1, -1, 18, -1, - -1, -1, 22, 23, -1, -1, -1, 27, -1, 29, + 101, 102, 103, 104, 105, 106, 107, 58, 120, 262, + 63, 264, 265, 114, 59, 268, 61, 63, 271, 113, + 213, 64, 65, 42, 43, 218, 45, 68, 129, 130, + 42, 43, 133, 45, 59, 63, 61, 58, 13, 292, + 144, 47, 146, 63, 58, 4, 150, 151, 40, 143, + 47, 304, 40, 10, 11, 58, 66, 58, 60, 153, + 60, 47, 4, 181, 63, 63, 259, 260, 25, 63, + 63, 58, 63, 4, 4, 5, 6, 7, 8, 197, + 63, 38, 39, 63, 40, 58, 187, 181, 58, 63, + 58, 31, 193, 50, 51, 52, 53, 54, 55, 56, + 30, 58, 120, 29, 247, 127, 207, 308, 209, 213, + 193, 41, 269, -1, 218, -1, -1, 10, 11, -1, + -1, -1, -1, 53, -1, -1, 227, -1, -1, -1, + 60, -1, 62, 234, 64, 65, -1, 67, 239, -1, + -1, -1, -1, -1, -1, 38, 39, -1, -1, 250, + 251, 269, -1, 254, 255, 259, 260, 50, 51, 52, + 53, 54, 55, 56, -1, 58, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 269, -1, -1, -1, 280, + -1, -1, -1, -1, 0, 1, -1, -1, 4, 5, + -1, 7, -1, 9, 10, 11, 12, 13, -1, -1, + 301, 302, 303, 19, 20, 21, -1, -1, 24, 25, + 26, -1, 28, 314, -1, -1, 32, 33, 34, 35, + 36, 37, 38, 39, -1, 41, -1, -1, 44, -1, + -1, 47, 48, 49, 50, 51, 52, 53, 54, 55, + 56, -1, 58, 59, -1, 61, -1, 63, 64, 65, + 66, 1, 68, -1, 4, 10, 11, 7, -1, -1, + -1, -1, -1, 13, 14, 15, 16, 17, 18, 19, + 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, + 30, 31, -1, 38, 39, -1, -1, -1, -1, -1, + -1, 41, -1, -1, -1, 50, 51, 52, 53, 54, + 55, 56, -1, 58, -1, -1, -1, -1, 1, -1, + 60, 4, 62, -1, 7, -1, -1, -1, 68, -1, + 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, + 23, 24, 25, 26, 27, 28, 29, 30, 31, 4, + 5, 6, 7, 8, -1, -1, -1, -1, 41, -1, + -1, 1, -1, -1, 4, 5, 6, 7, 8, -1, + -1, -1, -1, -1, 14, 30, -1, 60, 18, 62, + -1, -1, 22, 23, -1, 68, 41, 27, -1, 29, 30, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 41, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 53, -1, -1, -1, -1, -1, -1, - 60, -1, 62, -1, 64, 65, 1, 67, -1, 4, - 5, 6, 7, 8, -1, -1, -1, -1, -1, 14, - -1, -1, -1, 18, -1, -1, -1, 22, 23, -1, - -1, -1, 27, -1, 29, 30, -1, 4, 5, 6, - 7, 8, -1, -1, -1, -1, 41, 14, -1, -1, - -1, 18, -1, -1, -1, 22, 23, -1, 53, -1, - 27, -1, 29, 30, -1, 60, -1, 62, -1, 64, - 65, -1, 67, -1, 41, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 53, -1, -1, -1, - -1, -1, 59, 60, -1, 62, -1, 64, 65, -1, - 67, 4, 5, 6, 7, 8, -1, -1, -1, -1, + -1, 41, -1, -1, -1, 60, -1, 62, -1, 64, + 65, -1, 67, 53, -1, -1, -1, -1, -1, -1, + 60, -1, 62, 63, 64, 65, 66, 67, 1, -1, + -1, 4, 5, 6, 7, 8, -1, -1, -1, -1, -1, 14, -1, -1, -1, 18, -1, -1, -1, 22, - 23, -1, -1, -1, 27, -1, 29, 30, -1, 4, - 5, 6, 7, 8, -1, -1, -1, -1, 41, 14, - -1, -1, -1, 18, -1, -1, -1, 22, 23, -1, - 53, -1, 27, -1, 29, 30, -1, 60, -1, 62, - -1, 64, 65, 66, 67, -1, 41, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 53, -1, - -1, -1, -1, -1, -1, 60, -1, 62, 1, 64, - 65, 4, 67, -1, 7, -1, -1, -1, -1, -1, - 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, - 23, 24, 25, 26, 27, 28, 29, 30, 31, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 41, 9, - 10, 11, 12, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 25, 26, 60, -1, 62, - -1, -1, 32, 33, 34, 35, 36, 37, 38, 39, - -1, -1, -1, -1, -1, -1, -1, 47, 48, 49, - 50, 51, 52, 53, 54, 55, 56, -1, 58, 9, - 10, 11, 12, 63, -1, -1, 66, -1, -1, -1, - -1, -1, -1, -1, -1, 25, 26, -1, -1, -1, - -1, -1, 32, 33, 34, 35, 36, 37, 38, 39, - -1, -1, -1, -1, -1, -1, -1, 47, 48, 49, - 50, 51, 52, 53, 54, 55, 56, -1, 58, 9, - 10, 11, 12, -1, -1, -1, 66, -1, -1, -1, - -1, -1, -1, -1, -1, 25, 26, -1, -1, -1, - -1, -1, 32, 33, 34, 35, 36, 37, 38, 39, - -1, -1, -1, -1, -1, -1, -1, 47, 48, 49, - 50, 51, 52, 53, 54, 55, 56, -1, 58, 9, - 10, 11, 12, -1, -1, -1, 66, -1, -1, -1, - -1, -1, -1, -1, -1, 25, 26, -1, -1, -1, - -1, -1, 32, 33, 34, 35, 36, 37, 38, 39, - -1, -1, -1, -1, -1, -1, -1, 47, 48, 49, - 50, 51, 52, 53, 54, 55, 56, -1, 58, 9, - 10, 11, 12, -1, -1, -1, 66, -1, -1, -1, - -1, -1, -1, -1, -1, 25, 26, -1, -1, -1, + 23, -1, -1, -1, 27, -1, 29, 30, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 41, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 53, -1, -1, -1, -1, -1, -1, 60, -1, 62, + -1, 64, 65, 66, 67, 1, -1, -1, 4, 5, + 6, 7, 8, -1, -1, -1, -1, -1, 14, -1, + -1, -1, 18, -1, -1, -1, 22, 23, -1, -1, + -1, 27, -1, 29, 30, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 41, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 53, -1, -1, + -1, -1, -1, -1, 60, -1, 62, -1, 64, 65, + 1, 67, -1, 4, 5, 6, 7, 8, -1, -1, + -1, -1, -1, 14, -1, -1, -1, 18, -1, -1, + -1, 22, 23, -1, -1, -1, 27, -1, 29, 30, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 41, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 53, -1, -1, -1, -1, -1, -1, 60, + -1, 62, -1, 64, 65, 1, 67, -1, 4, 5, + 6, 7, 8, -1, -1, -1, -1, -1, 14, -1, + -1, -1, 18, -1, -1, -1, 22, 23, -1, -1, + -1, 27, -1, 29, 30, -1, 4, 5, 6, 7, + 8, -1, -1, -1, -1, 41, 14, -1, -1, -1, + 18, -1, -1, -1, 22, 23, -1, 53, -1, 27, + -1, 29, 30, -1, 60, -1, 62, -1, 64, 65, + -1, 67, -1, 41, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 53, -1, -1, -1, -1, + -1, 59, 60, -1, 62, -1, 64, 65, -1, 67, + 4, 5, 6, 7, 8, -1, -1, -1, -1, -1, + 14, -1, -1, -1, 18, -1, -1, -1, 22, 23, + -1, -1, -1, 27, -1, 29, 30, -1, 4, 5, + 6, 7, 8, -1, -1, -1, -1, 41, 14, -1, + -1, -1, 18, -1, -1, -1, 22, 23, -1, 53, + -1, 27, -1, 29, 30, -1, 60, -1, 62, -1, + 64, 65, 66, 67, -1, 41, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 53, -1, -1, + -1, -1, -1, -1, 60, -1, 62, 1, 64, 65, + 4, 67, -1, 7, -1, -1, -1, -1, -1, 13, + 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, 30, 31, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 41, 9, 10, + 11, 12, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 25, 26, 60, -1, 62, -1, + -1, 32, 33, 34, 35, 36, 37, 38, 39, -1, + -1, -1, -1, -1, -1, -1, 47, 48, 49, 50, + 51, 52, 53, 54, 55, 56, -1, 58, 9, 10, + 11, 12, 63, -1, -1, 66, -1, -1, -1, -1, + -1, -1, -1, -1, 25, 26, -1, -1, -1, -1, + -1, 32, 33, 34, 35, 36, 37, 38, 39, -1, + -1, -1, -1, -1, -1, -1, 47, 48, 49, 50, + 51, 52, 53, 54, 55, 56, -1, 58, 9, 10, + 11, 12, -1, -1, -1, 66, -1, -1, -1, -1, + -1, -1, -1, -1, 25, 26, -1, -1, -1, -1, + -1, 32, 33, 34, 35, 36, 37, 38, 39, -1, + -1, -1, -1, -1, -1, -1, 47, 48, 49, 50, + 51, 52, 53, 54, 55, 56, -1, 58, 9, 10, + 11, 12, -1, -1, -1, 66, -1, -1, -1, -1, + -1, -1, -1, -1, 25, 26, -1, -1, -1, -1, + -1, 32, 33, 34, 35, 36, 37, 38, 39, -1, + -1, -1, -1, -1, -1, -1, 47, 48, 49, 50, + 51, 52, 53, 54, 55, 56, -1, 58, 9, 10, + 11, 12, -1, -1, -1, 66, -1, -1, -1, -1, + -1, -1, -1, -1, 25, 26, -1, -1, -1, -1, + -1, 32, 33, 34, 35, 36, 37, 38, 39, -1, + -1, -1, -1, -1, -1, -1, 47, 48, 49, 50, + 51, 52, 53, 54, 55, 56, -1, 58, 59, -1, + 61, 9, 10, 11, 12, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 25, 26, -1, + -1, -1, -1, -1, 32, 33, 34, 35, 36, 37, + 38, 39, -1, -1, -1, 9, 10, 11, 12, 47, + 48, 49, 50, 51, 52, 53, 54, 55, 56, -1, + 58, 25, 26, 61, -1, -1, -1, -1, 32, 33, + 34, 35, 36, 37, 38, 39, -1, -1, -1, 9, + 10, 11, 12, 47, 48, 49, 50, 51, 52, 53, + 54, 55, 56, -1, 58, 25, 26, 61, -1, -1, -1, -1, 32, 33, 34, 35, 36, 37, 38, 39, - -1, -1, -1, -1, -1, -1, -1, 47, 48, 49, - 50, 51, 52, 53, 54, 55, 56, -1, 58, 59, - -1, 61, 9, 10, 11, 12, -1, -1, -1, -1, + -1, -1, -1, 9, 10, 11, 12, 47, 48, 49, + 50, 51, 52, 53, 54, 55, 56, -1, 58, 25, + 26, 61, -1, -1, -1, -1, 32, 33, 34, 35, + 36, 37, 38, 39, -1, -1, -1, 9, 10, 11, + 12, 47, 48, 49, 50, 51, 52, 53, 54, 55, + 56, -1, 58, 25, 26, 61, -1, -1, -1, -1, + 32, 33, 34, 35, 36, 37, 38, 39, -1, -1, + -1, 9, 10, 11, 12, 47, 48, 49, 50, 51, + 52, 53, 54, 55, 56, -1, 58, 25, 26, 61, + -1, -1, -1, -1, 32, 33, 34, 35, 36, 37, + 38, 39, -1, -1, -1, -1, -1, -1, -1, 47, + 48, 49, 50, 51, 52, 53, 54, 55, 56, -1, + 58, 59, 9, 10, 11, 12, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 25, 26, -1, -1, -1, -1, -1, 32, 33, 34, 35, 36, - 37, 38, 39, -1, -1, -1, 9, 10, 11, 12, - 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, - -1, 58, 25, 26, 61, -1, -1, -1, -1, 32, - 33, 34, 35, 36, 37, 38, 39, -1, -1, -1, - 9, 10, 11, 12, 47, 48, 49, 50, 51, 52, - 53, 54, 55, 56, -1, 58, 25, 26, 61, -1, - -1, -1, -1, 32, 33, 34, 35, 36, 37, 38, - 39, -1, -1, -1, 9, 10, 11, 12, 47, 48, - 49, 50, 51, 52, 53, 54, 55, 56, -1, 58, - 25, 26, 61, -1, -1, -1, -1, 32, 33, 34, - 35, 36, 37, 38, 39, -1, -1, -1, 9, 10, - 11, 12, 47, 48, 49, 50, 51, 52, 53, 54, - 55, 56, -1, 58, 25, 26, 61, -1, -1, -1, - -1, 32, 33, 34, 35, 36, 37, 38, 39, -1, - -1, -1, 9, 10, 11, 12, 47, 48, 49, 50, - 51, 52, 53, 54, 55, 56, -1, 58, 25, 26, - 61, -1, -1, -1, -1, 32, 33, 34, 35, 36, 37, 38, 39, -1, -1, -1, -1, -1, -1, -1, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, -1, 58, 59, 9, 10, 11, 12, -1, -1, -1, @@ -1266,53 +1290,53 @@ static const yytype_int16 yycheck[] = 33, 34, 35, 36, 37, 38, 39, -1, -1, -1, -1, -1, -1, -1, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, -1, 58, 59, 9, 10, 11, - 12, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 12, -1, -1, -1, -1, -1, -1, -1, 20, 21, + -1, -1, 24, 25, 26, -1, -1, -1, -1, -1, + 32, 33, 34, 35, 36, 37, 38, 39, -1, -1, + -1, -1, -1, -1, -1, 47, 48, 49, 50, 51, + 52, 53, 54, 55, 56, -1, 58, 9, 10, 11, + 12, -1, -1, -1, -1, -1, -1, -1, 20, 21, -1, -1, -1, 25, 26, -1, -1, -1, -1, -1, 32, 33, 34, 35, 36, 37, 38, 39, -1, -1, -1, -1, -1, -1, -1, 47, 48, 49, 50, 51, - 52, 53, 54, 55, 56, -1, 58, 59, 9, 10, - 11, 12, -1, -1, -1, -1, -1, -1, -1, 20, - 21, -1, -1, 24, 25, 26, -1, -1, -1, -1, - -1, 32, 33, 34, 35, 36, 37, 38, 39, -1, - -1, -1, -1, -1, -1, -1, 47, 48, 49, 50, - 51, 52, 53, 54, 55, 56, -1, 58, 9, 10, - 11, 12, -1, -1, -1, -1, -1, -1, -1, 20, - 21, -1, -1, -1, 25, 26, -1, -1, -1, -1, - -1, 32, 33, 34, 35, 36, 37, 38, 39, -1, - -1, -1, -1, -1, -1, -1, 47, 48, 49, 50, - 51, 52, 53, 54, 55, 56, -1, 58, 9, 10, - 11, 12, -1, -1, -1, -1, -1, -1, 19, -1, - -1, -1, -1, -1, 25, 26, -1, -1, -1, -1, - -1, 32, 33, 34, 35, 36, 37, 38, 39, -1, - -1, -1, 9, 10, 11, 12, 47, 48, 49, 50, - 51, 52, 53, 54, 55, 56, -1, 58, 25, 26, - -1, -1, -1, -1, -1, 32, 33, 34, 35, 36, - 37, 38, 39, -1, -1, -1, -1, 44, -1, -1, - 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, - -1, 58, 9, 10, 11, 12, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 24, 25, 26, - -1, -1, -1, -1, -1, 32, 33, 34, 35, 36, - 37, 38, 39, -1, -1, -1, -1, -1, -1, -1, - 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, - -1, 58, 9, 10, 11, 12, -1, -1, -1, -1, - -1, -1, 19, -1, -1, -1, -1, -1, 25, 26, - -1, -1, -1, -1, -1, 32, 33, 34, 35, 36, - 37, 38, 39, -1, -1, -1, 9, 10, 11, 12, - 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, - -1, 58, 25, 26, -1, -1, -1, -1, -1, 32, - 33, 34, 35, 36, 37, 38, 39, -1, -1, -1, - 9, 10, 11, 12, 47, 48, 49, 50, 51, 52, - 53, 54, 55, 56, -1, 58, 25, 26, -1, -1, - -1, -1, -1, 32, 33, 34, 35, 36, 37, 38, - 39, -1, -1, -1, 9, 10, 11, -1, -1, -1, - 49, 50, 51, 52, 53, 54, 55, 56, -1, 58, - 25, 26, -1, -1, -1, -1, -1, 32, 33, 34, - 35, 36, 37, 38, 39, -1, -1, 10, 11, -1, - -1, -1, -1, -1, 49, 50, 51, 52, 53, 54, - 55, 56, 25, 58, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 38, 39, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 50, 51, 52, - 53, 54, 55, 56, -1, 58 + 52, 53, 54, 55, 56, -1, 58, 9, 10, 11, + 12, -1, -1, -1, -1, -1, -1, 19, -1, -1, + -1, -1, -1, 25, 26, -1, -1, -1, -1, -1, + 32, 33, 34, 35, 36, 37, 38, 39, -1, -1, + -1, 9, 10, 11, 12, 47, 48, 49, 50, 51, + 52, 53, 54, 55, 56, -1, 58, 25, 26, -1, + -1, -1, -1, -1, 32, 33, 34, 35, 36, 37, + 38, 39, -1, -1, -1, -1, 44, -1, -1, 47, + 48, 49, 50, 51, 52, 53, 54, 55, 56, -1, + 58, 9, 10, 11, 12, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 24, 25, 26, -1, + -1, -1, -1, -1, 32, 33, 34, 35, 36, 37, + 38, 39, -1, -1, -1, -1, -1, -1, -1, 47, + 48, 49, 50, 51, 52, 53, 54, 55, 56, -1, + 58, 9, 10, 11, 12, -1, -1, -1, -1, -1, + -1, 19, -1, -1, -1, -1, -1, 25, 26, -1, + -1, -1, -1, -1, 32, 33, 34, 35, 36, 37, + 38, 39, -1, -1, -1, 9, 10, 11, 12, 47, + 48, 49, 50, 51, 52, 53, 54, 55, 56, -1, + 58, 25, 26, -1, -1, -1, -1, -1, 32, 33, + 34, 35, 36, 37, 38, 39, -1, -1, -1, 9, + 10, 11, 12, 47, 48, 49, 50, 51, 52, 53, + 54, 55, 56, -1, 58, 25, 26, -1, -1, -1, + -1, -1, 32, 33, 34, 35, 36, 37, 38, 39, + -1, -1, -1, 9, 10, 11, -1, -1, -1, 49, + 50, 51, 52, 53, 54, 55, 56, -1, 58, 25, + 26, -1, -1, -1, -1, -1, 32, 33, 34, 35, + 36, 37, 38, 39, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 49, 50, 51, 52, 53, 54, 55, + 56, 4, 58, -1, -1, -1, -1, -1, -1, -1, + 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, + 23, 24, 25, 26, 27, 28, 29, 30, 31, 4, + -1, -1, -1, -1, -1, -1, -1, -1, 13, 14, + 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, 30, 31, 4, -1, -1, + -1, -1, -1, -1, -1, -1, 13, 14, 15, 16, + 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, 30, 31 }; /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing @@ -1323,34 +1347,34 @@ static const yytype_uint8 yystos[] = 18, 22, 23, 27, 29, 30, 41, 53, 60, 62, 64, 65, 67, 74, 78, 81, 87, 0, 16, 17, 72, 75, 76, 60, 58, 41, 4, 74, 87, 87, - 74, 62, 1, 62, 82, 74, 1, 74, 4, 31, - 1, 4, 7, 81, 1, 66, 74, 1, 4, 13, + 74, 62, 1, 62, 82, 74, 1, 74, 4, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, - 24, 25, 26, 27, 28, 29, 30, 31, 60, 62, + 24, 25, 26, 27, 28, 29, 30, 31, 96, 1, + 4, 7, 81, 1, 66, 74, 1, 4, 60, 62, 81, 96, 97, 98, 9, 10, 11, 12, 25, 26, 32, 33, 34, 35, 36, 37, 38, 39, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 58, 59, 74, 5, 13, 64, 65, 77, 81, 77, 73, 74, 78, 72, 59, 74, 74, 88, 89, 83, 60, 63, 19, 13, 13, 28, 4, 4, 84, 61, 61, 1, - 58, 66, 66, 48, 63, 68, 63, 74, 4, 63, - 63, 68, 48, 74, 74, 74, 74, 74, 74, 74, + 58, 66, 66, 48, 63, 68, 63, 74, 4, 96, + 63, 63, 68, 48, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, - 74, 74, 74, 74, 74, 74, 74, 58, 62, 65, - 67, 90, 91, 92, 81, 1, 63, 66, 74, 13, - 73, 59, 59, 61, 84, 4, 62, 79, 80, 74, - 1, 74, 91, 91, 1, 74, 47, 42, 43, 45, - 1, 97, 53, 86, 87, 86, 61, 63, 86, 86, - 97, 4, 92, 93, 1, 4, 60, 62, 81, 94, - 95, 96, 40, 47, 58, 66, 74, 58, 63, 66, - 4, 62, 89, 45, 4, 59, 61, 59, 20, 21, - 24, 85, 60, 60, 74, 74, 86, 47, 63, 86, - 48, 66, 63, 63, 74, 4, 63, 48, 68, 63, - 92, 74, 66, 66, 74, 58, 4, 80, 63, 74, - 74, 74, 74, 44, 86, 86, 92, 92, 92, 61, - 63, 92, 95, 92, 58, 58, 66, 74, 24, 19, - 59, 59, 63, 92, 58, 59, 74, 74, 74, 92, - 85, 61, 59, 61, 74, 61 + 74, 74, 74, 74, 74, 74, 74, 74, 58, 62, + 65, 67, 90, 91, 92, 81, 1, 63, 66, 74, + 13, 73, 59, 59, 61, 84, 4, 62, 79, 80, + 74, 1, 74, 91, 91, 1, 74, 47, 42, 43, + 45, 1, 97, 53, 86, 87, 86, 61, 63, 86, + 86, 97, 4, 92, 93, 1, 4, 60, 62, 81, + 94, 95, 96, 40, 47, 58, 66, 74, 58, 63, + 66, 4, 62, 89, 45, 4, 96, 59, 61, 59, + 20, 21, 24, 85, 60, 60, 74, 74, 86, 47, + 63, 86, 48, 66, 63, 63, 74, 4, 63, 48, + 68, 63, 92, 74, 66, 66, 74, 58, 4, 80, + 63, 74, 74, 74, 74, 44, 86, 86, 92, 92, + 92, 61, 63, 92, 95, 92, 58, 58, 66, 74, + 24, 19, 59, 59, 63, 92, 58, 59, 74, 74, + 74, 92, 85, 61, 59, 61, 74, 61 }; /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ @@ -1362,17 +1386,17 @@ static const yytype_uint8 yyr1[] = 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, 75, 75, 76, 76, 76, 77, 78, 78, 79, 79, 80, - 80, 82, 81, 83, 81, 84, 84, 84, 85, 85, - 86, 86, 86, 87, 87, 87, 87, 87, 87, 87, + 80, 80, 82, 81, 83, 81, 84, 84, 84, 85, + 85, 86, 86, 86, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, - 87, 87, 88, 88, 89, 90, 90, 91, 91, 92, - 92, 92, 93, 93, 94, 94, 95, 95, 95, 95, - 95, 95, 95, 96, 96, 96, 96, 96, 96, 96, + 87, 87, 87, 88, 88, 89, 90, 90, 91, 91, + 92, 92, 92, 93, 93, 94, 94, 95, 95, 95, + 95, 95, 95, 95, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, 96, - 96, 96, 97, 97, 97, 97, 98, 98, 98, 98, - 98, 98, 98, 98, 98 + 96, 96, 96, 97, 97, 97, 97, 98, 98, 98, + 98, 98, 98, 98, 98, 98, 98, 98 }; /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */ @@ -1384,17 +1408,17 @@ static const yytype_uint8 yyr2[] = 3, 3, 3, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 1, 2, 3, 5, 4, 2, 1, 5, 8, 1, 3, 2, - 1, 0, 4, 0, 5, 0, 2, 4, 5, 3, - 3, 2, 1, 1, 1, 3, 2, 3, 2, 4, - 3, 2, 1, 3, 2, 2, 3, 5, 4, 4, - 3, 7, 6, 6, 6, 5, 5, 1, 1, 1, - 3, 3, 2, 3, 2, 2, 1, 4, 3, 3, - 4, 3, 1, 3, 1, 3, 1, 3, 1, 2, - 3, 3, 1, 3, 1, 3, 2, 4, 3, 3, - 3, 5, 3, 1, 1, 1, 1, 1, 1, 1, + 2, 1, 0, 4, 0, 5, 0, 2, 4, 5, + 3, 3, 2, 1, 1, 1, 3, 2, 3, 2, + 4, 3, 2, 1, 3, 2, 2, 3, 5, 4, + 4, 3, 7, 6, 6, 6, 5, 5, 1, 1, + 1, 3, 3, 2, 3, 2, 2, 1, 4, 3, + 3, 4, 3, 1, 3, 1, 3, 1, 3, 1, + 2, 3, 3, 1, 3, 1, 3, 2, 4, 3, + 3, 3, 5, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 0, 1, 3, 3, 3, 3, 3, 1, - 4, 2, 1, 5, 3 + 1, 1, 1, 0, 1, 3, 3, 3, 3, 3, + 1, 4, 2, 2, 1, 1, 5, 3 }; @@ -1827,7 +1851,6 @@ yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, case N: \ yyformat = S; \ break - default: /* Avoid compiler warnings. */ YYCASE_(0, YY_("syntax error")); YYCASE_(1, YY_("syntax error, unexpected %s")); YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s")); @@ -1896,189 +1919,189 @@ yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, YYLTYPE *yylocatio switch (yytype) { case 4: /* IDENT */ -#line 36 "src/parser.y" /* yacc.c:1258 */ +#line 36 "src/parser.y" /* yacc.c:1257 */ { jv_free(((*yyvaluep).literal)); } -#line 1902 "src/parser.c" /* yacc.c:1258 */ +#line 1925 "src/parser.c" /* yacc.c:1257 */ break; case 5: /* FIELD */ -#line 36 "src/parser.y" /* yacc.c:1258 */ +#line 36 "src/parser.y" /* yacc.c:1257 */ { jv_free(((*yyvaluep).literal)); } -#line 1908 "src/parser.c" /* yacc.c:1258 */ +#line 1931 "src/parser.c" /* yacc.c:1257 */ break; case 6: /* LITERAL */ -#line 36 "src/parser.y" /* yacc.c:1258 */ +#line 36 "src/parser.y" /* yacc.c:1257 */ { jv_free(((*yyvaluep).literal)); } -#line 1914 "src/parser.c" /* yacc.c:1258 */ +#line 1937 "src/parser.c" /* yacc.c:1257 */ break; case 7: /* FORMAT */ -#line 36 "src/parser.y" /* yacc.c:1258 */ +#line 36 "src/parser.y" /* yacc.c:1257 */ { jv_free(((*yyvaluep).literal)); } -#line 1920 "src/parser.c" /* yacc.c:1258 */ +#line 1943 "src/parser.c" /* yacc.c:1257 */ break; case 42: /* QQSTRING_TEXT */ -#line 36 "src/parser.y" /* yacc.c:1258 */ +#line 36 "src/parser.y" /* yacc.c:1257 */ { jv_free(((*yyvaluep).literal)); } -#line 1926 "src/parser.c" /* yacc.c:1258 */ +#line 1949 "src/parser.c" /* yacc.c:1257 */ break; case 71: /* Module */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 1932 "src/parser.c" /* yacc.c:1258 */ +#line 1955 "src/parser.c" /* yacc.c:1257 */ break; case 72: /* Imports */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 1938 "src/parser.c" /* yacc.c:1258 */ +#line 1961 "src/parser.c" /* yacc.c:1257 */ break; case 73: /* FuncDefs */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 1944 "src/parser.c" /* yacc.c:1258 */ +#line 1967 "src/parser.c" /* yacc.c:1257 */ break; case 74: /* Exp */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 1950 "src/parser.c" /* yacc.c:1258 */ +#line 1973 "src/parser.c" /* yacc.c:1257 */ break; case 75: /* Import */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 1956 "src/parser.c" /* yacc.c:1258 */ +#line 1979 "src/parser.c" /* yacc.c:1257 */ break; case 76: /* ImportWhat */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 1962 "src/parser.c" /* yacc.c:1258 */ +#line 1985 "src/parser.c" /* yacc.c:1257 */ break; case 77: /* ImportFrom */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 1968 "src/parser.c" /* yacc.c:1258 */ +#line 1991 "src/parser.c" /* yacc.c:1257 */ break; case 78: /* FuncDef */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 1974 "src/parser.c" /* yacc.c:1258 */ +#line 1997 "src/parser.c" /* yacc.c:1257 */ break; case 79: /* Params */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 1980 "src/parser.c" /* yacc.c:1258 */ +#line 2003 "src/parser.c" /* yacc.c:1257 */ break; case 80: /* Param */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 1986 "src/parser.c" /* yacc.c:1258 */ +#line 2009 "src/parser.c" /* yacc.c:1257 */ break; case 81: /* String */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 1992 "src/parser.c" /* yacc.c:1258 */ +#line 2015 "src/parser.c" /* yacc.c:1257 */ break; case 84: /* QQString */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 1998 "src/parser.c" /* yacc.c:1258 */ +#line 2021 "src/parser.c" /* yacc.c:1257 */ break; case 85: /* ElseBody */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2004 "src/parser.c" /* yacc.c:1258 */ +#line 2027 "src/parser.c" /* yacc.c:1257 */ break; case 86: /* ExpD */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2010 "src/parser.c" /* yacc.c:1258 */ +#line 2033 "src/parser.c" /* yacc.c:1257 */ break; case 87: /* Term */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2016 "src/parser.c" /* yacc.c:1258 */ +#line 2039 "src/parser.c" /* yacc.c:1257 */ break; case 88: /* Args */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2022 "src/parser.c" /* yacc.c:1258 */ +#line 2045 "src/parser.c" /* yacc.c:1257 */ break; case 89: /* Arg */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2028 "src/parser.c" /* yacc.c:1258 */ +#line 2051 "src/parser.c" /* yacc.c:1257 */ break; case 90: /* RepPatterns */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2034 "src/parser.c" /* yacc.c:1258 */ +#line 2057 "src/parser.c" /* yacc.c:1257 */ break; case 91: /* Patterns */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2040 "src/parser.c" /* yacc.c:1258 */ +#line 2063 "src/parser.c" /* yacc.c:1257 */ break; case 92: /* Pattern */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2046 "src/parser.c" /* yacc.c:1258 */ +#line 2069 "src/parser.c" /* yacc.c:1257 */ break; case 93: /* ArrayPats */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2052 "src/parser.c" /* yacc.c:1258 */ +#line 2075 "src/parser.c" /* yacc.c:1257 */ break; case 94: /* ObjPats */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2058 "src/parser.c" /* yacc.c:1258 */ +#line 2081 "src/parser.c" /* yacc.c:1257 */ break; case 95: /* ObjPat */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2064 "src/parser.c" /* yacc.c:1258 */ +#line 2087 "src/parser.c" /* yacc.c:1257 */ break; case 96: /* Keyword */ -#line 36 "src/parser.y" /* yacc.c:1258 */ +#line 36 "src/parser.y" /* yacc.c:1257 */ { jv_free(((*yyvaluep).literal)); } -#line 2070 "src/parser.c" /* yacc.c:1258 */ +#line 2093 "src/parser.c" /* yacc.c:1257 */ break; case 97: /* MkDict */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2076 "src/parser.c" /* yacc.c:1258 */ +#line 2099 "src/parser.c" /* yacc.c:1257 */ break; case 98: /* MkDictPair */ -#line 37 "src/parser.y" /* yacc.c:1258 */ +#line 37 "src/parser.y" /* yacc.c:1257 */ { block_free(((*yyvaluep).blk)); } -#line 2082 "src/parser.c" /* yacc.c:1258 */ +#line 2105 "src/parser.c" /* yacc.c:1257 */ break; @@ -2364,38 +2387,37 @@ YYLTYPE yylloc = yyloc_default; GCC warning that YYVAL may be used uninitialized. */ yyval = yyvsp[1-yylen]; - /* Default location. */ + /* Default location. */ YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen); - yyerror_range[1] = yyloc; YY_REDUCE_PRINT (yyn); switch (yyn) { case 2: -#line 300 "src/parser.y" /* yacc.c:1648 */ +#line 300 "src/parser.y" /* yacc.c:1646 */ { *answer = BLOCK((yyvsp[-2].blk), (yyvsp[-1].blk), gen_op_simple(TOP), (yyvsp[0].blk)); } -#line 2379 "src/parser.c" /* yacc.c:1648 */ +#line 2401 "src/parser.c" /* yacc.c:1646 */ break; case 3: -#line 303 "src/parser.y" /* yacc.c:1648 */ +#line 303 "src/parser.y" /* yacc.c:1646 */ { *answer = BLOCK((yyvsp[-2].blk), (yyvsp[-1].blk), (yyvsp[0].blk)); } -#line 2387 "src/parser.c" /* yacc.c:1648 */ +#line 2409 "src/parser.c" /* yacc.c:1646 */ break; case 4: -#line 308 "src/parser.y" /* yacc.c:1648 */ +#line 308 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_noop(); } -#line 2395 "src/parser.c" /* yacc.c:1648 */ +#line 2417 "src/parser.c" /* yacc.c:1646 */ break; case 5: -#line 311 "src/parser.y" /* yacc.c:1648 */ +#line 311 "src/parser.y" /* yacc.c:1646 */ { if (!block_is_const((yyvsp[-1].blk))) { FAIL((yyloc), "Module metadata must be constant"); @@ -2405,374 +2427,374 @@ YYLTYPE yylloc = yyloc_default; (yyval.blk) = gen_module((yyvsp[-1].blk)); } } -#line 2409 "src/parser.c" /* yacc.c:1648 */ +#line 2431 "src/parser.c" /* yacc.c:1646 */ break; case 6: -#line 322 "src/parser.y" /* yacc.c:1648 */ +#line 322 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_noop(); } -#line 2417 "src/parser.c" /* yacc.c:1648 */ +#line 2439 "src/parser.c" /* yacc.c:1646 */ break; case 7: -#line 325 "src/parser.y" /* yacc.c:1648 */ +#line 325 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = BLOCK((yyvsp[-1].blk), (yyvsp[0].blk)); } -#line 2425 "src/parser.c" /* yacc.c:1648 */ +#line 2447 "src/parser.c" /* yacc.c:1646 */ break; case 8: -#line 330 "src/parser.y" /* yacc.c:1648 */ +#line 330 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_noop(); } -#line 2433 "src/parser.c" /* yacc.c:1648 */ +#line 2455 "src/parser.c" /* yacc.c:1646 */ break; case 9: -#line 333 "src/parser.y" /* yacc.c:1648 */ +#line 333 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = block_join((yyvsp[-1].blk), (yyvsp[0].blk)); } -#line 2441 "src/parser.c" /* yacc.c:1648 */ +#line 2463 "src/parser.c" /* yacc.c:1646 */ break; case 10: -#line 338 "src/parser.y" /* yacc.c:1648 */ +#line 338 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = block_bind_referenced((yyvsp[-1].blk), (yyvsp[0].blk), OP_IS_CALL_PSEUDO); } -#line 2449 "src/parser.c" /* yacc.c:1648 */ +#line 2471 "src/parser.c" /* yacc.c:1646 */ break; case 11: -#line 342 "src/parser.y" /* yacc.c:1648 */ +#line 342 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_destructure((yyvsp[-4].blk), (yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 2457 "src/parser.c" /* yacc.c:1648 */ +#line 2479 "src/parser.c" /* yacc.c:1646 */ break; case 12: -#line 345 "src/parser.y" /* yacc.c:1648 */ +#line 345 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_reduce((yyvsp[-7].blk), (yyvsp[-5].blk), (yyvsp[-3].blk), (yyvsp[-1].blk)); } -#line 2465 "src/parser.c" /* yacc.c:1648 */ +#line 2487 "src/parser.c" /* yacc.c:1646 */ break; case 13: -#line 349 "src/parser.y" /* yacc.c:1648 */ +#line 349 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_foreach((yyvsp[-9].blk), (yyvsp[-7].blk), (yyvsp[-5].blk), (yyvsp[-3].blk), (yyvsp[-1].blk)); } -#line 2473 "src/parser.c" /* yacc.c:1648 */ +#line 2495 "src/parser.c" /* yacc.c:1646 */ break; case 14: -#line 353 "src/parser.y" /* yacc.c:1648 */ +#line 353 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_foreach((yyvsp[-7].blk), (yyvsp[-5].blk), (yyvsp[-3].blk), (yyvsp[-1].blk), gen_noop()); } -#line 2481 "src/parser.c" /* yacc.c:1648 */ +#line 2503 "src/parser.c" /* yacc.c:1646 */ break; case 15: -#line 357 "src/parser.y" /* yacc.c:1648 */ +#line 357 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_cond((yyvsp[-3].blk), (yyvsp[-1].blk), (yyvsp[0].blk)); } -#line 2489 "src/parser.c" /* yacc.c:1648 */ +#line 2511 "src/parser.c" /* yacc.c:1646 */ break; case 16: -#line 360 "src/parser.y" /* yacc.c:1648 */ +#line 360 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_cond((yyvsp[-3].blk), (yyvsp[-1].blk), gen_noop()); } -#line 2497 "src/parser.c" /* yacc.c:1648 */ +#line 2519 "src/parser.c" /* yacc.c:1646 */ break; case 17: -#line 363 "src/parser.y" /* yacc.c:1648 */ +#line 363 "src/parser.y" /* yacc.c:1646 */ { FAIL((yyloc), "Possibly unterminated 'if' statement"); (yyval.blk) = (yyvsp[-2].blk); } -#line 2506 "src/parser.c" /* yacc.c:1648 */ +#line 2528 "src/parser.c" /* yacc.c:1646 */ break; case 18: -#line 368 "src/parser.y" /* yacc.c:1648 */ +#line 368 "src/parser.y" /* yacc.c:1646 */ { //$$ = BLOCK(gen_op_target(FORK_OPT, $2), $2, $4); (yyval.blk) = gen_try((yyvsp[-2].blk), gen_try_handler((yyvsp[0].blk))); } -#line 2515 "src/parser.c" /* yacc.c:1648 */ +#line 2537 "src/parser.c" /* yacc.c:1646 */ break; case 19: -#line 372 "src/parser.y" /* yacc.c:1648 */ +#line 372 "src/parser.y" /* yacc.c:1646 */ { //$$ = BLOCK(gen_op_target(FORK_OPT, $2), $2, gen_op_simple(BACKTRACK)); (yyval.blk) = gen_try((yyvsp[0].blk), gen_op_simple(BACKTRACK)); } -#line 2524 "src/parser.c" /* yacc.c:1648 */ +#line 2546 "src/parser.c" /* yacc.c:1646 */ break; case 20: -#line 376 "src/parser.y" /* yacc.c:1648 */ +#line 376 "src/parser.y" /* yacc.c:1646 */ { FAIL((yyloc), "Possibly unterminated 'try' statement"); (yyval.blk) = (yyvsp[-2].blk); } -#line 2533 "src/parser.c" /* yacc.c:1648 */ +#line 2555 "src/parser.c" /* yacc.c:1646 */ break; case 21: -#line 381 "src/parser.y" /* yacc.c:1648 */ +#line 381 "src/parser.y" /* yacc.c:1646 */ { jv v = jv_string_fmt("*label-%s", jv_string_value((yyvsp[-2].literal))); (yyval.blk) = gen_location((yyloc), locations, gen_label(jv_string_value(v), (yyvsp[0].blk))); jv_free((yyvsp[-2].literal)); jv_free(v); } -#line 2544 "src/parser.c" /* yacc.c:1648 */ +#line 2566 "src/parser.c" /* yacc.c:1646 */ break; case 22: -#line 388 "src/parser.y" /* yacc.c:1648 */ +#line 388 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_try((yyvsp[-1].blk), gen_op_simple(BACKTRACK)); } -#line 2552 "src/parser.c" /* yacc.c:1648 */ +#line 2574 "src/parser.c" /* yacc.c:1646 */ break; case 23: -#line 392 "src/parser.y" /* yacc.c:1648 */ +#line 392 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_call("_assign", BLOCK(gen_lambda((yyvsp[-2].blk)), gen_lambda((yyvsp[0].blk)))); } -#line 2560 "src/parser.c" /* yacc.c:1648 */ +#line 2582 "src/parser.c" /* yacc.c:1646 */ break; case 24: -#line 396 "src/parser.y" /* yacc.c:1648 */ +#line 396 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_or((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 2568 "src/parser.c" /* yacc.c:1648 */ +#line 2590 "src/parser.c" /* yacc.c:1646 */ break; case 25: -#line 400 "src/parser.y" /* yacc.c:1648 */ +#line 400 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_and((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 2576 "src/parser.c" /* yacc.c:1648 */ +#line 2598 "src/parser.c" /* yacc.c:1646 */ break; case 26: -#line 404 "src/parser.y" /* yacc.c:1648 */ +#line 404 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_definedor((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 2584 "src/parser.c" /* yacc.c:1648 */ +#line 2606 "src/parser.c" /* yacc.c:1646 */ break; case 27: -#line 408 "src/parser.y" /* yacc.c:1648 */ +#line 408 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_definedor_assign((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 2592 "src/parser.c" /* yacc.c:1648 */ +#line 2614 "src/parser.c" /* yacc.c:1646 */ break; case 28: -#line 412 "src/parser.y" /* yacc.c:1648 */ +#line 412 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_call("_modify", BLOCK(gen_lambda((yyvsp[-2].blk)), gen_lambda((yyvsp[0].blk)))); } -#line 2600 "src/parser.c" /* yacc.c:1648 */ +#line 2622 "src/parser.c" /* yacc.c:1646 */ break; case 29: -#line 416 "src/parser.y" /* yacc.c:1648 */ +#line 416 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = block_join((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 2608 "src/parser.c" /* yacc.c:1648 */ +#line 2630 "src/parser.c" /* yacc.c:1646 */ break; case 30: -#line 420 "src/parser.y" /* yacc.c:1648 */ +#line 420 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_both((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 2616 "src/parser.c" /* yacc.c:1648 */ +#line 2638 "src/parser.c" /* yacc.c:1646 */ break; case 31: -#line 424 "src/parser.y" /* yacc.c:1648 */ +#line 424 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-2].blk), (yyvsp[0].blk), '+'); } -#line 2624 "src/parser.c" /* yacc.c:1648 */ +#line 2646 "src/parser.c" /* yacc.c:1646 */ break; case 32: -#line 428 "src/parser.y" /* yacc.c:1648 */ +#line 428 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_update((yyvsp[-2].blk), (yyvsp[0].blk), '+'); } -#line 2632 "src/parser.c" /* yacc.c:1648 */ +#line 2654 "src/parser.c" /* yacc.c:1646 */ break; case 33: -#line 432 "src/parser.y" /* yacc.c:1648 */ +#line 432 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = BLOCK((yyvsp[0].blk), gen_call("_negate", gen_noop())); } -#line 2640 "src/parser.c" /* yacc.c:1648 */ +#line 2662 "src/parser.c" /* yacc.c:1646 */ break; case 34: -#line 436 "src/parser.y" /* yacc.c:1648 */ +#line 436 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-2].blk), (yyvsp[0].blk), '-'); } -#line 2648 "src/parser.c" /* yacc.c:1648 */ +#line 2670 "src/parser.c" /* yacc.c:1646 */ break; case 35: -#line 440 "src/parser.y" /* yacc.c:1648 */ +#line 440 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_update((yyvsp[-2].blk), (yyvsp[0].blk), '-'); } -#line 2656 "src/parser.c" /* yacc.c:1648 */ +#line 2678 "src/parser.c" /* yacc.c:1646 */ break; case 36: -#line 444 "src/parser.y" /* yacc.c:1648 */ +#line 444 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-2].blk), (yyvsp[0].blk), '*'); } -#line 2664 "src/parser.c" /* yacc.c:1648 */ +#line 2686 "src/parser.c" /* yacc.c:1646 */ break; case 37: -#line 448 "src/parser.y" /* yacc.c:1648 */ +#line 448 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_update((yyvsp[-2].blk), (yyvsp[0].blk), '*'); } -#line 2672 "src/parser.c" /* yacc.c:1648 */ +#line 2694 "src/parser.c" /* yacc.c:1646 */ break; case 38: -#line 452 "src/parser.y" /* yacc.c:1648 */ +#line 452 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-2].blk), (yyvsp[0].blk), '/'); if (block_is_const_inf((yyval.blk))) FAIL((yyloc), "Division by zero?"); } -#line 2682 "src/parser.c" /* yacc.c:1648 */ +#line 2704 "src/parser.c" /* yacc.c:1646 */ break; case 39: -#line 458 "src/parser.y" /* yacc.c:1648 */ +#line 458 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-2].blk), (yyvsp[0].blk), '%'); if (block_is_const_inf((yyval.blk))) FAIL((yyloc), "Remainder by zero?"); } -#line 2692 "src/parser.c" /* yacc.c:1648 */ +#line 2714 "src/parser.c" /* yacc.c:1646 */ break; case 40: -#line 464 "src/parser.y" /* yacc.c:1648 */ +#line 464 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_update((yyvsp[-2].blk), (yyvsp[0].blk), '/'); } -#line 2700 "src/parser.c" /* yacc.c:1648 */ +#line 2722 "src/parser.c" /* yacc.c:1646 */ break; case 41: -#line 468 "src/parser.y" /* yacc.c:1648 */ +#line 468 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_update((yyvsp[-2].blk), (yyvsp[0].blk), '%'); } -#line 2708 "src/parser.c" /* yacc.c:1648 */ +#line 2730 "src/parser.c" /* yacc.c:1646 */ break; case 42: -#line 472 "src/parser.y" /* yacc.c:1648 */ +#line 472 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-2].blk), (yyvsp[0].blk), EQ); } -#line 2716 "src/parser.c" /* yacc.c:1648 */ +#line 2738 "src/parser.c" /* yacc.c:1646 */ break; case 43: -#line 476 "src/parser.y" /* yacc.c:1648 */ +#line 476 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-2].blk), (yyvsp[0].blk), NEQ); } -#line 2724 "src/parser.c" /* yacc.c:1648 */ +#line 2746 "src/parser.c" /* yacc.c:1646 */ break; case 44: -#line 480 "src/parser.y" /* yacc.c:1648 */ +#line 480 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-2].blk), (yyvsp[0].blk), '<'); } -#line 2732 "src/parser.c" /* yacc.c:1648 */ +#line 2754 "src/parser.c" /* yacc.c:1646 */ break; case 45: -#line 484 "src/parser.y" /* yacc.c:1648 */ +#line 484 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-2].blk), (yyvsp[0].blk), '>'); } -#line 2740 "src/parser.c" /* yacc.c:1648 */ +#line 2762 "src/parser.c" /* yacc.c:1646 */ break; case 46: -#line 488 "src/parser.y" /* yacc.c:1648 */ +#line 488 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-2].blk), (yyvsp[0].blk), LESSEQ); } -#line 2748 "src/parser.c" /* yacc.c:1648 */ +#line 2770 "src/parser.c" /* yacc.c:1646 */ break; case 47: -#line 492 "src/parser.y" /* yacc.c:1648 */ +#line 492 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-2].blk), (yyvsp[0].blk), GREATEREQ); } -#line 2756 "src/parser.c" /* yacc.c:1648 */ +#line 2778 "src/parser.c" /* yacc.c:1646 */ break; case 48: -#line 496 "src/parser.y" /* yacc.c:1648 */ +#line 496 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[0].blk); } -#line 2764 "src/parser.c" /* yacc.c:1648 */ +#line 2786 "src/parser.c" /* yacc.c:1646 */ break; case 49: -#line 501 "src/parser.y" /* yacc.c:1648 */ +#line 501 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[-1].blk); } -#line 2772 "src/parser.c" /* yacc.c:1648 */ +#line 2794 "src/parser.c" /* yacc.c:1646 */ break; case 50: -#line 504 "src/parser.y" /* yacc.c:1648 */ +#line 504 "src/parser.y" /* yacc.c:1646 */ { if (!block_is_const((yyvsp[-1].blk))) { FAIL((yyloc), "Module metadata must be constant"); @@ -2788,11 +2810,11 @@ YYLTYPE yylloc = yyloc_default; (yyval.blk) = gen_import_meta((yyvsp[-2].blk), (yyvsp[-1].blk)); } } -#line 2792 "src/parser.c" /* yacc.c:1648 */ +#line 2814 "src/parser.c" /* yacc.c:1646 */ break; case 51: -#line 521 "src/parser.y" /* yacc.c:1648 */ +#line 521 "src/parser.y" /* yacc.c:1646 */ { jv v = block_const((yyvsp[-3].blk)); // XXX Make gen_import take only blocks and the int is_data so we @@ -2802,11 +2824,11 @@ YYLTYPE yylloc = yyloc_default; jv_free((yyvsp[0].literal)); jv_free(v); } -#line 2806 "src/parser.c" /* yacc.c:1648 */ +#line 2828 "src/parser.c" /* yacc.c:1646 */ break; case 52: -#line 530 "src/parser.y" /* yacc.c:1648 */ +#line 530 "src/parser.y" /* yacc.c:1646 */ { jv v = block_const((yyvsp[-2].blk)); (yyval.blk) = gen_import(jv_string_value(v), jv_string_value((yyvsp[0].literal)), 0); @@ -2814,22 +2836,22 @@ YYLTYPE yylloc = yyloc_default; jv_free((yyvsp[0].literal)); jv_free(v); } -#line 2818 "src/parser.c" /* yacc.c:1648 */ +#line 2840 "src/parser.c" /* yacc.c:1646 */ break; case 53: -#line 537 "src/parser.y" /* yacc.c:1648 */ +#line 537 "src/parser.y" /* yacc.c:1646 */ { jv v = block_const((yyvsp[0].blk)); (yyval.blk) = gen_import(jv_string_value(v), NULL, 0); block_free((yyvsp[0].blk)); jv_free(v); } -#line 2829 "src/parser.c" /* yacc.c:1648 */ +#line 2851 "src/parser.c" /* yacc.c:1646 */ break; case 54: -#line 545 "src/parser.y" /* yacc.c:1648 */ +#line 545 "src/parser.y" /* yacc.c:1646 */ { if (!block_is_const((yyvsp[0].blk))) { FAIL((yyloc), "Import path must be constant"); @@ -2839,173 +2861,182 @@ YYLTYPE yylloc = yyloc_default; (yyval.blk) = (yyvsp[0].blk); } } -#line 2843 "src/parser.c" /* yacc.c:1648 */ +#line 2865 "src/parser.c" /* yacc.c:1646 */ break; case 55: -#line 556 "src/parser.y" /* yacc.c:1648 */ +#line 556 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_function(jv_string_value((yyvsp[-3].literal)), gen_noop(), (yyvsp[-1].blk)); jv_free((yyvsp[-3].literal)); } -#line 2852 "src/parser.c" /* yacc.c:1648 */ +#line 2874 "src/parser.c" /* yacc.c:1646 */ break; case 56: -#line 561 "src/parser.y" /* yacc.c:1648 */ +#line 561 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_function(jv_string_value((yyvsp[-6].literal)), (yyvsp[-4].blk), (yyvsp[-1].blk)); jv_free((yyvsp[-6].literal)); } -#line 2861 "src/parser.c" /* yacc.c:1648 */ +#line 2883 "src/parser.c" /* yacc.c:1646 */ break; case 57: -#line 567 "src/parser.y" /* yacc.c:1648 */ +#line 567 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[0].blk); } -#line 2869 "src/parser.c" /* yacc.c:1648 */ +#line 2891 "src/parser.c" /* yacc.c:1646 */ break; case 58: -#line 570 "src/parser.y" /* yacc.c:1648 */ +#line 570 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = BLOCK((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 2877 "src/parser.c" /* yacc.c:1648 */ +#line 2899 "src/parser.c" /* yacc.c:1646 */ break; case 59: -#line 575 "src/parser.y" /* yacc.c:1648 */ +#line 575 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_param_regular(jv_string_value((yyvsp[0].literal))); jv_free((yyvsp[0].literal)); } -#line 2886 "src/parser.c" /* yacc.c:1648 */ +#line 2908 "src/parser.c" /* yacc.c:1646 */ break; case 60: -#line 580 "src/parser.y" /* yacc.c:1648 */ +#line 579 "src/parser.y" /* yacc.c:1646 */ { - (yyval.blk) = gen_param(jv_string_value((yyvsp[0].literal))); + (yyval.blk) = gen_param_regular(jv_string_value((yyvsp[0].literal))); jv_free((yyvsp[0].literal)); } -#line 2895 "src/parser.c" /* yacc.c:1648 */ +#line 2917 "src/parser.c" /* yacc.c:1646 */ break; case 61: -#line 587 "src/parser.y" /* yacc.c:1648 */ - { (yyval.literal) = jv_string("text"); } -#line 2901 "src/parser.c" /* yacc.c:1648 */ +#line 583 "src/parser.y" /* yacc.c:1646 */ + { + (yyval.blk) = gen_param(jv_string_value((yyvsp[0].literal))); + jv_free((yyvsp[0].literal)); +} +#line 2926 "src/parser.c" /* yacc.c:1646 */ break; case 62: -#line 587 "src/parser.y" /* yacc.c:1648 */ +#line 590 "src/parser.y" /* yacc.c:1646 */ + { (yyval.literal) = jv_string("text"); } +#line 2932 "src/parser.c" /* yacc.c:1646 */ + break; + + case 63: +#line 590 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[-1].blk); jv_free((yyvsp[-2].literal)); } -#line 2910 "src/parser.c" /* yacc.c:1648 */ +#line 2941 "src/parser.c" /* yacc.c:1646 */ break; - case 63: -#line 591 "src/parser.y" /* yacc.c:1648 */ + case 64: +#line 594 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = (yyvsp[-1].literal); } -#line 2916 "src/parser.c" /* yacc.c:1648 */ +#line 2947 "src/parser.c" /* yacc.c:1646 */ break; - case 64: -#line 591 "src/parser.y" /* yacc.c:1648 */ + case 65: +#line 594 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[-1].blk); jv_free((yyvsp[-2].literal)); } -#line 2925 "src/parser.c" /* yacc.c:1648 */ +#line 2956 "src/parser.c" /* yacc.c:1646 */ break; - case 65: -#line 598 "src/parser.y" /* yacc.c:1648 */ + case 66: +#line 601 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_const(jv_string("")); } -#line 2933 "src/parser.c" /* yacc.c:1648 */ +#line 2964 "src/parser.c" /* yacc.c:1646 */ break; - case 66: -#line 601 "src/parser.y" /* yacc.c:1648 */ + case 67: +#line 604 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-1].blk), gen_const((yyvsp[0].literal)), '+'); } -#line 2941 "src/parser.c" /* yacc.c:1648 */ +#line 2972 "src/parser.c" /* yacc.c:1646 */ break; - case 67: -#line 604 "src/parser.y" /* yacc.c:1648 */ + case 68: +#line 607 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_binop((yyvsp[-3].blk), gen_format((yyvsp[-1].blk), jv_copy((yyvsp[-4].literal))), '+'); } -#line 2949 "src/parser.c" /* yacc.c:1648 */ +#line 2980 "src/parser.c" /* yacc.c:1646 */ break; - case 68: -#line 610 "src/parser.y" /* yacc.c:1648 */ + case 69: +#line 613 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_cond((yyvsp[-3].blk), (yyvsp[-1].blk), (yyvsp[0].blk)); } -#line 2957 "src/parser.c" /* yacc.c:1648 */ +#line 2988 "src/parser.c" /* yacc.c:1646 */ break; - case 69: -#line 613 "src/parser.y" /* yacc.c:1648 */ + case 70: +#line 616 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[-1].blk); } -#line 2965 "src/parser.c" /* yacc.c:1648 */ +#line 2996 "src/parser.c" /* yacc.c:1646 */ break; - case 70: -#line 618 "src/parser.y" /* yacc.c:1648 */ + case 71: +#line 621 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = block_join((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 2973 "src/parser.c" /* yacc.c:1648 */ +#line 3004 "src/parser.c" /* yacc.c:1646 */ break; - case 71: -#line 621 "src/parser.y" /* yacc.c:1648 */ + case 72: +#line 624 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = BLOCK((yyvsp[0].blk), gen_call("_negate", gen_noop())); } -#line 2981 "src/parser.c" /* yacc.c:1648 */ +#line 3012 "src/parser.c" /* yacc.c:1646 */ break; - case 72: -#line 624 "src/parser.y" /* yacc.c:1648 */ + case 73: +#line 627 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[0].blk); } -#line 2989 "src/parser.c" /* yacc.c:1648 */ +#line 3020 "src/parser.c" /* yacc.c:1646 */ break; - case 73: -#line 630 "src/parser.y" /* yacc.c:1648 */ + case 74: +#line 633 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_noop(); } -#line 2997 "src/parser.c" /* yacc.c:1648 */ +#line 3028 "src/parser.c" /* yacc.c:1646 */ break; - case 74: -#line 633 "src/parser.y" /* yacc.c:1648 */ + case 75: +#line 636 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_call("recurse", gen_noop()); } -#line 3005 "src/parser.c" /* yacc.c:1648 */ +#line 3036 "src/parser.c" /* yacc.c:1646 */ break; - case 75: -#line 636 "src/parser.y" /* yacc.c:1648 */ + case 76: +#line 639 "src/parser.y" /* yacc.c:1646 */ { jv v = jv_string_fmt("*label-%s", jv_string_value((yyvsp[0].literal))); // impossible symbol (yyval.blk) = gen_location((yyloc), locations, @@ -3014,231 +3045,231 @@ YYLTYPE yylloc = yyloc_default; jv_free(v); jv_free((yyvsp[0].literal)); } -#line 3018 "src/parser.c" /* yacc.c:1648 */ +#line 3049 "src/parser.c" /* yacc.c:1646 */ break; - case 76: -#line 644 "src/parser.y" /* yacc.c:1648 */ + case 77: +#line 647 "src/parser.y" /* yacc.c:1646 */ { FAIL((yyloc), "break requires a label to break to"); (yyval.blk) = gen_noop(); } -#line 3027 "src/parser.c" /* yacc.c:1648 */ +#line 3058 "src/parser.c" /* yacc.c:1646 */ break; - case 77: -#line 648 "src/parser.y" /* yacc.c:1648 */ + case 78: +#line 651 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_index_opt((yyvsp[-2].blk), gen_const((yyvsp[-1].literal))); } -#line 3035 "src/parser.c" /* yacc.c:1648 */ +#line 3066 "src/parser.c" /* yacc.c:1646 */ break; - case 78: -#line 651 "src/parser.y" /* yacc.c:1648 */ + case 79: +#line 654 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_index_opt(gen_noop(), gen_const((yyvsp[-1].literal))); } -#line 3043 "src/parser.c" /* yacc.c:1648 */ +#line 3074 "src/parser.c" /* yacc.c:1646 */ break; - case 79: -#line 654 "src/parser.y" /* yacc.c:1648 */ + case 80: +#line 657 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_index_opt((yyvsp[-3].blk), (yyvsp[-1].blk)); } -#line 3051 "src/parser.c" /* yacc.c:1648 */ +#line 3082 "src/parser.c" /* yacc.c:1646 */ break; - case 80: -#line 657 "src/parser.y" /* yacc.c:1648 */ + case 81: +#line 660 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_index_opt(gen_noop(), (yyvsp[-1].blk)); } -#line 3059 "src/parser.c" /* yacc.c:1648 */ +#line 3090 "src/parser.c" /* yacc.c:1646 */ break; - case 81: -#line 660 "src/parser.y" /* yacc.c:1648 */ + case 82: +#line 663 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_index((yyvsp[-1].blk), gen_const((yyvsp[0].literal))); } -#line 3067 "src/parser.c" /* yacc.c:1648 */ +#line 3098 "src/parser.c" /* yacc.c:1646 */ break; - case 82: -#line 663 "src/parser.y" /* yacc.c:1648 */ + case 83: +#line 666 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_index(gen_noop(), gen_const((yyvsp[0].literal))); } -#line 3075 "src/parser.c" /* yacc.c:1648 */ +#line 3106 "src/parser.c" /* yacc.c:1646 */ break; - case 83: -#line 666 "src/parser.y" /* yacc.c:1648 */ + case 84: +#line 669 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_index((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 3083 "src/parser.c" /* yacc.c:1648 */ +#line 3114 "src/parser.c" /* yacc.c:1646 */ break; - case 84: -#line 669 "src/parser.y" /* yacc.c:1648 */ + case 85: +#line 672 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_index(gen_noop(), (yyvsp[0].blk)); } -#line 3091 "src/parser.c" /* yacc.c:1648 */ +#line 3122 "src/parser.c" /* yacc.c:1646 */ break; - case 85: -#line 672 "src/parser.y" /* yacc.c:1648 */ + case 86: +#line 675 "src/parser.y" /* yacc.c:1646 */ { FAIL((yyloc), "try .[\"field\"] instead of .field for unusually named fields"); (yyval.blk) = gen_noop(); } -#line 3100 "src/parser.c" /* yacc.c:1648 */ +#line 3131 "src/parser.c" /* yacc.c:1646 */ break; - case 86: -#line 676 "src/parser.y" /* yacc.c:1648 */ + case 87: +#line 679 "src/parser.y" /* yacc.c:1646 */ { jv_free((yyvsp[-1].literal)); FAIL((yyloc), "try .[\"field\"] instead of .field for unusually named fields"); (yyval.blk) = gen_noop(); } -#line 3110 "src/parser.c" /* yacc.c:1648 */ +#line 3141 "src/parser.c" /* yacc.c:1646 */ break; - case 87: -#line 682 "src/parser.y" /* yacc.c:1648 */ + case 88: +#line 685 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_index_opt((yyvsp[-4].blk), (yyvsp[-2].blk)); } -#line 3118 "src/parser.c" /* yacc.c:1648 */ +#line 3149 "src/parser.c" /* yacc.c:1646 */ break; - case 88: -#line 685 "src/parser.y" /* yacc.c:1648 */ + case 89: +#line 688 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_index((yyvsp[-3].blk), (yyvsp[-1].blk)); } -#line 3126 "src/parser.c" /* yacc.c:1648 */ +#line 3157 "src/parser.c" /* yacc.c:1646 */ break; - case 89: -#line 688 "src/parser.y" /* yacc.c:1648 */ + case 90: +#line 691 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = block_join((yyvsp[-3].blk), gen_op_simple(EACH_OPT)); } -#line 3134 "src/parser.c" /* yacc.c:1648 */ +#line 3165 "src/parser.c" /* yacc.c:1646 */ break; - case 90: -#line 691 "src/parser.y" /* yacc.c:1648 */ + case 91: +#line 694 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = block_join((yyvsp[-2].blk), gen_op_simple(EACH)); } -#line 3142 "src/parser.c" /* yacc.c:1648 */ +#line 3173 "src/parser.c" /* yacc.c:1646 */ break; - case 91: -#line 694 "src/parser.y" /* yacc.c:1648 */ + case 92: +#line 697 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_slice_index((yyvsp[-6].blk), (yyvsp[-4].blk), (yyvsp[-2].blk), INDEX_OPT); } -#line 3150 "src/parser.c" /* yacc.c:1648 */ +#line 3181 "src/parser.c" /* yacc.c:1646 */ break; - case 92: -#line 697 "src/parser.y" /* yacc.c:1648 */ + case 93: +#line 700 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_slice_index((yyvsp[-5].blk), (yyvsp[-3].blk), gen_const(jv_null()), INDEX_OPT); } -#line 3158 "src/parser.c" /* yacc.c:1648 */ +#line 3189 "src/parser.c" /* yacc.c:1646 */ break; - case 93: -#line 700 "src/parser.y" /* yacc.c:1648 */ + case 94: +#line 703 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_slice_index((yyvsp[-5].blk), gen_const(jv_null()), (yyvsp[-2].blk), INDEX_OPT); } -#line 3166 "src/parser.c" /* yacc.c:1648 */ +#line 3197 "src/parser.c" /* yacc.c:1646 */ break; - case 94: -#line 703 "src/parser.y" /* yacc.c:1648 */ + case 95: +#line 706 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_slice_index((yyvsp[-5].blk), (yyvsp[-3].blk), (yyvsp[-1].blk), INDEX); } -#line 3174 "src/parser.c" /* yacc.c:1648 */ +#line 3205 "src/parser.c" /* yacc.c:1646 */ break; - case 95: -#line 706 "src/parser.y" /* yacc.c:1648 */ + case 96: +#line 709 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_slice_index((yyvsp[-4].blk), (yyvsp[-2].blk), gen_const(jv_null()), INDEX); } -#line 3182 "src/parser.c" /* yacc.c:1648 */ +#line 3213 "src/parser.c" /* yacc.c:1646 */ break; - case 96: -#line 709 "src/parser.y" /* yacc.c:1648 */ + case 97: +#line 712 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_slice_index((yyvsp[-4].blk), gen_const(jv_null()), (yyvsp[-1].blk), INDEX); } -#line 3190 "src/parser.c" /* yacc.c:1648 */ +#line 3221 "src/parser.c" /* yacc.c:1646 */ break; - case 97: -#line 712 "src/parser.y" /* yacc.c:1648 */ + case 98: +#line 715 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_const((yyvsp[0].literal)); } -#line 3198 "src/parser.c" /* yacc.c:1648 */ +#line 3229 "src/parser.c" /* yacc.c:1646 */ break; - case 98: -#line 715 "src/parser.y" /* yacc.c:1648 */ + case 99: +#line 718 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[0].blk); } -#line 3206 "src/parser.c" /* yacc.c:1648 */ +#line 3237 "src/parser.c" /* yacc.c:1646 */ break; - case 99: -#line 718 "src/parser.y" /* yacc.c:1648 */ + case 100: +#line 721 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_format(gen_noop(), (yyvsp[0].literal)); } -#line 3214 "src/parser.c" /* yacc.c:1648 */ +#line 3245 "src/parser.c" /* yacc.c:1646 */ break; - case 100: -#line 721 "src/parser.y" /* yacc.c:1648 */ + case 101: +#line 724 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[-1].blk); } -#line 3222 "src/parser.c" /* yacc.c:1648 */ +#line 3253 "src/parser.c" /* yacc.c:1646 */ break; - case 101: -#line 724 "src/parser.y" /* yacc.c:1648 */ + case 102: +#line 727 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_collect((yyvsp[-1].blk)); } -#line 3230 "src/parser.c" /* yacc.c:1648 */ +#line 3261 "src/parser.c" /* yacc.c:1646 */ break; - case 102: -#line 727 "src/parser.y" /* yacc.c:1648 */ + case 103: +#line 730 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_const(jv_array()); } -#line 3238 "src/parser.c" /* yacc.c:1648 */ +#line 3269 "src/parser.c" /* yacc.c:1646 */ break; - case 103: -#line 730 "src/parser.y" /* yacc.c:1648 */ + case 104: +#line 733 "src/parser.y" /* yacc.c:1646 */ { block o = gen_const_object((yyvsp[-1].blk)); if (o.first != NULL) @@ -3246,29 +3277,34 @@ YYLTYPE yylloc = yyloc_default; else (yyval.blk) = BLOCK(gen_subexp(gen_const(jv_object())), (yyvsp[-1].blk), gen_op_simple(POP)); } -#line 3250 "src/parser.c" /* yacc.c:1648 */ +#line 3281 "src/parser.c" /* yacc.c:1646 */ break; - case 104: -#line 737 "src/parser.y" /* yacc.c:1648 */ + case 105: +#line 740 "src/parser.y" /* yacc.c:1646 */ { - (yyval.blk) = gen_const(JV_OBJECT(jv_string("file"), jv_copy(locations->fname), - jv_string("line"), jv_number(locfile_get_line(locations, (yyloc).start) + 1))); + (yyval.blk) = gen_location((yyloc), locations, gen_op_unbound(LOADV, jv_string_value((yyvsp[0].literal)))); + jv_free((yyvsp[0].literal)); } -#line 3259 "src/parser.c" /* yacc.c:1648 */ +#line 3290 "src/parser.c" /* yacc.c:1646 */ break; - case 105: -#line 741 "src/parser.y" /* yacc.c:1648 */ + case 106: +#line 744 "src/parser.y" /* yacc.c:1646 */ { - (yyval.blk) = gen_location((yyloc), locations, gen_op_unbound(LOADV, jv_string_value((yyvsp[0].literal)))); + if (strcmp(jv_string_value((yyvsp[0].literal)), "__loc__") == 0) { + (yyval.blk) = gen_const(JV_OBJECT(jv_string("file"), jv_copy(locations->fname), + jv_string("line"), jv_number(locfile_get_line(locations, (yyloc).start) + 1))); + } else { + (yyval.blk) = gen_location((yyloc), locations, gen_op_unbound(LOADV, jv_string_value((yyvsp[0].literal)))); + } jv_free((yyvsp[0].literal)); } -#line 3268 "src/parser.c" /* yacc.c:1648 */ +#line 3304 "src/parser.c" /* yacc.c:1646 */ break; - case 106: -#line 745 "src/parser.y" /* yacc.c:1648 */ + case 107: +#line 753 "src/parser.y" /* yacc.c:1646 */ { const char *s = jv_string_value((yyvsp[0].literal)); if (strcmp(s, "false") == 0) @@ -3281,198 +3317,198 @@ YYLTYPE yylloc = yyloc_default; (yyval.blk) = gen_location((yyloc), locations, gen_call(s, gen_noop())); jv_free((yyvsp[0].literal)); } -#line 3285 "src/parser.c" /* yacc.c:1648 */ +#line 3321 "src/parser.c" /* yacc.c:1646 */ break; - case 107: -#line 757 "src/parser.y" /* yacc.c:1648 */ + case 108: +#line 765 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_call(jv_string_value((yyvsp[-3].literal)), (yyvsp[-1].blk)); (yyval.blk) = gen_location((yylsp[-3]), locations, (yyval.blk)); jv_free((yyvsp[-3].literal)); } -#line 3295 "src/parser.c" /* yacc.c:1648 */ +#line 3331 "src/parser.c" /* yacc.c:1646 */ break; - case 108: -#line 762 "src/parser.y" /* yacc.c:1648 */ + case 109: +#line 770 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_noop(); } -#line 3301 "src/parser.c" /* yacc.c:1648 */ +#line 3337 "src/parser.c" /* yacc.c:1646 */ break; - case 109: -#line 763 "src/parser.y" /* yacc.c:1648 */ + case 110: +#line 771 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_noop(); } -#line 3307 "src/parser.c" /* yacc.c:1648 */ +#line 3343 "src/parser.c" /* yacc.c:1646 */ break; - case 110: -#line 764 "src/parser.y" /* yacc.c:1648 */ + case 111: +#line 772 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[-3].blk); } -#line 3313 "src/parser.c" /* yacc.c:1648 */ +#line 3349 "src/parser.c" /* yacc.c:1646 */ break; - case 111: -#line 765 "src/parser.y" /* yacc.c:1648 */ + case 112: +#line 773 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_noop(); } -#line 3319 "src/parser.c" /* yacc.c:1648 */ +#line 3355 "src/parser.c" /* yacc.c:1646 */ break; - case 112: -#line 768 "src/parser.y" /* yacc.c:1648 */ + case 113: +#line 776 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[0].blk); } -#line 3327 "src/parser.c" /* yacc.c:1648 */ +#line 3363 "src/parser.c" /* yacc.c:1646 */ break; - case 113: -#line 771 "src/parser.y" /* yacc.c:1648 */ + case 114: +#line 779 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = BLOCK((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 3335 "src/parser.c" /* yacc.c:1648 */ +#line 3371 "src/parser.c" /* yacc.c:1646 */ break; - case 114: -#line 776 "src/parser.y" /* yacc.c:1648 */ + case 115: +#line 784 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_lambda((yyvsp[0].blk)); } -#line 3343 "src/parser.c" /* yacc.c:1648 */ +#line 3379 "src/parser.c" /* yacc.c:1646 */ break; - case 115: -#line 781 "src/parser.y" /* yacc.c:1648 */ + case 116: +#line 789 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = BLOCK((yyvsp[-2].blk), gen_destructure_alt((yyvsp[0].blk))); } -#line 3351 "src/parser.c" /* yacc.c:1648 */ +#line 3387 "src/parser.c" /* yacc.c:1646 */ break; - case 116: -#line 784 "src/parser.y" /* yacc.c:1648 */ + case 117: +#line 792 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_destructure_alt((yyvsp[0].blk)); } -#line 3359 "src/parser.c" /* yacc.c:1648 */ +#line 3395 "src/parser.c" /* yacc.c:1646 */ break; - case 117: -#line 789 "src/parser.y" /* yacc.c:1648 */ + case 118: +#line 797 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = BLOCK((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 3367 "src/parser.c" /* yacc.c:1648 */ +#line 3403 "src/parser.c" /* yacc.c:1646 */ break; - case 118: -#line 792 "src/parser.y" /* yacc.c:1648 */ + case 119: +#line 800 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[0].blk); } -#line 3375 "src/parser.c" /* yacc.c:1648 */ +#line 3411 "src/parser.c" /* yacc.c:1646 */ break; - case 119: -#line 797 "src/parser.y" /* yacc.c:1648 */ + case 120: +#line 805 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_op_unbound(STOREV, jv_string_value((yyvsp[0].literal))); jv_free((yyvsp[0].literal)); } -#line 3384 "src/parser.c" /* yacc.c:1648 */ +#line 3420 "src/parser.c" /* yacc.c:1646 */ break; - case 120: -#line 801 "src/parser.y" /* yacc.c:1648 */ + case 121: +#line 809 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = BLOCK((yyvsp[-1].blk), gen_op_simple(POP)); } -#line 3392 "src/parser.c" /* yacc.c:1648 */ +#line 3428 "src/parser.c" /* yacc.c:1646 */ break; - case 121: -#line 804 "src/parser.y" /* yacc.c:1648 */ + case 122: +#line 812 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = BLOCK((yyvsp[-1].blk), gen_op_simple(POP)); } -#line 3400 "src/parser.c" /* yacc.c:1648 */ +#line 3436 "src/parser.c" /* yacc.c:1646 */ break; - case 122: -#line 809 "src/parser.y" /* yacc.c:1648 */ + case 123: +#line 817 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_array_matcher(gen_noop(), (yyvsp[0].blk)); } -#line 3408 "src/parser.c" /* yacc.c:1648 */ +#line 3444 "src/parser.c" /* yacc.c:1646 */ break; - case 123: -#line 812 "src/parser.y" /* yacc.c:1648 */ + case 124: +#line 820 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_array_matcher((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 3416 "src/parser.c" /* yacc.c:1648 */ +#line 3452 "src/parser.c" /* yacc.c:1646 */ break; - case 124: -#line 817 "src/parser.y" /* yacc.c:1648 */ + case 125: +#line 825 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[0].blk); } -#line 3424 "src/parser.c" /* yacc.c:1648 */ +#line 3460 "src/parser.c" /* yacc.c:1646 */ break; - case 125: -#line 820 "src/parser.y" /* yacc.c:1648 */ + case 126: +#line 828 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = BLOCK((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 3432 "src/parser.c" /* yacc.c:1648 */ +#line 3468 "src/parser.c" /* yacc.c:1646 */ break; - case 126: -#line 825 "src/parser.y" /* yacc.c:1648 */ + case 127: +#line 833 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_object_matcher(gen_const((yyvsp[0].literal)), gen_op_unbound(STOREV, jv_string_value((yyvsp[0].literal)))); } -#line 3440 "src/parser.c" /* yacc.c:1648 */ +#line 3476 "src/parser.c" /* yacc.c:1646 */ break; - case 127: -#line 828 "src/parser.y" /* yacc.c:1648 */ + case 128: +#line 836 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_object_matcher(gen_const((yyvsp[-2].literal)), BLOCK(gen_op_simple(DUP), gen_op_unbound(STOREV, jv_string_value((yyvsp[-2].literal))), (yyvsp[0].blk))); } -#line 3448 "src/parser.c" /* yacc.c:1648 */ +#line 3484 "src/parser.c" /* yacc.c:1646 */ break; - case 128: -#line 831 "src/parser.y" /* yacc.c:1648 */ + case 129: +#line 839 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_object_matcher(gen_const((yyvsp[-2].literal)), (yyvsp[0].blk)); } -#line 3456 "src/parser.c" /* yacc.c:1648 */ +#line 3492 "src/parser.c" /* yacc.c:1646 */ break; - case 129: -#line 834 "src/parser.y" /* yacc.c:1648 */ + case 130: +#line 842 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_object_matcher(gen_const((yyvsp[-2].literal)), (yyvsp[0].blk)); } -#line 3464 "src/parser.c" /* yacc.c:1648 */ +#line 3500 "src/parser.c" /* yacc.c:1646 */ break; - case 130: -#line 837 "src/parser.y" /* yacc.c:1648 */ + case 131: +#line 845 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_object_matcher((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 3472 "src/parser.c" /* yacc.c:1648 */ +#line 3508 "src/parser.c" /* yacc.c:1646 */ break; - case 131: -#line 840 "src/parser.y" /* yacc.c:1648 */ + case 132: +#line 848 "src/parser.y" /* yacc.c:1646 */ { jv msg = check_object_key((yyvsp[-3].blk)); if (jv_is_valid(msg)) { @@ -3481,258 +3517,276 @@ YYLTYPE yylloc = yyloc_default; jv_free(msg); (yyval.blk) = gen_object_matcher((yyvsp[-3].blk), (yyvsp[0].blk)); } -#line 3485 "src/parser.c" /* yacc.c:1648 */ +#line 3521 "src/parser.c" /* yacc.c:1646 */ break; - case 132: -#line 848 "src/parser.y" /* yacc.c:1648 */ + case 133: +#line 856 "src/parser.y" /* yacc.c:1646 */ { FAIL((yyloc), "May need parentheses around object key expression"); (yyval.blk) = (yyvsp[0].blk); } -#line 3494 "src/parser.c" /* yacc.c:1648 */ +#line 3530 "src/parser.c" /* yacc.c:1646 */ break; - case 133: -#line 854 "src/parser.y" /* yacc.c:1648 */ + case 134: +#line 862 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("as"); } -#line 3502 "src/parser.c" /* yacc.c:1648 */ +#line 3538 "src/parser.c" /* yacc.c:1646 */ break; - case 134: -#line 857 "src/parser.y" /* yacc.c:1648 */ + case 135: +#line 865 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("def"); } -#line 3510 "src/parser.c" /* yacc.c:1648 */ +#line 3546 "src/parser.c" /* yacc.c:1646 */ break; - case 135: -#line 860 "src/parser.y" /* yacc.c:1648 */ + case 136: +#line 868 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("module"); } -#line 3518 "src/parser.c" /* yacc.c:1648 */ +#line 3554 "src/parser.c" /* yacc.c:1646 */ break; - case 136: -#line 863 "src/parser.y" /* yacc.c:1648 */ + case 137: +#line 871 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("import"); } -#line 3526 "src/parser.c" /* yacc.c:1648 */ +#line 3562 "src/parser.c" /* yacc.c:1646 */ break; - case 137: -#line 866 "src/parser.y" /* yacc.c:1648 */ + case 138: +#line 874 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("include"); } -#line 3534 "src/parser.c" /* yacc.c:1648 */ +#line 3570 "src/parser.c" /* yacc.c:1646 */ break; - case 138: -#line 869 "src/parser.y" /* yacc.c:1648 */ + case 139: +#line 877 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("if"); } -#line 3542 "src/parser.c" /* yacc.c:1648 */ +#line 3578 "src/parser.c" /* yacc.c:1646 */ break; - case 139: -#line 872 "src/parser.y" /* yacc.c:1648 */ + case 140: +#line 880 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("then"); } -#line 3550 "src/parser.c" /* yacc.c:1648 */ +#line 3586 "src/parser.c" /* yacc.c:1646 */ break; - case 140: -#line 875 "src/parser.y" /* yacc.c:1648 */ + case 141: +#line 883 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("else"); } -#line 3558 "src/parser.c" /* yacc.c:1648 */ +#line 3594 "src/parser.c" /* yacc.c:1646 */ break; - case 141: -#line 878 "src/parser.y" /* yacc.c:1648 */ + case 142: +#line 886 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("elif"); } -#line 3566 "src/parser.c" /* yacc.c:1648 */ +#line 3602 "src/parser.c" /* yacc.c:1646 */ break; - case 142: -#line 881 "src/parser.y" /* yacc.c:1648 */ + case 143: +#line 889 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("reduce"); } -#line 3574 "src/parser.c" /* yacc.c:1648 */ +#line 3610 "src/parser.c" /* yacc.c:1646 */ break; - case 143: -#line 884 "src/parser.y" /* yacc.c:1648 */ + case 144: +#line 892 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("foreach"); } -#line 3582 "src/parser.c" /* yacc.c:1648 */ +#line 3618 "src/parser.c" /* yacc.c:1646 */ break; - case 144: -#line 887 "src/parser.y" /* yacc.c:1648 */ + case 145: +#line 895 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("end"); } -#line 3590 "src/parser.c" /* yacc.c:1648 */ +#line 3626 "src/parser.c" /* yacc.c:1646 */ break; - case 145: -#line 890 "src/parser.y" /* yacc.c:1648 */ + case 146: +#line 898 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("and"); } -#line 3598 "src/parser.c" /* yacc.c:1648 */ +#line 3634 "src/parser.c" /* yacc.c:1646 */ break; - case 146: -#line 893 "src/parser.y" /* yacc.c:1648 */ + case 147: +#line 901 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("or"); } -#line 3606 "src/parser.c" /* yacc.c:1648 */ +#line 3642 "src/parser.c" /* yacc.c:1646 */ break; - case 147: -#line 896 "src/parser.y" /* yacc.c:1648 */ + case 148: +#line 904 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("try"); } -#line 3614 "src/parser.c" /* yacc.c:1648 */ +#line 3650 "src/parser.c" /* yacc.c:1646 */ break; - case 148: -#line 899 "src/parser.y" /* yacc.c:1648 */ + case 149: +#line 907 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("catch"); } -#line 3622 "src/parser.c" /* yacc.c:1648 */ +#line 3658 "src/parser.c" /* yacc.c:1646 */ break; - case 149: -#line 902 "src/parser.y" /* yacc.c:1648 */ + case 150: +#line 910 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("label"); } -#line 3630 "src/parser.c" /* yacc.c:1648 */ +#line 3666 "src/parser.c" /* yacc.c:1646 */ break; - case 150: -#line 905 "src/parser.y" /* yacc.c:1648 */ + case 151: +#line 913 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("break"); } -#line 3638 "src/parser.c" /* yacc.c:1648 */ +#line 3674 "src/parser.c" /* yacc.c:1646 */ break; - case 151: -#line 908 "src/parser.y" /* yacc.c:1648 */ + case 152: +#line 916 "src/parser.y" /* yacc.c:1646 */ { (yyval.literal) = jv_string("__loc__"); } -#line 3646 "src/parser.c" /* yacc.c:1648 */ +#line 3682 "src/parser.c" /* yacc.c:1646 */ break; - case 152: -#line 913 "src/parser.y" /* yacc.c:1648 */ + case 153: +#line 921 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk)=gen_noop(); } -#line 3654 "src/parser.c" /* yacc.c:1648 */ +#line 3690 "src/parser.c" /* yacc.c:1646 */ break; - case 153: -#line 916 "src/parser.y" /* yacc.c:1648 */ + case 154: +#line 924 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[0].blk); } -#line 3660 "src/parser.c" /* yacc.c:1648 */ +#line 3696 "src/parser.c" /* yacc.c:1646 */ break; - case 154: -#line 917 "src/parser.y" /* yacc.c:1648 */ + case 155: +#line 925 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk)=block_join((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 3666 "src/parser.c" /* yacc.c:1648 */ +#line 3702 "src/parser.c" /* yacc.c:1646 */ break; - case 155: -#line 918 "src/parser.y" /* yacc.c:1648 */ + case 156: +#line 926 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = (yyvsp[0].blk); } -#line 3672 "src/parser.c" /* yacc.c:1648 */ +#line 3708 "src/parser.c" /* yacc.c:1646 */ break; - case 156: -#line 921 "src/parser.y" /* yacc.c:1648 */ + case 157: +#line 929 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_dictpair(gen_const((yyvsp[-2].literal)), (yyvsp[0].blk)); } -#line 3680 "src/parser.c" /* yacc.c:1648 */ +#line 3716 "src/parser.c" /* yacc.c:1646 */ break; - case 157: -#line 924 "src/parser.y" /* yacc.c:1648 */ + case 158: +#line 932 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_dictpair(gen_const((yyvsp[-2].literal)), (yyvsp[0].blk)); } -#line 3688 "src/parser.c" /* yacc.c:1648 */ +#line 3724 "src/parser.c" /* yacc.c:1646 */ break; - case 158: -#line 927 "src/parser.y" /* yacc.c:1648 */ + case 159: +#line 935 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_dictpair((yyvsp[-2].blk), (yyvsp[0].blk)); } -#line 3696 "src/parser.c" /* yacc.c:1648 */ +#line 3732 "src/parser.c" /* yacc.c:1646 */ break; - case 159: -#line 930 "src/parser.y" /* yacc.c:1648 */ + case 160: +#line 938 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_dictpair((yyvsp[0].blk), BLOCK(gen_op_simple(POP), gen_op_simple(DUP2), gen_op_simple(DUP2), gen_op_simple(INDEX))); } -#line 3705 "src/parser.c" /* yacc.c:1648 */ +#line 3741 "src/parser.c" /* yacc.c:1646 */ break; - case 160: -#line 934 "src/parser.y" /* yacc.c:1648 */ + case 161: +#line 942 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_dictpair(gen_location((yyloc), locations, gen_op_unbound(LOADV, jv_string_value((yyvsp[-2].literal)))), (yyvsp[0].blk)); } -#line 3714 "src/parser.c" /* yacc.c:1648 */ +#line 3750 "src/parser.c" /* yacc.c:1646 */ break; - case 161: -#line 938 "src/parser.y" /* yacc.c:1648 */ + case 162: +#line 946 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_dictpair(gen_const((yyvsp[0].literal)), gen_location((yyloc), locations, gen_op_unbound(LOADV, jv_string_value((yyvsp[0].literal))))); } -#line 3723 "src/parser.c" /* yacc.c:1648 */ +#line 3759 "src/parser.c" /* yacc.c:1646 */ break; - case 162: -#line 942 "src/parser.y" /* yacc.c:1648 */ + case 163: +#line 950 "src/parser.y" /* yacc.c:1646 */ + { + (yyval.blk) = gen_dictpair(gen_const((yyvsp[0].literal)), + gen_location((yyloc), locations, gen_op_unbound(LOADV, jv_string_value((yyvsp[0].literal))))); + } +#line 3768 "src/parser.c" /* yacc.c:1646 */ + break; + + case 164: +#line 954 "src/parser.y" /* yacc.c:1646 */ { (yyval.blk) = gen_dictpair(gen_const(jv_copy((yyvsp[0].literal))), gen_index(gen_noop(), gen_const((yyvsp[0].literal)))); } -#line 3732 "src/parser.c" /* yacc.c:1648 */ +#line 3777 "src/parser.c" /* yacc.c:1646 */ break; - case 163: -#line 946 "src/parser.y" /* yacc.c:1648 */ + case 165: +#line 958 "src/parser.y" /* yacc.c:1646 */ + { + (yyval.blk) = gen_dictpair(gen_const(jv_copy((yyvsp[0].literal))), + gen_index(gen_noop(), gen_const((yyvsp[0].literal)))); + } +#line 3786 "src/parser.c" /* yacc.c:1646 */ + break; + + case 166: +#line 962 "src/parser.y" /* yacc.c:1646 */ { jv msg = check_object_key((yyvsp[-3].blk)); if (jv_is_valid(msg)) { @@ -3741,20 +3795,20 @@ YYLTYPE yylloc = yyloc_default; jv_free(msg); (yyval.blk) = gen_dictpair((yyvsp[-3].blk), (yyvsp[0].blk)); } -#line 3745 "src/parser.c" /* yacc.c:1648 */ +#line 3799 "src/parser.c" /* yacc.c:1646 */ break; - case 164: -#line 954 "src/parser.y" /* yacc.c:1648 */ + case 167: +#line 970 "src/parser.y" /* yacc.c:1646 */ { FAIL((yyloc), "May need parentheses around object key expression"); (yyval.blk) = (yyvsp[0].blk); } -#line 3754 "src/parser.c" /* yacc.c:1648 */ +#line 3808 "src/parser.c" /* yacc.c:1646 */ break; -#line 3758 "src/parser.c" /* yacc.c:1648 */ +#line 3812 "src/parser.c" /* yacc.c:1646 */ default: break; } /* User semantic actions sometimes alter yychar, and that requires @@ -3877,6 +3931,7 @@ YYLTYPE yylloc = yyloc_default; if (/*CONSTCOND*/ 0) goto yyerrorlab; + yyerror_range[1] = yylsp[1-yylen]; /* Do not reclaim the symbols of the rule whose action triggered this YYERROR. */ YYPOPSTACK (yylen); @@ -3988,7 +4043,7 @@ YYLTYPE yylloc = yyloc_default; #endif return yyresult; } -#line 958 "src/parser.y" /* yacc.c:1907 */ +#line 974 "src/parser.y" /* yacc.c:1906 */ int jq_parse(struct locfile* locations, block* answer) { diff --git a/src/parser.h b/src/parser.h index e83a000a96..b15c53aad4 100644 --- a/src/parser.h +++ b/src/parser.h @@ -1,8 +1,8 @@ -/* A Bison parser, made by GNU Bison 3.0.5. */ +/* A Bison parser, made by GNU Bison 3.0.4. */ /* Bison interface for Yacc-like parsers in C - Copyright (C) 1984, 1989-1990, 2000-2015, 2018 Free Software Foundation, Inc. + Copyright (C) 1984, 1989-1990, 2000-2015 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -40,7 +40,7 @@ extern int yydebug; #endif /* "%code requires" blocks. */ -#line 11 "src/parser.y" /* yacc.c:1910 */ +#line 11 "src/parser.y" /* yacc.c:1909 */ #include "locfile.h" struct lexer_param; @@ -57,7 +57,7 @@ struct lexer_param; } \ } while (0) -#line 61 "src/parser.h" /* yacc.c:1910 */ +#line 61 "src/parser.h" /* yacc.c:1909 */ /* Token type. */ #ifndef YYTOKENTYPE @@ -163,12 +163,12 @@ struct lexer_param; union YYSTYPE { -#line 31 "src/parser.y" /* yacc.c:1910 */ +#line 31 "src/parser.y" /* yacc.c:1909 */ jv literal; block blk; -#line 172 "src/parser.h" /* yacc.c:1910 */ +#line 172 "src/parser.h" /* yacc.c:1909 */ }; typedef union YYSTYPE YYSTYPE; diff --git a/src/parser.y b/src/parser.y index 62558502f0..2fdaed2f93 100644 --- a/src/parser.y +++ b/src/parser.y @@ -576,7 +576,10 @@ Param: $$ = gen_param_regular(jv_string_value($2)); jv_free($2); } | - +'$' Keyword { + $$ = gen_param_regular(jv_string_value($2)); + jv_free($2); +} | IDENT { $$ = gen_param(jv_string_value($1)); jv_free($1); @@ -734,14 +737,19 @@ FORMAT { else $$ = BLOCK(gen_subexp(gen_const(jv_object())), $2, gen_op_simple(POP)); } | -'$' LOC { - $$ = gen_const(JV_OBJECT(jv_string("file"), jv_copy(locations->fname), - jv_string("line"), jv_number(locfile_get_line(locations, @$.start) + 1))); -} | '$' IDENT { $$ = gen_location(@$, locations, gen_op_unbound(LOADV, jv_string_value($2))); jv_free($2); } | +'$' Keyword { + if (strcmp(jv_string_value($2), "__loc__") == 0) { + $$ = gen_const(JV_OBJECT(jv_string("file"), jv_copy(locations->fname), + jv_string("line"), jv_number(locfile_get_line(locations, @$.start) + 1))); + } else { + $$ = gen_location(@$, locations, gen_op_unbound(LOADV, jv_string_value($2))); + } + jv_free($2); +} | IDENT { const char *s = jv_string_value($1); if (strcmp(s, "false") == 0) @@ -939,10 +947,18 @@ IDENT ':' ExpD { $$ = gen_dictpair(gen_const($2), gen_location(@$, locations, gen_op_unbound(LOADV, jv_string_value($2)))); } +| '$' Keyword { + $$ = gen_dictpair(gen_const($2), + gen_location(@$, locations, gen_op_unbound(LOADV, jv_string_value($2)))); + } | IDENT { $$ = gen_dictpair(gen_const(jv_copy($1)), gen_index(gen_noop(), gen_const($1))); } +| Keyword { + $$ = gen_dictpair(gen_const(jv_copy($1)), + gen_index(gen_noop(), gen_const($1))); + } | '(' Exp ')' ':' ExpD { jv msg = check_object_key($2); if (jv_is_valid(msg)) { diff --git a/tests/jq.test b/tests/jq.test index af3c1a9fec..53a462b3f6 100644 --- a/tests/jq.test +++ b/tests/jq.test @@ -1662,3 +1662,14 @@ true builtins|any(.[:1] == "_") null false + +# Test ability to use keywords +(.[] as $kw | "\"{\($kw)} as $\($kw) | $\($kw) | {$\($kw)} | {\($kw):.\($kw)}\""|eval|empty),null +["as","def","module","import","include","if","then","else","elif","end","reduce","foreach","and","or","try","catch","label","break","__loc__"] +null + +(.[] as $kw | "\"def f($\($kw)): $\($kw); f(.)\""|eval|empty),null +["as","def","module","import","include","if","then","else","elif","end","reduce","foreach","and","or","try","catch","label","break","__loc__"] +null + +