00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044 #define YYBISON 1
00045
00046
00047 #define YYBISON_VERSION "2.5"
00048
00049
00050 #define YYSKELETON_NAME "yacc.c"
00051
00052
00053 #define YYPURE 1
00054
00055
00056 #define YYPUSH 0
00057
00058
00059 #define YYPULL 1
00060
00061
00062 #define YYLSP_NEEDED 0
00063
00064
00065
00066
00067
00068
00069 #line 12 "ripper.y"
00070
00071
00072 #ifndef PARSER_DEBUG
00073 #define PARSER_DEBUG 0
00074 #endif
00075 #define YYDEBUG 1
00076 #define YYERROR_VERBOSE 1
00077 #define YYSTACK_USE_ALLOCA 0
00078
00079 #include "ruby/ruby.h"
00080 #include "ruby/st.h"
00081 #include "ruby/encoding.h"
00082 #include "internal.h"
00083 #include "node.h"
00084 #include "parse.h"
00085 #include "id.h"
00086 #include "regenc.h"
00087 #include <stdio.h>
00088 #include <errno.h>
00089 #include <ctype.h>
00090 #include "probes.h"
00091
00092 #define YYMALLOC(size) rb_parser_malloc(parser, (size))
00093 #define YYREALLOC(ptr, size) rb_parser_realloc(parser, (ptr), (size))
00094 #define YYCALLOC(nelem, size) rb_parser_calloc(parser, (nelem), (size))
00095 #define YYFREE(ptr) rb_parser_free(parser, (ptr))
00096 #define malloc YYMALLOC
00097 #define realloc YYREALLOC
00098 #define calloc YYCALLOC
00099 #define free YYFREE
00100
00101 #ifndef RIPPER
00102 static ID register_symid(ID, const char *, long, rb_encoding *);
00103 static ID register_symid_str(ID, VALUE);
00104 #define REGISTER_SYMID(id, name) register_symid((id), (name), strlen(name), enc)
00105 #include "id.c"
00106 #endif
00107
00108 #define is_notop_id(id) ((id)>tLAST_OP_ID)
00109 #define is_local_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_LOCAL)
00110 #define is_global_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_GLOBAL)
00111 #define is_instance_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_INSTANCE)
00112 #define is_attrset_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_ATTRSET)
00113 #define is_const_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_CONST)
00114 #define is_class_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_CLASS)
00115 #define is_junk_id(id) (is_notop_id(id)&&((id)&ID_SCOPE_MASK)==ID_JUNK)
00116 #define id_type(id) (is_notop_id(id) ? (int)((id)&ID_SCOPE_MASK) : -1)
00117
00118 #define is_asgn_or_id(id) ((is_notop_id(id)) && \
00119 (((id)&ID_SCOPE_MASK) == ID_GLOBAL || \
00120 ((id)&ID_SCOPE_MASK) == ID_INSTANCE || \
00121 ((id)&ID_SCOPE_MASK) == ID_CLASS))
00122
00123 enum lex_state_bits {
00124 EXPR_BEG_bit,
00125 EXPR_END_bit,
00126 EXPR_ENDARG_bit,
00127 EXPR_ENDFN_bit,
00128 EXPR_ARG_bit,
00129 EXPR_CMDARG_bit,
00130 EXPR_MID_bit,
00131 EXPR_FNAME_bit,
00132 EXPR_DOT_bit,
00133 EXPR_CLASS_bit,
00134 EXPR_VALUE_bit,
00135 EXPR_LABELARG_bit,
00136 EXPR_MAX_STATE
00137 };
00138
00139 enum lex_state_e {
00140 #define DEF_EXPR(n) EXPR_##n = (1 << EXPR_##n##_bit)
00141 DEF_EXPR(BEG),
00142 DEF_EXPR(END),
00143 DEF_EXPR(ENDARG),
00144 DEF_EXPR(ENDFN),
00145 DEF_EXPR(ARG),
00146 DEF_EXPR(CMDARG),
00147 DEF_EXPR(MID),
00148 DEF_EXPR(FNAME),
00149 DEF_EXPR(DOT),
00150 DEF_EXPR(CLASS),
00151 DEF_EXPR(VALUE),
00152 DEF_EXPR(LABELARG),
00153 EXPR_BEG_ANY = (EXPR_BEG | EXPR_VALUE | EXPR_MID | EXPR_CLASS | EXPR_LABELARG),
00154 EXPR_ARG_ANY = (EXPR_ARG | EXPR_CMDARG),
00155 EXPR_END_ANY = (EXPR_END | EXPR_ENDARG | EXPR_ENDFN)
00156 };
00157 #define IS_lex_state_for(x, ls) ((x) & (ls))
00158 #define IS_lex_state(ls) IS_lex_state_for(lex_state, (ls))
00159
00160 #if PARSER_DEBUG
00161 static const char *lex_state_name(enum lex_state_e state);
00162 #endif
00163
00164 typedef VALUE stack_type;
00165
00166 # define BITSTACK_PUSH(stack, n) ((stack) = ((stack)<<1)|((n)&1))
00167 # define BITSTACK_POP(stack) ((stack) = (stack) >> 1)
00168 # define BITSTACK_LEXPOP(stack) ((stack) = ((stack) >> 1) | ((stack) & 1))
00169 # define BITSTACK_SET_P(stack) ((stack)&1)
00170
00171 #define COND_PUSH(n) BITSTACK_PUSH(cond_stack, (n))
00172 #define COND_POP() BITSTACK_POP(cond_stack)
00173 #define COND_LEXPOP() BITSTACK_LEXPOP(cond_stack)
00174 #define COND_P() BITSTACK_SET_P(cond_stack)
00175
00176 #define CMDARG_PUSH(n) BITSTACK_PUSH(cmdarg_stack, (n))
00177 #define CMDARG_POP() BITSTACK_POP(cmdarg_stack)
00178 #define CMDARG_LEXPOP() BITSTACK_LEXPOP(cmdarg_stack)
00179 #define CMDARG_P() BITSTACK_SET_P(cmdarg_stack)
00180
00181 struct vtable {
00182 ID *tbl;
00183 int pos;
00184 int capa;
00185 struct vtable *prev;
00186 };
00187
00188 struct local_vars {
00189 struct vtable *args;
00190 struct vtable *vars;
00191 struct vtable *used;
00192 struct local_vars *prev;
00193 stack_type cmdargs;
00194 };
00195
00196 #define DVARS_INHERIT ((void*)1)
00197 #define DVARS_TOPSCOPE NULL
00198 #define DVARS_SPECIAL_P(tbl) (!POINTER_P(tbl))
00199 #define POINTER_P(val) ((VALUE)(val) & ~(VALUE)3)
00200
00201 static int
00202 vtable_size(const struct vtable *tbl)
00203 {
00204 if (POINTER_P(tbl)) {
00205 return tbl->pos;
00206 }
00207 else {
00208 return 0;
00209 }
00210 }
00211
00212 #define VTBL_DEBUG 0
00213
00214 static struct vtable *
00215 vtable_alloc(struct vtable *prev)
00216 {
00217 struct vtable *tbl = ALLOC(struct vtable);
00218 tbl->pos = 0;
00219 tbl->capa = 8;
00220 tbl->tbl = ALLOC_N(ID, tbl->capa);
00221 tbl->prev = prev;
00222 if (VTBL_DEBUG) printf("vtable_alloc: %p\n", (void *)tbl);
00223 return tbl;
00224 }
00225
00226 static void
00227 vtable_free(struct vtable *tbl)
00228 {
00229 if (VTBL_DEBUG)printf("vtable_free: %p\n", (void *)tbl);
00230 if (POINTER_P(tbl)) {
00231 if (tbl->tbl) {
00232 xfree(tbl->tbl);
00233 }
00234 xfree(tbl);
00235 }
00236 }
00237
00238 static void
00239 vtable_add(struct vtable *tbl, ID id)
00240 {
00241 if (!POINTER_P(tbl)) {
00242 rb_bug("vtable_add: vtable is not allocated (%p)", (void *)tbl);
00243 }
00244 if (VTBL_DEBUG) printf("vtable_add: %p, %s\n", (void *)tbl, rb_id2name(id));
00245
00246 if (tbl->pos == tbl->capa) {
00247 tbl->capa = tbl->capa * 2;
00248 REALLOC_N(tbl->tbl, ID, tbl->capa);
00249 }
00250 tbl->tbl[tbl->pos++] = id;
00251 }
00252
00253 static int
00254 vtable_included(const struct vtable * tbl, ID id)
00255 {
00256 int i;
00257
00258 if (POINTER_P(tbl)) {
00259 for (i = 0; i < tbl->pos; i++) {
00260 if (tbl->tbl[i] == id) {
00261 return i+1;
00262 }
00263 }
00264 }
00265 return 0;
00266 }
00267
00268
00269 #ifndef RIPPER
00270 typedef struct token_info {
00271 const char *token;
00272 int linenum;
00273 int column;
00274 int nonspc;
00275 struct token_info *next;
00276 } token_info;
00277 #endif
00278
00279
00280
00281
00282
00283
00284
00285
00286
00287
00288 struct parser_params {
00289 int is_ripper;
00290 NODE *heap;
00291
00292 YYSTYPE *parser_yylval;
00293 VALUE eofp;
00294
00295 NODE *parser_lex_strterm;
00296 enum lex_state_e parser_lex_state;
00297 stack_type parser_cond_stack;
00298 stack_type parser_cmdarg_stack;
00299 int parser_class_nest;
00300 int parser_paren_nest;
00301 int parser_lpar_beg;
00302 int parser_in_single;
00303 int parser_in_def;
00304 int parser_brace_nest;
00305 int parser_compile_for_eval;
00306 VALUE parser_cur_mid;
00307 int parser_in_kwarg;
00308 int parser_in_defined;
00309 char *parser_tokenbuf;
00310 int parser_tokidx;
00311 int parser_toksiz;
00312 int parser_tokline;
00313 VALUE parser_lex_input;
00314 VALUE parser_lex_lastline;
00315 VALUE parser_lex_nextline;
00316 const char *parser_lex_pbeg;
00317 const char *parser_lex_p;
00318 const char *parser_lex_pend;
00319 int parser_heredoc_end;
00320 int parser_command_start;
00321 NODE *parser_deferred_nodes;
00322 long parser_lex_gets_ptr;
00323 VALUE (*parser_lex_gets)(struct parser_params*,VALUE);
00324 struct local_vars *parser_lvtbl;
00325 int parser_ruby__end__seen;
00326 int line_count;
00327 int has_shebang;
00328 char *parser_ruby_sourcefile;
00329 int parser_ruby_sourceline;
00330 VALUE parser_ruby_sourcefile_string;
00331 rb_encoding *enc;
00332
00333 int parser_yydebug;
00334
00335 int last_cr_line;
00336
00337 #ifndef RIPPER
00338
00339 NODE *parser_eval_tree_begin;
00340 NODE *parser_eval_tree;
00341 VALUE debug_lines;
00342 VALUE coverage;
00343 int nerr;
00344
00345 int parser_token_info_enabled;
00346 token_info *parser_token_info;
00347 #else
00348
00349 const char *tokp;
00350 VALUE delayed;
00351 int delayed_line;
00352 int delayed_col;
00353
00354 VALUE value;
00355 VALUE result;
00356 VALUE parsing_thread;
00357 int toplevel_p;
00358 #endif
00359 };
00360
00361 #define STR_NEW(p,n) rb_enc_str_new((p),(n),current_enc)
00362 #define STR_NEW0() rb_enc_str_new(0,0,current_enc)
00363 #define STR_NEW2(p) rb_enc_str_new((p),strlen(p),current_enc)
00364 #define STR_NEW3(p,n,e,func) parser_str_new((p),(n),(e),(func),current_enc)
00365 #define ENC_SINGLE(cr) ((cr)==ENC_CODERANGE_7BIT)
00366 #define TOK_INTERN(mb) rb_intern3(tok(), toklen(), current_enc)
00367
00368 static int parser_yyerror(struct parser_params*, const char*);
00369 #define yyerror(msg) parser_yyerror(parser, (msg))
00370
00371 #define lex_strterm (parser->parser_lex_strterm)
00372 #define lex_state (parser->parser_lex_state)
00373 #define cond_stack (parser->parser_cond_stack)
00374 #define cmdarg_stack (parser->parser_cmdarg_stack)
00375 #define class_nest (parser->parser_class_nest)
00376 #define paren_nest (parser->parser_paren_nest)
00377 #define lpar_beg (parser->parser_lpar_beg)
00378 #define brace_nest (parser->parser_brace_nest)
00379 #define in_single (parser->parser_in_single)
00380 #define in_def (parser->parser_in_def)
00381 #define compile_for_eval (parser->parser_compile_for_eval)
00382 #define cur_mid (parser->parser_cur_mid)
00383 #define in_defined (parser->parser_in_defined)
00384 #define tokenbuf (parser->parser_tokenbuf)
00385 #define tokidx (parser->parser_tokidx)
00386 #define toksiz (parser->parser_toksiz)
00387 #define tokline (parser->parser_tokline)
00388 #define lex_input (parser->parser_lex_input)
00389 #define lex_lastline (parser->parser_lex_lastline)
00390 #define lex_nextline (parser->parser_lex_nextline)
00391 #define lex_pbeg (parser->parser_lex_pbeg)
00392 #define lex_p (parser->parser_lex_p)
00393 #define lex_pend (parser->parser_lex_pend)
00394 #define heredoc_end (parser->parser_heredoc_end)
00395 #define command_start (parser->parser_command_start)
00396 #define deferred_nodes (parser->parser_deferred_nodes)
00397 #define lex_gets_ptr (parser->parser_lex_gets_ptr)
00398 #define lex_gets (parser->parser_lex_gets)
00399 #define lvtbl (parser->parser_lvtbl)
00400 #define ruby__end__seen (parser->parser_ruby__end__seen)
00401 #define ruby_sourceline (parser->parser_ruby_sourceline)
00402 #define ruby_sourcefile (parser->parser_ruby_sourcefile)
00403 #define ruby_sourcefile_string (parser->parser_ruby_sourcefile_string)
00404 #define current_enc (parser->enc)
00405 #define yydebug (parser->parser_yydebug)
00406 #ifdef RIPPER
00407 #else
00408 #define ruby_eval_tree (parser->parser_eval_tree)
00409 #define ruby_eval_tree_begin (parser->parser_eval_tree_begin)
00410 #define ruby_debug_lines (parser->debug_lines)
00411 #define ruby_coverage (parser->coverage)
00412 #endif
00413
00414 #if YYPURE
00415 static int yylex(void*, void*);
00416 #else
00417 static int yylex(void*);
00418 #endif
00419
00420 #ifndef RIPPER
00421 #define yyparse ruby_yyparse
00422
00423 static NODE* node_newnode(struct parser_params *, enum node_type, VALUE, VALUE, VALUE);
00424 #define rb_node_newnode(type, a1, a2, a3) node_newnode(parser, (type), (a1), (a2), (a3))
00425
00426 static NODE *cond_gen(struct parser_params*,NODE*);
00427 #define cond(node) cond_gen(parser, (node))
00428 static NODE *logop_gen(struct parser_params*,enum node_type,NODE*,NODE*);
00429 #define logop(type,node1,node2) logop_gen(parser, (type), (node1), (node2))
00430
00431 static NODE *newline_node(NODE*);
00432 static void fixpos(NODE*,NODE*);
00433
00434 static int value_expr_gen(struct parser_params*,NODE*);
00435 static void void_expr_gen(struct parser_params*,NODE*);
00436 static NODE *remove_begin(NODE*);
00437 static NODE *remove_begin_all(NODE*);
00438 #define value_expr(node) value_expr_gen(parser, (node) = remove_begin(node))
00439 #define void_expr0(node) void_expr_gen(parser, (node))
00440 #define void_expr(node) void_expr0((node) = remove_begin(node))
00441 static void void_stmts_gen(struct parser_params*,NODE*);
00442 #define void_stmts(node) void_stmts_gen(parser, (node))
00443 static void reduce_nodes_gen(struct parser_params*,NODE**);
00444 #define reduce_nodes(n) reduce_nodes_gen(parser,(n))
00445 static void block_dup_check_gen(struct parser_params*,NODE*,NODE*);
00446 #define block_dup_check(n1,n2) block_dup_check_gen(parser,(n1),(n2))
00447
00448 static NODE *block_append_gen(struct parser_params*,NODE*,NODE*);
00449 #define block_append(h,t) block_append_gen(parser,(h),(t))
00450 static NODE *list_append_gen(struct parser_params*,NODE*,NODE*);
00451 #define list_append(l,i) list_append_gen(parser,(l),(i))
00452 static NODE *list_concat_gen(struct parser_params*,NODE*,NODE*);
00453 #define list_concat(h,t) list_concat_gen(parser,(h),(t))
00454 static NODE *arg_append_gen(struct parser_params*,NODE*,NODE*);
00455 #define arg_append(h,t) arg_append_gen(parser,(h),(t))
00456 static NODE *arg_concat_gen(struct parser_params*,NODE*,NODE*);
00457 #define arg_concat(h,t) arg_concat_gen(parser,(h),(t))
00458 static NODE *literal_concat_gen(struct parser_params*,NODE*,NODE*);
00459 #define literal_concat(h,t) literal_concat_gen(parser,(h),(t))
00460 static int literal_concat0(struct parser_params *, VALUE, VALUE);
00461 static NODE *new_evstr_gen(struct parser_params*,NODE*);
00462 #define new_evstr(n) new_evstr_gen(parser,(n))
00463 static NODE *evstr2dstr_gen(struct parser_params*,NODE*);
00464 #define evstr2dstr(n) evstr2dstr_gen(parser,(n))
00465 static NODE *splat_array(NODE*);
00466
00467 static NODE *call_bin_op_gen(struct parser_params*,NODE*,ID,NODE*);
00468 #define call_bin_op(recv,id,arg1) call_bin_op_gen(parser, (recv),(id),(arg1))
00469 static NODE *call_uni_op_gen(struct parser_params*,NODE*,ID);
00470 #define call_uni_op(recv,id) call_uni_op_gen(parser, (recv),(id))
00471
00472 static NODE *new_args_gen(struct parser_params*,NODE*,NODE*,ID,NODE*,NODE*);
00473 #define new_args(f,o,r,p,t) new_args_gen(parser, (f),(o),(r),(p),(t))
00474 static NODE *new_args_tail_gen(struct parser_params*,NODE*,ID,ID);
00475 #define new_args_tail(k,kr,b) new_args_tail_gen(parser, (k),(kr),(b))
00476
00477 static NODE *negate_lit(NODE*);
00478 static NODE *ret_args_gen(struct parser_params*,NODE*);
00479 #define ret_args(node) ret_args_gen(parser, (node))
00480 static NODE *arg_blk_pass(NODE*,NODE*);
00481 static NODE *new_yield_gen(struct parser_params*,NODE*);
00482 #define new_yield(node) new_yield_gen(parser, (node))
00483 static NODE *dsym_node_gen(struct parser_params*,NODE*);
00484 #define dsym_node(node) dsym_node_gen(parser, (node))
00485
00486 static NODE *gettable_gen(struct parser_params*,ID);
00487 #define gettable(id) gettable_gen(parser,(id))
00488 static NODE *assignable_gen(struct parser_params*,ID,NODE*);
00489 #define assignable(id,node) assignable_gen(parser, (id), (node))
00490
00491 static NODE *aryset_gen(struct parser_params*,NODE*,NODE*);
00492 #define aryset(node1,node2) aryset_gen(parser, (node1), (node2))
00493 static NODE *attrset_gen(struct parser_params*,NODE*,ID);
00494 #define attrset(node,id) attrset_gen(parser, (node), (id))
00495
00496 static void rb_backref_error_gen(struct parser_params*,NODE*);
00497 #define rb_backref_error(n) rb_backref_error_gen(parser,(n))
00498 static NODE *node_assign_gen(struct parser_params*,NODE*,NODE*);
00499 #define node_assign(node1, node2) node_assign_gen(parser, (node1), (node2))
00500
00501 static NODE *new_op_assign_gen(struct parser_params *parser, NODE *lhs, ID op, NODE *rhs);
00502 static NODE *new_attr_op_assign_gen(struct parser_params *parser, NODE *lhs, ID attr, ID op, NODE *rhs);
00503 #define new_attr_op_assign(lhs, type, attr, op, rhs) new_attr_op_assign_gen(parser, (lhs), (attr), (op), (rhs))
00504 static NODE *new_const_op_assign_gen(struct parser_params *parser, NODE *lhs, ID op, NODE *rhs);
00505 #define new_const_op_assign(lhs, op, rhs) new_const_op_assign_gen(parser, (lhs), (op), (rhs))
00506
00507 #define new_defined(expr) NEW_DEFINED(remove_begin_all(expr))
00508
00509 static NODE *match_op_gen(struct parser_params*,NODE*,NODE*);
00510 #define match_op(node1,node2) match_op_gen(parser, (node1), (node2))
00511
00512 static ID *local_tbl_gen(struct parser_params*);
00513 #define local_tbl() local_tbl_gen(parser)
00514
00515 static void fixup_nodes(NODE **);
00516
00517 static VALUE reg_compile_gen(struct parser_params*, VALUE, int);
00518 #define reg_compile(str,options) reg_compile_gen(parser, (str), (options))
00519 static void reg_fragment_setenc_gen(struct parser_params*, VALUE, int);
00520 #define reg_fragment_setenc(str,options) reg_fragment_setenc_gen(parser, (str), (options))
00521 static int reg_fragment_check_gen(struct parser_params*, VALUE, int);
00522 #define reg_fragment_check(str,options) reg_fragment_check_gen(parser, (str), (options))
00523 static NODE *reg_named_capture_assign_gen(struct parser_params* parser, VALUE regexp, NODE *match);
00524 #define reg_named_capture_assign(regexp,match) reg_named_capture_assign_gen(parser,(regexp),(match))
00525
00526 #define get_id(id) (id)
00527 #define get_value(val) (val)
00528 #else
00529 #define value_expr(node) ((void)(node))
00530 #define remove_begin(node) (node)
00531 #define rb_dvar_defined(id) 0
00532 #define rb_local_defined(id) 0
00533 static ID ripper_get_id(VALUE);
00534 #define get_id(id) ripper_get_id(id)
00535 static VALUE ripper_get_value(VALUE);
00536 #define get_value(val) ripper_get_value(val)
00537 static VALUE assignable_gen(struct parser_params*,VALUE);
00538 #define assignable(lhs,node) assignable_gen(parser, (lhs))
00539 static int id_is_var_gen(struct parser_params *parser, ID id);
00540 #define id_is_var(id) id_is_var_gen(parser, (id))
00541
00542 #define node_assign(node1, node2) dispatch2(assign, (node1), (node2))
00543
00544 static VALUE new_op_assign_gen(struct parser_params *parser, VALUE lhs, VALUE op, VALUE rhs);
00545 static VALUE new_attr_op_assign_gen(struct parser_params *parser, VALUE lhs, VALUE type, VALUE attr, VALUE op, VALUE rhs);
00546 #define new_attr_op_assign(lhs, type, attr, op, rhs) new_attr_op_assign_gen(parser, (lhs), (type), (attr), (op), (rhs))
00547
00548 #endif
00549
00550 #define new_op_assign(lhs, op, rhs) new_op_assign_gen(parser, (lhs), (op), (rhs))
00551
00552 static ID formal_argument_gen(struct parser_params*, ID);
00553 #define formal_argument(id) formal_argument_gen(parser, (id))
00554 static ID shadowing_lvar_gen(struct parser_params*,ID);
00555 #define shadowing_lvar(name) shadowing_lvar_gen(parser, (name))
00556 static void new_bv_gen(struct parser_params*,ID);
00557 #define new_bv(id) new_bv_gen(parser, (id))
00558
00559 static void local_push_gen(struct parser_params*,int);
00560 #define local_push(top) local_push_gen(parser,(top))
00561 static void local_pop_gen(struct parser_params*);
00562 #define local_pop() local_pop_gen(parser)
00563 static int local_var_gen(struct parser_params*, ID);
00564 #define local_var(id) local_var_gen(parser, (id))
00565 static int arg_var_gen(struct parser_params*, ID);
00566 #define arg_var(id) arg_var_gen(parser, (id))
00567 static int local_id_gen(struct parser_params*, ID);
00568 #define local_id(id) local_id_gen(parser, (id))
00569 static ID internal_id_gen(struct parser_params*);
00570 #define internal_id() internal_id_gen(parser)
00571
00572 static const struct vtable *dyna_push_gen(struct parser_params *);
00573 #define dyna_push() dyna_push_gen(parser)
00574 static void dyna_pop_gen(struct parser_params*, const struct vtable *);
00575 #define dyna_pop(node) dyna_pop_gen(parser, (node))
00576 static int dyna_in_block_gen(struct parser_params*);
00577 #define dyna_in_block() dyna_in_block_gen(parser)
00578 #define dyna_var(id) local_var(id)
00579 static int dvar_defined_gen(struct parser_params*,ID,int);
00580 #define dvar_defined(id) dvar_defined_gen(parser, (id), 0)
00581 #define dvar_defined_get(id) dvar_defined_gen(parser, (id), 1)
00582 static int dvar_curr_gen(struct parser_params*,ID);
00583 #define dvar_curr(id) dvar_curr_gen(parser, (id))
00584
00585 static int lvar_defined_gen(struct parser_params*, ID);
00586 #define lvar_defined(id) lvar_defined_gen(parser, (id))
00587
00588 #define RE_OPTION_ONCE (1<<16)
00589 #define RE_OPTION_ENCODING_SHIFT 8
00590 #define RE_OPTION_ENCODING(e) (((e)&0xff)<<RE_OPTION_ENCODING_SHIFT)
00591 #define RE_OPTION_ENCODING_IDX(o) (((o)>>RE_OPTION_ENCODING_SHIFT)&0xff)
00592 #define RE_OPTION_ENCODING_NONE(o) ((o)&RE_OPTION_ARG_ENCODING_NONE)
00593 #define RE_OPTION_MASK 0xff
00594 #define RE_OPTION_ARG_ENCODING_NONE 32
00595
00596 #define NODE_STRTERM NODE_ZARRAY
00597 #define NODE_HEREDOC NODE_ARRAY
00598 #define SIGN_EXTEND(x,n) (((1<<(n)-1)^((x)&~(~0<<(n))))-(1<<(n)-1))
00599 #define nd_func u1.id
00600 #if SIZEOF_SHORT == 2
00601 #define nd_term(node) ((signed short)(node)->u2.id)
00602 #else
00603 #define nd_term(node) SIGN_EXTEND((node)->u2.id, CHAR_BIT*2)
00604 #endif
00605 #define nd_paren(node) (char)((node)->u2.id >> CHAR_BIT*2)
00606 #define nd_nest u3.cnt
00607
00608
00609
00610 #ifdef RIPPER
00611 #define RIPPER_VERSION "0.1.0"
00612
00613 #include "eventids1.c"
00614 #include "eventids2.c"
00615
00616 static VALUE ripper_dispatch0(struct parser_params*,ID);
00617 static VALUE ripper_dispatch1(struct parser_params*,ID,VALUE);
00618 static VALUE ripper_dispatch2(struct parser_params*,ID,VALUE,VALUE);
00619 static VALUE ripper_dispatch3(struct parser_params*,ID,VALUE,VALUE,VALUE);
00620 static VALUE ripper_dispatch4(struct parser_params*,ID,VALUE,VALUE,VALUE,VALUE);
00621 static VALUE ripper_dispatch5(struct parser_params*,ID,VALUE,VALUE,VALUE,VALUE,VALUE);
00622 static VALUE ripper_dispatch7(struct parser_params*,ID,VALUE,VALUE,VALUE,VALUE,VALUE,VALUE,VALUE);
00623
00624 #define dispatch0(n) ripper_dispatch0(parser, TOKEN_PASTE(ripper_id_, n))
00625 #define dispatch1(n,a) ripper_dispatch1(parser, TOKEN_PASTE(ripper_id_, n), (a))
00626 #define dispatch2(n,a,b) ripper_dispatch2(parser, TOKEN_PASTE(ripper_id_, n), (a), (b))
00627 #define dispatch3(n,a,b,c) ripper_dispatch3(parser, TOKEN_PASTE(ripper_id_, n), (a), (b), (c))
00628 #define dispatch4(n,a,b,c,d) ripper_dispatch4(parser, TOKEN_PASTE(ripper_id_, n), (a), (b), (c), (d))
00629 #define dispatch5(n,a,b,c,d,e) ripper_dispatch5(parser, TOKEN_PASTE(ripper_id_, n), (a), (b), (c), (d), (e))
00630 #define dispatch7(n,a,b,c,d,e,f,g) ripper_dispatch7(parser, TOKEN_PASTE(ripper_id_, n), (a), (b), (c), (d), (e), (f), (g))
00631
00632 #define yyparse ripper_yyparse
00633
00634 #define ripper_intern(s) ID2SYM(rb_intern(s))
00635 static VALUE ripper_id2sym(ID);
00636 #ifdef __GNUC__
00637 #define ripper_id2sym(id) ((id) < 256 && rb_ispunct(id) ? \
00638 ID2SYM(id) : ripper_id2sym(id))
00639 #endif
00640
00641 #define arg_new() dispatch0(args_new)
00642 #define arg_add(l,a) dispatch2(args_add, (l), (a))
00643 #define arg_add_star(l,a) dispatch2(args_add_star, (l), (a))
00644 #define arg_add_block(l,b) dispatch2(args_add_block, (l), (b))
00645 #define arg_add_optblock(l,b) ((b)==Qundef? (l) : dispatch2(args_add_block, (l), (b)))
00646 #define bare_assoc(v) dispatch1(bare_assoc_hash, (v))
00647 #define arg_add_assocs(l,b) arg_add((l), bare_assoc(b))
00648
00649 #define args2mrhs(a) dispatch1(mrhs_new_from_args, (a))
00650 #define mrhs_new() dispatch0(mrhs_new)
00651 #define mrhs_add(l,a) dispatch2(mrhs_add, (l), (a))
00652 #define mrhs_add_star(l,a) dispatch2(mrhs_add_star, (l), (a))
00653
00654 #define mlhs_new() dispatch0(mlhs_new)
00655 #define mlhs_add(l,a) dispatch2(mlhs_add, (l), (a))
00656 #define mlhs_add_star(l,a) dispatch2(mlhs_add_star, (l), (a))
00657
00658 #define params_new(pars, opts, rest, pars2, kws, kwrest, blk) \
00659 dispatch7(params, (pars), (opts), (rest), (pars2), (kws), (kwrest), (blk))
00660
00661 #define blockvar_new(p,v) dispatch2(block_var, (p), (v))
00662 #define blockvar_add_star(l,a) dispatch2(block_var_add_star, (l), (a))
00663 #define blockvar_add_block(l,a) dispatch2(block_var_add_block, (l), (a))
00664
00665 #define method_optarg(m,a) ((a)==Qundef ? (m) : dispatch2(method_add_arg,(m),(a)))
00666 #define method_arg(m,a) dispatch2(method_add_arg,(m),(a))
00667 #define method_add_block(m,b) dispatch2(method_add_block, (m), (b))
00668
00669 #define escape_Qundef(x) ((x)==Qundef ? Qnil : (x))
00670
00671 static inline VALUE
00672 new_args_gen(struct parser_params *parser, VALUE f, VALUE o, VALUE r, VALUE p, VALUE tail)
00673 {
00674 NODE *t = (NODE *)tail;
00675 VALUE k = t->u1.value, kr = t->u2.value, b = t->u3.value;
00676 return params_new(f, o, r, p, k, kr, escape_Qundef(b));
00677 }
00678 #define new_args(f,o,r,p,t) new_args_gen(parser, (f),(o),(r),(p),(t))
00679
00680 static inline VALUE
00681 new_args_tail_gen(struct parser_params *parser, VALUE k, VALUE kr, VALUE b)
00682 {
00683 return (VALUE)rb_node_newnode(NODE_MEMO, k, kr, b);
00684 }
00685 #define new_args_tail(k,kr,b) new_args_tail_gen(parser, (k),(kr),(b))
00686
00687 #define new_defined(expr) dispatch1(defined, (expr))
00688
00689 #define FIXME 0
00690
00691 #endif
00692
00693 #ifndef RIPPER
00694 # define Qnone 0
00695 # define ifndef_ripper(x) (x)
00696 #else
00697 # define Qnone Qnil
00698 # define ifndef_ripper(x)
00699 #endif
00700
00701 #ifndef RIPPER
00702 # define rb_warn0(fmt) rb_compile_warn(ruby_sourcefile, ruby_sourceline, (fmt))
00703 # define rb_warnI(fmt,a) rb_compile_warn(ruby_sourcefile, ruby_sourceline, (fmt), (a))
00704 # define rb_warnS(fmt,a) rb_compile_warn(ruby_sourcefile, ruby_sourceline, (fmt), (a))
00705 # define rb_warn4S(file,line,fmt,a) rb_compile_warn((file), (line), (fmt), (a))
00706 # define rb_warning0(fmt) rb_compile_warning(ruby_sourcefile, ruby_sourceline, (fmt))
00707 # define rb_warningS(fmt,a) rb_compile_warning(ruby_sourcefile, ruby_sourceline, (fmt), (a))
00708 #else
00709 # define rb_warn0(fmt) ripper_warn0(parser, (fmt))
00710 # define rb_warnI(fmt,a) ripper_warnI(parser, (fmt), (a))
00711 # define rb_warnS(fmt,a) ripper_warnS(parser, (fmt), (a))
00712 # define rb_warn4S(file,line,fmt,a) ripper_warnS(parser, (fmt), (a))
00713 # define rb_warning0(fmt) ripper_warning0(parser, (fmt))
00714 # define rb_warningS(fmt,a) ripper_warningS(parser, (fmt), (a))
00715 static void ripper_warn0(struct parser_params*, const char*);
00716 static void ripper_warnI(struct parser_params*, const char*, int);
00717 static void ripper_warnS(struct parser_params*, const char*, const char*);
00718 static void ripper_warning0(struct parser_params*, const char*);
00719 static void ripper_warningS(struct parser_params*, const char*, const char*);
00720 #endif
00721
00722 #ifdef RIPPER
00723 static void ripper_compile_error(struct parser_params*, const char *fmt, ...);
00724 # define rb_compile_error ripper_compile_error
00725 # define compile_error ripper_compile_error
00726 # define PARSER_ARG parser,
00727 #else
00728 # define rb_compile_error rb_compile_error_with_enc
00729 # define compile_error parser->nerr++,rb_compile_error_with_enc
00730 # define PARSER_ARG ruby_sourcefile, ruby_sourceline, current_enc,
00731 #endif
00732
00733
00734
00735
00736 #ifdef OLD_YACC
00737 #ifndef YYMAXDEPTH
00738 #define YYMAXDEPTH 10000
00739 #endif
00740 #endif
00741
00742 #ifndef RIPPER
00743 static void token_info_push(struct parser_params*, const char *token);
00744 static void token_info_pop(struct parser_params*, const char *token);
00745 #define token_info_push(token) (RTEST(ruby_verbose) ? token_info_push(parser, (token)) : (void)0)
00746 #define token_info_pop(token) (RTEST(ruby_verbose) ? token_info_pop(parser, (token)) : (void)0)
00747 #else
00748 #define token_info_push(token)
00749 #define token_info_pop(token)
00750 #endif
00751
00752
00753
00754 #line 755 "parse.c"
00755
00756
00757 #ifndef YYDEBUG
00758 # define YYDEBUG 1
00759 #endif
00760
00761
00762 #ifdef YYERROR_VERBOSE
00763 # undef YYERROR_VERBOSE
00764 # define YYERROR_VERBOSE 1
00765 #else
00766 # define YYERROR_VERBOSE 0
00767 #endif
00768
00769
00770 #ifndef YYTOKEN_TABLE
00771 # define YYTOKEN_TABLE 0
00772 #endif
00773
00774
00775
00776 #ifndef YYTOKENTYPE
00777 # define YYTOKENTYPE
00778
00779
00780 enum yytokentype {
00781 END_OF_INPUT = 0,
00782 keyword_class = 258,
00783 keyword_module = 259,
00784 keyword_def = 260,
00785 keyword_undef = 261,
00786 keyword_begin = 262,
00787 keyword_rescue = 263,
00788 keyword_ensure = 264,
00789 keyword_end = 265,
00790 keyword_if = 266,
00791 keyword_unless = 267,
00792 keyword_then = 268,
00793 keyword_elsif = 269,
00794 keyword_else = 270,
00795 keyword_case = 271,
00796 keyword_when = 272,
00797 keyword_while = 273,
00798 keyword_until = 274,
00799 keyword_for = 275,
00800 keyword_break = 276,
00801 keyword_next = 277,
00802 keyword_redo = 278,
00803 keyword_retry = 279,
00804 keyword_in = 280,
00805 keyword_do = 281,
00806 keyword_do_cond = 282,
00807 keyword_do_block = 283,
00808 keyword_do_LAMBDA = 284,
00809 keyword_return = 285,
00810 keyword_yield = 286,
00811 keyword_super = 287,
00812 keyword_self = 288,
00813 keyword_nil = 289,
00814 keyword_true = 290,
00815 keyword_false = 291,
00816 keyword_and = 292,
00817 keyword_or = 293,
00818 keyword_not = 294,
00819 modifier_if = 295,
00820 modifier_unless = 296,
00821 modifier_while = 297,
00822 modifier_until = 298,
00823 modifier_rescue = 299,
00824 keyword_alias = 300,
00825 keyword_defined = 301,
00826 keyword_BEGIN = 302,
00827 keyword_END = 303,
00828 keyword__LINE__ = 304,
00829 keyword__FILE__ = 305,
00830 keyword__ENCODING__ = 306,
00831 tIDENTIFIER = 307,
00832 tFID = 308,
00833 tGVAR = 309,
00834 tIVAR = 310,
00835 tCONSTANT = 311,
00836 tCVAR = 312,
00837 tLABEL = 313,
00838 tINTEGER = 314,
00839 tFLOAT = 315,
00840 tRATIONAL = 316,
00841 tIMAGINARY = 317,
00842 tSTRING_CONTENT = 318,
00843 tCHAR = 319,
00844 tNTH_REF = 320,
00845 tBACK_REF = 321,
00846 tREGEXP_END = 322,
00847 tUPLUS = 130,
00848 tUMINUS = 131,
00849 tPOW = 132,
00850 tCMP = 134,
00851 tEQ = 139,
00852 tEQQ = 140,
00853 tNEQ = 141,
00854 tGEQ = 138,
00855 tLEQ = 137,
00856 tANDOP = 323,
00857 tOROP = 324,
00858 tMATCH = 142,
00859 tNMATCH = 143,
00860 tDOT2 = 128,
00861 tDOT3 = 129,
00862 tAREF = 144,
00863 tASET = 145,
00864 tLSHFT = 135,
00865 tRSHFT = 136,
00866 tCOLON2 = 325,
00867 tCOLON3 = 326,
00868 tOP_ASGN = 327,
00869 tASSOC = 328,
00870 tLPAREN = 329,
00871 tLPAREN_ARG = 330,
00872 tRPAREN = 331,
00873 tLBRACK = 332,
00874 tLBRACE = 333,
00875 tLBRACE_ARG = 334,
00876 tSTAR = 335,
00877 tDSTAR = 336,
00878 tAMPER = 337,
00879 tLAMBDA = 338,
00880 tSYMBEG = 339,
00881 tSTRING_BEG = 340,
00882 tXSTRING_BEG = 341,
00883 tREGEXP_BEG = 342,
00884 tWORDS_BEG = 343,
00885 tQWORDS_BEG = 344,
00886 tSYMBOLS_BEG = 345,
00887 tQSYMBOLS_BEG = 346,
00888 tSTRING_DBEG = 347,
00889 tSTRING_DEND = 348,
00890 tSTRING_DVAR = 349,
00891 tSTRING_END = 350,
00892 tLAMBEG = 351,
00893 tLOWEST = 352,
00894 tUMINUS_NUM = 353,
00895 tLAST_TOKEN = 354
00896 };
00897 #endif
00898
00899
00900
00901 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
00902 typedef union YYSTYPE
00903 {
00904
00905
00906 #line 699 "ripper.y"
00907
00908 VALUE val;
00909 NODE *node;
00910 ID id;
00911 int num;
00912 const struct vtable *vars;
00913
00914
00915
00916
00917 #line 918 "parse.c"
00918 } YYSTYPE;
00919 # define YYSTYPE_IS_TRIVIAL 1
00920 # define yystype YYSTYPE
00921 # define YYSTYPE_IS_DECLARED 1
00922 #endif
00923
00924
00925
00926
00927
00928
00929 #line 930 "parse.c"
00930
00931 #ifdef short
00932 # undef short
00933 #endif
00934
00935 #ifdef YYTYPE_UINT8
00936 typedef YYTYPE_UINT8 yytype_uint8;
00937 #else
00938 typedef unsigned char yytype_uint8;
00939 #endif
00940
00941 #ifdef YYTYPE_INT8
00942 typedef YYTYPE_INT8 yytype_int8;
00943 #elif (defined __STDC__ || defined __C99__FUNC__ \
00944 || defined __cplusplus || defined _MSC_VER)
00945 typedef signed char yytype_int8;
00946 #else
00947 typedef short int yytype_int8;
00948 #endif
00949
00950 #ifdef YYTYPE_UINT16
00951 typedef YYTYPE_UINT16 yytype_uint16;
00952 #else
00953 typedef unsigned short int yytype_uint16;
00954 #endif
00955
00956 #ifdef YYTYPE_INT16
00957 typedef YYTYPE_INT16 yytype_int16;
00958 #else
00959 typedef short int yytype_int16;
00960 #endif
00961
00962 #ifndef YYSIZE_T
00963 # ifdef __SIZE_TYPE__
00964 # define YYSIZE_T __SIZE_TYPE__
00965 # elif defined size_t
00966 # define YYSIZE_T size_t
00967 # elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \
00968 || defined __cplusplus || defined _MSC_VER)
00969 # include <stddef.h>
00970 # define YYSIZE_T size_t
00971 # else
00972 # define YYSIZE_T unsigned int
00973 # endif
00974 #endif
00975
00976 #define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
00977
00978 #ifndef YY_
00979 # if defined YYENABLE_NLS && YYENABLE_NLS
00980 # if ENABLE_NLS
00981 # include <libintl.h>
00982 # define YY_(msgid) dgettext ("bison-runtime", msgid)
00983 # endif
00984 # endif
00985 # ifndef YY_
00986 # define YY_(msgid) msgid
00987 # endif
00988 #endif
00989
00990
00991 #if ! defined lint || defined __GNUC__
00992 # define YYUSE(e) ((void) (e))
00993 #else
00994 # define YYUSE(e)
00995 #endif
00996
00997
00998 #ifndef lint
00999 # define YYID(n) (n)
01000 #else
01001 #if (defined __STDC__ || defined __C99__FUNC__ \
01002 || defined __cplusplus || defined _MSC_VER)
01003 static int
01004 YYID (int yyi)
01005 #else
01006 static int
01007 YYID (yyi)
01008 int yyi;
01009 #endif
01010 {
01011 return yyi;
01012 }
01013 #endif
01014
01015 #if ! defined yyoverflow || YYERROR_VERBOSE
01016
01017
01018
01019 # ifdef YYSTACK_USE_ALLOCA
01020 # if YYSTACK_USE_ALLOCA
01021 # ifdef __GNUC__
01022 # define YYSTACK_ALLOC __builtin_alloca
01023 # elif defined __BUILTIN_VA_ARG_INCR
01024 # include <alloca.h>
01025 # elif defined _AIX
01026 # define YYSTACK_ALLOC __alloca
01027 # elif defined _MSC_VER
01028 # include <malloc.h>
01029 # define alloca _alloca
01030 # else
01031 # define YYSTACK_ALLOC alloca
01032 # if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
01033 || defined __cplusplus || defined _MSC_VER)
01034 # include <stdlib.h>
01035 # ifndef EXIT_SUCCESS
01036 # define EXIT_SUCCESS 0
01037 # endif
01038 # endif
01039 # endif
01040 # endif
01041 # endif
01042
01043 # ifdef YYSTACK_ALLOC
01044
01045 # define YYSTACK_FREE(Ptr) do { ; } while (YYID (0))
01046 # ifndef YYSTACK_ALLOC_MAXIMUM
01047
01048
01049
01050
01051 # define YYSTACK_ALLOC_MAXIMUM 4032
01052 # endif
01053 # else
01054 # define YYSTACK_ALLOC YYMALLOC
01055 # define YYSTACK_FREE YYFREE
01056 # ifndef YYSTACK_ALLOC_MAXIMUM
01057 # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
01058 # endif
01059 # if (defined __cplusplus && ! defined EXIT_SUCCESS \
01060 && ! ((defined YYMALLOC || defined malloc) \
01061 && (defined YYFREE || defined free)))
01062 # include <stdlib.h>
01063 # ifndef EXIT_SUCCESS
01064 # define EXIT_SUCCESS 0
01065 # endif
01066 # endif
01067 # ifndef YYMALLOC
01068 # define YYMALLOC malloc
01069 # if ! defined malloc && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
01070 || defined __cplusplus || defined _MSC_VER)
01071 void *malloc (YYSIZE_T);
01072 # endif
01073 # endif
01074 # ifndef YYFREE
01075 # define YYFREE free
01076 # if ! defined free && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
01077 || defined __cplusplus || defined _MSC_VER)
01078 void free (void *);
01079 # endif
01080 # endif
01081 # endif
01082 #endif
01083
01084
01085 #if (! defined yyoverflow \
01086 && (! defined __cplusplus \
01087 || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
01088
01089
01090 union yyalloc
01091 {
01092 yytype_int16 yyss_alloc;
01093 YYSTYPE yyvs_alloc;
01094 };
01095
01096
01097 # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
01098
01099
01100
01101 # define YYSTACK_BYTES(N) \
01102 ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \
01103 + YYSTACK_GAP_MAXIMUM)
01104
01105 # define YYCOPY_NEEDED 1
01106
01107
01108
01109
01110
01111
01112 # define YYSTACK_RELOCATE(Stack_alloc, Stack) \
01113 do \
01114 { \
01115 YYSIZE_T yynewbytes; \
01116 YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
01117 Stack = &yyptr->Stack_alloc; \
01118 yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
01119 yyptr += yynewbytes / sizeof (*yyptr); \
01120 } \
01121 while (YYID (0))
01122
01123 #endif
01124
01125 #if defined YYCOPY_NEEDED && YYCOPY_NEEDED
01126
01127
01128 # ifndef YYCOPY
01129 # if defined __GNUC__ && 1 < __GNUC__
01130 # define YYCOPY(To, From, Count) \
01131 __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
01132 # else
01133 # define YYCOPY(To, From, Count) \
01134 do \
01135 { \
01136 YYSIZE_T yyi; \
01137 for (yyi = 0; yyi < (Count); yyi++) \
01138 (To)[yyi] = (From)[yyi]; \
01139 } \
01140 while (YYID (0))
01141 # endif
01142 # endif
01143 #endif
01144
01145
01146 #define YYFINAL 3
01147
01148 #define YYLAST 11071
01149
01150
01151 #define YYNTOKENS 144
01152
01153 #define YYNNTS 203
01154
01155 #define YYNRULES 626
01156
01157 #define YYNSTATES 1059
01158
01159
01160 #define YYUNDEFTOK 2
01161 #define YYMAXUTOK 354
01162
01163 #define YYTRANSLATE(YYX) \
01164 ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
01165
01166
01167 static const yytype_uint8 yytranslate[] =
01168 {
01169 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01170 143, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01171 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01172 2, 2, 142, 129, 2, 2, 2, 127, 122, 2,
01173 138, 139, 125, 123, 136, 124, 135, 126, 2, 2,
01174 2, 2, 2, 2, 2, 2, 2, 2, 117, 141,
01175 119, 115, 118, 116, 2, 2, 2, 2, 2, 2,
01176 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01177 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01178 2, 134, 2, 140, 121, 2, 137, 2, 2, 2,
01179 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01180 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01181 2, 2, 2, 132, 120, 133, 130, 2, 81, 82,
01182 68, 69, 70, 2, 71, 85, 86, 76, 75, 72,
01183 73, 74, 79, 80, 83, 84, 2, 2, 2, 2,
01184 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01185 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01186 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01187 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01188 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01189 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01190 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01191 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01192 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01193 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
01194 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
01195 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
01196 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
01197 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
01198 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
01199 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
01200 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
01201 65, 66, 67, 77, 78, 87, 88, 89, 90, 91,
01202 92, 93, 94, 95, 96, 97, 98, 99, 100, 101,
01203 102, 103, 104, 105, 106, 107, 108, 109, 110, 111,
01204 112, 113, 114, 128, 131
01205 };
01206
01207 #if YYDEBUG
01208
01209
01210 static const yytype_uint16 yyprhs[] =
01211 {
01212 0, 0, 3, 4, 7, 10, 12, 14, 18, 21,
01213 23, 24, 30, 35, 38, 40, 42, 46, 49, 51,
01214 52, 58, 59, 64, 68, 72, 76, 79, 83, 87,
01215 91, 95, 99, 104, 106, 110, 114, 121, 127, 133,
01216 139, 145, 149, 153, 157, 159, 163, 167, 169, 173,
01217 177, 181, 184, 186, 188, 190, 192, 194, 199, 200,
01218 206, 208, 211, 215, 220, 226, 231, 237, 240, 243,
01219 246, 249, 252, 254, 258, 260, 264, 266, 269, 273,
01220 279, 282, 287, 290, 295, 297, 301, 303, 307, 310,
01221 314, 316, 320, 322, 324, 329, 333, 337, 341, 345,
01222 348, 350, 352, 354, 359, 363, 367, 371, 375, 378,
01223 380, 382, 384, 387, 389, 393, 395, 397, 399, 401,
01224 403, 405, 407, 409, 411, 413, 414, 419, 421, 423,
01225 425, 427, 429, 431, 433, 435, 437, 439, 441, 443,
01226 445, 447, 449, 451, 453, 455, 457, 459, 461, 463,
01227 465, 467, 469, 471, 473, 475, 477, 479, 481, 483,
01228 485, 487, 489, 491, 493, 495, 497, 499, 501, 503,
01229 505, 507, 509, 511, 513, 515, 517, 519, 521, 523,
01230 525, 527, 529, 531, 533, 535, 537, 539, 541, 543,
01231 545, 547, 549, 551, 553, 555, 557, 559, 561, 565,
01232 571, 575, 581, 588, 594, 600, 606, 612, 617, 621,
01233 625, 629, 633, 637, 641, 645, 649, 653, 658, 661,
01234 664, 668, 672, 676, 680, 684, 688, 692, 696, 700,
01235 704, 708, 712, 716, 719, 722, 726, 730, 734, 738,
01236 739, 744, 751, 753, 755, 757, 760, 765, 768, 772,
01237 774, 776, 778, 780, 783, 788, 791, 793, 796, 799,
01238 804, 806, 807, 810, 813, 816, 818, 820, 823, 827,
01239 832, 834, 836, 840, 845, 848, 850, 852, 854, 856,
01240 858, 860, 862, 864, 866, 868, 870, 871, 876, 877,
01241 881, 882, 883, 889, 893, 897, 900, 904, 908, 910,
01242 915, 919, 921, 922, 929, 934, 938, 941, 943, 946,
01243 949, 956, 963, 964, 965, 973, 974, 975, 983, 989,
01244 994, 995, 996, 1006, 1007, 1014, 1015, 1016, 1025, 1026,
01245 1032, 1033, 1040, 1041, 1042, 1052, 1054, 1056, 1058, 1060,
01246 1062, 1064, 1066, 1068, 1070, 1072, 1074, 1076, 1078, 1080,
01247 1082, 1084, 1086, 1088, 1091, 1093, 1095, 1097, 1103, 1105,
01248 1108, 1110, 1112, 1114, 1118, 1120, 1124, 1126, 1131, 1138,
01249 1142, 1148, 1151, 1156, 1158, 1162, 1167, 1170, 1173, 1175,
01250 1178, 1179, 1186, 1195, 1200, 1207, 1212, 1215, 1222, 1225,
01251 1230, 1237, 1240, 1245, 1248, 1253, 1255, 1257, 1259, 1263,
01252 1265, 1270, 1272, 1277, 1279, 1283, 1285, 1287, 1288, 1289,
01253 1290, 1296, 1301, 1303, 1307, 1311, 1312, 1318, 1321, 1326,
01254 1332, 1338, 1341, 1342, 1348, 1349, 1355, 1359, 1360, 1365,
01255 1366, 1371, 1374, 1376, 1381, 1382, 1388, 1389, 1395, 1401,
01256 1403, 1405, 1412, 1414, 1416, 1418, 1420, 1423, 1425, 1428,
01257 1430, 1432, 1434, 1436, 1438, 1440, 1442, 1445, 1449, 1453,
01258 1457, 1461, 1465, 1466, 1470, 1472, 1475, 1479, 1483, 1484,
01259 1488, 1492, 1496, 1500, 1504, 1505, 1509, 1510, 1514, 1515,
01260 1518, 1519, 1522, 1523, 1526, 1528, 1529, 1533, 1534, 1535,
01261 1536, 1543, 1545, 1547, 1549, 1551, 1554, 1556, 1558, 1560,
01262 1562, 1566, 1568, 1571, 1573, 1575, 1577, 1579, 1581, 1583,
01263 1585, 1587, 1589, 1591, 1593, 1595, 1597, 1599, 1601, 1603,
01264 1605, 1607, 1609, 1611, 1613, 1615, 1617, 1618, 1623, 1626,
01265 1630, 1631, 1635, 1640, 1643, 1646, 1648, 1651, 1652, 1659,
01266 1668, 1673, 1680, 1685, 1692, 1695, 1700, 1707, 1710, 1715,
01267 1718, 1723, 1725, 1726, 1728, 1730, 1732, 1734, 1736, 1738,
01268 1740, 1744, 1746, 1750, 1752, 1755, 1757, 1760, 1762, 1764,
01269 1768, 1770, 1774, 1776, 1778, 1781, 1783, 1787, 1791, 1793,
01270 1797, 1799, 1803, 1805, 1807, 1810, 1812, 1814, 1816, 1819,
01271 1822, 1824, 1826, 1827, 1832, 1834, 1837, 1839, 1843, 1847,
01272 1850, 1853, 1855, 1857, 1859, 1861, 1863, 1865, 1867, 1869,
01273 1871, 1873, 1875, 1877, 1878, 1880, 1881, 1883, 1886, 1889,
01274 1890, 1892, 1894, 1896, 1898, 1900, 1903
01275 };
01276
01277
01278 static const yytype_int16 yyrhs[] =
01279 {
01280 145, 0, -1, -1, 146, 147, -1, 148, 339, -1,
01281 346, -1, 149, -1, 148, 345, 149, -1, 1, 149,
01282 -1, 156, -1, -1, 47, 150, 132, 147, 133, -1,
01283 152, 265, 233, 268, -1, 153, 339, -1, 346, -1,
01284 154, -1, 153, 345, 154, -1, 1, 156, -1, 156,
01285 -1, -1, 47, 155, 132, 147, 133, -1, -1, 45,
01286 179, 157, 179, -1, 45, 54, 54, -1, 45, 54,
01287 66, -1, 45, 54, 65, -1, 6, 180, -1, 156,
01288 40, 160, -1, 156, 41, 160, -1, 156, 42, 160,
01289 -1, 156, 43, 160, -1, 156, 44, 156, -1, 48,
01290 132, 152, 133, -1, 158, -1, 167, 115, 161, -1,
01291 301, 89, 161, -1, 218, 134, 190, 342, 89, 161,
01292 -1, 218, 135, 52, 89, 161, -1, 218, 135, 56,
01293 89, 161, -1, 218, 87, 56, 89, 161, -1, 218,
01294 87, 52, 89, 161, -1, 302, 89, 161, -1, 174,
01295 115, 198, -1, 167, 115, 197, -1, 159, -1, 174,
01296 115, 161, -1, 174, 115, 158, -1, 161, -1, 159,
01297 37, 159, -1, 159, 38, 159, -1, 39, 340, 159,
01298 -1, 129, 161, -1, 184, -1, 159, -1, 166, -1,
01299 162, -1, 254, -1, 254, 338, 336, 192, -1, -1,
01300 96, 164, 241, 152, 133, -1, 335, -1, 165, 192,
01301 -1, 165, 192, 163, -1, 218, 135, 336, 192, -1,
01302 218, 135, 336, 192, 163, -1, 218, 87, 336, 192,
01303 -1, 218, 87, 336, 192, 163, -1, 32, 192, -1,
01304 31, 192, -1, 30, 191, -1, 21, 191, -1, 22,
01305 191, -1, 169, -1, 91, 168, 341, -1, 169, -1,
01306 91, 168, 341, -1, 171, -1, 171, 170, -1, 171,
01307 97, 173, -1, 171, 97, 173, 136, 172, -1, 171,
01308 97, -1, 171, 97, 136, 172, -1, 97, 173, -1,
01309 97, 173, 136, 172, -1, 97, -1, 97, 136, 172,
01310 -1, 173, -1, 91, 168, 341, -1, 170, 136, -1,
01311 171, 170, 136, -1, 170, -1, 172, 136, 170, -1,
01312 298, -1, 299, -1, 218, 134, 190, 342, -1, 218,
01313 135, 52, -1, 218, 87, 52, -1, 218, 135, 56,
01314 -1, 218, 87, 56, -1, 88, 56, -1, 302, -1,
01315 298, -1, 299, -1, 218, 134, 190, 342, -1, 218,
01316 135, 52, -1, 218, 87, 52, -1, 218, 135, 56,
01317 -1, 218, 87, 56, -1, 88, 56, -1, 302, -1,
01318 52, -1, 56, -1, 88, 175, -1, 175, -1, 218,
01319 87, 175, -1, 52, -1, 56, -1, 53, -1, 182,
01320 -1, 183, -1, 177, -1, 293, -1, 178, -1, 295,
01321 -1, 179, -1, -1, 180, 136, 181, 179, -1, 120,
01322 -1, 121, -1, 122, -1, 71, -1, 72, -1, 73,
01323 -1, 79, -1, 80, -1, 118, -1, 75, -1, 119,
01324 -1, 76, -1, 74, -1, 85, -1, 86, -1, 123,
01325 -1, 124, -1, 125, -1, 97, -1, 126, -1, 127,
01326 -1, 70, -1, 98, -1, 129, -1, 130, -1, 68,
01327 -1, 69, -1, 83, -1, 84, -1, 137, -1, 49,
01328 -1, 50, -1, 51, -1, 47, -1, 48, -1, 45,
01329 -1, 37, -1, 7, -1, 21, -1, 16, -1, 3,
01330 -1, 5, -1, 46, -1, 26, -1, 15, -1, 14,
01331 -1, 10, -1, 9, -1, 36, -1, 20, -1, 25,
01332 -1, 4, -1, 22, -1, 34, -1, 39, -1, 38,
01333 -1, 23, -1, 8, -1, 24, -1, 30, -1, 33,
01334 -1, 32, -1, 13, -1, 35, -1, 6, -1, 17,
01335 -1, 31, -1, 11, -1, 12, -1, 18, -1, 19,
01336 -1, 174, 115, 184, -1, 174, 115, 184, 44, 184,
01337 -1, 301, 89, 184, -1, 301, 89, 184, 44, 184,
01338 -1, 218, 134, 190, 342, 89, 184, -1, 218, 135,
01339 52, 89, 184, -1, 218, 135, 56, 89, 184, -1,
01340 218, 87, 52, 89, 184, -1, 218, 87, 56, 89,
01341 184, -1, 88, 56, 89, 184, -1, 302, 89, 184,
01342 -1, 184, 81, 184, -1, 184, 82, 184, -1, 184,
01343 123, 184, -1, 184, 124, 184, -1, 184, 125, 184,
01344 -1, 184, 126, 184, -1, 184, 127, 184, -1, 184,
01345 70, 184, -1, 128, 297, 70, 184, -1, 68, 184,
01346 -1, 69, 184, -1, 184, 120, 184, -1, 184, 121,
01347 184, -1, 184, 122, 184, -1, 184, 71, 184, -1,
01348 184, 118, 184, -1, 184, 75, 184, -1, 184, 119,
01349 184, -1, 184, 76, 184, -1, 184, 72, 184, -1,
01350 184, 73, 184, -1, 184, 74, 184, -1, 184, 79,
01351 184, -1, 184, 80, 184, -1, 129, 184, -1, 130,
01352 184, -1, 184, 85, 184, -1, 184, 86, 184, -1,
01353 184, 77, 184, -1, 184, 78, 184, -1, -1, 46,
01354 340, 185, 184, -1, 184, 116, 184, 340, 117, 184,
01355 -1, 199, -1, 184, -1, 346, -1, 196, 343, -1,
01356 196, 136, 333, 343, -1, 333, 343, -1, 138, 190,
01357 341, -1, 346, -1, 188, -1, 346, -1, 191, -1,
01358 196, 136, -1, 196, 136, 333, 136, -1, 333, 136,
01359 -1, 166, -1, 196, 195, -1, 333, 195, -1, 196,
01360 136, 333, 195, -1, 194, -1, -1, 193, 191, -1,
01361 99, 186, -1, 136, 194, -1, 346, -1, 186, -1,
01362 97, 186, -1, 196, 136, 186, -1, 196, 136, 97,
01363 186, -1, 198, -1, 186, -1, 196, 136, 186, -1,
01364 196, 136, 97, 186, -1, 97, 186, -1, 269, -1,
01365 270, -1, 273, -1, 274, -1, 275, -1, 280, -1,
01366 278, -1, 281, -1, 300, -1, 302, -1, 53, -1,
01367 -1, 219, 200, 151, 229, -1, -1, 92, 201, 341,
01368 -1, -1, -1, 92, 202, 159, 203, 341, -1, 91,
01369 152, 139, -1, 218, 87, 56, -1, 88, 56, -1,
01370 94, 187, 140, -1, 95, 332, 133, -1, 30, -1,
01371 31, 138, 191, 341, -1, 31, 138, 341, -1, 31,
01372 -1, -1, 46, 340, 138, 204, 159, 341, -1, 39,
01373 138, 159, 341, -1, 39, 138, 341, -1, 165, 260,
01374 -1, 255, -1, 255, 260, -1, 100, 246, -1, 220,
01375 160, 230, 152, 232, 229, -1, 221, 160, 230, 152,
01376 233, 229, -1, -1, -1, 222, 205, 160, 231, 206,
01377 152, 229, -1, -1, -1, 223, 207, 160, 231, 208,
01378 152, 229, -1, 224, 160, 339, 263, 229, -1, 224,
01379 339, 263, 229, -1, -1, -1, 225, 234, 25, 209,
01380 160, 231, 210, 152, 229, -1, -1, 226, 176, 303,
01381 211, 151, 229, -1, -1, -1, 226, 85, 159, 212,
01382 344, 213, 151, 229, -1, -1, 227, 176, 214, 151,
01383 229, -1, -1, 228, 177, 215, 305, 151, 229, -1,
01384 -1, -1, 228, 330, 338, 216, 177, 217, 305, 151,
01385 229, -1, 21, -1, 22, -1, 23, -1, 24, -1,
01386 199, -1, 7, -1, 11, -1, 12, -1, 18, -1,
01387 19, -1, 16, -1, 20, -1, 3, -1, 4, -1,
01388 5, -1, 10, -1, 344, -1, 13, -1, 344, 13,
01389 -1, 344, -1, 27, -1, 233, -1, 14, 160, 230,
01390 152, 232, -1, 346, -1, 15, 152, -1, 174, -1,
01391 167, -1, 311, -1, 91, 237, 341, -1, 235, -1,
01392 236, 136, 235, -1, 236, -1, 236, 136, 97, 311,
01393 -1, 236, 136, 97, 311, 136, 236, -1, 236, 136,
01394 97, -1, 236, 136, 97, 136, 236, -1, 97, 311,
01395 -1, 97, 311, 136, 236, -1, 97, -1, 97, 136,
01396 236, -1, 317, 136, 320, 329, -1, 317, 329, -1,
01397 320, 329, -1, 328, -1, 136, 238, -1, -1, 313,
01398 136, 323, 136, 326, 239, -1, 313, 136, 323, 136,
01399 326, 136, 313, 239, -1, 313, 136, 323, 239, -1,
01400 313, 136, 323, 136, 313, 239, -1, 313, 136, 326,
01401 239, -1, 313, 136, -1, 313, 136, 326, 136, 313,
01402 239, -1, 313, 239, -1, 323, 136, 326, 239, -1,
01403 323, 136, 326, 136, 313, 239, -1, 323, 239, -1,
01404 323, 136, 313, 239, -1, 326, 239, -1, 326, 136,
01405 313, 239, -1, 238, -1, 346, -1, 242, -1, 120,
01406 243, 120, -1, 78, -1, 120, 240, 243, 120, -1,
01407 340, -1, 340, 141, 244, 340, -1, 245, -1, 244,
01408 136, 245, -1, 52, -1, 310, -1, -1, -1, -1,
01409 247, 248, 250, 249, 251, -1, 138, 309, 243, 139,
01410 -1, 309, -1, 113, 152, 133, -1, 29, 152, 10,
01411 -1, -1, 28, 253, 241, 152, 10, -1, 166, 252,
01412 -1, 254, 338, 336, 189, -1, 254, 338, 336, 189,
01413 260, -1, 254, 338, 336, 192, 252, -1, 165, 188,
01414 -1, -1, 218, 135, 336, 256, 189, -1, -1, 218,
01415 87, 336, 257, 188, -1, 218, 87, 337, -1, -1,
01416 218, 135, 258, 188, -1, -1, 218, 87, 259, 188,
01417 -1, 32, 188, -1, 32, -1, 218, 134, 190, 342,
01418 -1, -1, 132, 261, 241, 152, 133, -1, -1, 26,
01419 262, 241, 152, 10, -1, 17, 196, 230, 152, 264,
01420 -1, 233, -1, 263, -1, 8, 266, 267, 230, 152,
01421 265, -1, 346, -1, 186, -1, 198, -1, 346, -1,
01422 90, 174, -1, 346, -1, 9, 152, -1, 346, -1,
01423 296, -1, 293, -1, 295, -1, 271, -1, 64, -1,
01424 272, -1, 271, 272, -1, 102, 284, 112, -1, 103,
01425 285, 112, -1, 104, 286, 67, -1, 105, 142, 112,
01426 -1, 105, 276, 112, -1, -1, 276, 277, 142, -1,
01427 287, -1, 277, 287, -1, 107, 142, 112, -1, 107,
01428 279, 112, -1, -1, 279, 277, 142, -1, 106, 142,
01429 112, -1, 106, 282, 112, -1, 108, 142, 112, -1,
01430 108, 283, 112, -1, -1, 282, 63, 142, -1, -1,
01431 283, 63, 142, -1, -1, 284, 287, -1, -1, 285,
01432 287, -1, -1, 286, 287, -1, 63, -1, -1, 111,
01433 288, 292, -1, -1, -1, -1, 109, 289, 290, 291,
01434 152, 110, -1, 54, -1, 55, -1, 57, -1, 302,
01435 -1, 101, 294, -1, 177, -1, 55, -1, 54, -1,
01436 57, -1, 101, 285, 112, -1, 297, -1, 128, 297,
01437 -1, 59, -1, 60, -1, 61, -1, 62, -1, 52,
01438 -1, 55, -1, 54, -1, 56, -1, 57, -1, 34,
01439 -1, 33, -1, 35, -1, 36, -1, 50, -1, 49,
01440 -1, 51, -1, 298, -1, 299, -1, 298, -1, 299,
01441 -1, 65, -1, 66, -1, 344, -1, -1, 119, 304,
01442 160, 344, -1, 1, 344, -1, 138, 309, 341, -1,
01443 -1, 306, 309, 344, -1, 318, 136, 320, 329, -1,
01444 318, 329, -1, 320, 329, -1, 328, -1, 136, 307,
01445 -1, -1, 313, 136, 324, 136, 326, 308, -1, 313,
01446 136, 324, 136, 326, 136, 313, 308, -1, 313, 136,
01447 324, 308, -1, 313, 136, 324, 136, 313, 308, -1,
01448 313, 136, 326, 308, -1, 313, 136, 326, 136, 313,
01449 308, -1, 313, 308, -1, 324, 136, 326, 308, -1,
01450 324, 136, 326, 136, 313, 308, -1, 324, 308, -1,
01451 324, 136, 313, 308, -1, 326, 308, -1, 326, 136,
01452 313, 308, -1, 307, -1, -1, 56, -1, 55, -1,
01453 54, -1, 57, -1, 310, -1, 52, -1, 311, -1,
01454 91, 237, 341, -1, 312, -1, 313, 136, 312, -1,
01455 58, -1, 314, 186, -1, 314, -1, 314, 218, -1,
01456 314, -1, 316, -1, 317, 136, 316, -1, 315, -1,
01457 318, 136, 315, -1, 70, -1, 98, -1, 319, 52,
01458 -1, 319, -1, 311, 115, 186, -1, 311, 115, 218,
01459 -1, 322, -1, 323, 136, 322, -1, 321, -1, 324,
01460 136, 321, -1, 125, -1, 97, -1, 325, 52, -1,
01461 325, -1, 122, -1, 99, -1, 327, 52, -1, 136,
01462 328, -1, 346, -1, 300, -1, -1, 138, 331, 159,
01463 341, -1, 346, -1, 333, 343, -1, 334, -1, 333,
01464 136, 334, -1, 186, 90, 186, -1, 58, 186, -1,
01465 98, 186, -1, 52, -1, 56, -1, 53, -1, 52,
01466 -1, 56, -1, 53, -1, 182, -1, 52, -1, 53,
01467 -1, 182, -1, 135, -1, 87, -1, -1, 345, -1,
01468 -1, 143, -1, 340, 139, -1, 340, 140, -1, -1,
01469 143, -1, 136, -1, 141, -1, 143, -1, 344, -1,
01470 345, 141, -1, -1
01471 };
01472
01473
01474 static const yytype_uint16 yyrline[] =
01475 {
01476 0, 863, 863, 863, 894, 905, 914, 922, 930, 936,
01477 938, 937, 958, 991, 1002, 1011, 1019, 1027, 1033, 1038,
01478 1037, 1058, 1058, 1066, 1074, 1085, 1095, 1103, 1112, 1121,
01479 1134, 1147, 1156, 1168, 1169, 1179, 1184, 1205, 1210, 1215,
01480 1225, 1230, 1240, 1249, 1258, 1261, 1270, 1282, 1283, 1291,
01481 1299, 1307, 1315, 1318, 1330, 1331, 1334, 1335, 1347, 1346,
01482 1368, 1378, 1387, 1400, 1409, 1421, 1430, 1442, 1451, 1460,
01483 1468, 1476, 1486, 1487, 1497, 1498, 1508, 1516, 1524, 1532,
01484 1541, 1549, 1558, 1566, 1575, 1583, 1594, 1595, 1605, 1613,
01485 1623, 1631, 1641, 1645, 1649, 1657, 1665, 1673, 1681, 1693,
01486 1703, 1715, 1724, 1733, 1741, 1749, 1757, 1765, 1778, 1791,
01487 1802, 1810, 1813, 1821, 1829, 1839, 1840, 1841, 1842, 1847,
01488 1858, 1859, 1862, 1870, 1873, 1881, 1881, 1891, 1892, 1893,
01489 1894, 1895, 1896, 1897, 1898, 1899, 1900, 1901, 1902, 1903,
01490 1904, 1905, 1906, 1907, 1908, 1909, 1910, 1911, 1912, 1913,
01491 1914, 1915, 1916, 1917, 1918, 1919, 1920, 1923, 1923, 1923,
01492 1924, 1924, 1925, 1925, 1925, 1926, 1926, 1926, 1926, 1927,
01493 1927, 1927, 1927, 1928, 1928, 1928, 1929, 1929, 1929, 1929,
01494 1930, 1930, 1930, 1930, 1931, 1931, 1931, 1931, 1932, 1932,
01495 1932, 1932, 1933, 1933, 1933, 1933, 1934, 1934, 1937, 1946,
01496 1956, 1961, 1971, 1997, 2002, 2007, 2012, 2022, 2032, 2043,
01497 2057, 2071, 2079, 2087, 2095, 2103, 2111, 2119, 2128, 2136,
01498 2144, 2152, 2160, 2168, 2176, 2184, 2192, 2200, 2208, 2216,
01499 2224, 2232, 2243, 2251, 2259, 2267, 2275, 2283, 2291, 2299,
01500 2299, 2309, 2319, 2325, 2337, 2338, 2342, 2350, 2360, 2370,
01501 2371, 2374, 2375, 2376, 2380, 2388, 2398, 2407, 2415, 2425,
01502 2434, 2443, 2443, 2455, 2465, 2469, 2475, 2483, 2491, 2505,
01503 2521, 2522, 2525, 2539, 2554, 2564, 2565, 2566, 2567, 2568,
01504 2569, 2570, 2571, 2572, 2573, 2574, 2583, 2582, 2610, 2610,
01505 2619, 2623, 2618, 2632, 2640, 2648, 2656, 2669, 2677, 2685,
01506 2693, 2701, 2709, 2709, 2719, 2727, 2735, 2745, 2746, 2756,
01507 2760, 2772, 2784, 2784, 2784, 2795, 2795, 2795, 2806, 2817,
01508 2826, 2828, 2825, 2892, 2891, 2913, 2918, 2912, 2937, 2936,
01509 2958, 2957, 2980, 2981, 2980, 3001, 3009, 3017, 3025, 3035,
01510 3047, 3053, 3059, 3065, 3071, 3077, 3083, 3089, 3095, 3101,
01511 3111, 3117, 3122, 3123, 3130, 3135, 3138, 3139, 3152, 3153,
01512 3163, 3164, 3167, 3175, 3185, 3193, 3203, 3211, 3220, 3229,
01513 3237, 3245, 3254, 3266, 3274, 3285, 3289, 3293, 3297, 3303,
01514 3308, 3313, 3317, 3321, 3325, 3329, 3333, 3341, 3345, 3349,
01515 3353, 3357, 3361, 3365, 3369, 3373, 3379, 3380, 3386, 3395,
01516 3404, 3415, 3419, 3429, 3436, 3445, 3453, 3459, 3462, 3467,
01517 3459, 3483, 3491, 3497, 3501, 3508, 3507, 3528, 3544, 3553,
01518 3565, 3579, 3589, 3588, 3605, 3604, 3620, 3629, 3628, 3646,
01519 3645, 3662, 3670, 3678, 3693, 3692, 3712, 3711, 3732, 3744,
01520 3745, 3748, 3767, 3770, 3778, 3786, 3789, 3793, 3796, 3804,
01521 3807, 3808, 3816, 3819, 3836, 3837, 3838, 3848, 3858, 3885,
01522 3950, 3959, 3970, 3977, 3987, 3995, 4005, 4014, 4025, 4032,
01523 4044, 4053, 4063, 4072, 4083, 4090, 4101, 4108, 4123, 4130,
01524 4141, 4148, 4159, 4166, 4195, 4197, 4196, 4213, 4219, 4224,
01525 4212, 4243, 4251, 4259, 4267, 4270, 4281, 4282, 4283, 4284,
01526 4287, 4298, 4299, 4309, 4310, 4311, 4312, 4315, 4316, 4317,
01527 4318, 4319, 4322, 4323, 4324, 4325, 4326, 4327, 4328, 4331,
01528 4344, 4354, 4362, 4372, 4373, 4376, 4385, 4384, 4393, 4405,
01529 4415, 4415, 4428, 4432, 4436, 4440, 4446, 4451, 4456, 4460,
01530 4464, 4468, 4472, 4476, 4480, 4484, 4488, 4492, 4496, 4500,
01531 4504, 4508, 4513, 4519, 4528, 4537, 4546, 4557, 4558, 4565,
01532 4574, 4593, 4600, 4614, 4621, 4630, 4641, 4650, 4661, 4669,
01533 4686, 4694, 4710, 4711, 4714, 4719, 4725, 4737, 4749, 4757,
01534 4773, 4781, 4797, 4798, 4801, 4814, 4825, 4826, 4829, 4846,
01535 4850, 4860, 4870, 4870, 4899, 4900, 4910, 4917, 4927, 4939,
01536 4947, 4959, 4960, 4961, 4964, 4965, 4966, 4967, 4970, 4971,
01537 4972, 4975, 4980, 4987, 4988, 4991, 4992, 4995, 4998, 5001,
01538 5002, 5003, 5006, 5007, 5010, 5011, 5015
01539 };
01540 #endif
01541
01542 #if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
01543
01544
01545 static const char *const yytname[] =
01546 {
01547 "\"end-of-input\"", "error", "$undefined", "keyword_class",
01548 "keyword_module", "keyword_def", "keyword_undef", "keyword_begin",
01549 "keyword_rescue", "keyword_ensure", "keyword_end", "keyword_if",
01550 "keyword_unless", "keyword_then", "keyword_elsif", "keyword_else",
01551 "keyword_case", "keyword_when", "keyword_while", "keyword_until",
01552 "keyword_for", "keyword_break", "keyword_next", "keyword_redo",
01553 "keyword_retry", "keyword_in", "keyword_do", "keyword_do_cond",
01554 "keyword_do_block", "keyword_do_LAMBDA", "keyword_return",
01555 "keyword_yield", "keyword_super", "keyword_self", "keyword_nil",
01556 "keyword_true", "keyword_false", "keyword_and", "keyword_or",
01557 "keyword_not", "modifier_if", "modifier_unless", "modifier_while",
01558 "modifier_until", "modifier_rescue", "keyword_alias", "keyword_defined",
01559 "keyword_BEGIN", "keyword_END", "keyword__LINE__", "keyword__FILE__",
01560 "keyword__ENCODING__", "tIDENTIFIER", "tFID", "tGVAR", "tIVAR",
01561 "tCONSTANT", "tCVAR", "tLABEL", "tINTEGER", "tFLOAT", "tRATIONAL",
01562 "tIMAGINARY", "tSTRING_CONTENT", "tCHAR", "tNTH_REF", "tBACK_REF",
01563 "tREGEXP_END", "\"unary+\"", "\"unary-\"", "\"**\"", "\"<=>\"", "\"==\"",
01564 "\"===\"", "\"!=\"", "\">=\"", "\"<=\"", "\"&&\"", "\"||\"", "\"=~\"",
01565 "\"!~\"", "\"..\"", "\"...\"", "\"[]\"", "\"[]=\"", "\"<<\"", "\">>\"",
01566 "\"::\"", "\":: at EXPR_BEG\"", "tOP_ASGN", "\"=>\"", "\"(\"",
01567 "\"( arg\"", "\")\"", "\"[\"", "\"{\"", "\"{ arg\"", "\"*\"",
01568 "\"**arg\"", "\"&\"", "\"->\"", "tSYMBEG", "tSTRING_BEG", "tXSTRING_BEG",
01569 "tREGEXP_BEG", "tWORDS_BEG", "tQWORDS_BEG", "tSYMBOLS_BEG",
01570 "tQSYMBOLS_BEG", "tSTRING_DBEG", "tSTRING_DEND", "tSTRING_DVAR",
01571 "tSTRING_END", "tLAMBEG", "tLOWEST", "'='", "'?'", "':'", "'>'", "'<'",
01572 "'|'", "'^'", "'&'", "'+'", "'-'", "'*'", "'/'", "'%'", "tUMINUS_NUM",
01573 "'!'", "'~'", "tLAST_TOKEN", "'{'", "'}'", "'['", "'.'", "','", "'`'",
01574 "'('", "')'", "']'", "';'", "' '", "'\\n'", "$accept", "program", "$@1",
01575 "top_compstmt", "top_stmts", "top_stmt", "$@2", "bodystmt", "compstmt",
01576 "stmts", "stmt_or_begin", "$@3", "stmt", "$@4", "command_asgn", "expr",
01577 "expr_value", "command_call", "block_command", "cmd_brace_block", "@5",
01578 "fcall", "command", "mlhs", "mlhs_inner", "mlhs_basic", "mlhs_item",
01579 "mlhs_head", "mlhs_post", "mlhs_node", "lhs", "cname", "cpath", "fname",
01580 "fsym", "fitem", "undef_list", "$@6", "op", "reswords", "arg", "$@7",
01581 "arg_value", "aref_args", "paren_args", "opt_paren_args",
01582 "opt_call_args", "call_args", "command_args", "@8", "block_arg",
01583 "opt_block_arg", "args", "mrhs_arg", "mrhs", "primary", "@9", "$@10",
01584 "$@11", "$@12", "$@13", "$@14", "$@15", "$@16", "$@17", "$@18", "$@19",
01585 "@20", "@21", "@22", "@23", "@24", "$@25", "$@26", "primary_value",
01586 "k_begin", "k_if", "k_unless", "k_while", "k_until", "k_case", "k_for",
01587 "k_class", "k_module", "k_def", "k_end", "then", "do", "if_tail",
01588 "opt_else", "for_var", "f_marg", "f_marg_list", "f_margs",
01589 "block_args_tail", "opt_block_args_tail", "block_param",
01590 "opt_block_param", "block_param_def", "opt_bv_decl", "bv_decls", "bvar",
01591 "lambda", "@27", "@28", "@29", "f_larglist", "lambda_body", "do_block",
01592 "@30", "block_call", "method_call", "@31", "@32", "@33", "@34",
01593 "brace_block", "@35", "@36", "case_body", "cases", "opt_rescue",
01594 "exc_list", "exc_var", "opt_ensure", "literal", "strings", "string",
01595 "string1", "xstring", "regexp", "words", "word_list", "word", "symbols",
01596 "symbol_list", "qwords", "qsymbols", "qword_list", "qsym_list",
01597 "string_contents", "xstring_contents", "regexp_contents",
01598 "string_content", "@37", "@38", "@39", "@40", "string_dvar", "symbol",
01599 "sym", "dsym", "numeric", "simple_numeric", "user_variable",
01600 "keyword_variable", "var_ref", "var_lhs", "backref", "superclass",
01601 "$@41", "f_arglist", "@42", "args_tail", "opt_args_tail", "f_args",
01602 "f_bad_arg", "f_norm_arg", "f_arg_item", "f_arg", "f_label", "f_kw",
01603 "f_block_kw", "f_block_kwarg", "f_kwarg", "kwrest_mark", "f_kwrest",
01604 "f_opt", "f_block_opt", "f_block_optarg", "f_optarg", "restarg_mark",
01605 "f_rest_arg", "blkarg_mark", "f_block_arg", "opt_f_block_arg",
01606 "singleton", "$@43", "assoc_list", "assocs", "assoc", "operation",
01607 "operation2", "operation3", "dot_or_colon", "opt_terms", "opt_nl",
01608 "rparen", "rbracket", "trailer", "term", "terms", "none", 0
01609 };
01610 #endif
01611
01612 # ifdef YYPRINT
01613
01614
01615 static const yytype_uint16 yytoknum[] =
01616 {
01617 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
01618 265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
01619 275, 276, 277, 278, 279, 280, 281, 282, 283, 284,
01620 285, 286, 287, 288, 289, 290, 291, 292, 293, 294,
01621 295, 296, 297, 298, 299, 300, 301, 302, 303, 304,
01622 305, 306, 307, 308, 309, 310, 311, 312, 313, 314,
01623 315, 316, 317, 318, 319, 320, 321, 322, 130, 131,
01624 132, 134, 139, 140, 141, 138, 137, 323, 324, 142,
01625 143, 128, 129, 144, 145, 135, 136, 325, 326, 327,
01626 328, 329, 330, 331, 332, 333, 334, 335, 336, 337,
01627 338, 339, 340, 341, 342, 343, 344, 345, 346, 347,
01628 348, 349, 350, 351, 352, 61, 63, 58, 62, 60,
01629 124, 94, 38, 43, 45, 42, 47, 37, 353, 33,
01630 126, 354, 123, 125, 91, 46, 44, 96, 40, 41,
01631 93, 59, 32, 10
01632 };
01633 # endif
01634
01635
01636 static const yytype_uint16 yyr1[] =
01637 {
01638 0, 144, 146, 145, 147, 148, 148, 148, 148, 149,
01639 150, 149, 151, 152, 153, 153, 153, 153, 154, 155,
01640 154, 157, 156, 156, 156, 156, 156, 156, 156, 156,
01641 156, 156, 156, 156, 156, 156, 156, 156, 156, 156,
01642 156, 156, 156, 156, 156, 158, 158, 159, 159, 159,
01643 159, 159, 159, 160, 161, 161, 162, 162, 164, 163,
01644 165, 166, 166, 166, 166, 166, 166, 166, 166, 166,
01645 166, 166, 167, 167, 168, 168, 169, 169, 169, 169,
01646 169, 169, 169, 169, 169, 169, 170, 170, 171, 171,
01647 172, 172, 173, 173, 173, 173, 173, 173, 173, 173,
01648 173, 174, 174, 174, 174, 174, 174, 174, 174, 174,
01649 175, 175, 176, 176, 176, 177, 177, 177, 177, 177,
01650 178, 178, 179, 179, 180, 181, 180, 182, 182, 182,
01651 182, 182, 182, 182, 182, 182, 182, 182, 182, 182,
01652 182, 182, 182, 182, 182, 182, 182, 182, 182, 182,
01653 182, 182, 182, 182, 182, 182, 182, 183, 183, 183,
01654 183, 183, 183, 183, 183, 183, 183, 183, 183, 183,
01655 183, 183, 183, 183, 183, 183, 183, 183, 183, 183,
01656 183, 183, 183, 183, 183, 183, 183, 183, 183, 183,
01657 183, 183, 183, 183, 183, 183, 183, 183, 184, 184,
01658 184, 184, 184, 184, 184, 184, 184, 184, 184, 184,
01659 184, 184, 184, 184, 184, 184, 184, 184, 184, 184,
01660 184, 184, 184, 184, 184, 184, 184, 184, 184, 184,
01661 184, 184, 184, 184, 184, 184, 184, 184, 184, 185,
01662 184, 184, 184, 186, 187, 187, 187, 187, 188, 189,
01663 189, 190, 190, 190, 190, 190, 191, 191, 191, 191,
01664 191, 193, 192, 194, 195, 195, 196, 196, 196, 196,
01665 197, 197, 198, 198, 198, 199, 199, 199, 199, 199,
01666 199, 199, 199, 199, 199, 199, 200, 199, 201, 199,
01667 202, 203, 199, 199, 199, 199, 199, 199, 199, 199,
01668 199, 199, 204, 199, 199, 199, 199, 199, 199, 199,
01669 199, 199, 205, 206, 199, 207, 208, 199, 199, 199,
01670 209, 210, 199, 211, 199, 212, 213, 199, 214, 199,
01671 215, 199, 216, 217, 199, 199, 199, 199, 199, 218,
01672 219, 220, 221, 222, 223, 224, 225, 226, 227, 228,
01673 229, 230, 230, 230, 231, 231, 232, 232, 233, 233,
01674 234, 234, 235, 235, 236, 236, 237, 237, 237, 237,
01675 237, 237, 237, 237, 237, 238, 238, 238, 238, 239,
01676 239, 240, 240, 240, 240, 240, 240, 240, 240, 240,
01677 240, 240, 240, 240, 240, 240, 241, 241, 242, 242,
01678 242, 243, 243, 244, 244, 245, 245, 247, 248, 249,
01679 246, 250, 250, 251, 251, 253, 252, 254, 254, 254,
01680 254, 255, 256, 255, 257, 255, 255, 258, 255, 259,
01681 255, 255, 255, 255, 261, 260, 262, 260, 263, 264,
01682 264, 265, 265, 266, 266, 266, 267, 267, 268, 268,
01683 269, 269, 269, 270, 271, 271, 271, 272, 273, 274,
01684 275, 275, 276, 276, 277, 277, 278, 278, 279, 279,
01685 280, 280, 281, 281, 282, 282, 283, 283, 284, 284,
01686 285, 285, 286, 286, 287, 288, 287, 289, 290, 291,
01687 287, 292, 292, 292, 292, 293, 294, 294, 294, 294,
01688 295, 296, 296, 297, 297, 297, 297, 298, 298, 298,
01689 298, 298, 299, 299, 299, 299, 299, 299, 299, 300,
01690 300, 301, 301, 302, 302, 303, 304, 303, 303, 305,
01691 306, 305, 307, 307, 307, 307, 308, 308, 309, 309,
01692 309, 309, 309, 309, 309, 309, 309, 309, 309, 309,
01693 309, 309, 309, 310, 310, 310, 310, 311, 311, 312,
01694 312, 313, 313, 314, 315, 315, 316, 316, 317, 317,
01695 318, 318, 319, 319, 320, 320, 321, 322, 323, 323,
01696 324, 324, 325, 325, 326, 326, 327, 327, 328, 329,
01697 329, 330, 331, 330, 332, 332, 333, 333, 334, 334,
01698 334, 335, 335, 335, 336, 336, 336, 336, 337, 337,
01699 337, 338, 338, 339, 339, 340, 340, 341, 342, 343,
01700 343, 343, 344, 344, 345, 345, 346
01701 };
01702
01703
01704 static const yytype_uint8 yyr2[] =
01705 {
01706 0, 2, 0, 2, 2, 1, 1, 3, 2, 1,
01707 0, 5, 4, 2, 1, 1, 3, 2, 1, 0,
01708 5, 0, 4, 3, 3, 3, 2, 3, 3, 3,
01709 3, 3, 4, 1, 3, 3, 6, 5, 5, 5,
01710 5, 3, 3, 3, 1, 3, 3, 1, 3, 3,
01711 3, 2, 1, 1, 1, 1, 1, 4, 0, 5,
01712 1, 2, 3, 4, 5, 4, 5, 2, 2, 2,
01713 2, 2, 1, 3, 1, 3, 1, 2, 3, 5,
01714 2, 4, 2, 4, 1, 3, 1, 3, 2, 3,
01715 1, 3, 1, 1, 4, 3, 3, 3, 3, 2,
01716 1, 1, 1, 4, 3, 3, 3, 3, 2, 1,
01717 1, 1, 2, 1, 3, 1, 1, 1, 1, 1,
01718 1, 1, 1, 1, 1, 0, 4, 1, 1, 1,
01719 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
01720 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
01721 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
01722 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
01723 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
01724 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
01725 1, 1, 1, 1, 1, 1, 1, 1, 3, 5,
01726 3, 5, 6, 5, 5, 5, 5, 4, 3, 3,
01727 3, 3, 3, 3, 3, 3, 3, 4, 2, 2,
01728 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
01729 3, 3, 3, 2, 2, 3, 3, 3, 3, 0,
01730 4, 6, 1, 1, 1, 2, 4, 2, 3, 1,
01731 1, 1, 1, 2, 4, 2, 1, 2, 2, 4,
01732 1, 0, 2, 2, 2, 1, 1, 2, 3, 4,
01733 1, 1, 3, 4, 2, 1, 1, 1, 1, 1,
01734 1, 1, 1, 1, 1, 1, 0, 4, 0, 3,
01735 0, 0, 5, 3, 3, 2, 3, 3, 1, 4,
01736 3, 1, 0, 6, 4, 3, 2, 1, 2, 2,
01737 6, 6, 0, 0, 7, 0, 0, 7, 5, 4,
01738 0, 0, 9, 0, 6, 0, 0, 8, 0, 5,
01739 0, 6, 0, 0, 9, 1, 1, 1, 1, 1,
01740 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
01741 1, 1, 1, 2, 1, 1, 1, 5, 1, 2,
01742 1, 1, 1, 3, 1, 3, 1, 4, 6, 3,
01743 5, 2, 4, 1, 3, 4, 2, 2, 1, 2,
01744 0, 6, 8, 4, 6, 4, 2, 6, 2, 4,
01745 6, 2, 4, 2, 4, 1, 1, 1, 3, 1,
01746 4, 1, 4, 1, 3, 1, 1, 0, 0, 0,
01747 5, 4, 1, 3, 3, 0, 5, 2, 4, 5,
01748 5, 2, 0, 5, 0, 5, 3, 0, 4, 0,
01749 4, 2, 1, 4, 0, 5, 0, 5, 5, 1,
01750 1, 6, 1, 1, 1, 1, 2, 1, 2, 1,
01751 1, 1, 1, 1, 1, 1, 2, 3, 3, 3,
01752 3, 3, 0, 3, 1, 2, 3, 3, 0, 3,
01753 3, 3, 3, 3, 0, 3, 0, 3, 0, 2,
01754 0, 2, 0, 2, 1, 0, 3, 0, 0, 0,
01755 6, 1, 1, 1, 1, 2, 1, 1, 1, 1,
01756 3, 1, 2, 1, 1, 1, 1, 1, 1, 1,
01757 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
01758 1, 1, 1, 1, 1, 1, 0, 4, 2, 3,
01759 0, 3, 4, 2, 2, 1, 2, 0, 6, 8,
01760 4, 6, 4, 6, 2, 4, 6, 2, 4, 2,
01761 4, 1, 0, 1, 1, 1, 1, 1, 1, 1,
01762 3, 1, 3, 1, 2, 1, 2, 1, 1, 3,
01763 1, 3, 1, 1, 2, 1, 3, 3, 1, 3,
01764 1, 3, 1, 1, 2, 1, 1, 1, 2, 2,
01765 1, 1, 0, 4, 1, 2, 1, 3, 3, 2,
01766 2, 1, 1, 1, 1, 1, 1, 1, 1, 1,
01767 1, 1, 1, 0, 1, 0, 1, 2, 2, 0,
01768 1, 1, 1, 1, 1, 2, 0
01769 };
01770
01771
01772
01773
01774 static const yytype_uint16 yydefact[] =
01775 {
01776 2, 0, 0, 1, 0, 347, 348, 349, 0, 340,
01777 341, 342, 345, 343, 344, 346, 335, 336, 337, 338,
01778 298, 261, 261, 513, 512, 514, 515, 615, 0, 615,
01779 10, 0, 517, 516, 518, 601, 603, 509, 508, 602,
01780 511, 503, 504, 505, 506, 454, 523, 524, 0, 0,
01781 0, 0, 290, 626, 626, 84, 407, 480, 478, 480,
01782 482, 462, 474, 468, 476, 0, 0, 0, 3, 613,
01783 6, 9, 33, 44, 47, 55, 261, 54, 0, 72,
01784 0, 76, 86, 0, 52, 242, 0, 286, 0, 0,
01785 312, 315, 613, 0, 0, 0, 0, 56, 307, 275,
01786 276, 453, 455, 277, 278, 279, 281, 280, 282, 451,
01787 452, 450, 501, 519, 520, 283, 0, 284, 60, 5,
01788 8, 167, 178, 168, 191, 164, 184, 174, 173, 194,
01789 195, 189, 172, 171, 166, 192, 196, 197, 176, 165,
01790 179, 183, 185, 177, 170, 186, 193, 188, 187, 180,
01791 190, 175, 163, 182, 181, 162, 169, 160, 161, 157,
01792 158, 159, 115, 117, 116, 152, 153, 148, 130, 131,
01793 132, 139, 136, 138, 133, 134, 154, 155, 140, 141,
01794 145, 149, 135, 137, 127, 128, 129, 142, 143, 144,
01795 146, 147, 150, 151, 156, 120, 122, 124, 26, 118,
01796 119, 121, 123, 0, 0, 0, 0, 0, 0, 0,
01797 0, 256, 0, 243, 266, 70, 260, 626, 0, 519,
01798 520, 0, 284, 626, 596, 71, 69, 615, 68, 0,
01799 626, 431, 67, 615, 616, 0, 0, 21, 239, 0,
01800 0, 335, 336, 298, 301, 432, 0, 218, 0, 219,
01801 295, 0, 19, 0, 0, 613, 15, 18, 615, 74,
01802 14, 615, 0, 0, 619, 619, 244, 0, 0, 619,
01803 594, 615, 0, 0, 0, 82, 339, 0, 92, 93,
01804 100, 309, 408, 498, 497, 499, 496, 0, 495, 0,
01805 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
01806 502, 51, 233, 234, 622, 623, 4, 624, 614, 0,
01807 0, 0, 0, 0, 0, 0, 436, 434, 421, 61,
01808 306, 415, 417, 0, 88, 0, 80, 77, 0, 0,
01809 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
01810 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
01811 0, 0, 0, 0, 0, 429, 626, 427, 0, 53,
01812 0, 0, 0, 0, 613, 0, 614, 0, 361, 360,
01813 0, 0, 519, 520, 284, 110, 111, 0, 0, 113,
01814 0, 0, 519, 520, 284, 328, 187, 180, 190, 175,
01815 157, 158, 159, 115, 116, 592, 330, 591, 0, 612,
01816 611, 0, 308, 456, 0, 0, 125, 599, 295, 267,
01817 600, 263, 0, 0, 0, 257, 265, 429, 626, 427,
01818 0, 0, 0, 258, 615, 0, 300, 262, 615, 252,
01819 626, 626, 251, 615, 305, 50, 23, 25, 24, 0,
01820 302, 0, 0, 0, 429, 427, 0, 17, 0, 615,
01821 293, 13, 614, 73, 289, 291, 296, 621, 620, 245,
01822 621, 247, 297, 595, 0, 99, 502, 90, 85, 0,
01823 429, 626, 427, 552, 484, 487, 485, 500, 481, 457,
01824 479, 458, 459, 483, 460, 461, 0, 464, 470, 0,
01825 471, 466, 467, 0, 472, 0, 473, 0, 625, 7,
01826 27, 28, 29, 30, 31, 48, 49, 626, 626, 58,
01827 62, 626, 0, 34, 271, 0, 43, 270, 615, 0,
01828 78, 89, 46, 45, 0, 198, 266, 42, 216, 223,
01829 228, 229, 230, 225, 227, 237, 238, 231, 232, 209,
01830 210, 235, 236, 615, 224, 226, 220, 221, 222, 211,
01831 212, 213, 214, 215, 604, 606, 605, 607, 0, 261,
01832 426, 615, 604, 606, 605, 607, 0, 261, 0, 626,
01833 352, 0, 351, 0, 0, 0, 0, 0, 0, 295,
01834 429, 626, 427, 320, 325, 110, 111, 112, 0, 526,
01835 323, 525, 429, 626, 427, 0, 0, 530, 332, 604,
01836 605, 261, 35, 200, 41, 208, 0, 198, 598, 0,
01837 268, 264, 626, 604, 605, 615, 604, 605, 597, 299,
01838 617, 248, 253, 255, 304, 22, 0, 240, 0, 32,
01839 424, 422, 207, 0, 75, 16, 615, 619, 0, 83,
01840 96, 98, 615, 604, 605, 558, 555, 554, 553, 556,
01841 563, 572, 0, 583, 573, 587, 586, 582, 552, 409,
01842 551, 412, 557, 559, 561, 537, 565, 570, 626, 575,
01843 626, 580, 537, 585, 537, 0, 535, 488, 0, 463,
01844 465, 475, 469, 477, 217, 399, 615, 0, 397, 396,
01845 0, 626, 0, 274, 0, 87, 81, 0, 0, 0,
01846 0, 0, 0, 430, 65, 0, 0, 433, 0, 0,
01847 428, 63, 626, 350, 287, 626, 626, 442, 626, 353,
01848 626, 355, 313, 354, 316, 0, 0, 319, 608, 294,
01849 615, 604, 605, 0, 0, 528, 0, 0, 110, 111,
01850 114, 615, 0, 615, 552, 0, 552, 0, 250, 418,
01851 57, 249, 0, 126, 269, 259, 0, 0, 433, 0,
01852 0, 626, 615, 11, 0, 292, 246, 91, 94, 0,
01853 373, 364, 366, 615, 362, 615, 0, 0, 0, 544,
01854 564, 0, 533, 590, 574, 0, 534, 0, 547, 584,
01855 0, 549, 588, 489, 491, 492, 493, 486, 494, 395,
01856 615, 0, 559, 380, 567, 568, 626, 626, 578, 380,
01857 380, 378, 401, 0, 0, 0, 0, 0, 272, 79,
01858 199, 0, 40, 205, 39, 206, 66, 425, 618, 0,
01859 37, 203, 38, 204, 64, 423, 443, 444, 626, 445,
01860 0, 626, 358, 0, 0, 356, 0, 0, 0, 318,
01861 0, 0, 433, 0, 326, 0, 0, 433, 329, 593,
01862 615, 0, 0, 333, 419, 420, 201, 0, 254, 303,
01863 20, 615, 0, 371, 0, 560, 0, 0, 0, 410,
01864 576, 536, 562, 537, 537, 571, 626, 589, 537, 581,
01865 537, 559, 537, 0, 0, 398, 0, 386, 388, 0,
01866 566, 0, 376, 377, 0, 391, 0, 393, 0, 437,
01867 435, 0, 416, 273, 241, 36, 202, 0, 0, 447,
01868 359, 0, 12, 449, 0, 310, 311, 0, 0, 268,
01869 626, 321, 0, 527, 324, 529, 331, 531, 530, 363,
01870 374, 0, 369, 365, 411, 0, 0, 0, 540, 0,
01871 542, 532, 0, 548, 0, 545, 550, 0, 400, 577,
01872 379, 380, 380, 295, 429, 569, 626, 380, 579, 380,
01873 380, 405, 615, 403, 406, 59, 0, 446, 0, 101,
01874 102, 109, 0, 448, 0, 314, 317, 439, 440, 438,
01875 0, 0, 0, 0, 372, 0, 367, 414, 413, 537,
01876 537, 537, 537, 490, 0, 383, 0, 385, 608, 294,
01877 375, 0, 392, 0, 389, 394, 0, 402, 108, 429,
01878 626, 427, 626, 626, 0, 327, 0, 370, 0, 541,
01879 0, 538, 543, 546, 380, 380, 380, 380, 404, 608,
01880 107, 615, 604, 605, 441, 357, 322, 334, 368, 537,
01881 384, 0, 381, 387, 390, 433, 539, 380, 382
01882 };
01883
01884
01885 static const yytype_int16 yydefgoto[] =
01886 {
01887 -1, 1, 2, 68, 69, 70, 239, 568, 569, 255,
01888 256, 448, 257, 439, 72, 73, 360, 74, 75, 510,
01889 691, 246, 77, 78, 258, 79, 80, 81, 468, 82,
01890 212, 379, 380, 195, 196, 197, 198, 606, 557, 200,
01891 84, 441, 214, 263, 231, 749, 428, 429, 228, 229,
01892 216, 415, 430, 516, 517, 85, 358, 261, 262, 636,
01893 626, 362, 847, 363, 848, 733, 990, 737, 734, 932,
01894 595, 597, 747, 938, 248, 87, 88, 89, 90, 91,
01895 92, 93, 94, 95, 96, 714, 571, 722, 844, 845,
01896 371, 771, 772, 773, 960, 898, 800, 687, 688, 801,
01897 972, 973, 281, 282, 473, 776, 659, 879, 322, 511,
01898 97, 98, 712, 705, 566, 558, 320, 508, 507, 578,
01899 989, 716, 838, 918, 922, 99, 100, 101, 102, 103,
01900 104, 105, 293, 486, 106, 297, 107, 108, 295, 299,
01901 289, 287, 291, 478, 678, 677, 793, 893, 797, 109,
01902 288, 110, 111, 112, 219, 220, 115, 221, 222, 590,
01903 736, 745, 746, 881, 779, 661, 662, 891, 664, 665,
01904 666, 667, 805, 806, 668, 669, 670, 671, 808, 809,
01905 672, 673, 674, 675, 676, 782, 398, 596, 268, 431,
01906 224, 118, 630, 560, 401, 306, 425, 426, 707, 459,
01907 572, 366, 260
01908 };
01909
01910
01911
01912 #define YYPACT_NINF -816
01913 static const yytype_int16 yypact[] =
01914 {
01915 -816, 132, 2698, -816, 7384, -816, -816, -816, 6899, -816,
01916 -816, -816, -816, -816, -816, -816, 7499, 7499, -816, -816,
01917 7499, 4040, 3629, -816, -816, -816, -816, 140, 6764, 0,
01918 -816, 27, -816, -816, -816, 2944, 3766, -816, -816, 3081,
01919 -816, -816, -816, -816, -816, -816, -816, -816, 8879, 8879,
01920 166, 5108, 288, 7844, 8189, 7162, -816, 6629, -816, -816,
01921 -816, 105, 123, 177, 196, 941, 8994, 8879, -816, 17,
01922 -816, 867, -816, 484, -816, -816, 76, 294, 226, -816,
01923 210, 9224, -816, 237, 3060, 285, 311, -816, 9109, 9109,
01924 -816, -816, 6009, 9335, 9446, 9557, 6493, 30, 62, -816,
01925 -816, 256, -816, -816, -816, -816, -816, -816, -816, -816,
01926 -816, -816, -816, 491, 593, -816, 303, 616, -816, -816,
01927 -816, -816, -816, -816, -816, -816, -816, -816, -816, -816,
01928 -816, -816, -816, -816, -816, -816, -816, -816, -816, -816,
01929 -816, -816, -816, -816, -816, -816, -816, -816, -816, -816,
01930 -816, -816, -816, -816, -816, -816, -816, -816, -816, -816,
01931 -816, -816, -816, -816, -816, -816, -816, -816, -816, -816,
01932 -816, -816, -816, -816, -816, -816, -816, -816, -816, -816,
01933 -816, -816, -816, -816, -816, -816, -816, -816, -816, -816,
01934 -816, -816, -816, -816, -816, -816, -816, -816, 229, -816,
01935 -816, -816, -816, 270, 8879, 359, 5249, 8879, 8879, 8879,
01936 8879, -816, 310, 3060, 349, -816, -816, 322, 393, 34,
01937 38, 365, 63, 325, -816, -816, -816, 5894, -816, 7499,
01938 7499, -816, -816, 6124, -816, 9109, 679, -816, 309, 332,
01939 5390, -816, -816, -816, 328, 361, 76, -816, 421, 402,
01940 736, 7614, -816, 5108, 362, 17, -816, 867, 0, 408,
01941 -816, 0, 9109, 398, -15, 180, -816, 349, 429, 180,
01942 -816, 0, 502, 941, 9668, 440, -816, 466, 563, 601,
01943 645, -816, -816, -816, -816, -816, -816, 425, -816, 506,
01944 540, 545, 453, 575, 469, 101, 474, 658, 476, 222,
01945 522, -816, -816, -816, -816, -816, -816, -816, 6239, 9109,
01946 9109, 9109, 9109, 7614, 9109, 9109, -816, -816, -816, 498,
01947 -816, -816, -816, 8304, -816, 5108, 7273, 460, 8304, 8879,
01948 8879, 8879, 8879, 8879, 8879, 8879, 8879, 8879, 8879, 8879,
01949 8879, 8879, 8879, 8879, 8879, 8879, 8879, 8879, 8879, 8879,
01950 8879, 8879, 8879, 8879, 8879, 9951, 7499, 10030, 4455, 484,
01951 113, 113, 9109, 9109, 17, 585, 472, 551, -816, -816,
01952 651, 595, 67, 88, 93, 487, 542, 9109, 78, -816,
01953 114, 686, -816, -816, -816, -816, 48, 50, 60, 266,
01954 276, 289, 347, 380, 416, -816, -816, -816, 30, -816,
01955 -816, 10109, -816, -816, 8994, 8994, -816, -816, 240, -816,
01956 -816, -816, 8879, 8879, 7729, -816, -816, 10188, 7499, 10267,
01957 8879, 8879, 7959, -816, 0, 494, -816, -816, 0, -816,
01958 490, 500, -816, 136, -816, -816, -816, -816, -816, 6899,
01959 -816, 8879, 5523, 497, 10188, 10267, 8879, 867, 512, 0,
01960 -816, -816, 6354, 528, -816, 484, -816, 8074, -816, -816,
01961 8189, -816, -816, -816, 309, 703, -816, -816, 529, 9668,
01962 10346, 7499, 10425, 1091, -816, -816, -816, -816, -816, -816,
01963 -816, -816, -816, -816, -816, -816, 35, -816, -816, 481,
01964 -816, -816, -816, 45, -816, 521, -816, 8879, -816, -816,
01965 -816, -816, -816, -816, -816, -816, -816, 70, 70, -816,
01966 -816, 70, 8879, -816, 536, 537, -816, -816, 0, 9668,
01967 557, -816, -816, -816, 566, 3197, -816, -816, 402, 2451,
01968 2451, 2451, 2451, 1100, 1100, 2544, 2079, 2451, 2451, 3334,
01969 3334, 708, 708, 10928, 1100, 1100, 849, 849, 944, 385,
01970 385, 402, 402, 402, 4177, 3218, 4314, 3355, 361, 558,
01971 -816, 0, 760, -816, 768, -816, 361, 3903, 685, 693,
01972 -816, 4596, 689, 4878, 59, 59, 585, 8419, 685, 106,
01973 10504, 7499, 10583, -816, 484, -816, 703, -816, 17, -816,
01974 -816, -816, 10662, 7499, 10109, 4455, 9109, 565, -816, -816,
01975 -816, 1231, -816, 2786, -816, 3060, 6899, 2923, -816, 8879,
01976 349, -816, 325, 2807, 3492, 0, 241, 306, -816, -816,
01977 -816, -816, 7729, 7959, -816, -816, 9109, 3060, 576, -816,
01978 -816, -816, 3060, 5523, 278, -816, 0, 180, 9668, 529,
01979 588, 351, 0, 334, 348, -816, -816, -816, -816, -816,
01980 -816, -816, 893, -816, -816, -816, -816, -816, 1256, -816,
01981 -816, -816, -816, 596, -816, 581, 8879, -816, 583, 672,
01982 589, -816, 591, 682, 603, 702, -816, -816, 858, -816,
01983 -816, -816, -816, -816, 402, -816, 1059, 5664, -816, -816,
01984 5390, 70, 5664, 620, 8534, -816, 529, 9668, 8994, 8879,
01985 646, 8994, 8994, -816, 498, 361, 625, 770, 8994, 8994,
01986 -816, 498, 361, -816, -816, 8649, 766, -816, 527, -816,
01987 766, -816, -816, -816, -816, 685, 228, -816, 71, 89,
01988 0, 116, 125, 9109, 17, -816, 9109, 4455, 588, 351,
01989 -816, 0, 685, 136, 1256, 4455, 1256, 7034, -816, 62,
01990 294, -816, 8879, -816, -816, -816, 8879, 8879, 415, 8879,
01991 8879, 653, 136, -816, 654, -816, -816, -816, 318, 893,
01992 441, -816, 659, 0, -816, 0, 297, 8879, 1256, -816,
01993 -816, 742, -816, -816, -816, 58, -816, 1256, -816, -816,
01994 772, -816, -816, -816, -816, -816, -816, -816, -816, -816,
01995 0, 674, 683, 666, 9779, -816, 667, 589, -816, 673,
01996 677, -816, 675, 807, 690, 5390, 812, 8879, 710, 529,
01997 3060, 8879, -816, 3060, -816, 3060, -816, -816, -816, 8994,
01998 -816, 3060, -816, 3060, -816, -816, 536, -816, 757, -816,
01999 4993, 845, -816, 9109, 685, -816, 685, 5664, 5664, -816,
02000 8764, 4737, 126, 59, -816, 17, 685, -816, -816, -816,
02001 0, 685, 17, -816, -816, -816, 3060, 8879, 7959, -816,
02002 -816, 0, 942, 725, 1005, -816, 723, 5664, 5390, -816,
02003 -816, -816, -816, 733, 738, -816, 589, -816, 740, -816,
02004 743, -816, 740, 5779, 761, -816, 9779, 1256, -816, 830,
02005 709, 742, -816, -816, 1256, -816, 772, -816, 1080, -816,
02006 -816, 754, -816, 752, 3060, -816, 3060, 9890, 113, -816,
02007 -816, 5664, -816, -816, 113, -816, -816, 685, 685, -816,
02008 171, -816, 4455, -816, -816, -816, -816, -816, 565, -816,
02009 756, 942, 492, -816, -816, 880, 762, 1256, -816, 772,
02010 -816, -816, 772, -816, 772, -816, -816, 789, -816, 709,
02011 -816, 780, 782, -816, 10741, -816, 589, 784, -816, 790,
02012 784, -816, 225, -816, -816, -816, 874, -816, 721, 563,
02013 601, 645, 4455, -816, 4596, -816, -816, -816, -816, -816,
02014 5664, 685, 4455, 942, 756, 942, 797, -816, -816, 740,
02015 800, 740, 740, -816, 1256, -816, 772, -816, 764, 799,
02016 -816, 772, -816, 772, -816, -816, 1080, -816, 703, 10820,
02017 7499, 10899, 693, 527, 685, -816, 685, 756, 942, -816,
02018 772, -816, -816, -816, 784, 808, 784, 784, -816, 253,
02019 351, 0, 148, 159, -816, -816, -816, -816, 756, 740,
02020 -816, 772, -816, -816, -816, 169, -816, 784, -816
02021 };
02022
02023
02024 static const yytype_int16 yypgoto[] =
02025 {
02026 -816, -816, -816, -380, -816, 23, -816, -566, 358, -816,
02027 505, -816, 20, -816, -308, -42, -75, 39, -816, -330,
02028 -816, 726, -11, 850, -141, 7, -63, -816, -416, 16,
02029 1705, -294, 859, -55, -816, -16, -816, -816, 3, -816,
02030 1056, -816, 1763, -816, -6, 246, -349, 122, 4, -816,
02031 -374, -200, 47, -816, -312, -51, -816, -816, -816, -816,
02032 -816, -816, -816, -816, -816, -816, -816, -816, -816, -816,
02033 -816, -816, -816, -816, 74, -816, -816, -816, -816, -816,
02034 -816, -816, -816, -816, -816, -550, -346, -536, -61, -648,
02035 -816, -787, -765, 191, 277, 43, -816, -392, -816, -655,
02036 -816, -48, -816, -816, -816, -816, -816, -816, 215, -816,
02037 -816, -816, -816, -816, -816, -816, -90, -816, -816, -551,
02038 -816, -53, -816, -816, -816, -816, -816, -816, 877, -816,
02039 -816, -816, -816, 684, -816, -816, -816, -816, -816, -816,
02040 -816, 924, -816, -196, -816, -816, -816, -816, -816, 26,
02041 -816, 51, -816, -9, 846, 1250, 889, 1597, 1618, -816,
02042 -816, 54, -816, -407, -359, -311, -804, 957, -693, -447,
02043 -113, 205, 92, -816, -816, -816, -24, -730, -815, 110,
02044 230, -816, -654, -816, -146, -609, -816, -816, -816, 57,
02045 -385, -816, -336, -816, 613, -59, -26, -223, -560, -220,
02046 -56, 37, -2
02047 };
02048
02049
02050
02051
02052 #define YYTABLE_NINF -627
02053 static const yytype_int16 yytable[] =
02054 {
02055 119, 235, 286, 238, 276, 211, 211, 561, 402, 211,
02056 434, 199, 237, 307, 361, 573, 527, 364, 327, 559,
02057 522, 567, 71, 423, 71, 725, 232, 120, 727, 742,
02058 276, 199, 810, 365, 201, 453, 307, 618, 454, 724,
02059 611, 396, 276, 276, 276, 461, 359, 359, 611, 463,
02060 359, 266, 270, 639, 201, 758, 300, 889, 259, 202,
02061 199, 786, 628, 217, 217, 601, 660, 217, 841, 615,
02062 318, 275, 846, 223, 223, 618, 86, 223, 86, 202,
02063 319, 559, 768, 567, 587, 882, 721, 943, 316, 968,
02064 218, 218, -101, 480, 218, 483, -105, 487, 474, 199,
02065 264, 487, 316, 696, 974, 301, 308, 940, 474, 631,
02066 265, 269, 449, -102, -107, 588, 690, 399, -109, 692,
02067 876, 457, 642, -521, 884, 86, 570, -522, 458, 277,
02068 585, -108, 3, 890, 586, -513, 631, -512, 215, 225,
02069 218, -104, 226, 234, 475, 894, 476, -514, 685, -101,
02070 -106, -103, 421, -102, 475, 277, 476, 655, 304, 240,
02071 305, -104, 218, 218, 489, 400, 218, 370, 381, 381,
02072 852, 856, -106, 314, 315, 849, 994, 679, -109, 861,
02073 656, 857, -103, -513, 518, -512, 840, 682, 577, 968,
02074 686, 433, 858, 435, 317, -514, 451, 902, 903, 307,
02075 304, 619, 305, -92, 882, 621, 943, -96, 317, -604,
02076 624, 467, 974, 490, 230, 416, 211, 889, 211, 211,
02077 455, 416, 250, 276, -93, -98, 634, -605, 432, -100,
02078 1027, 423, 730, 589, 500, 501, 502, 503, 618, 803,
02079 318, 570, -99, 962, 741, 464, 631, 292, 611, 611,
02080 969, 660, -95, 764, 304, 304, 305, 305, 631, 882,
02081 259, -97, -94, 1048, 466, 294, -105, 359, 359, 359,
02082 359, 447, 505, 506, 217, 276, 217, 951, 233, 234,
02083 86, 819, 987, 234, 223, 495, 223, 574, 575, -104,
02084 680, -104, 452, 1000, 925, 695, 926, 680, 740, 815,
02085 -106, 218, -106, 218, 218, 576, 934, 218, 307, 218,
02086 -103, 936, -103, 788, 86, 791, 460, 931, 882, 296,
02087 359, 359, 321, 458, 591, 86, 877, 86, 71, 446,
02088 759, 499, 259, 504, 496, 584, 218, 660, 298, 660,
02089 888, 323, 520, 892, -433, 211, 324, 775, 277, 424,
02090 1035, 427, 328, -515, 432, -108, -104, 1010, 58, -95,
02091 565, 1016, 513, -517, 850, 406, 991, 523, 234, 304,
02092 515, 305, -339, -97, 826, 515, -516, 985, 986, 988,
02093 851, 834, 86, 218, 218, 218, 218, 86, 218, 218,
02094 522, -604, 404, -73, -105, 760, -105, 218, 355, 86,
02095 277, -515, 218, 837, 565, -433, 467, 211, 233, 254,
02096 878, -517, 755, 765, -87, 408, 432, 766, 276, -339,
02097 -339, -106, 565, 625, -516, 412, 1026, -288, 416, 416,
02098 218, -288, 86, 860, -518, 862, 218, 218, -294, 413,
02099 119, 1025, 199, 602, 604, 356, 357, 440, 565, -95,
02100 -433, 218, -433, -433, 420, 329, 467, 967, 414, 970,
02101 211, 422, 71, -97, 442, 201, 227, -507, 276, 432,
02102 -95, 612, 329, -95, 1046, 565, 1047, -95, 218, 218,
02103 417, 1055, -518, 618, -97, -294, -294, -97, 474, -605,
02104 202, -97, 218, 645, 611, 646, 647, 648, 649, 230,
02105 999, 450, 1001, -510, 867, 689, 689, 1002, 444, 689,
02106 352, 353, 354, -601, 637, -507, 86, 700, 723, 723,
02107 859, 314, 315, -72, 948, 950, 86, 418, 419, 953,
02108 -103, 955, 735, 956, 475, 706, 476, 477, 456, 869,
02109 811, 843, 840, 277, 645, 218, 646, 647, 648, 649,
02110 875, -510, 703, 470, 743, 418, 445, 1034, 465, 1036,
02111 710, 755, 462, 704, 254, 484, 1037, 717, -602, 474,
02112 211, 711, 982, 804, -507, 767, 469, 872, 984, 432,
02113 -521, 488, 211, 1049, 762, 565, 491, 276, 494, 706,
02114 753, 432, 497, 277, 509, 748, 521, 565, 443, 751,
02115 471, 472, 577, 474, 1057, 750, -101, 579, 474, 199,
02116 416, 254, 482, 498, -608, 475, 706, 476, 479, -601,
02117 583, -507, -507, 681, 726, -601, 622, -92, 995, -510,
02118 629, 119, 201, 620, 467, 887, 623, 935, 474, 887,
02119 1029, 1031, 1032, 1033, 633, 86, 276, 86, 939, 475,
02120 -519, 476, 481, 71, 475, 218, 476, 202, 853, 864,
02121 812, 855, 807, 683, -87, 638, 783, 218, 783, 86,
02122 218, 1041, -266, 694, -602, -608, -510, -510, 854, 761,
02123 -602, 698, -522, 254, 475, 631, 476, 485, -520, 689,
02124 1056, 359, 863, 697, 359, 713, -424, -519, -519, 827,
02125 218, 715, 719, 744, 706, 405, 748, 86, -102, 763,
02126 751, 777, 277, 839, 842, 706, 842, 778, 842, 781,
02127 -608, 474, -608, -608, 784, 785, -604, 787, 76, -93,
02128 76, -109, -284, 436, 789, -520, -520, 523, 580, 790,
02129 822, 824, 76, 76, 437, 438, 76, 830, 832, 812,
02130 199, 811, -100, 276, 792, 887, -267, 886, 811, 416,
02131 811, 86, 515, 821, 86, 828, 86, 475, 924, 476,
02132 492, 277, 218, 592, 812, 218, 218, 76, 329, -284,
02133 -284, 840, 218, 218, 804, 581, 582, 870, 804, 868,
02134 -295, 804, 76, 804, 895, 874, 964, 723, 896, 933,
02135 650, 359, 897, 901, 783, 783, 937, 218, 1019, 904,
02136 218, 86, 651, 906, 76, 76, 908, 909, 76, 86,
02137 593, 594, 912, 910, 645, 446, 646, 647, 648, 649,
02138 650, 350, 351, 352, 353, 354, 919, -295, -295, 923,
02139 654, 655, 651, 593, 594, 276, -268, 917, 113, 708,
02140 113, -108, 905, 907, 921, 1020, 1021, 709, 811, 829,
02141 811, 941, 944, 652, 656, 811, 276, 811, 915, 947,
02142 654, 655, -99, 807, 949, -104, 952, 966, 900, 954,
02143 807, 958, 807, -106, 783, -103, 963, 975, -269, 86,
02144 997, 804, 993, 804, 656, 998, -95, 113, 804, 1003,
02145 804, 278, -604, 218, -97, 811, -94, 309, 310, 311,
02146 312, 313, 794, 795, 86, 796, 1004, 218, 1006, 329,
02147 1011, 86, 86, 46, 47, 86, 1013, 278, 842, 718,
02148 1018, 720, 76, 1028, 342, 343, 1030, -605, 804, 372,
02149 382, 382, 382, 368, 1051, 645, 1017, 646, 647, 648,
02150 649, 86, 86, 76, 385, 76, 76, 635, 835, 76,
02151 871, 76, 1045, 799, 783, 865, 76, 86, 1038, 1044,
02152 959, 349, 350, 351, 352, 353, 354, 76, 403, 76,
02153 807, 493, 807, 290, 769, 397, 885, 807, 76, 807,
02154 770, 978, 992, 965, 645, 86, 646, 647, 648, 649,
02155 41, 42, 43, 44, 1005, 1007, 86, 961, 883, 211,
02156 1012, 598, 1014, 1015, 329, 706, 0, 0, 432, 0,
02157 717, 842, 0, 0, 565, 0, 0, 807, 0, 342,
02158 343, 0, 0, 769, 76, 76, 76, 76, 76, 76,
02159 76, 76, 0, 0, 0, 813, 0, 0, 814, 76,
02160 816, 76, 113, 0, 76, 0, 86, 645, 86, 646,
02161 647, 648, 649, 0, 86, 0, 86, 350, 351, 352,
02162 353, 354, 213, 213, 0, 0, 213, 1050, 1052, 1053,
02163 1054, 0, 76, 0, 76, 0, 113, 0, 76, 76,
02164 0, 0, 0, 0, 218, 0, 769, 113, 0, 113,
02165 1058, 0, 942, 76, 247, 249, 0, 0, 0, 213,
02166 213, 645, 0, 646, 647, 648, 649, 650, 0, 0,
02167 278, 0, 302, 303, 0, 0, 0, 0, 0, 651,
02168 76, 76, 971, 0, 646, 647, 648, 649, 0, 0,
02169 0, 0, 0, 645, 76, 646, 647, 648, 649, 650,
02170 652, 0, 0, 0, 113, 0, 653, 654, 655, 113,
02171 0, 651, 0, 0, 0, 0, 0, 0, 76, 0,
02172 329, 113, 278, 911, 0, 0, 0, 0, 76, 0,
02173 0, 656, 652, 0, 657, 342, 343, 0, 653, 654,
02174 655, 0, 0, 0, 0, 0, 0, 76, 920, 0,
02175 0, 0, 234, 0, 113, 927, 928, 0, 0, 930,
02176 0, 0, 0, 656, 0, 0, 657, 0, 0, 0,
02177 347, 348, 349, 350, 351, 352, 353, 354, 0, 658,
02178 0, -626, 0, 0, 0, 945, 946, 0, 0, -626,
02179 -626, -626, 0, 0, -626, -626, -626, 0, -626, 0,
02180 0, 957, 114, 0, 114, 0, 0, -626, -626, 0,
02181 213, 0, 0, 213, 213, 213, 302, 0, -626, -626,
02182 0, -626, -626, -626, -626, -626, 0, 0, 0, 983,
02183 0, 0, 0, 213, 0, 213, 213, 0, 113, 0,
02184 0, 0, 0, 0, 0, 0, 0, 76, 113, 76,
02185 0, 114, 0, 0, 0, 279, 0, 76, 645, 0,
02186 646, 647, 648, 649, 650, 278, 0, 0, -626, 76,
02187 0, 76, 76, 0, 0, 0, 651, 0, 0, 0,
02188 0, 279, 0, 0, 0, 0, 0, 0, 0, 0,
02189 1022, -626, 1023, 373, 383, 383, 383, 652, 1024, 0,
02190 0, 0, 76, 653, 654, 655, 0, 0, 0, 76,
02191 0, 0, 0, -626, -626, 278, -626, 0, 0, 230,
02192 -626, 0, -626, 0, -626, 0, 0, 0, 656, 213,
02193 0, 657, 0, 0, 525, 528, 529, 530, 531, 532,
02194 533, 534, 535, 536, 537, 538, 539, 540, 541, 542,
02195 543, 544, 545, 546, 547, 548, 549, 550, 551, 552,
02196 553, 0, 213, 76, 0, 0, 76, 113, 76, 113,
02197 0, 0, 0, 0, 76, 0, 0, 76, 76, 0,
02198 663, 0, 0, 0, 76, 76, 0, 0, 0, 0,
02199 0, 113, 0, 0, 0, 0, 0, 0, 0, 0,
02200 0, 0, 0, 0, 0, 0, 114, 0, 0, 76,
02201 603, 605, 76, 76, 0, 0, 0, 0, 607, 213,
02202 213, 76, 0, 0, 213, 0, 603, 605, 213, 113,
02203 0, 0, 0, 0, 278, 0, 0, 0, 0, 0,
02204 114, 0, 0, 0, 0, 0, 0, 627, 0, 0,
02205 0, 114, 632, 114, 0, 0, 0, 0, 0, 0,
02206 0, 0, 0, 213, 0, 0, 213, 0, 0, 0,
02207 0, 0, 0, 0, 279, 0, 0, 213, 0, 0,
02208 0, 0, 0, 113, 0, 0, 113, 0, 113, 0,
02209 0, 76, 0, 278, 0, 0, 0, 0, 0, 0,
02210 0, 0, 0, 684, 0, 76, 0, 0, 114, 0,
02211 0, 0, 0, 114, 0, 0, 76, 0, 213, 76,
02212 0, 0, 0, 76, 76, 114, 279, 76, 0, 0,
02213 0, 0, 0, 113, 0, 0, 0, 0, 0, 0,
02214 0, 113, 0, 0, 0, 0, 0, 0, 0, 116,
02215 0, 116, 0, 76, 76, 0, 0, 0, 114, 774,
02216 0, 0, 0, 0, 0, 663, 0, 0, 0, 76,
02217 117, 0, 117, 0, 0, 0, 0, 0, 0, 0,
02218 0, 0, 0, 213, 0, 0, 0, 213, 0, 0,
02219 0, 0, 0, 802, 0, 0, 0, 76, 116, 213,
02220 382, 0, 0, 0, 0, 0, 0, 0, 76, 0,
02221 0, 113, 0, 0, 0, 213, 0, 0, 0, 117,
02222 0, 0, 0, 280, 0, 0, 0, 0, 213, 213,
02223 0, 0, 0, 0, 0, 0, 113, 0, 0, 0,
02224 0, 0, 114, 113, 113, 0, 0, 113, 0, 280,
02225 0, 663, 114, 663, 0, 0, 0, 83, 76, 83,
02226 76, 374, 384, 384, 0, 0, 76, 0, 76, 279,
02227 0, 0, 213, 113, 113, 0, 774, 873, 0, 0,
02228 0, 0, 0, 0, 0, 663, 0, 0, 0, 113,
02229 0, 0, 382, 0, 663, 0, 76, 0, 0, 0,
02230 213, 0, 0, 0, 607, 820, 83, 823, 825, 0,
02231 0, 0, 0, 979, 831, 833, 0, 113, 0, 279,
02232 0, 213, 0, 0, 0, 0, 0, 0, 113, 0,
02233 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02234 0, 0, 0, 0, 0, 0, 0, 0, 369, 0,
02235 0, 0, 0, 116, 0, 0, 0, 0, 866, 0,
02236 0, 0, 823, 825, 0, 831, 833, 267, 0, 0,
02237 0, 114, 0, 114, 117, 0, 0, 0, 113, 774,
02238 113, 774, 0, 213, 0, 0, 113, 116, 113, 0,
02239 0, 0, 0, 0, 0, 114, 0, 0, 116, 0,
02240 116, 0, 0, 0, 802, 0, 0, 0, 117, 0,
02241 0, 802, 0, 0, 0, 0, 0, 0, 0, 117,
02242 0, 117, 0, 213, 0, 0, 0, 914, 0, 0,
02243 0, 0, 0, 114, 0, 916, 0, 0, 279, 0,
02244 0, 0, 280, 0, 0, 0, 0, 0, 774, 996,
02245 0, 0, 0, 0, 663, 116, 213, 0, 0, 0,
02246 116, 83, 0, 0, 0, 0, 0, 0, 0, 0,
02247 0, 0, 116, 916, 213, 0, 117, 0, 0, 0,
02248 0, 117, 0, 0, 0, 0, 0, 114, 0, 0,
02249 114, 0, 114, 117, 280, 83, 0, 279, 0, 0,
02250 774, 0, 774, 0, 0, 116, 83, 0, 83, 0,
02251 0, 802, 0, 0, 0, 0, 0, 407, 0, 0,
02252 409, 410, 411, 0, 0, 0, 117, 0, 0, 0,
02253 0, 0, 0, 0, 0, 774, 0, 114, 0, 0,
02254 0, 0, 0, 0, 0, 114, 0, 0, 0, 0,
02255 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02256 0, 0, 0, 83, 0, 0, 0, 0, 83, 0,
02257 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02258 83, 0, 0, 524, 0, 0, 0, 0, 0, 116,
02259 0, 0, 0, 0, 0, 0, 0, 0, 0, 116,
02260 0, 0, 0, 0, 383, 0, 0, 0, 0, 0,
02261 117, 0, 0, 83, 0, 114, 0, 0, 0, 0,
02262 117, 0, 0, 0, 0, 0, 213, 0, 0, 0,
02263 0, 0, 0, 0, 0, 0, 514, 280, 0, 0,
02264 114, 526, 0, 0, 0, 0, 0, 114, 114, 0,
02265 0, 114, 0, 0, 0, 0, 0, 0, 0, 0,
02266 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02267 0, 0, 0, 0, 0, 0, 0, 114, 114, 0,
02268 0, 0, 0, 0, 0, 0, 0, 280, 0, 0,
02269 0, 0, 0, 114, 0, 0, 383, 83, 0, 329,
02270 330, 331, 332, 333, 334, 335, 336, 83, 338, 339,
02271 0, 0, 0, 0, 342, 343, 0, 980, 116, 0,
02272 116, 114, 0, 0, 0, 0, 608, 610, 0, 0,
02273 0, 0, 114, 0, 0, 267, 0, 0, 0, 117,
02274 0, 117, 116, 0, 0, 0, 0, 345, 346, 347,
02275 348, 349, 350, 351, 352, 353, 354, 0, 0, 0,
02276 0, 0, 0, 117, 0, 0, 0, 0, 0, 0,
02277 610, 0, 0, 267, 0, 0, 0, 0, 0, 0,
02278 116, 0, 114, 0, 114, 0, 0, 0, 0, 0,
02279 114, 0, 114, 0, 0, 0, 0, 0, 0, 0,
02280 0, 117, 0, 0, 0, 0, 280, 0, 0, 0,
02281 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02282 0, 0, 0, 0, 0, 693, 83, 0, 83, 0,
02283 0, 0, 0, 0, 116, 0, 0, 116, 0, 116,
02284 0, 0, 0, 0, 0, 0, 798, 0, 0, 0,
02285 83, 0, 0, 0, 0, 117, 0, 0, 117, 0,
02286 117, 0, 0, 0, 0, 280, 0, 0, 0, 0,
02287 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02288 0, 0, 0, 0, 116, 0, 0, 0, 83, 0,
02289 526, 0, 116, 0, 0, 0, 0, 0, 0, 0,
02290 0, 0, 0, 0, 0, 117, 0, 0, 0, 0,
02291 0, 0, 0, 117, 0, 0, 0, 0, 0, 0,
02292 0, 0, 754, 0, 0, 0, 0, 0, 0, 0,
02293 0, 0, 0, 0, 0, 610, 267, 0, 0, 0,
02294 0, 0, 83, 0, 0, 83, 0, 83, 0, 0,
02295 0, 0, 0, 524, 0, 0, 0, 0, 0, 0,
02296 0, 0, 116, 0, 0, 0, 0, 0, 0, 0,
02297 0, 0, 384, 0, 0, 0, 0, 0, 0, 780,
02298 0, 0, 0, 117, 0, 0, 0, 116, 0, 0,
02299 0, 0, 83, 0, 116, 116, 0, 0, 116, 0,
02300 83, 0, 0, 0, 0, 0, 0, 818, 117, 0,
02301 0, 0, 0, 0, 0, 117, 117, 0, 0, 117,
02302 0, 0, 0, 0, 116, 116, 0, 0, 836, 0,
02303 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02304 116, 0, 0, 0, 0, 117, 117, 0, 0, 0,
02305 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02306 0, 117, 0, 0, 384, 0, 0, 0, 116, 0,
02307 83, 329, -627, -627, -627, -627, 334, 335, 0, 116,
02308 -627, -627, 0, 0, 0, 981, 342, 343, 0, 117,
02309 880, 0, 0, 0, 0, 83, 0, 0, 0, 0,
02310 117, 0, 83, 83, 0, 0, 83, 0, 0, 0,
02311 0, 0, 0, 0, 0, 0, 0, 0, 0, 345,
02312 346, 347, 348, 349, 350, 351, 352, 353, 354, 116,
02313 913, 116, 83, 83, 0, 0, 0, 116, 0, 116,
02314 0, 0, 0, 0, 0, 0, 0, 0, 83, 0,
02315 117, 0, 117, 0, 0, 0, 0, 0, 117, 0,
02316 117, 0, 0, 929, 329, 330, 331, 332, 333, 334,
02317 335, 0, 977, 338, 339, 0, 83, 0, 0, 342,
02318 343, 267, 0, 0, 0, 0, 0, 83, 0, 0,
02319 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02320 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02321 0, 0, 345, 346, 347, 348, 349, 350, 351, 352,
02322 353, 354, 0, 0, 0, 0, 0, 0, 0, 0,
02323 0, 0, 0, 0, 0, 0, 0, 83, 0, 83,
02324 0, 0, 0, 0, 0, 83, 0, 83, -626, 4,
02325 0, 5, 6, 7, 8, 9, 0, 0, 0, 10,
02326 11, 0, 0, 0, 12, 0, 13, 14, 15, 16,
02327 17, 18, 19, 0, 0, 0, 0, 0, 20, 21,
02328 22, 23, 24, 25, 26, 0, 0, 27, 0, 0,
02329 0, 0, 0, 28, 29, 30, 31, 32, 33, 34,
02330 35, 36, 37, 38, 39, 40, 0, 41, 42, 43,
02331 44, 0, 45, 46, 47, 0, 48, 49, 0, 0,
02332 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02333 0, 0, 0, 0, 0, 0, 50, 0, 0, 51,
02334 52, 0, 53, 54, 0, 55, 0, 0, 56, 57,
02335 58, 59, 60, 61, 62, 63, 64, -608, 0, 0,
02336 0, 0, 0, 0, 0, -608, -608, -608, 0, 0,
02337 -608, -608, -608, 0, -608, 0, 65, 66, 67, 0,
02338 752, 0, 0, -608, -608, -608, -608, 0, 0, -626,
02339 0, -626, 0, 0, -608, -608, 0, -608, -608, -608,
02340 -608, -608, 0, 0, 0, 0, 329, 330, 331, 332,
02341 333, 334, 335, 336, 337, 338, 339, 340, 341, 0,
02342 0, 342, 343, 0, 0, 0, 0, -608, -608, -608,
02343 -608, -608, -608, -608, -608, -608, -608, -608, -608, -608,
02344 0, 0, -608, -608, -608, 0, 756, -608, 0, 0,
02345 0, 0, 344, -608, 345, 346, 347, 348, 349, 350,
02346 351, 352, 353, 354, 0, 0, 0, -608, 0, 0,
02347 -608, 0, -105, -608, -608, -608, -608, -608, -608, -608,
02348 -608, -608, -608, -608, -608, 0, 0, 0, 0, -608,
02349 -608, -608, -608, -608, -507, 0, -608, -608, -608, 0,
02350 -608, 0, -507, -507, -507, 0, 0, -507, -507, -507,
02351 0, -507, 0, 0, 0, 0, 0, 699, 0, -507,
02352 0, -507, -507, -507, 0, 0, 0, 0, 0, 0,
02353 0, -507, -507, 0, -507, -507, -507, -507, -507, 0,
02354 0, 0, 0, 329, 330, 331, 332, 333, 334, 335,
02355 336, 337, 338, 339, 340, 341, 0, 0, 342, 343,
02356 0, 0, 0, 0, -507, -507, -507, -507, -507, -507,
02357 -507, -507, -507, -507, -507, -507, -507, 0, 0, -507,
02358 -507, -507, 0, -507, -507, 0, 0, 0, 0, 344,
02359 -507, 345, 346, 347, 348, 349, 350, 351, 352, 353,
02360 354, 0, 0, 0, -507, 0, 0, -507, 0, -507,
02361 -507, -507, -507, -507, -507, -507, -507, -507, -507, -507,
02362 -507, -507, 0, 0, 0, 0, 0, -507, -507, -507,
02363 -507, -510, 0, -507, -507, -507, 0, -507, 0, -510,
02364 -510, -510, 0, 0, -510, -510, -510, 0, -510, 0,
02365 0, 0, 0, 0, 0, 0, -510, 0, -510, -510,
02366 -510, 0, 0, 0, 0, 0, 0, 0, -510, -510,
02367 0, -510, -510, -510, -510, -510, 0, 0, 0, 0,
02368 329, 330, 331, 332, 333, 334, 335, 336, 337, 338,
02369 339, 340, 341, 0, 0, 342, 343, 0, 0, 0,
02370 0, -510, -510, -510, -510, -510, -510, -510, -510, -510,
02371 -510, -510, -510, -510, 0, 0, -510, -510, -510, 0,
02372 -510, -510, 0, 0, 0, 0, 344, -510, 345, 346,
02373 347, 348, 349, 350, 351, 352, 353, 354, 0, 0,
02374 0, -510, 0, 0, -510, 0, -510, -510, -510, -510,
02375 -510, -510, -510, -510, -510, -510, -510, -510, -510, 0,
02376 0, 0, 0, 0, -510, -510, -510, -510, -609, 0,
02377 -510, -510, -510, 0, -510, 0, -609, -609, -609, 0,
02378 0, -609, -609, -609, 0, -609, 0, 0, 0, 0,
02379 0, 699, 0, 0, -609, -609, -609, -609, 0, 0,
02380 0, 0, 0, 0, 0, -609, -609, 0, -609, -609,
02381 -609, -609, -609, 0, 0, 0, 0, 329, 330, 331,
02382 332, 333, 334, 335, 336, 337, 338, 339, 340, 341,
02383 0, 0, 342, 343, 0, 0, 0, 0, -609, -609,
02384 -609, -609, -609, -609, -609, -609, -609, -609, -609, -609,
02385 -609, 0, 0, -609, -609, -609, 0, 0, -609, 0,
02386 0, 0, 0, 344, -609, 345, 346, 347, 348, 349,
02387 350, 351, 352, 353, 354, 0, 0, 0, -609, 0,
02388 0, -609, 0, -243, -609, -609, -609, -609, -609, -609,
02389 -609, -609, -609, -609, -609, -609, 0, 0, 0, 0,
02390 -609, -609, -609, -609, -609, -610, 0, -609, -609, -609,
02391 0, -609, 0, -610, -610, -610, 0, 0, -610, -610,
02392 -610, 0, -610, 0, 0, 0, 0, 0, 0, 0,
02393 0, -610, -610, -610, -610, 0, 0, 0, 0, 0,
02394 0, 0, -610, -610, 0, -610, -610, -610, -610, -610,
02395 0, 0, 0, 0, 329, 330, 331, 332, 333, 334,
02396 335, 336, 337, 338, 339, -627, -627, 0, 0, 342,
02397 343, 0, 0, 0, 0, -610, -610, -610, -610, -610,
02398 -610, -610, -610, -610, -610, -610, -610, -610, 0, 0,
02399 -610, -610, -610, 0, 0, -610, 0, 0, 0, 0,
02400 0, -610, 345, 346, 347, 348, 349, 350, 351, 352,
02401 353, 354, 0, 0, 0, -610, 0, 0, -610, 0,
02402 0, -610, -610, -610, -610, -610, -610, -610, -610, -610,
02403 -610, -610, -610, 0, 0, 0, 0, -610, -610, -610,
02404 -610, -610, -294, 0, -610, -610, -610, 0, -610, 0,
02405 -294, -294, -294, 0, 0, -294, -294, -294, 0, -294,
02406 0, 0, 0, 0, 0, 0, 0, 0, 0, -294,
02407 -294, -294, 0, 0, 0, 0, 0, 0, 0, -294,
02408 -294, 0, -294, -294, -294, -294, -294, 0, 0, 0,
02409 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02410 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02411 0, 0, -294, -294, -294, -294, -294, -294, -294, -294,
02412 -294, -294, -294, -294, -294, 0, 0, -294, -294, -294,
02413 0, 757, -294, 0, 0, 0, 0, 0, -294, 0,
02414 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02415 0, 0, -294, 0, 0, -294, 0, -107, -294, -294,
02416 -294, -294, -294, -294, -294, -294, -294, -294, -294, -294,
02417 0, 0, 0, 0, 0, -294, -294, -294, -294, -432,
02418 0, -294, -294, -294, 0, -294, 0, -432, -432, -432,
02419 0, 0, -432, -432, -432, 0, -432, 0, 0, 0,
02420 0, 0, 0, 0, 0, -432, -432, -432, 0, 0,
02421 0, 0, 0, 0, 0, 0, -432, -432, 0, -432,
02422 -432, -432, -432, -432, 0, 0, 0, 0, 0, 0,
02423 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02424 0, 0, 0, 0, 0, 0, 0, 0, 0, -432,
02425 -432, -432, -432, -432, -432, -432, -432, -432, -432, -432,
02426 -432, -432, 0, 0, -432, -432, -432, 0, 0, -432,
02427 0, 0, 0, 0, 0, -432, 0, 0, 0, 0,
02428 0, 0, 0, 0, 0, 0, 0, 0, 0, -432,
02429 0, 0, 0, 0, 0, -432, 0, -432, -432, -432,
02430 -432, -432, -432, -432, -432, -432, -432, 0, 0, 0,
02431 0, -432, -432, -432, -432, -432, -285, 230, -432, -432,
02432 -432, 0, -432, 0, -285, -285, -285, 0, 0, -285,
02433 -285, -285, 0, -285, 0, 0, 0, 0, 0, 0,
02434 0, 0, 0, -285, -285, -285, 0, 0, 0, 0,
02435 0, 0, 0, -285, -285, 0, -285, -285, -285, -285,
02436 -285, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02437 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02438 0, 0, 0, 0, 0, 0, -285, -285, -285, -285,
02439 -285, -285, -285, -285, -285, -285, -285, -285, -285, 0,
02440 0, -285, -285, -285, 0, 0, -285, 0, 0, 0,
02441 0, 0, -285, 0, 0, 0, 0, 0, 0, 0,
02442 0, 0, 0, 0, 0, 0, -285, 0, 0, -285,
02443 0, 0, -285, -285, -285, -285, -285, -285, -285, -285,
02444 -285, -285, -285, -285, 0, 0, 0, 0, 0, -285,
02445 -285, -285, -285, -422, 0, -285, -285, -285, 0, -285,
02446 0, -422, -422, -422, 0, 0, -422, -422, -422, 0,
02447 -422, 0, 0, 0, 0, 0, 0, 0, 0, -422,
02448 -422, -422, 0, 0, 0, 0, 0, 0, 0, 0,
02449 -422, -422, 0, -422, -422, -422, -422, -422, 0, 0,
02450 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02451 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02452 0, 0, 0, -422, -422, -422, -422, -422, -422, -422,
02453 -422, -422, -422, -422, -422, -422, 0, 0, -422, -422,
02454 -422, 0, 0, -422, 0, 0, 0, 0, 0, -422,
02455 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02456 0, 0, 0, -422, 0, 0, 0, 0, 0, -422,
02457 0, -422, -422, -422, -422, -422, -422, -422, -422, -422,
02458 -422, 0, 0, 0, 0, -422, -422, -422, -422, -422,
02459 -301, -422, -422, -422, -422, 0, -422, 0, -301, -301,
02460 -301, 0, 0, -301, -301, -301, 0, -301, 0, 0,
02461 0, 0, 0, 0, 0, 0, 0, -301, -301, 0,
02462 0, 0, 0, 0, 0, 0, 0, -301, -301, 0,
02463 -301, -301, -301, -301, -301, 0, 0, 0, 0, 0,
02464 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02465 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02466 -301, -301, -301, -301, -301, -301, -301, -301, -301, -301,
02467 -301, -301, -301, 0, 0, -301, -301, -301, 0, 0,
02468 -301, 0, 0, 0, 0, 0, -301, 0, 0, 0,
02469 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02470 -301, 0, 0, 0, 0, 0, -301, 0, -301, -301,
02471 -301, -301, -301, -301, -301, -301, -301, -301, 0, 0,
02472 0, 0, 0, -301, -301, -301, -301, -608, 227, -301,
02473 -301, -301, 0, -301, 0, -608, -608, -608, 0, 0,
02474 0, -608, -608, 0, -608, 0, 0, 0, 0, 0,
02475 0, 0, 0, -608, 0, 0, 0, 0, 0, 0,
02476 0, 0, 0, 0, -608, -608, 0, -608, -608, -608,
02477 -608, -608, 0, 0, 0, 0, 0, 0, 0, 0,
02478 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02479 0, 0, 0, 0, 0, 0, 0, -608, -608, -608,
02480 -608, -608, -608, -608, -608, -608, -608, -608, -608, -608,
02481 0, 0, -608, -608, -608, 0, 701, 0, 0, 0,
02482 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02483 0, 0, 0, 0, 0, 0, 0, -608, 0, 0,
02484 0, 0, -105, -608, 0, -608, -608, -608, -608, -608,
02485 -608, -608, -608, -608, -608, 0, 0, 0, 0, -608,
02486 -608, -608, -608, -96, -294, 0, -608, 0, -608, 0,
02487 -608, 0, -294, -294, -294, 0, 0, 0, -294, -294,
02488 0, -294, 0, 0, 0, 0, 0, 0, 0, 0,
02489 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02490 0, -294, -294, 0, -294, -294, -294, -294, -294, 0,
02491 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02492 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02493 0, 0, 0, 0, -294, -294, -294, -294, -294, -294,
02494 -294, -294, -294, -294, -294, -294, -294, 0, 0, -294,
02495 -294, -294, 0, 702, 0, 0, 0, 0, 0, 0,
02496 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02497 0, 0, 0, 0, -294, 0, 0, 0, 0, -107,
02498 -294, 0, -294, -294, -294, -294, -294, -294, -294, -294,
02499 -294, -294, 0, 0, 0, 0, 0, -294, -294, -294,
02500 -98, 0, 0, -294, 0, -294, 251, -294, 5, 6,
02501 7, 8, 9, -626, -626, -626, 10, 11, 0, 0,
02502 -626, 12, 0, 13, 14, 15, 16, 17, 18, 19,
02503 0, 0, 0, 0, 0, 20, 21, 22, 23, 24,
02504 25, 26, 0, 0, 27, 0, 0, 0, 0, 0,
02505 28, 29, 252, 31, 32, 33, 34, 35, 36, 37,
02506 38, 39, 40, 0, 41, 42, 43, 44, 0, 45,
02507 46, 47, 0, 48, 49, 0, 0, 0, 0, 0,
02508 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02509 0, 0, 0, 50, 0, 0, 51, 52, 0, 53,
02510 54, 0, 55, 0, 0, 56, 57, 58, 59, 60,
02511 61, 62, 63, 64, 0, 0, 0, 0, 0, 0,
02512 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02513 0, 0, 0, 65, 66, 67, 0, 0, 0, 0,
02514 0, 0, 0, 0, 0, 0, -626, 251, -626, 5,
02515 6, 7, 8, 9, 0, 0, -626, 10, 11, 0,
02516 -626, -626, 12, 0, 13, 14, 15, 16, 17, 18,
02517 19, 0, 0, 0, 0, 0, 20, 21, 22, 23,
02518 24, 25, 26, 0, 0, 27, 0, 0, 0, 0,
02519 0, 28, 29, 252, 31, 32, 33, 34, 35, 36,
02520 37, 38, 39, 40, 0, 41, 42, 43, 44, 0,
02521 45, 46, 47, 0, 48, 49, 0, 0, 0, 0,
02522 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02523 0, 0, 0, 0, 50, 0, 0, 51, 52, 0,
02524 53, 54, 0, 55, 0, 0, 56, 57, 58, 59,
02525 60, 61, 62, 63, 64, 0, 0, 0, 0, 0,
02526 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02527 0, 0, 0, 0, 65, 66, 67, 0, 0, 0,
02528 0, 0, 0, 0, 0, 0, 0, -626, 251, -626,
02529 5, 6, 7, 8, 9, 0, 0, -626, 10, 11,
02530 0, 0, -626, 12, -626, 13, 14, 15, 16, 17,
02531 18, 19, 0, 0, 0, 0, 0, 20, 21, 22,
02532 23, 24, 25, 26, 0, 0, 27, 0, 0, 0,
02533 0, 0, 28, 29, 252, 31, 32, 33, 34, 35,
02534 36, 37, 38, 39, 40, 0, 41, 42, 43, 44,
02535 0, 45, 46, 47, 0, 48, 49, 0, 0, 0,
02536 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02537 0, 0, 0, 0, 0, 50, 0, 0, 51, 52,
02538 0, 53, 54, 0, 55, 0, 0, 56, 57, 58,
02539 59, 60, 61, 62, 63, 64, 0, 0, 0, 0,
02540 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02541 0, 0, 0, 0, 0, 65, 66, 67, 0, 0,
02542 0, 0, 0, 0, 0, 0, 0, 0, -626, 251,
02543 -626, 5, 6, 7, 8, 9, 0, 0, -626, 10,
02544 11, 0, 0, -626, 12, 0, 13, 14, 15, 16,
02545 17, 18, 19, 0, 0, 0, 0, 0, 20, 21,
02546 22, 23, 24, 25, 26, 0, 0, 27, 0, 0,
02547 0, 0, 0, 28, 29, 252, 31, 32, 33, 34,
02548 35, 36, 37, 38, 39, 40, 0, 41, 42, 43,
02549 44, 0, 45, 46, 47, 0, 48, 49, 0, 0,
02550 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02551 0, 0, 0, 0, 0, 0, 50, 0, 0, 51,
02552 52, 0, 53, 54, 0, 55, 0, 0, 56, 57,
02553 58, 59, 60, 61, 62, 63, 64, 0, 0, 0,
02554 0, 0, 0, 0, 251, 0, 5, 6, 7, 8,
02555 9, 0, -626, -626, 10, 11, 65, 66, 67, 12,
02556 0, 13, 14, 15, 16, 17, 18, 19, 0, -626,
02557 0, -626, 0, 20, 21, 22, 23, 24, 25, 26,
02558 0, 0, 27, 0, 0, 0, 0, 0, 28, 29,
02559 252, 31, 32, 33, 34, 35, 36, 37, 38, 39,
02560 40, 0, 41, 42, 43, 44, 0, 45, 46, 47,
02561 0, 48, 49, 0, 0, 0, 0, 0, 0, 0,
02562 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02563 0, 50, 0, 0, 51, 52, 0, 53, 54, 0,
02564 55, 0, 0, 56, 57, 58, 59, 60, 61, 62,
02565 63, 64, 0, 0, 0, 0, 0, 0, 0, 251,
02566 0, 5, 6, 7, 8, 9, 0, 0, 0, 10,
02567 11, 65, 66, 67, 12, 0, 13, 14, 15, 16,
02568 17, 18, 19, 0, -626, 0, -626, 0, 20, 21,
02569 22, 23, 24, 25, 26, 0, 0, 27, 0, 0,
02570 0, 0, 0, 28, 29, 252, 31, 32, 33, 34,
02571 35, 36, 37, 38, 39, 40, 0, 41, 42, 43,
02572 44, 0, 45, 46, 47, 0, 48, 49, 0, 0,
02573 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02574 0, 0, 0, 0, 0, 0, 50, 0, 0, 253,
02575 52, 0, 53, 54, 0, 55, 0, 0, 56, 57,
02576 58, 59, 60, 61, 62, 63, 64, 0, 0, 0,
02577 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02578 0, 0, 0, 0, 0, 0, 65, 66, 67, 0,
02579 0, 0, 0, 0, 0, 0, 0, -626, 0, -626,
02580 251, -626, 5, 6, 7, 8, 9, 0, 0, 0,
02581 10, 11, 0, 0, 0, 12, 0, 13, 14, 15,
02582 16, 17, 18, 19, 0, 0, 0, 0, 0, 20,
02583 21, 22, 23, 24, 25, 26, 0, 0, 27, 0,
02584 0, 0, 0, 0, 28, 29, 252, 31, 32, 33,
02585 34, 35, 36, 37, 38, 39, 40, 0, 41, 42,
02586 43, 44, 0, 45, 46, 47, 0, 48, 49, 0,
02587 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02588 0, 0, 0, 0, 0, 0, 0, 50, 0, 0,
02589 51, 52, 0, 53, 54, 0, 55, 0, 0, 56,
02590 57, 58, 59, 60, 61, 62, 63, 64, 0, 0,
02591 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02592 0, 0, 0, 0, 0, 0, 0, 65, 66, 67,
02593 0, 0, 0, 0, 0, 0, 0, 0, -626, 0,
02594 -626, 251, -626, 5, 6, 7, 8, 9, 0, 0,
02595 0, 10, 11, 0, 0, 0, 12, 0, 13, 14,
02596 15, 16, 17, 18, 19, 0, 0, 0, 0, 0,
02597 20, 21, 22, 23, 24, 25, 26, 0, 0, 27,
02598 0, 0, 0, 0, 0, 28, 29, 252, 31, 32,
02599 33, 34, 35, 36, 37, 38, 39, 40, 0, 41,
02600 42, 43, 44, 0, 45, 46, 47, 0, 48, 49,
02601 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02602 0, 0, 0, 0, 0, 0, 0, 0, 50, 0,
02603 0, 51, 52, 0, 53, 54, 0, 55, 0, 0,
02604 56, 57, 58, 59, 60, 61, 62, 63, 64, 0,
02605 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02606 0, 0, 0, 0, 0, 0, 0, 0, 65, 66,
02607 67, 0, 0, -626, 4, 0, 5, 6, 7, 8,
02608 9, -626, 0, -626, 10, 11, 0, 0, 0, 12,
02609 0, 13, 14, 15, 16, 17, 18, 19, 0, 0,
02610 0, 0, 0, 20, 21, 22, 23, 24, 25, 26,
02611 0, 0, 27, 0, 0, 0, 0, 0, 28, 29,
02612 30, 31, 32, 33, 34, 35, 36, 37, 38, 39,
02613 40, 0, 41, 42, 43, 44, 0, 45, 46, 47,
02614 0, 48, 49, 0, 0, 0, 0, 0, 0, 0,
02615 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02616 0, 50, 0, 0, 51, 52, 0, 53, 54, 0,
02617 55, 0, 0, 56, 57, 58, 59, 60, 61, 62,
02618 63, 64, 0, 0, 0, 0, 0, 0, 0, 0,
02619 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02620 0, 65, 66, 67, 0, 0, -626, 0, 0, 0,
02621 0, 0, 0, 0, -626, 251, -626, 5, 6, 7,
02622 8, 9, 0, 0, -626, 10, 11, 0, 0, 0,
02623 12, 0, 13, 14, 15, 16, 17, 18, 19, 0,
02624 0, 0, 0, 0, 20, 21, 22, 23, 24, 25,
02625 26, 0, 0, 27, 0, 0, 0, 0, 0, 28,
02626 29, 252, 31, 32, 33, 34, 35, 36, 37, 38,
02627 39, 40, 0, 41, 42, 43, 44, 0, 45, 46,
02628 47, 0, 48, 49, 0, 0, 0, 0, 0, 0,
02629 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02630 0, 0, 50, 0, 0, 51, 52, 0, 53, 54,
02631 0, 55, 0, 0, 56, 57, 58, 59, 60, 61,
02632 62, 63, 64, 0, 0, 0, 0, 0, 0, 0,
02633 251, 0, 5, 6, 7, 8, 9, 0, 0, 0,
02634 10, 11, 65, 66, 67, 12, 0, 13, 14, 15,
02635 16, 17, 18, 19, 0, -626, 0, -626, 0, 20,
02636 21, 22, 23, 24, 25, 26, 0, 0, 27, 0,
02637 0, 0, 0, 0, 28, 29, 252, 31, 32, 33,
02638 34, 35, 36, 37, 38, 39, 40, 0, 41, 42,
02639 43, 44, 0, 45, 46, 47, 0, 48, 49, 0,
02640 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02641 0, 0, 0, 0, 0, 0, 0, 50, 0, 0,
02642 51, 52, 0, 53, 54, 0, 55, 0, 0, 56,
02643 57, 58, 59, 60, 61, 62, 63, 64, 0, -626,
02644 0, 0, 0, 0, 0, 0, 0, 5, 6, 7,
02645 0, 9, 0, 0, 0, 10, 11, 65, 66, 67,
02646 12, 0, 13, 14, 15, 16, 17, 18, 19, 0,
02647 -626, 0, -626, 0, 20, 21, 22, 23, 24, 25,
02648 26, 0, 0, 203, 0, 0, 0, 0, 0, 0,
02649 29, 0, 0, 32, 33, 34, 35, 36, 37, 38,
02650 39, 40, 204, 41, 42, 43, 44, 0, 45, 46,
02651 47, 0, 48, 49, 0, 0, 0, 0, 0, 0,
02652 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02653 0, 0, 205, 0, 0, 206, 52, 0, 53, 54,
02654 0, 207, 208, 209, 56, 57, 58, 59, 60, 61,
02655 62, 63, 64, 0, 0, 0, 0, 0, 0, 0,
02656 0, 0, 5, 6, 7, 0, 9, 0, 0, 0,
02657 10, 11, 65, 210, 67, 12, 0, 13, 14, 15,
02658 16, 17, 18, 19, 0, 0, 0, 234, 0, 20,
02659 21, 22, 23, 24, 25, 26, 0, 0, 27, 0,
02660 0, 0, 0, 0, 0, 29, 0, 0, 32, 33,
02661 34, 35, 36, 37, 38, 39, 40, 0, 41, 42,
02662 43, 44, 0, 45, 46, 47, 0, 48, 49, 0,
02663 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02664 0, 0, 0, 0, 0, 0, 0, 205, 0, 0,
02665 206, 52, 0, 53, 54, 0, 0, 0, 0, 56,
02666 57, 58, 59, 60, 61, 62, 63, 64, 0, 0,
02667 0, 0, 0, 0, 0, 0, 0, 5, 6, 7,
02668 0, 9, 0, 0, 0, 10, 11, 65, 66, 67,
02669 12, 0, 13, 14, 15, 16, 17, 18, 19, 0,
02670 304, 0, 305, 0, 20, 21, 22, 23, 24, 25,
02671 26, 0, 0, 27, 0, 0, 0, 0, 0, 0,
02672 29, 0, 0, 32, 33, 34, 35, 36, 37, 38,
02673 39, 40, 0, 41, 42, 43, 44, 0, 45, 46,
02674 47, 0, 48, 49, 0, 0, 0, 0, 0, 0,
02675 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02676 0, 0, 205, 0, 0, 206, 52, 0, 53, 54,
02677 0, 0, 0, 0, 56, 57, 58, 59, 60, 61,
02678 62, 63, 64, 0, 0, 0, 0, 0, 0, 0,
02679 0, 0, 5, 6, 7, 8, 9, 0, 0, 0,
02680 10, 11, 65, 66, 67, 12, 0, 13, 14, 15,
02681 16, 17, 18, 19, 0, 0, 0, 234, 0, 20,
02682 21, 22, 23, 24, 25, 26, 0, 0, 27, 0,
02683 0, 0, 0, 0, 28, 29, 30, 31, 32, 33,
02684 34, 35, 36, 37, 38, 39, 40, 0, 41, 42,
02685 43, 44, 0, 45, 46, 47, 0, 48, 49, 0,
02686 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02687 0, 0, 0, 0, 0, 0, 0, 50, 0, 0,
02688 51, 52, 0, 53, 54, 0, 55, 0, 0, 56,
02689 57, 58, 59, 60, 61, 62, 63, 64, 0, 0,
02690 0, 0, 0, 0, 0, 0, 0, 5, 6, 7,
02691 8, 9, 0, 0, 0, 10, 11, 65, 66, 67,
02692 12, 0, 13, 14, 15, 16, 17, 18, 19, 0,
02693 498, 0, 0, 0, 20, 21, 22, 23, 24, 25,
02694 26, 0, 0, 27, 0, 0, 0, 0, 0, 28,
02695 29, 252, 31, 32, 33, 34, 35, 36, 37, 38,
02696 39, 40, 0, 41, 42, 43, 44, 0, 45, 46,
02697 47, 0, 48, 49, 0, 0, 0, 0, 0, 0,
02698 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02699 0, 0, 50, 0, 0, 51, 52, 0, 53, 54,
02700 0, 55, 0, 0, 56, 57, 58, 59, 60, 61,
02701 62, 63, 64, 0, 0, 0, 0, 0, 0, 0,
02702 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02703 0, 0, 65, 66, 67, 0, 0, 0, 0, 0,
02704 0, 0, 0, 0, 0, 498, 121, 122, 123, 124,
02705 125, 126, 127, 128, 129, 130, 131, 132, 133, 134,
02706 135, 136, 137, 138, 139, 140, 141, 142, 143, 144,
02707 0, 0, 0, 145, 146, 147, 386, 387, 388, 389,
02708 152, 153, 154, 0, 0, 0, 0, 0, 155, 156,
02709 157, 158, 390, 391, 392, 393, 163, 37, 38, 394,
02710 40, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02711 0, 165, 166, 167, 168, 169, 170, 171, 172, 173,
02712 0, 0, 174, 175, 0, 0, 176, 177, 178, 179,
02713 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02714 180, 181, 0, 0, 0, 0, 0, 0, 0, 0,
02715 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02716 0, 182, 183, 184, 185, 186, 187, 188, 189, 190,
02717 191, 0, 192, 193, 0, 0, 0, 0, 0, 0,
02718 194, 395, 121, 122, 123, 124, 125, 126, 127, 128,
02719 129, 130, 131, 132, 133, 134, 135, 136, 137, 138,
02720 139, 140, 141, 142, 143, 144, 0, 0, 0, 145,
02721 146, 147, 148, 149, 150, 151, 152, 153, 154, 0,
02722 0, 0, 0, 0, 155, 156, 157, 158, 159, 160,
02723 161, 162, 163, 283, 284, 164, 285, 0, 0, 0,
02724 0, 0, 0, 0, 0, 0, 0, 165, 166, 167,
02725 168, 169, 170, 171, 172, 173, 0, 0, 174, 175,
02726 0, 0, 176, 177, 178, 179, 0, 0, 0, 0,
02727 0, 0, 0, 0, 0, 0, 180, 181, 0, 0,
02728 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02729 0, 0, 0, 0, 0, 0, 0, 182, 183, 184,
02730 185, 186, 187, 188, 189, 190, 191, 0, 192, 193,
02731 0, 0, 0, 0, 0, 0, 194, 121, 122, 123,
02732 124, 125, 126, 127, 128, 129, 130, 131, 132, 133,
02733 134, 135, 136, 137, 138, 139, 140, 141, 142, 143,
02734 144, 0, 0, 0, 145, 146, 147, 148, 149, 150,
02735 151, 152, 153, 154, 0, 0, 0, 0, 0, 155,
02736 156, 157, 158, 159, 160, 161, 162, 163, 236, 0,
02737 164, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02738 0, 0, 165, 166, 167, 168, 169, 170, 171, 172,
02739 173, 0, 0, 174, 175, 0, 0, 176, 177, 178,
02740 179, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02741 0, 180, 181, 0, 0, 57, 0, 0, 0, 0,
02742 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02743 0, 0, 182, 183, 184, 185, 186, 187, 188, 189,
02744 190, 191, 0, 192, 193, 0, 0, 0, 0, 0,
02745 0, 194, 121, 122, 123, 124, 125, 126, 127, 128,
02746 129, 130, 131, 132, 133, 134, 135, 136, 137, 138,
02747 139, 140, 141, 142, 143, 144, 0, 0, 0, 145,
02748 146, 147, 148, 149, 150, 151, 152, 153, 154, 0,
02749 0, 0, 0, 0, 155, 156, 157, 158, 159, 160,
02750 161, 162, 163, 0, 0, 164, 0, 0, 0, 0,
02751 0, 0, 0, 0, 0, 0, 0, 165, 166, 167,
02752 168, 169, 170, 171, 172, 173, 0, 0, 174, 175,
02753 0, 0, 176, 177, 178, 179, 0, 0, 0, 0,
02754 0, 0, 0, 0, 0, 0, 180, 181, 0, 0,
02755 57, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02756 0, 0, 0, 0, 0, 0, 0, 182, 183, 184,
02757 185, 186, 187, 188, 189, 190, 191, 0, 192, 193,
02758 0, 0, 0, 0, 0, 0, 194, 121, 122, 123,
02759 124, 125, 126, 127, 128, 129, 130, 131, 132, 133,
02760 134, 135, 136, 137, 138, 139, 140, 141, 142, 143,
02761 144, 0, 0, 0, 145, 146, 147, 148, 149, 150,
02762 151, 152, 153, 154, 0, 0, 0, 0, 0, 155,
02763 156, 157, 158, 159, 160, 161, 162, 163, 0, 0,
02764 164, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02765 0, 0, 165, 166, 167, 168, 169, 170, 171, 172,
02766 173, 0, 0, 174, 175, 0, 0, 176, 177, 178,
02767 179, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02768 0, 180, 181, 0, 0, 0, 0, 0, 0, 0,
02769 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02770 0, 0, 182, 183, 184, 185, 186, 187, 188, 189,
02771 190, 191, 0, 192, 193, 5, 6, 7, 0, 9,
02772 0, 194, 0, 10, 11, 0, 0, 0, 12, 0,
02773 13, 14, 15, 241, 242, 18, 19, 0, 0, 0,
02774 0, 0, 243, 244, 245, 23, 24, 25, 26, 0,
02775 0, 203, 0, 0, 0, 0, 0, 0, 271, 0,
02776 0, 32, 33, 34, 35, 36, 37, 38, 39, 40,
02777 0, 41, 42, 43, 44, 0, 45, 46, 47, 0,
02778 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02779 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02780 272, 0, 0, 206, 52, 0, 53, 54, 0, 0,
02781 0, 0, 56, 57, 58, 59, 60, 61, 62, 63,
02782 64, 0, 0, 0, 0, 0, 5, 6, 7, 0,
02783 9, 0, 0, 0, 10, 11, 0, 0, 0, 12,
02784 273, 13, 14, 15, 241, 242, 18, 19, 274, 0,
02785 0, 0, 0, 243, 244, 245, 23, 24, 25, 26,
02786 0, 0, 203, 0, 0, 0, 0, 0, 0, 271,
02787 0, 0, 32, 33, 34, 35, 36, 37, 38, 39,
02788 40, 0, 41, 42, 43, 44, 0, 45, 46, 47,
02789 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02790 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02791 0, 272, 0, 0, 206, 52, 0, 53, 54, 0,
02792 0, 0, 0, 56, 57, 58, 59, 60, 61, 62,
02793 63, 64, 0, 0, 0, 0, 0, 5, 6, 7,
02794 8, 9, 0, 0, 0, 10, 11, 0, 0, 0,
02795 12, 273, 13, 14, 15, 16, 17, 18, 19, 519,
02796 0, 0, 0, 0, 20, 21, 22, 23, 24, 25,
02797 26, 0, 0, 27, 0, 0, 0, 0, 0, 28,
02798 29, 30, 31, 32, 33, 34, 35, 36, 37, 38,
02799 39, 40, 0, 41, 42, 43, 44, 0, 45, 46,
02800 47, 0, 48, 49, 0, 0, 0, 0, 0, 0,
02801 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02802 0, 0, 50, 0, 0, 51, 52, 0, 53, 54,
02803 0, 55, 0, 0, 56, 57, 58, 59, 60, 61,
02804 62, 63, 64, 0, 0, 0, 0, 0, 0, 0,
02805 0, 0, 5, 6, 7, 0, 9, 0, 0, 0,
02806 10, 11, 65, 66, 67, 12, 0, 13, 14, 15,
02807 16, 17, 18, 19, 0, 0, 0, 0, 0, 20,
02808 21, 22, 23, 24, 25, 26, 0, 0, 203, 0,
02809 0, 0, 0, 0, 0, 29, 0, 0, 32, 33,
02810 34, 35, 36, 37, 38, 39, 40, 204, 41, 42,
02811 43, 44, 0, 45, 46, 47, 0, 48, 49, 0,
02812 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02813 0, 0, 0, 0, 0, 0, 0, 205, 0, 0,
02814 206, 52, 0, 53, 54, 0, 207, 208, 209, 56,
02815 57, 58, 59, 60, 61, 62, 63, 64, 0, 0,
02816 0, 0, 0, 0, 0, 0, 0, 5, 6, 7,
02817 8, 9, 0, 0, 0, 10, 11, 65, 210, 67,
02818 12, 0, 13, 14, 15, 16, 17, 18, 19, 0,
02819 0, 0, 0, 0, 20, 21, 22, 23, 24, 25,
02820 26, 0, 0, 27, 0, 0, 0, 0, 0, 28,
02821 29, 0, 31, 32, 33, 34, 35, 36, 37, 38,
02822 39, 40, 0, 41, 42, 43, 44, 0, 45, 46,
02823 47, 0, 48, 49, 0, 0, 0, 0, 0, 0,
02824 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02825 0, 0, 50, 0, 0, 51, 52, 0, 53, 54,
02826 0, 55, 0, 0, 56, 57, 58, 59, 60, 61,
02827 62, 63, 64, 0, 0, 0, 0, 0, 0, 0,
02828 0, 0, 5, 6, 7, 0, 9, 0, 0, 0,
02829 10, 11, 65, 66, 67, 12, 0, 13, 14, 15,
02830 241, 242, 18, 19, 0, 0, 0, 0, 0, 243,
02831 244, 245, 23, 24, 25, 26, 0, 0, 203, 0,
02832 0, 0, 0, 0, 0, 29, 0, 0, 32, 33,
02833 34, 35, 36, 37, 38, 39, 40, 204, 41, 42,
02834 43, 44, 0, 45, 46, 47, 0, 48, 49, 0,
02835 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02836 0, 0, 0, 0, 0, 0, 0, 205, 0, 0,
02837 206, 52, 0, 53, 54, 0, 609, 208, 209, 56,
02838 57, 58, 59, 60, 61, 62, 63, 64, 0, 0,
02839 0, 0, 0, 0, 0, 0, 0, 5, 6, 7,
02840 0, 9, 0, 0, 0, 10, 11, 65, 210, 67,
02841 12, 0, 13, 14, 15, 241, 242, 18, 19, 0,
02842 0, 0, 0, 0, 243, 244, 245, 23, 24, 25,
02843 26, 0, 0, 203, 0, 0, 0, 0, 0, 0,
02844 29, 0, 0, 32, 33, 34, 35, 36, 37, 38,
02845 39, 40, 204, 41, 42, 43, 44, 0, 45, 46,
02846 47, 0, 48, 49, 0, 0, 0, 0, 0, 0,
02847 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02848 0, 0, 205, 0, 0, 206, 52, 0, 53, 54,
02849 0, 207, 208, 0, 56, 57, 58, 59, 60, 61,
02850 62, 63, 64, 0, 0, 0, 0, 0, 0, 0,
02851 0, 0, 5, 6, 7, 0, 9, 0, 0, 0,
02852 10, 11, 65, 210, 67, 12, 0, 13, 14, 15,
02853 241, 242, 18, 19, 0, 0, 0, 0, 0, 243,
02854 244, 245, 23, 24, 25, 26, 0, 0, 203, 0,
02855 0, 0, 0, 0, 0, 29, 0, 0, 32, 33,
02856 34, 35, 36, 37, 38, 39, 40, 204, 41, 42,
02857 43, 44, 0, 45, 46, 47, 0, 48, 49, 0,
02858 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02859 0, 0, 0, 0, 0, 0, 0, 205, 0, 0,
02860 206, 52, 0, 53, 54, 0, 0, 208, 209, 56,
02861 57, 58, 59, 60, 61, 62, 63, 64, 0, 0,
02862 0, 0, 0, 0, 0, 0, 0, 5, 6, 7,
02863 0, 9, 0, 0, 0, 10, 11, 65, 210, 67,
02864 12, 0, 13, 14, 15, 241, 242, 18, 19, 0,
02865 0, 0, 0, 0, 243, 244, 245, 23, 24, 25,
02866 26, 0, 0, 203, 0, 0, 0, 0, 0, 0,
02867 29, 0, 0, 32, 33, 34, 35, 36, 37, 38,
02868 39, 40, 204, 41, 42, 43, 44, 0, 45, 46,
02869 47, 0, 48, 49, 0, 0, 0, 0, 0, 0,
02870 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02871 0, 0, 205, 0, 0, 206, 52, 0, 53, 54,
02872 0, 609, 208, 0, 56, 57, 58, 59, 60, 61,
02873 62, 63, 64, 0, 0, 0, 0, 0, 0, 0,
02874 0, 0, 5, 6, 7, 0, 9, 0, 0, 0,
02875 10, 11, 65, 210, 67, 12, 0, 13, 14, 15,
02876 241, 242, 18, 19, 0, 0, 0, 0, 0, 243,
02877 244, 245, 23, 24, 25, 26, 0, 0, 203, 0,
02878 0, 0, 0, 0, 0, 29, 0, 0, 32, 33,
02879 34, 35, 36, 37, 38, 39, 40, 204, 41, 42,
02880 43, 44, 0, 45, 46, 47, 0, 48, 49, 0,
02881 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02882 0, 0, 0, 0, 0, 0, 0, 205, 0, 0,
02883 206, 52, 0, 53, 54, 0, 0, 208, 0, 56,
02884 57, 58, 59, 60, 61, 62, 63, 64, 0, 0,
02885 0, 0, 0, 0, 0, 0, 0, 5, 6, 7,
02886 0, 9, 0, 0, 0, 10, 11, 65, 210, 67,
02887 12, 0, 13, 14, 15, 16, 17, 18, 19, 0,
02888 0, 0, 0, 0, 20, 21, 22, 23, 24, 25,
02889 26, 0, 0, 203, 0, 0, 0, 0, 0, 0,
02890 29, 0, 0, 32, 33, 34, 35, 36, 37, 38,
02891 39, 40, 0, 41, 42, 43, 44, 0, 45, 46,
02892 47, 0, 48, 49, 0, 0, 0, 0, 0, 0,
02893 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02894 0, 0, 205, 0, 0, 206, 52, 0, 53, 54,
02895 0, 512, 0, 0, 56, 57, 58, 59, 60, 61,
02896 62, 63, 64, 0, 0, 0, 0, 0, 0, 0,
02897 0, 0, 5, 6, 7, 0, 9, 0, 0, 0,
02898 10, 11, 65, 210, 67, 12, 0, 13, 14, 15,
02899 241, 242, 18, 19, 0, 0, 0, 0, 0, 243,
02900 244, 245, 23, 24, 25, 26, 0, 0, 203, 0,
02901 0, 0, 0, 0, 0, 29, 0, 0, 32, 33,
02902 34, 35, 36, 37, 38, 39, 40, 0, 41, 42,
02903 43, 44, 0, 45, 46, 47, 0, 48, 49, 0,
02904 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02905 0, 0, 0, 0, 0, 0, 0, 205, 0, 0,
02906 206, 52, 0, 53, 54, 0, 207, 0, 0, 56,
02907 57, 58, 59, 60, 61, 62, 63, 64, 0, 0,
02908 0, 0, 0, 0, 0, 0, 0, 5, 6, 7,
02909 0, 9, 0, 0, 0, 10, 11, 65, 210, 67,
02910 12, 0, 13, 14, 15, 241, 242, 18, 19, 0,
02911 0, 0, 0, 0, 243, 244, 245, 23, 24, 25,
02912 26, 0, 0, 203, 0, 0, 0, 0, 0, 0,
02913 29, 0, 0, 32, 33, 34, 35, 36, 37, 38,
02914 39, 40, 0, 41, 42, 43, 44, 0, 45, 46,
02915 47, 0, 48, 49, 0, 0, 0, 0, 0, 0,
02916 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02917 0, 0, 205, 0, 0, 206, 52, 0, 53, 54,
02918 0, 817, 0, 0, 56, 57, 58, 59, 60, 61,
02919 62, 63, 64, 0, 0, 0, 0, 0, 0, 0,
02920 0, 0, 5, 6, 7, 0, 9, 0, 0, 0,
02921 10, 11, 65, 210, 67, 12, 0, 13, 14, 15,
02922 241, 242, 18, 19, 0, 0, 0, 0, 0, 243,
02923 244, 245, 23, 24, 25, 26, 0, 0, 203, 0,
02924 0, 0, 0, 0, 0, 29, 0, 0, 32, 33,
02925 34, 35, 36, 37, 38, 39, 40, 0, 41, 42,
02926 43, 44, 0, 45, 46, 47, 0, 48, 49, 0,
02927 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02928 0, 0, 0, 0, 0, 0, 0, 205, 0, 0,
02929 206, 52, 0, 53, 54, 0, 512, 0, 0, 56,
02930 57, 58, 59, 60, 61, 62, 63, 64, 0, 0,
02931 0, 0, 0, 0, 0, 0, 0, 5, 6, 7,
02932 0, 9, 0, 0, 0, 10, 11, 65, 210, 67,
02933 12, 0, 13, 14, 15, 241, 242, 18, 19, 0,
02934 0, 0, 0, 0, 243, 244, 245, 23, 24, 25,
02935 26, 0, 0, 203, 0, 0, 0, 0, 0, 0,
02936 29, 0, 0, 32, 33, 34, 35, 36, 37, 38,
02937 39, 40, 0, 41, 42, 43, 44, 0, 45, 46,
02938 47, 0, 48, 49, 0, 0, 0, 0, 0, 0,
02939 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02940 0, 0, 205, 0, 0, 206, 52, 0, 53, 54,
02941 0, 609, 0, 0, 56, 57, 58, 59, 60, 61,
02942 62, 63, 64, 0, 0, 0, 0, 0, 0, 0,
02943 0, 0, 5, 6, 7, 0, 9, 0, 0, 0,
02944 10, 11, 65, 210, 67, 12, 0, 13, 14, 15,
02945 241, 242, 18, 19, 0, 0, 0, 0, 0, 243,
02946 244, 245, 23, 24, 25, 26, 0, 0, 203, 0,
02947 0, 0, 0, 0, 0, 29, 0, 0, 32, 33,
02948 34, 35, 36, 37, 38, 39, 40, 0, 41, 42,
02949 43, 44, 0, 45, 46, 47, 0, 48, 49, 0,
02950 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02951 0, 0, 0, 0, 0, 0, 0, 205, 0, 0,
02952 206, 52, 0, 53, 54, 0, 0, 0, 0, 56,
02953 57, 58, 59, 60, 61, 62, 63, 64, 0, 0,
02954 0, 0, 0, 0, 0, 0, 0, 5, 6, 7,
02955 0, 9, 0, 0, 0, 10, 11, 65, 210, 67,
02956 12, 0, 13, 14, 15, 16, 17, 18, 19, 0,
02957 0, 0, 0, 0, 20, 21, 22, 23, 24, 25,
02958 26, 0, 0, 203, 0, 0, 0, 0, 0, 0,
02959 29, 0, 0, 32, 33, 34, 35, 36, 37, 38,
02960 39, 40, 0, 41, 42, 43, 44, 0, 45, 46,
02961 47, 0, 48, 49, 0, 0, 0, 0, 0, 0,
02962 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02963 0, 0, 205, 0, 0, 206, 52, 0, 53, 54,
02964 0, 0, 0, 0, 56, 57, 58, 59, 60, 61,
02965 62, 63, 64, 0, 0, 0, 0, 0, 0, 0,
02966 0, 0, 5, 6, 7, 0, 9, 0, 0, 0,
02967 10, 11, 65, 210, 67, 12, 0, 13, 14, 15,
02968 16, 17, 18, 19, 0, 0, 0, 0, 0, 20,
02969 21, 22, 23, 24, 25, 26, 0, 0, 27, 0,
02970 0, 0, 0, 0, 0, 29, 0, 0, 32, 33,
02971 34, 35, 36, 37, 38, 39, 40, 0, 41, 42,
02972 43, 44, 0, 45, 46, 47, 0, 48, 49, 0,
02973 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02974 0, 0, 0, 0, 0, 0, 0, 205, 0, 0,
02975 206, 52, 0, 53, 54, 0, 0, 0, 0, 56,
02976 57, 58, 59, 60, 61, 62, 63, 64, 0, 0,
02977 0, 0, 0, 0, 0, 0, 0, 5, 6, 7,
02978 0, 9, 0, 0, 0, 10, 11, 65, 66, 67,
02979 12, 0, 13, 14, 15, 241, 242, 18, 19, 0,
02980 0, 0, 0, 0, 243, 244, 245, 23, 24, 25,
02981 26, 0, 0, 203, 0, 0, 0, 0, 0, 0,
02982 271, 0, 0, 32, 33, 34, 35, 36, 37, 38,
02983 39, 40, 0, 41, 42, 43, 44, 0, 45, 46,
02984 47, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02985 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02986 0, 0, 272, 0, 0, 325, 52, 0, 53, 54,
02987 0, 326, 0, 0, 56, 57, 58, 59, 60, 61,
02988 62, 63, 64, 0, 0, 0, 0, 0, 5, 6,
02989 7, 0, 9, 0, 0, 0, 10, 11, 0, 0,
02990 0, 12, 273, 13, 14, 15, 241, 242, 18, 19,
02991 0, 0, 0, 0, 0, 243, 244, 245, 23, 24,
02992 25, 26, 0, 0, 203, 0, 0, 0, 0, 0,
02993 0, 271, 0, 0, 32, 33, 34, 35, 36, 37,
02994 38, 39, 40, 0, 41, 42, 43, 44, 0, 45,
02995 46, 47, 0, 0, 0, 0, 0, 0, 0, 0,
02996 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
02997 0, 0, 0, 367, 0, 0, 51, 52, 0, 53,
02998 54, 0, 55, 0, 0, 56, 57, 58, 59, 60,
02999 61, 62, 63, 64, 0, 0, 0, 0, 0, 5,
03000 6, 7, 0, 9, 0, 0, 0, 10, 11, 0,
03001 0, 0, 12, 273, 13, 14, 15, 241, 242, 18,
03002 19, 0, 0, 0, 0, 0, 243, 244, 245, 23,
03003 24, 25, 26, 0, 0, 203, 0, 0, 0, 0,
03004 0, 0, 271, 0, 0, 32, 33, 34, 375, 36,
03005 37, 38, 376, 40, 0, 41, 42, 43, 44, 0,
03006 45, 46, 47, 0, 0, 0, 0, 0, 0, 0,
03007 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03008 0, 377, 0, 0, 378, 0, 0, 206, 52, 0,
03009 53, 54, 0, 0, 0, 0, 56, 57, 58, 59,
03010 60, 61, 62, 63, 64, 0, 0, 0, 0, 0,
03011 5, 6, 7, 0, 9, 0, 0, 0, 10, 11,
03012 0, 0, 0, 12, 273, 13, 14, 15, 241, 242,
03013 18, 19, 0, 0, 0, 0, 0, 243, 244, 245,
03014 23, 24, 25, 26, 0, 0, 203, 0, 0, 0,
03015 0, 0, 0, 271, 0, 0, 32, 33, 34, 375,
03016 36, 37, 38, 376, 40, 0, 41, 42, 43, 44,
03017 0, 45, 46, 47, 0, 0, 0, 0, 0, 0,
03018 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03019 0, 0, 0, 0, 0, 378, 0, 0, 206, 52,
03020 0, 53, 54, 0, 0, 0, 0, 56, 57, 58,
03021 59, 60, 61, 62, 63, 64, 0, 0, 0, 0,
03022 0, 5, 6, 7, 0, 9, 0, 0, 0, 10,
03023 11, 0, 0, 0, 12, 273, 13, 14, 15, 241,
03024 242, 18, 19, 0, 0, 0, 0, 0, 243, 244,
03025 245, 23, 24, 25, 26, 0, 0, 203, 0, 0,
03026 0, 0, 0, 0, 271, 0, 0, 32, 33, 34,
03027 35, 36, 37, 38, 39, 40, 0, 41, 42, 43,
03028 44, 0, 45, 46, 47, 0, 0, 0, 0, 0,
03029 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03030 0, 0, 0, 0, 0, 0, 272, 0, 0, 325,
03031 52, 0, 53, 54, 0, 0, 0, 0, 56, 57,
03032 58, 59, 60, 61, 62, 63, 64, 0, 0, 0,
03033 0, 0, 5, 6, 7, 0, 9, 0, 0, 0,
03034 10, 11, 0, 0, 0, 12, 273, 13, 14, 15,
03035 241, 242, 18, 19, 0, 0, 0, 0, 0, 243,
03036 244, 245, 23, 24, 25, 26, 0, 0, 203, 0,
03037 0, 0, 0, 0, 0, 271, 0, 0, 32, 33,
03038 34, 35, 36, 37, 38, 39, 40, 0, 41, 42,
03039 43, 44, 0, 45, 46, 47, 0, 0, 0, 0,
03040 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03041 0, 0, 0, 0, 0, 0, 0, 899, 0, 0,
03042 206, 52, 0, 53, 54, 0, 0, 0, 0, 56,
03043 57, 58, 59, 60, 61, 62, 63, 64, 0, 0,
03044 0, 0, 0, 5, 6, 7, 0, 9, 0, 0,
03045 0, 10, 11, 0, 0, 0, 12, 273, 13, 14,
03046 15, 241, 242, 18, 19, 0, 0, 0, 0, 0,
03047 243, 244, 245, 23, 24, 25, 26, 0, 0, 203,
03048 0, 0, 0, 0, 0, 0, 271, 0, 0, 32,
03049 33, 34, 35, 36, 37, 38, 39, 40, 0, 41,
03050 42, 43, 44, 0, 45, 46, 47, 0, 0, 0,
03051 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03052 0, 0, 0, 0, 0, 0, 0, 0, 976, 0,
03053 0, 206, 52, 0, 53, 54, 0, 0, 0, 0,
03054 56, 57, 58, 59, 60, 61, 62, 63, 64, 0,
03055 0, 0, 0, 554, 555, 0, 0, 556, 0, 0,
03056 0, 0, 0, 0, 0, 0, 0, 0, 273, 165,
03057 166, 167, 168, 169, 170, 171, 172, 173, 0, 0,
03058 174, 175, 0, 0, 176, 177, 178, 179, 0, 0,
03059 0, 0, 0, 0, 0, 0, 0, 0, 180, 181,
03060 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03061 0, 0, 0, 0, 0, 0, 0, 0, 0, 182,
03062 183, 184, 185, 186, 187, 188, 189, 190, 191, 0,
03063 192, 193, 562, 563, 0, 0, 564, 0, 194, 0,
03064 0, 0, 0, 0, 0, 0, 0, 0, 165, 166,
03065 167, 168, 169, 170, 171, 172, 173, 0, 0, 174,
03066 175, 0, 0, 176, 177, 178, 179, 0, 0, 0,
03067 0, 0, 0, 0, 0, 0, 0, 180, 181, 0,
03068 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03069 0, 0, 0, 0, 0, 0, 0, 0, 182, 183,
03070 184, 185, 186, 187, 188, 189, 190, 191, 0, 192,
03071 193, 599, 563, 0, 0, 600, 0, 194, 0, 0,
03072 0, 0, 0, 0, 0, 0, 0, 165, 166, 167,
03073 168, 169, 170, 171, 172, 173, 0, 0, 174, 175,
03074 0, 0, 176, 177, 178, 179, 0, 0, 0, 0,
03075 0, 0, 0, 0, 0, 0, 180, 181, 0, 0,
03076 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03077 0, 0, 0, 0, 0, 0, 0, 182, 183, 184,
03078 185, 186, 187, 188, 189, 190, 191, 0, 192, 193,
03079 613, 555, 0, 0, 614, 0, 194, 0, 0, 0,
03080 0, 0, 0, 0, 0, 0, 165, 166, 167, 168,
03081 169, 170, 171, 172, 173, 0, 0, 174, 175, 0,
03082 0, 176, 177, 178, 179, 0, 0, 0, 0, 0,
03083 0, 0, 0, 0, 0, 180, 181, 0, 0, 0,
03084 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03085 0, 0, 0, 0, 0, 0, 182, 183, 184, 185,
03086 186, 187, 188, 189, 190, 191, 0, 192, 193, 616,
03087 563, 0, 0, 617, 0, 194, 0, 0, 0, 0,
03088 0, 0, 0, 0, 0, 165, 166, 167, 168, 169,
03089 170, 171, 172, 173, 0, 0, 174, 175, 0, 0,
03090 176, 177, 178, 179, 0, 0, 0, 0, 0, 0,
03091 0, 0, 0, 0, 180, 181, 0, 0, 0, 0,
03092 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03093 0, 0, 0, 0, 0, 182, 183, 184, 185, 186,
03094 187, 188, 189, 190, 191, 0, 192, 193, 640, 555,
03095 0, 0, 641, 0, 194, 0, 0, 0, 0, 0,
03096 0, 0, 0, 0, 165, 166, 167, 168, 169, 170,
03097 171, 172, 173, 0, 0, 174, 175, 0, 0, 176,
03098 177, 178, 179, 0, 0, 0, 0, 0, 0, 0,
03099 0, 0, 0, 180, 181, 0, 0, 0, 0, 0,
03100 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03101 0, 0, 0, 0, 182, 183, 184, 185, 186, 187,
03102 188, 189, 190, 191, 0, 192, 193, 643, 563, 0,
03103 0, 644, 0, 194, 0, 0, 0, 0, 0, 0,
03104 0, 0, 0, 165, 166, 167, 168, 169, 170, 171,
03105 172, 173, 0, 0, 174, 175, 0, 0, 176, 177,
03106 178, 179, 0, 0, 0, 0, 0, 0, 0, 0,
03107 0, 0, 180, 181, 0, 0, 0, 0, 0, 0,
03108 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03109 0, 0, 0, 182, 183, 184, 185, 186, 187, 188,
03110 189, 190, 191, 0, 192, 193, 728, 555, 0, 0,
03111 729, 0, 194, 0, 0, 0, 0, 0, 0, 0,
03112 0, 0, 165, 166, 167, 168, 169, 170, 171, 172,
03113 173, 0, 0, 174, 175, 0, 0, 176, 177, 178,
03114 179, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03115 0, 180, 181, 0, 0, 0, 0, 0, 0, 0,
03116 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03117 0, 0, 182, 183, 184, 185, 186, 187, 188, 189,
03118 190, 191, 0, 192, 193, 731, 563, 0, 0, 732,
03119 0, 194, 0, 0, 0, 0, 0, 0, 0, 0,
03120 0, 165, 166, 167, 168, 169, 170, 171, 172, 173,
03121 0, 0, 174, 175, 0, 0, 176, 177, 178, 179,
03122 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03123 180, 181, 0, 0, 0, 0, 0, 0, 0, 0,
03124 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03125 0, 182, 183, 184, 185, 186, 187, 188, 189, 190,
03126 191, 0, 192, 193, 738, 555, 0, 0, 739, 0,
03127 194, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03128 165, 166, 167, 168, 169, 170, 171, 172, 173, 0,
03129 0, 174, 175, 0, 0, 176, 177, 178, 179, 0,
03130 0, 0, 0, 0, 0, 0, 0, 0, 0, 180,
03131 181, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03132 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03133 182, 183, 184, 185, 186, 187, 188, 189, 190, 191,
03134 0, 192, 193, 1008, 555, 0, 0, 1009, 0, 194,
03135 0, 0, 0, 0, 0, 0, 0, 0, 0, 165,
03136 166, 167, 168, 169, 170, 171, 172, 173, 0, 0,
03137 174, 175, 0, 0, 176, 177, 178, 179, 0, 0,
03138 0, 0, 0, 0, 0, 0, 0, 0, 180, 181,
03139 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03140 0, 0, 0, 0, 0, 0, 0, 0, 0, 182,
03141 183, 184, 185, 186, 187, 188, 189, 190, 191, 0,
03142 192, 193, 1039, 555, 0, 0, 1040, 0, 194, 0,
03143 0, 0, 0, 0, 0, 0, 0, 0, 165, 166,
03144 167, 168, 169, 170, 171, 172, 173, 0, 0, 174,
03145 175, 0, 0, 176, 177, 178, 179, 0, 0, 0,
03146 0, 0, 0, 0, 0, 0, 0, 180, 181, 0,
03147 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03148 0, 0, 0, 0, 0, 0, 0, 0, 182, 183,
03149 184, 185, 186, 187, 188, 189, 190, 191, 0, 192,
03150 193, 1042, 563, 0, 0, 1043, 0, 194, 0, 0,
03151 0, 0, 0, 0, 0, 0, 0, 165, 166, 167,
03152 168, 169, 170, 171, 172, 173, 0, 0, 174, 175,
03153 0, 0, 176, 177, 178, 179, 0, 0, 0, 0,
03154 0, 0, 0, 0, 0, 0, 180, 181, 329, 330,
03155 331, 332, 333, 334, 335, 336, 337, 338, 339, 340,
03156 341, 0, 0, 342, 343, 0, 0, 182, 183, 184,
03157 185, 186, 187, 188, 189, 190, 191, 0, 192, 193,
03158 0, 0, 0, 0, 0, 0, 194, 0, 0, 0,
03159 0, 0, 0, 0, 344, 0, 345, 346, 347, 348,
03160 349, 350, 351, 352, 353, 354, 0, 0, 0, 0,
03161 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
03162 0, 234
03163 };
03164
03165 #define yypact_value_is_default(yystate) \
03166 ((yystate) == (-816))
03167
03168 #define yytable_value_is_error(yytable_value) \
03169 ((yytable_value) == (-627))
03170
03171 static const yytype_int16 yycheck[] =
03172 {
03173 2, 27, 57, 29, 55, 16, 17, 356, 98, 20,
03174 233, 8, 28, 69, 89, 361, 328, 92, 81, 355,
03175 328, 357, 2, 223, 4, 576, 22, 4, 578, 595,
03176 81, 28, 686, 92, 8, 258, 92, 422, 261, 575,
03177 414, 96, 93, 94, 95, 265, 88, 89, 422, 269,
03178 92, 53, 54, 469, 28, 615, 65, 787, 51, 8,
03179 57, 670, 442, 16, 17, 401, 473, 20, 716, 418,
03180 76, 55, 720, 16, 17, 460, 2, 20, 4, 28,
03181 76, 417, 642, 419, 378, 778, 27, 874, 26, 904,
03182 16, 17, 25, 289, 20, 291, 25, 293, 63, 96,
03183 53, 297, 26, 519, 908, 66, 69, 872, 63, 445,
03184 53, 54, 253, 25, 25, 1, 508, 87, 25, 511,
03185 775, 136, 471, 89, 778, 51, 13, 89, 143, 55,
03186 52, 25, 0, 787, 56, 87, 472, 87, 16, 17,
03187 66, 25, 20, 143, 109, 800, 111, 87, 78, 115,
03188 25, 25, 89, 115, 109, 81, 111, 99, 141, 132,
03189 143, 13, 88, 89, 63, 135, 92, 93, 94, 95,
03190 730, 737, 13, 37, 38, 725, 941, 142, 115, 745,
03191 122, 741, 13, 135, 325, 135, 15, 142, 17, 1004,
03192 120, 233, 742, 235, 132, 135, 255, 806, 807, 255,
03193 141, 424, 143, 136, 897, 428, 993, 136, 132, 138,
03194 433, 274, 1016, 112, 138, 217, 227, 947, 229, 230,
03195 262, 223, 56, 274, 136, 136, 449, 138, 230, 136,
03196 995, 431, 581, 119, 309, 310, 311, 312, 623, 686,
03197 246, 13, 136, 897, 593, 271, 582, 142, 622, 623,
03198 904, 658, 136, 633, 141, 141, 143, 143, 594, 952,
03199 253, 136, 136, 1028, 273, 142, 13, 309, 310, 311,
03200 312, 251, 314, 315, 227, 326, 229, 886, 138, 143,
03201 206, 697, 930, 143, 227, 63, 229, 362, 363, 141,
03202 486, 143, 255, 947, 844, 518, 846, 493, 592, 691,
03203 141, 227, 143, 229, 230, 364, 856, 233, 364, 235,
03204 141, 861, 143, 672, 240, 674, 136, 853, 1011, 142,
03205 362, 363, 28, 143, 380, 251, 29, 253, 308, 89,
03206 89, 308, 325, 313, 112, 377, 262, 744, 142, 746,
03207 787, 115, 326, 790, 26, 356, 136, 658, 274, 227,
03208 1004, 229, 115, 87, 356, 115, 115, 966, 102, 25,
03209 357, 136, 323, 87, 136, 136, 932, 328, 143, 141,
03210 323, 143, 87, 25, 704, 328, 87, 927, 928, 930,
03211 726, 711, 308, 309, 310, 311, 312, 313, 314, 315,
03212 698, 138, 89, 115, 141, 89, 143, 323, 87, 325,
03213 326, 135, 328, 715, 401, 87, 469, 418, 138, 51,
03214 113, 135, 612, 636, 136, 56, 418, 637, 469, 134,
03215 135, 115, 419, 439, 135, 115, 992, 139, 430, 431,
03216 356, 143, 358, 744, 87, 746, 362, 363, 87, 90,
03217 442, 991, 439, 404, 405, 134, 135, 138, 445, 115,
03218 132, 377, 134, 135, 89, 70, 519, 904, 136, 906,
03219 471, 136, 442, 115, 132, 439, 138, 87, 519, 471,
03220 136, 414, 70, 139, 1024, 472, 1026, 143, 404, 405,
03221 87, 1041, 135, 868, 136, 134, 135, 139, 63, 138,
03222 439, 143, 418, 52, 868, 54, 55, 56, 57, 138,
03223 947, 139, 949, 87, 89, 507, 508, 954, 87, 511,
03224 125, 126, 127, 26, 457, 135, 442, 543, 574, 575,
03225 743, 37, 38, 115, 883, 884, 452, 134, 135, 888,
03226 115, 890, 588, 892, 109, 561, 111, 112, 140, 762,
03227 686, 14, 15, 469, 52, 471, 54, 55, 56, 57,
03228 773, 135, 558, 87, 596, 134, 135, 1004, 56, 1006,
03229 566, 761, 133, 559, 206, 112, 1013, 569, 26, 63,
03230 581, 567, 918, 686, 87, 638, 136, 136, 924, 581,
03231 89, 112, 593, 1030, 626, 582, 112, 638, 112, 615,
03232 606, 593, 70, 519, 96, 601, 136, 594, 240, 601,
03233 134, 135, 17, 63, 1051, 601, 115, 56, 63, 606,
03234 612, 253, 67, 141, 26, 109, 642, 111, 112, 132,
03235 25, 134, 135, 142, 577, 138, 136, 136, 136, 87,
03236 133, 633, 606, 139, 697, 781, 136, 860, 63, 785,
03237 999, 1000, 1001, 1002, 132, 571, 697, 573, 871, 109,
03238 87, 111, 112, 633, 109, 581, 111, 606, 733, 749,
03239 686, 736, 686, 142, 136, 136, 668, 593, 670, 595,
03240 596, 1020, 136, 136, 132, 87, 134, 135, 734, 622,
03241 138, 115, 89, 325, 109, 1021, 111, 112, 87, 691,
03242 1049, 733, 747, 136, 736, 10, 138, 134, 135, 705,
03243 626, 8, 13, 138, 730, 89, 712, 633, 115, 133,
03244 712, 115, 638, 715, 716, 741, 718, 136, 720, 136,
03245 132, 63, 134, 135, 52, 136, 138, 136, 2, 136,
03246 4, 115, 87, 54, 52, 134, 135, 698, 87, 136,
03247 701, 702, 16, 17, 65, 66, 20, 708, 709, 775,
03248 747, 897, 136, 804, 52, 901, 136, 781, 904, 761,
03249 906, 687, 715, 117, 690, 140, 692, 109, 843, 111,
03250 112, 697, 698, 87, 800, 701, 702, 51, 70, 134,
03251 135, 15, 708, 709, 897, 134, 135, 133, 901, 136,
03252 87, 904, 66, 906, 120, 136, 87, 853, 115, 855,
03253 58, 843, 136, 136, 806, 807, 862, 733, 87, 136,
03254 736, 737, 70, 136, 88, 89, 141, 10, 92, 745,
03255 134, 135, 10, 133, 52, 89, 54, 55, 56, 57,
03256 58, 123, 124, 125, 126, 127, 838, 134, 135, 841,
03257 98, 99, 70, 134, 135, 896, 136, 90, 2, 89,
03258 4, 115, 809, 810, 9, 134, 135, 89, 1004, 89,
03259 1006, 136, 139, 91, 122, 1011, 917, 1013, 829, 136,
03260 98, 99, 136, 897, 136, 115, 136, 901, 804, 136,
03261 904, 120, 906, 115, 886, 115, 56, 133, 136, 815,
03262 10, 1004, 136, 1006, 122, 133, 136, 51, 1011, 110,
03263 1013, 55, 138, 829, 136, 1051, 136, 40, 41, 42,
03264 43, 44, 54, 55, 840, 57, 136, 843, 136, 70,
03265 136, 847, 848, 65, 66, 851, 136, 81, 930, 571,
03266 56, 573, 206, 136, 85, 86, 136, 138, 1051, 93,
03267 94, 95, 96, 93, 136, 52, 972, 54, 55, 56,
03268 57, 877, 878, 227, 95, 229, 230, 452, 712, 233,
03269 769, 235, 1023, 686, 966, 750, 240, 893, 1016, 1022,
03270 896, 122, 123, 124, 125, 126, 127, 251, 101, 253,
03271 1004, 297, 1006, 59, 91, 96, 781, 1011, 262, 1013,
03272 97, 917, 938, 901, 52, 921, 54, 55, 56, 57,
03273 59, 60, 61, 62, 961, 962, 932, 897, 778, 1020,
03274 967, 398, 969, 970, 70, 1041, -1, -1, 1020, -1,
03275 1022, 1023, -1, -1, 1021, -1, -1, 1051, -1, 85,
03276 86, -1, -1, 91, 308, 309, 310, 311, 312, 313,
03277 314, 315, -1, -1, -1, 687, -1, -1, 690, 323,
03278 692, 325, 206, -1, 328, -1, 982, 52, 984, 54,
03279 55, 56, 57, -1, 990, -1, 992, 123, 124, 125,
03280 126, 127, 16, 17, -1, -1, 20, 1034, 1035, 1036,
03281 1037, -1, 356, -1, 358, -1, 240, -1, 362, 363,
03282 -1, -1, -1, -1, 1020, -1, 91, 251, -1, 253,
03283 1057, -1, 97, 377, 48, 49, -1, -1, -1, 53,
03284 54, 52, -1, 54, 55, 56, 57, 58, -1, -1,
03285 274, -1, 66, 67, -1, -1, -1, -1, -1, 70,
03286 404, 405, 52, -1, 54, 55, 56, 57, -1, -1,
03287 -1, -1, -1, 52, 418, 54, 55, 56, 57, 58,
03288 91, -1, -1, -1, 308, -1, 97, 98, 99, 313,
03289 -1, 70, -1, -1, -1, -1, -1, -1, 442, -1,
03290 70, 325, 326, 815, -1, -1, -1, -1, 452, -1,
03291 -1, 122, 91, -1, 125, 85, 86, -1, 97, 98,
03292 99, -1, -1, -1, -1, -1, -1, 471, 840, -1,
03293 -1, -1, 143, -1, 358, 847, 848, -1, -1, 851,
03294 -1, -1, -1, 122, -1, -1, 125, -1, -1, -1,
03295 120, 121, 122, 123, 124, 125, 126, 127, -1, 138,
03296 -1, 0, -1, -1, -1, 877, 878, -1, -1, 8,
03297 9, 10, -1, -1, 13, 14, 15, -1, 17, -1,
03298 -1, 893, 2, -1, 4, -1, -1, 26, 27, -1,
03299 204, -1, -1, 207, 208, 209, 210, -1, 37, 38,
03300 -1, 40, 41, 42, 43, 44, -1, -1, -1, 921,
03301 -1, -1, -1, 227, -1, 229, 230, -1, 442, -1,
03302 -1, -1, -1, -1, -1, -1, -1, 571, 452, 573,
03303 -1, 51, -1, -1, -1, 55, -1, 581, 52, -1,
03304 54, 55, 56, 57, 58, 469, -1, -1, 87, 593,
03305 -1, 595, 596, -1, -1, -1, 70, -1, -1, -1,
03306 -1, 81, -1, -1, -1, -1, -1, -1, -1, -1,
03307 982, 110, 984, 93, 94, 95, 96, 91, 990, -1,
03308 -1, -1, 626, 97, 98, 99, -1, -1, -1, 633,
03309 -1, -1, -1, 132, 133, 519, 135, -1, -1, 138,
03310 139, -1, 141, -1, 143, -1, -1, -1, 122, 323,
03311 -1, 125, -1, -1, 328, 329, 330, 331, 332, 333,
03312 334, 335, 336, 337, 338, 339, 340, 341, 342, 343,
03313 344, 345, 346, 347, 348, 349, 350, 351, 352, 353,
03314 354, -1, 356, 687, -1, -1, 690, 571, 692, 573,
03315 -1, -1, -1, -1, 698, -1, -1, 701, 702, -1,
03316 473, -1, -1, -1, 708, 709, -1, -1, -1, -1,
03317 -1, 595, -1, -1, -1, -1, -1, -1, -1, -1,
03318 -1, -1, -1, -1, -1, -1, 206, -1, -1, 733,
03319 404, 405, 736, 737, -1, -1, -1, -1, 412, 413,
03320 414, 745, -1, -1, 418, -1, 420, 421, 422, 633,
03321 -1, -1, -1, -1, 638, -1, -1, -1, -1, -1,
03322 240, -1, -1, -1, -1, -1, -1, 441, -1, -1,
03323 -1, 251, 446, 253, -1, -1, -1, -1, -1, -1,
03324 -1, -1, -1, 457, -1, -1, 460, -1, -1, -1,
03325 -1, -1, -1, -1, 274, -1, -1, 471, -1, -1,
03326 -1, -1, -1, 687, -1, -1, 690, -1, 692, -1,
03327 -1, 815, -1, 697, -1, -1, -1, -1, -1, -1,
03328 -1, -1, -1, 497, -1, 829, -1, -1, 308, -1,
03329 -1, -1, -1, 313, -1, -1, 840, -1, 512, 843,
03330 -1, -1, -1, 847, 848, 325, 326, 851, -1, -1,
03331 -1, -1, -1, 737, -1, -1, -1, -1, -1, -1,
03332 -1, 745, -1, -1, -1, -1, -1, -1, -1, 2,
03333 -1, 4, -1, 877, 878, -1, -1, -1, 358, 652,
03334 -1, -1, -1, -1, -1, 658, -1, -1, -1, 893,
03335 2, -1, 4, -1, -1, -1, -1, -1, -1, -1,
03336 -1, -1, -1, 577, -1, -1, -1, 581, -1, -1,
03337 -1, -1, -1, 686, -1, -1, -1, 921, 51, 593,
03338 804, -1, -1, -1, -1, -1, -1, -1, 932, -1,
03339 -1, 815, -1, -1, -1, 609, -1, -1, -1, 51,
03340 -1, -1, -1, 55, -1, -1, -1, -1, 622, 623,
03341 -1, -1, -1, -1, -1, -1, 840, -1, -1, -1,
03342 -1, -1, 442, 847, 848, -1, -1, 851, -1, 81,
03343 -1, 744, 452, 746, -1, -1, -1, 2, 982, 4,
03344 984, 93, 94, 95, -1, -1, 990, -1, 992, 469,
03345 -1, -1, 666, 877, 878, -1, 769, 770, -1, -1,
03346 -1, -1, -1, -1, -1, 778, -1, -1, -1, 893,
03347 -1, -1, 896, -1, 787, -1, 1020, -1, -1, -1,
03348 694, -1, -1, -1, 698, 699, 51, 701, 702, -1,
03349 -1, -1, -1, 917, 708, 709, -1, 921, -1, 519,
03350 -1, 715, -1, -1, -1, -1, -1, -1, 932, -1,
03351 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03352 -1, -1, -1, -1, -1, -1, -1, -1, 93, -1,
03353 -1, -1, -1, 206, -1, -1, -1, -1, 752, -1,
03354 -1, -1, 756, 757, -1, 759, 760, 54, -1, -1,
03355 -1, 571, -1, 573, 206, -1, -1, -1, 982, 872,
03356 984, 874, -1, 777, -1, -1, 990, 240, 992, -1,
03357 -1, -1, -1, -1, -1, 595, -1, -1, 251, -1,
03358 253, -1, -1, -1, 897, -1, -1, -1, 240, -1,
03359 -1, 904, -1, -1, -1, -1, -1, -1, -1, 251,
03360 -1, 253, -1, 817, -1, -1, -1, 821, -1, -1,
03361 -1, -1, -1, 633, -1, 829, -1, -1, 638, -1,
03362 -1, -1, 274, -1, -1, -1, -1, -1, 941, 942,
03363 -1, -1, -1, -1, 947, 308, 850, -1, -1, -1,
03364 313, 206, -1, -1, -1, -1, -1, -1, -1, -1,
03365 -1, -1, 325, 867, 868, -1, 308, -1, -1, -1,
03366 -1, 313, -1, -1, -1, -1, -1, 687, -1, -1,
03367 690, -1, 692, 325, 326, 240, -1, 697, -1, -1,
03368 993, -1, 995, -1, -1, 358, 251, -1, 253, -1,
03369 -1, 1004, -1, -1, -1, -1, -1, 204, -1, -1,
03370 207, 208, 209, -1, -1, -1, 358, -1, -1, -1,
03371 -1, -1, -1, -1, -1, 1028, -1, 737, -1, -1,
03372 -1, -1, -1, -1, -1, 745, -1, -1, -1, -1,
03373 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03374 -1, -1, -1, 308, -1, -1, -1, -1, 313, -1,
03375 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03376 325, -1, -1, 328, -1, -1, -1, -1, -1, 442,
03377 -1, -1, -1, -1, -1, -1, -1, -1, -1, 452,
03378 -1, -1, -1, -1, 804, -1, -1, -1, -1, -1,
03379 442, -1, -1, 358, -1, 815, -1, -1, -1, -1,
03380 452, -1, -1, -1, -1, -1, 1020, -1, -1, -1,
03381 -1, -1, -1, -1, -1, -1, 323, 469, -1, -1,
03382 840, 328, -1, -1, -1, -1, -1, 847, 848, -1,
03383 -1, 851, -1, -1, -1, -1, -1, -1, -1, -1,
03384 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03385 -1, -1, -1, -1, -1, -1, -1, 877, 878, -1,
03386 -1, -1, -1, -1, -1, -1, -1, 519, -1, -1,
03387 -1, -1, -1, 893, -1, -1, 896, 442, -1, 70,
03388 71, 72, 73, 74, 75, 76, 77, 452, 79, 80,
03389 -1, -1, -1, -1, 85, 86, -1, 917, 571, -1,
03390 573, 921, -1, -1, -1, -1, 413, 414, -1, -1,
03391 -1, -1, 932, -1, -1, 422, -1, -1, -1, 571,
03392 -1, 573, 595, -1, -1, -1, -1, 118, 119, 120,
03393 121, 122, 123, 124, 125, 126, 127, -1, -1, -1,
03394 -1, -1, -1, 595, -1, -1, -1, -1, -1, -1,
03395 457, -1, -1, 460, -1, -1, -1, -1, -1, -1,
03396 633, -1, 982, -1, 984, -1, -1, -1, -1, -1,
03397 990, -1, 992, -1, -1, -1, -1, -1, -1, -1,
03398 -1, 633, -1, -1, -1, -1, 638, -1, -1, -1,
03399 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03400 -1, -1, -1, -1, -1, 512, 571, -1, 573, -1,
03401 -1, -1, -1, -1, 687, -1, -1, 690, -1, 692,
03402 -1, -1, -1, -1, -1, -1, 678, -1, -1, -1,
03403 595, -1, -1, -1, -1, 687, -1, -1, 690, -1,
03404 692, -1, -1, -1, -1, 697, -1, -1, -1, -1,
03405 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03406 -1, -1, -1, -1, 737, -1, -1, -1, 633, -1,
03407 577, -1, 745, -1, -1, -1, -1, -1, -1, -1,
03408 -1, -1, -1, -1, -1, 737, -1, -1, -1, -1,
03409 -1, -1, -1, 745, -1, -1, -1, -1, -1, -1,
03410 -1, -1, 609, -1, -1, -1, -1, -1, -1, -1,
03411 -1, -1, -1, -1, -1, 622, 623, -1, -1, -1,
03412 -1, -1, 687, -1, -1, 690, -1, 692, -1, -1,
03413 -1, -1, -1, 698, -1, -1, -1, -1, -1, -1,
03414 -1, -1, 815, -1, -1, -1, -1, -1, -1, -1,
03415 -1, -1, 804, -1, -1, -1, -1, -1, -1, 666,
03416 -1, -1, -1, 815, -1, -1, -1, 840, -1, -1,
03417 -1, -1, 737, -1, 847, 848, -1, -1, 851, -1,
03418 745, -1, -1, -1, -1, -1, -1, 694, 840, -1,
03419 -1, -1, -1, -1, -1, 847, 848, -1, -1, 851,
03420 -1, -1, -1, -1, 877, 878, -1, -1, 715, -1,
03421 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03422 893, -1, -1, -1, -1, 877, 878, -1, -1, -1,
03423 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03424 -1, 893, -1, -1, 896, -1, -1, -1, 921, -1,
03425 815, 70, 71, 72, 73, 74, 75, 76, -1, 932,
03426 79, 80, -1, -1, -1, 917, 85, 86, -1, 921,
03427 777, -1, -1, -1, -1, 840, -1, -1, -1, -1,
03428 932, -1, 847, 848, -1, -1, 851, -1, -1, -1,
03429 -1, -1, -1, -1, -1, -1, -1, -1, -1, 118,
03430 119, 120, 121, 122, 123, 124, 125, 126, 127, 982,
03431 817, 984, 877, 878, -1, -1, -1, 990, -1, 992,
03432 -1, -1, -1, -1, -1, -1, -1, -1, 893, -1,
03433 982, -1, 984, -1, -1, -1, -1, -1, 990, -1,
03434 992, -1, -1, 850, 70, 71, 72, 73, 74, 75,
03435 76, -1, 917, 79, 80, -1, 921, -1, -1, 85,
03436 86, 868, -1, -1, -1, -1, -1, 932, -1, -1,
03437 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03438 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03439 -1, -1, 118, 119, 120, 121, 122, 123, 124, 125,
03440 126, 127, -1, -1, -1, -1, -1, -1, -1, -1,
03441 -1, -1, -1, -1, -1, -1, -1, 982, -1, 984,
03442 -1, -1, -1, -1, -1, 990, -1, 992, 0, 1,
03443 -1, 3, 4, 5, 6, 7, -1, -1, -1, 11,
03444 12, -1, -1, -1, 16, -1, 18, 19, 20, 21,
03445 22, 23, 24, -1, -1, -1, -1, -1, 30, 31,
03446 32, 33, 34, 35, 36, -1, -1, 39, -1, -1,
03447 -1, -1, -1, 45, 46, 47, 48, 49, 50, 51,
03448 52, 53, 54, 55, 56, 57, -1, 59, 60, 61,
03449 62, -1, 64, 65, 66, -1, 68, 69, -1, -1,
03450 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03451 -1, -1, -1, -1, -1, -1, 88, -1, -1, 91,
03452 92, -1, 94, 95, -1, 97, -1, -1, 100, 101,
03453 102, 103, 104, 105, 106, 107, 108, 0, -1, -1,
03454 -1, -1, -1, -1, -1, 8, 9, 10, -1, -1,
03455 13, 14, 15, -1, 17, -1, 128, 129, 130, -1,
03456 44, -1, -1, 26, 27, 28, 29, -1, -1, 141,
03457 -1, 143, -1, -1, 37, 38, -1, 40, 41, 42,
03458 43, 44, -1, -1, -1, -1, 70, 71, 72, 73,
03459 74, 75, 76, 77, 78, 79, 80, 81, 82, -1,
03460 -1, 85, 86, -1, -1, -1, -1, 70, 71, 72,
03461 73, 74, 75, 76, 77, 78, 79, 80, 81, 82,
03462 -1, -1, 85, 86, 87, -1, 89, 90, -1, -1,
03463 -1, -1, 116, 96, 118, 119, 120, 121, 122, 123,
03464 124, 125, 126, 127, -1, -1, -1, 110, -1, -1,
03465 113, -1, 115, 116, 117, 118, 119, 120, 121, 122,
03466 123, 124, 125, 126, 127, -1, -1, -1, -1, 132,
03467 133, 134, 135, 136, 0, -1, 139, 140, 141, -1,
03468 143, -1, 8, 9, 10, -1, -1, 13, 14, 15,
03469 -1, 17, -1, -1, -1, -1, -1, 44, -1, 25,
03470 -1, 27, 28, 29, -1, -1, -1, -1, -1, -1,
03471 -1, 37, 38, -1, 40, 41, 42, 43, 44, -1,
03472 -1, -1, -1, 70, 71, 72, 73, 74, 75, 76,
03473 77, 78, 79, 80, 81, 82, -1, -1, 85, 86,
03474 -1, -1, -1, -1, 70, 71, 72, 73, 74, 75,
03475 76, 77, 78, 79, 80, 81, 82, -1, -1, 85,
03476 86, 87, -1, 89, 90, -1, -1, -1, -1, 116,
03477 96, 118, 119, 120, 121, 122, 123, 124, 125, 126,
03478 127, -1, -1, -1, 110, -1, -1, 113, -1, 115,
03479 116, 117, 118, 119, 120, 121, 122, 123, 124, 125,
03480 126, 127, -1, -1, -1, -1, -1, 133, 134, 135,
03481 136, 0, -1, 139, 140, 141, -1, 143, -1, 8,
03482 9, 10, -1, -1, 13, 14, 15, -1, 17, -1,
03483 -1, -1, -1, -1, -1, -1, 25, -1, 27, 28,
03484 29, -1, -1, -1, -1, -1, -1, -1, 37, 38,
03485 -1, 40, 41, 42, 43, 44, -1, -1, -1, -1,
03486 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
03487 80, 81, 82, -1, -1, 85, 86, -1, -1, -1,
03488 -1, 70, 71, 72, 73, 74, 75, 76, 77, 78,
03489 79, 80, 81, 82, -1, -1, 85, 86, 87, -1,
03490 89, 90, -1, -1, -1, -1, 116, 96, 118, 119,
03491 120, 121, 122, 123, 124, 125, 126, 127, -1, -1,
03492 -1, 110, -1, -1, 113, -1, 115, 116, 117, 118,
03493 119, 120, 121, 122, 123, 124, 125, 126, 127, -1,
03494 -1, -1, -1, -1, 133, 134, 135, 136, 0, -1,
03495 139, 140, 141, -1, 143, -1, 8, 9, 10, -1,
03496 -1, 13, 14, 15, -1, 17, -1, -1, -1, -1,
03497 -1, 44, -1, -1, 26, 27, 28, 29, -1, -1,
03498 -1, -1, -1, -1, -1, 37, 38, -1, 40, 41,
03499 42, 43, 44, -1, -1, -1, -1, 70, 71, 72,
03500 73, 74, 75, 76, 77, 78, 79, 80, 81, 82,
03501 -1, -1, 85, 86, -1, -1, -1, -1, 70, 71,
03502 72, 73, 74, 75, 76, 77, 78, 79, 80, 81,
03503 82, -1, -1, 85, 86, 87, -1, -1, 90, -1,
03504 -1, -1, -1, 116, 96, 118, 119, 120, 121, 122,
03505 123, 124, 125, 126, 127, -1, -1, -1, 110, -1,
03506 -1, 113, -1, 136, 116, 117, 118, 119, 120, 121,
03507 122, 123, 124, 125, 126, 127, -1, -1, -1, -1,
03508 132, 133, 134, 135, 136, 0, -1, 139, 140, 141,
03509 -1, 143, -1, 8, 9, 10, -1, -1, 13, 14,
03510 15, -1, 17, -1, -1, -1, -1, -1, -1, -1,
03511 -1, 26, 27, 28, 29, -1, -1, -1, -1, -1,
03512 -1, -1, 37, 38, -1, 40, 41, 42, 43, 44,
03513 -1, -1, -1, -1, 70, 71, 72, 73, 74, 75,
03514 76, 77, 78, 79, 80, 81, 82, -1, -1, 85,
03515 86, -1, -1, -1, -1, 70, 71, 72, 73, 74,
03516 75, 76, 77, 78, 79, 80, 81, 82, -1, -1,
03517 85, 86, 87, -1, -1, 90, -1, -1, -1, -1,
03518 -1, 96, 118, 119, 120, 121, 122, 123, 124, 125,
03519 126, 127, -1, -1, -1, 110, -1, -1, 113, -1,
03520 -1, 116, 117, 118, 119, 120, 121, 122, 123, 124,
03521 125, 126, 127, -1, -1, -1, -1, 132, 133, 134,
03522 135, 136, 0, -1, 139, 140, 141, -1, 143, -1,
03523 8, 9, 10, -1, -1, 13, 14, 15, -1, 17,
03524 -1, -1, -1, -1, -1, -1, -1, -1, -1, 27,
03525 28, 29, -1, -1, -1, -1, -1, -1, -1, 37,
03526 38, -1, 40, 41, 42, 43, 44, -1, -1, -1,
03527 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03528 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03529 -1, -1, 70, 71, 72, 73, 74, 75, 76, 77,
03530 78, 79, 80, 81, 82, -1, -1, 85, 86, 87,
03531 -1, 89, 90, -1, -1, -1, -1, -1, 96, -1,
03532 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03533 -1, -1, 110, -1, -1, 113, -1, 115, 116, 117,
03534 118, 119, 120, 121, 122, 123, 124, 125, 126, 127,
03535 -1, -1, -1, -1, -1, 133, 134, 135, 136, 0,
03536 -1, 139, 140, 141, -1, 143, -1, 8, 9, 10,
03537 -1, -1, 13, 14, 15, -1, 17, -1, -1, -1,
03538 -1, -1, -1, -1, -1, 26, 27, 28, -1, -1,
03539 -1, -1, -1, -1, -1, -1, 37, 38, -1, 40,
03540 41, 42, 43, 44, -1, -1, -1, -1, -1, -1,
03541 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03542 -1, -1, -1, -1, -1, -1, -1, -1, -1, 70,
03543 71, 72, 73, 74, 75, 76, 77, 78, 79, 80,
03544 81, 82, -1, -1, 85, 86, 87, -1, -1, 90,
03545 -1, -1, -1, -1, -1, 96, -1, -1, -1, -1,
03546 -1, -1, -1, -1, -1, -1, -1, -1, -1, 110,
03547 -1, -1, -1, -1, -1, 116, -1, 118, 119, 120,
03548 121, 122, 123, 124, 125, 126, 127, -1, -1, -1,
03549 -1, 132, 133, 134, 135, 136, 0, 138, 139, 140,
03550 141, -1, 143, -1, 8, 9, 10, -1, -1, 13,
03551 14, 15, -1, 17, -1, -1, -1, -1, -1, -1,
03552 -1, -1, -1, 27, 28, 29, -1, -1, -1, -1,
03553 -1, -1, -1, 37, 38, -1, 40, 41, 42, 43,
03554 44, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03555 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03556 -1, -1, -1, -1, -1, -1, 70, 71, 72, 73,
03557 74, 75, 76, 77, 78, 79, 80, 81, 82, -1,
03558 -1, 85, 86, 87, -1, -1, 90, -1, -1, -1,
03559 -1, -1, 96, -1, -1, -1, -1, -1, -1, -1,
03560 -1, -1, -1, -1, -1, -1, 110, -1, -1, 113,
03561 -1, -1, 116, 117, 118, 119, 120, 121, 122, 123,
03562 124, 125, 126, 127, -1, -1, -1, -1, -1, 133,
03563 134, 135, 136, 0, -1, 139, 140, 141, -1, 143,
03564 -1, 8, 9, 10, -1, -1, 13, 14, 15, -1,
03565 17, -1, -1, -1, -1, -1, -1, -1, -1, 26,
03566 27, 28, -1, -1, -1, -1, -1, -1, -1, -1,
03567 37, 38, -1, 40, 41, 42, 43, 44, -1, -1,
03568 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03569 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03570 -1, -1, -1, 70, 71, 72, 73, 74, 75, 76,
03571 77, 78, 79, 80, 81, 82, -1, -1, 85, 86,
03572 87, -1, -1, 90, -1, -1, -1, -1, -1, 96,
03573 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03574 -1, -1, -1, 110, -1, -1, -1, -1, -1, 116,
03575 -1, 118, 119, 120, 121, 122, 123, 124, 125, 126,
03576 127, -1, -1, -1, -1, 132, 133, 134, 135, 136,
03577 0, 138, 139, 140, 141, -1, 143, -1, 8, 9,
03578 10, -1, -1, 13, 14, 15, -1, 17, -1, -1,
03579 -1, -1, -1, -1, -1, -1, -1, 27, 28, -1,
03580 -1, -1, -1, -1, -1, -1, -1, 37, 38, -1,
03581 40, 41, 42, 43, 44, -1, -1, -1, -1, -1,
03582 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03583 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03584 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
03585 80, 81, 82, -1, -1, 85, 86, 87, -1, -1,
03586 90, -1, -1, -1, -1, -1, 96, -1, -1, -1,
03587 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03588 110, -1, -1, -1, -1, -1, 116, -1, 118, 119,
03589 120, 121, 122, 123, 124, 125, 126, 127, -1, -1,
03590 -1, -1, -1, 133, 134, 135, 136, 0, 138, 139,
03591 140, 141, -1, 143, -1, 8, 9, 10, -1, -1,
03592 -1, 14, 15, -1, 17, -1, -1, -1, -1, -1,
03593 -1, -1, -1, 26, -1, -1, -1, -1, -1, -1,
03594 -1, -1, -1, -1, 37, 38, -1, 40, 41, 42,
03595 43, 44, -1, -1, -1, -1, -1, -1, -1, -1,
03596 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03597 -1, -1, -1, -1, -1, -1, -1, 70, 71, 72,
03598 73, 74, 75, 76, 77, 78, 79, 80, 81, 82,
03599 -1, -1, 85, 86, 87, -1, 89, -1, -1, -1,
03600 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03601 -1, -1, -1, -1, -1, -1, -1, 110, -1, -1,
03602 -1, -1, 115, 116, -1, 118, 119, 120, 121, 122,
03603 123, 124, 125, 126, 127, -1, -1, -1, -1, 132,
03604 133, 134, 135, 136, 0, -1, 139, -1, 141, -1,
03605 143, -1, 8, 9, 10, -1, -1, -1, 14, 15,
03606 -1, 17, -1, -1, -1, -1, -1, -1, -1, -1,
03607 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03608 -1, 37, 38, -1, 40, 41, 42, 43, 44, -1,
03609 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03610 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03611 -1, -1, -1, -1, 70, 71, 72, 73, 74, 75,
03612 76, 77, 78, 79, 80, 81, 82, -1, -1, 85,
03613 86, 87, -1, 89, -1, -1, -1, -1, -1, -1,
03614 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03615 -1, -1, -1, -1, 110, -1, -1, -1, -1, 115,
03616 116, -1, 118, 119, 120, 121, 122, 123, 124, 125,
03617 126, 127, -1, -1, -1, -1, -1, 133, 134, 135,
03618 136, -1, -1, 139, -1, 141, 1, 143, 3, 4,
03619 5, 6, 7, 8, 9, 10, 11, 12, -1, -1,
03620 15, 16, -1, 18, 19, 20, 21, 22, 23, 24,
03621 -1, -1, -1, -1, -1, 30, 31, 32, 33, 34,
03622 35, 36, -1, -1, 39, -1, -1, -1, -1, -1,
03623 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
03624 55, 56, 57, -1, 59, 60, 61, 62, -1, 64,
03625 65, 66, -1, 68, 69, -1, -1, -1, -1, -1,
03626 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03627 -1, -1, -1, 88, -1, -1, 91, 92, -1, 94,
03628 95, -1, 97, -1, -1, 100, 101, 102, 103, 104,
03629 105, 106, 107, 108, -1, -1, -1, -1, -1, -1,
03630 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03631 -1, -1, -1, 128, 129, 130, -1, -1, -1, -1,
03632 -1, -1, -1, -1, -1, -1, 141, 1, 143, 3,
03633 4, 5, 6, 7, -1, -1, 10, 11, 12, -1,
03634 14, 15, 16, -1, 18, 19, 20, 21, 22, 23,
03635 24, -1, -1, -1, -1, -1, 30, 31, 32, 33,
03636 34, 35, 36, -1, -1, 39, -1, -1, -1, -1,
03637 -1, 45, 46, 47, 48, 49, 50, 51, 52, 53,
03638 54, 55, 56, 57, -1, 59, 60, 61, 62, -1,
03639 64, 65, 66, -1, 68, 69, -1, -1, -1, -1,
03640 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03641 -1, -1, -1, -1, 88, -1, -1, 91, 92, -1,
03642 94, 95, -1, 97, -1, -1, 100, 101, 102, 103,
03643 104, 105, 106, 107, 108, -1, -1, -1, -1, -1,
03644 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03645 -1, -1, -1, -1, 128, 129, 130, -1, -1, -1,
03646 -1, -1, -1, -1, -1, -1, -1, 141, 1, 143,
03647 3, 4, 5, 6, 7, -1, -1, 10, 11, 12,
03648 -1, -1, 15, 16, 17, 18, 19, 20, 21, 22,
03649 23, 24, -1, -1, -1, -1, -1, 30, 31, 32,
03650 33, 34, 35, 36, -1, -1, 39, -1, -1, -1,
03651 -1, -1, 45, 46, 47, 48, 49, 50, 51, 52,
03652 53, 54, 55, 56, 57, -1, 59, 60, 61, 62,
03653 -1, 64, 65, 66, -1, 68, 69, -1, -1, -1,
03654 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03655 -1, -1, -1, -1, -1, 88, -1, -1, 91, 92,
03656 -1, 94, 95, -1, 97, -1, -1, 100, 101, 102,
03657 103, 104, 105, 106, 107, 108, -1, -1, -1, -1,
03658 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03659 -1, -1, -1, -1, -1, 128, 129, 130, -1, -1,
03660 -1, -1, -1, -1, -1, -1, -1, -1, 141, 1,
03661 143, 3, 4, 5, 6, 7, -1, -1, 10, 11,
03662 12, -1, -1, 15, 16, -1, 18, 19, 20, 21,
03663 22, 23, 24, -1, -1, -1, -1, -1, 30, 31,
03664 32, 33, 34, 35, 36, -1, -1, 39, -1, -1,
03665 -1, -1, -1, 45, 46, 47, 48, 49, 50, 51,
03666 52, 53, 54, 55, 56, 57, -1, 59, 60, 61,
03667 62, -1, 64, 65, 66, -1, 68, 69, -1, -1,
03668 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03669 -1, -1, -1, -1, -1, -1, 88, -1, -1, 91,
03670 92, -1, 94, 95, -1, 97, -1, -1, 100, 101,
03671 102, 103, 104, 105, 106, 107, 108, -1, -1, -1,
03672 -1, -1, -1, -1, 1, -1, 3, 4, 5, 6,
03673 7, -1, 9, 10, 11, 12, 128, 129, 130, 16,
03674 -1, 18, 19, 20, 21, 22, 23, 24, -1, 141,
03675 -1, 143, -1, 30, 31, 32, 33, 34, 35, 36,
03676 -1, -1, 39, -1, -1, -1, -1, -1, 45, 46,
03677 47, 48, 49, 50, 51, 52, 53, 54, 55, 56,
03678 57, -1, 59, 60, 61, 62, -1, 64, 65, 66,
03679 -1, 68, 69, -1, -1, -1, -1, -1, -1, -1,
03680 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03681 -1, 88, -1, -1, 91, 92, -1, 94, 95, -1,
03682 97, -1, -1, 100, 101, 102, 103, 104, 105, 106,
03683 107, 108, -1, -1, -1, -1, -1, -1, -1, 1,
03684 -1, 3, 4, 5, 6, 7, -1, -1, -1, 11,
03685 12, 128, 129, 130, 16, -1, 18, 19, 20, 21,
03686 22, 23, 24, -1, 141, -1, 143, -1, 30, 31,
03687 32, 33, 34, 35, 36, -1, -1, 39, -1, -1,
03688 -1, -1, -1, 45, 46, 47, 48, 49, 50, 51,
03689 52, 53, 54, 55, 56, 57, -1, 59, 60, 61,
03690 62, -1, 64, 65, 66, -1, 68, 69, -1, -1,
03691 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03692 -1, -1, -1, -1, -1, -1, 88, -1, -1, 91,
03693 92, -1, 94, 95, -1, 97, -1, -1, 100, 101,
03694 102, 103, 104, 105, 106, 107, 108, -1, -1, -1,
03695 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03696 -1, -1, -1, -1, -1, -1, 128, 129, 130, -1,
03697 -1, -1, -1, -1, -1, -1, -1, 139, -1, 141,
03698 1, 143, 3, 4, 5, 6, 7, -1, -1, -1,
03699 11, 12, -1, -1, -1, 16, -1, 18, 19, 20,
03700 21, 22, 23, 24, -1, -1, -1, -1, -1, 30,
03701 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
03702 -1, -1, -1, -1, 45, 46, 47, 48, 49, 50,
03703 51, 52, 53, 54, 55, 56, 57, -1, 59, 60,
03704 61, 62, -1, 64, 65, 66, -1, 68, 69, -1,
03705 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03706 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
03707 91, 92, -1, 94, 95, -1, 97, -1, -1, 100,
03708 101, 102, 103, 104, 105, 106, 107, 108, -1, -1,
03709 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03710 -1, -1, -1, -1, -1, -1, -1, 128, 129, 130,
03711 -1, -1, -1, -1, -1, -1, -1, -1, 139, -1,
03712 141, 1, 143, 3, 4, 5, 6, 7, -1, -1,
03713 -1, 11, 12, -1, -1, -1, 16, -1, 18, 19,
03714 20, 21, 22, 23, 24, -1, -1, -1, -1, -1,
03715 30, 31, 32, 33, 34, 35, 36, -1, -1, 39,
03716 -1, -1, -1, -1, -1, 45, 46, 47, 48, 49,
03717 50, 51, 52, 53, 54, 55, 56, 57, -1, 59,
03718 60, 61, 62, -1, 64, 65, 66, -1, 68, 69,
03719 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03720 -1, -1, -1, -1, -1, -1, -1, -1, 88, -1,
03721 -1, 91, 92, -1, 94, 95, -1, 97, -1, -1,
03722 100, 101, 102, 103, 104, 105, 106, 107, 108, -1,
03723 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03724 -1, -1, -1, -1, -1, -1, -1, -1, 128, 129,
03725 130, -1, -1, 133, 1, -1, 3, 4, 5, 6,
03726 7, 141, -1, 143, 11, 12, -1, -1, -1, 16,
03727 -1, 18, 19, 20, 21, 22, 23, 24, -1, -1,
03728 -1, -1, -1, 30, 31, 32, 33, 34, 35, 36,
03729 -1, -1, 39, -1, -1, -1, -1, -1, 45, 46,
03730 47, 48, 49, 50, 51, 52, 53, 54, 55, 56,
03731 57, -1, 59, 60, 61, 62, -1, 64, 65, 66,
03732 -1, 68, 69, -1, -1, -1, -1, -1, -1, -1,
03733 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03734 -1, 88, -1, -1, 91, 92, -1, 94, 95, -1,
03735 97, -1, -1, 100, 101, 102, 103, 104, 105, 106,
03736 107, 108, -1, -1, -1, -1, -1, -1, -1, -1,
03737 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03738 -1, 128, 129, 130, -1, -1, 133, -1, -1, -1,
03739 -1, -1, -1, -1, 141, 1, 143, 3, 4, 5,
03740 6, 7, -1, -1, 10, 11, 12, -1, -1, -1,
03741 16, -1, 18, 19, 20, 21, 22, 23, 24, -1,
03742 -1, -1, -1, -1, 30, 31, 32, 33, 34, 35,
03743 36, -1, -1, 39, -1, -1, -1, -1, -1, 45,
03744 46, 47, 48, 49, 50, 51, 52, 53, 54, 55,
03745 56, 57, -1, 59, 60, 61, 62, -1, 64, 65,
03746 66, -1, 68, 69, -1, -1, -1, -1, -1, -1,
03747 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03748 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
03749 -1, 97, -1, -1, 100, 101, 102, 103, 104, 105,
03750 106, 107, 108, -1, -1, -1, -1, -1, -1, -1,
03751 1, -1, 3, 4, 5, 6, 7, -1, -1, -1,
03752 11, 12, 128, 129, 130, 16, -1, 18, 19, 20,
03753 21, 22, 23, 24, -1, 141, -1, 143, -1, 30,
03754 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
03755 -1, -1, -1, -1, 45, 46, 47, 48, 49, 50,
03756 51, 52, 53, 54, 55, 56, 57, -1, 59, 60,
03757 61, 62, -1, 64, 65, 66, -1, 68, 69, -1,
03758 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03759 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
03760 91, 92, -1, 94, 95, -1, 97, -1, -1, 100,
03761 101, 102, 103, 104, 105, 106, 107, 108, -1, 110,
03762 -1, -1, -1, -1, -1, -1, -1, 3, 4, 5,
03763 -1, 7, -1, -1, -1, 11, 12, 128, 129, 130,
03764 16, -1, 18, 19, 20, 21, 22, 23, 24, -1,
03765 141, -1, 143, -1, 30, 31, 32, 33, 34, 35,
03766 36, -1, -1, 39, -1, -1, -1, -1, -1, -1,
03767 46, -1, -1, 49, 50, 51, 52, 53, 54, 55,
03768 56, 57, 58, 59, 60, 61, 62, -1, 64, 65,
03769 66, -1, 68, 69, -1, -1, -1, -1, -1, -1,
03770 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03771 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
03772 -1, 97, 98, 99, 100, 101, 102, 103, 104, 105,
03773 106, 107, 108, -1, -1, -1, -1, -1, -1, -1,
03774 -1, -1, 3, 4, 5, -1, 7, -1, -1, -1,
03775 11, 12, 128, 129, 130, 16, -1, 18, 19, 20,
03776 21, 22, 23, 24, -1, -1, -1, 143, -1, 30,
03777 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
03778 -1, -1, -1, -1, -1, 46, -1, -1, 49, 50,
03779 51, 52, 53, 54, 55, 56, 57, -1, 59, 60,
03780 61, 62, -1, 64, 65, 66, -1, 68, 69, -1,
03781 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03782 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
03783 91, 92, -1, 94, 95, -1, -1, -1, -1, 100,
03784 101, 102, 103, 104, 105, 106, 107, 108, -1, -1,
03785 -1, -1, -1, -1, -1, -1, -1, 3, 4, 5,
03786 -1, 7, -1, -1, -1, 11, 12, 128, 129, 130,
03787 16, -1, 18, 19, 20, 21, 22, 23, 24, -1,
03788 141, -1, 143, -1, 30, 31, 32, 33, 34, 35,
03789 36, -1, -1, 39, -1, -1, -1, -1, -1, -1,
03790 46, -1, -1, 49, 50, 51, 52, 53, 54, 55,
03791 56, 57, -1, 59, 60, 61, 62, -1, 64, 65,
03792 66, -1, 68, 69, -1, -1, -1, -1, -1, -1,
03793 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03794 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
03795 -1, -1, -1, -1, 100, 101, 102, 103, 104, 105,
03796 106, 107, 108, -1, -1, -1, -1, -1, -1, -1,
03797 -1, -1, 3, 4, 5, 6, 7, -1, -1, -1,
03798 11, 12, 128, 129, 130, 16, -1, 18, 19, 20,
03799 21, 22, 23, 24, -1, -1, -1, 143, -1, 30,
03800 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
03801 -1, -1, -1, -1, 45, 46, 47, 48, 49, 50,
03802 51, 52, 53, 54, 55, 56, 57, -1, 59, 60,
03803 61, 62, -1, 64, 65, 66, -1, 68, 69, -1,
03804 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03805 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
03806 91, 92, -1, 94, 95, -1, 97, -1, -1, 100,
03807 101, 102, 103, 104, 105, 106, 107, 108, -1, -1,
03808 -1, -1, -1, -1, -1, -1, -1, 3, 4, 5,
03809 6, 7, -1, -1, -1, 11, 12, 128, 129, 130,
03810 16, -1, 18, 19, 20, 21, 22, 23, 24, -1,
03811 141, -1, -1, -1, 30, 31, 32, 33, 34, 35,
03812 36, -1, -1, 39, -1, -1, -1, -1, -1, 45,
03813 46, 47, 48, 49, 50, 51, 52, 53, 54, 55,
03814 56, 57, -1, 59, 60, 61, 62, -1, 64, 65,
03815 66, -1, 68, 69, -1, -1, -1, -1, -1, -1,
03816 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03817 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
03818 -1, 97, -1, -1, 100, 101, 102, 103, 104, 105,
03819 106, 107, 108, -1, -1, -1, -1, -1, -1, -1,
03820 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03821 -1, -1, 128, 129, 130, -1, -1, -1, -1, -1,
03822 -1, -1, -1, -1, -1, 141, 3, 4, 5, 6,
03823 7, 8, 9, 10, 11, 12, 13, 14, 15, 16,
03824 17, 18, 19, 20, 21, 22, 23, 24, 25, 26,
03825 -1, -1, -1, 30, 31, 32, 33, 34, 35, 36,
03826 37, 38, 39, -1, -1, -1, -1, -1, 45, 46,
03827 47, 48, 49, 50, 51, 52, 53, 54, 55, 56,
03828 57, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03829 -1, 68, 69, 70, 71, 72, 73, 74, 75, 76,
03830 -1, -1, 79, 80, -1, -1, 83, 84, 85, 86,
03831 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03832 97, 98, -1, -1, -1, -1, -1, -1, -1, -1,
03833 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03834 -1, 118, 119, 120, 121, 122, 123, 124, 125, 126,
03835 127, -1, 129, 130, -1, -1, -1, -1, -1, -1,
03836 137, 138, 3, 4, 5, 6, 7, 8, 9, 10,
03837 11, 12, 13, 14, 15, 16, 17, 18, 19, 20,
03838 21, 22, 23, 24, 25, 26, -1, -1, -1, 30,
03839 31, 32, 33, 34, 35, 36, 37, 38, 39, -1,
03840 -1, -1, -1, -1, 45, 46, 47, 48, 49, 50,
03841 51, 52, 53, 54, 55, 56, 57, -1, -1, -1,
03842 -1, -1, -1, -1, -1, -1, -1, 68, 69, 70,
03843 71, 72, 73, 74, 75, 76, -1, -1, 79, 80,
03844 -1, -1, 83, 84, 85, 86, -1, -1, -1, -1,
03845 -1, -1, -1, -1, -1, -1, 97, 98, -1, -1,
03846 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03847 -1, -1, -1, -1, -1, -1, -1, 118, 119, 120,
03848 121, 122, 123, 124, 125, 126, 127, -1, 129, 130,
03849 -1, -1, -1, -1, -1, -1, 137, 3, 4, 5,
03850 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
03851 16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
03852 26, -1, -1, -1, 30, 31, 32, 33, 34, 35,
03853 36, 37, 38, 39, -1, -1, -1, -1, -1, 45,
03854 46, 47, 48, 49, 50, 51, 52, 53, 54, -1,
03855 56, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03856 -1, -1, 68, 69, 70, 71, 72, 73, 74, 75,
03857 76, -1, -1, 79, 80, -1, -1, 83, 84, 85,
03858 86, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03859 -1, 97, 98, -1, -1, 101, -1, -1, -1, -1,
03860 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03861 -1, -1, 118, 119, 120, 121, 122, 123, 124, 125,
03862 126, 127, -1, 129, 130, -1, -1, -1, -1, -1,
03863 -1, 137, 3, 4, 5, 6, 7, 8, 9, 10,
03864 11, 12, 13, 14, 15, 16, 17, 18, 19, 20,
03865 21, 22, 23, 24, 25, 26, -1, -1, -1, 30,
03866 31, 32, 33, 34, 35, 36, 37, 38, 39, -1,
03867 -1, -1, -1, -1, 45, 46, 47, 48, 49, 50,
03868 51, 52, 53, -1, -1, 56, -1, -1, -1, -1,
03869 -1, -1, -1, -1, -1, -1, -1, 68, 69, 70,
03870 71, 72, 73, 74, 75, 76, -1, -1, 79, 80,
03871 -1, -1, 83, 84, 85, 86, -1, -1, -1, -1,
03872 -1, -1, -1, -1, -1, -1, 97, 98, -1, -1,
03873 101, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03874 -1, -1, -1, -1, -1, -1, -1, 118, 119, 120,
03875 121, 122, 123, 124, 125, 126, 127, -1, 129, 130,
03876 -1, -1, -1, -1, -1, -1, 137, 3, 4, 5,
03877 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
03878 16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
03879 26, -1, -1, -1, 30, 31, 32, 33, 34, 35,
03880 36, 37, 38, 39, -1, -1, -1, -1, -1, 45,
03881 46, 47, 48, 49, 50, 51, 52, 53, -1, -1,
03882 56, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03883 -1, -1, 68, 69, 70, 71, 72, 73, 74, 75,
03884 76, -1, -1, 79, 80, -1, -1, 83, 84, 85,
03885 86, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03886 -1, 97, 98, -1, -1, -1, -1, -1, -1, -1,
03887 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03888 -1, -1, 118, 119, 120, 121, 122, 123, 124, 125,
03889 126, 127, -1, 129, 130, 3, 4, 5, -1, 7,
03890 -1, 137, -1, 11, 12, -1, -1, -1, 16, -1,
03891 18, 19, 20, 21, 22, 23, 24, -1, -1, -1,
03892 -1, -1, 30, 31, 32, 33, 34, 35, 36, -1,
03893 -1, 39, -1, -1, -1, -1, -1, -1, 46, -1,
03894 -1, 49, 50, 51, 52, 53, 54, 55, 56, 57,
03895 -1, 59, 60, 61, 62, -1, 64, 65, 66, -1,
03896 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03897 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03898 88, -1, -1, 91, 92, -1, 94, 95, -1, -1,
03899 -1, -1, 100, 101, 102, 103, 104, 105, 106, 107,
03900 108, -1, -1, -1, -1, -1, 3, 4, 5, -1,
03901 7, -1, -1, -1, 11, 12, -1, -1, -1, 16,
03902 128, 18, 19, 20, 21, 22, 23, 24, 136, -1,
03903 -1, -1, -1, 30, 31, 32, 33, 34, 35, 36,
03904 -1, -1, 39, -1, -1, -1, -1, -1, -1, 46,
03905 -1, -1, 49, 50, 51, 52, 53, 54, 55, 56,
03906 57, -1, 59, 60, 61, 62, -1, 64, 65, 66,
03907 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03908 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03909 -1, 88, -1, -1, 91, 92, -1, 94, 95, -1,
03910 -1, -1, -1, 100, 101, 102, 103, 104, 105, 106,
03911 107, 108, -1, -1, -1, -1, -1, 3, 4, 5,
03912 6, 7, -1, -1, -1, 11, 12, -1, -1, -1,
03913 16, 128, 18, 19, 20, 21, 22, 23, 24, 136,
03914 -1, -1, -1, -1, 30, 31, 32, 33, 34, 35,
03915 36, -1, -1, 39, -1, -1, -1, -1, -1, 45,
03916 46, 47, 48, 49, 50, 51, 52, 53, 54, 55,
03917 56, 57, -1, 59, 60, 61, 62, -1, 64, 65,
03918 66, -1, 68, 69, -1, -1, -1, -1, -1, -1,
03919 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03920 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
03921 -1, 97, -1, -1, 100, 101, 102, 103, 104, 105,
03922 106, 107, 108, -1, -1, -1, -1, -1, -1, -1,
03923 -1, -1, 3, 4, 5, -1, 7, -1, -1, -1,
03924 11, 12, 128, 129, 130, 16, -1, 18, 19, 20,
03925 21, 22, 23, 24, -1, -1, -1, -1, -1, 30,
03926 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
03927 -1, -1, -1, -1, -1, 46, -1, -1, 49, 50,
03928 51, 52, 53, 54, 55, 56, 57, 58, 59, 60,
03929 61, 62, -1, 64, 65, 66, -1, 68, 69, -1,
03930 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03931 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
03932 91, 92, -1, 94, 95, -1, 97, 98, 99, 100,
03933 101, 102, 103, 104, 105, 106, 107, 108, -1, -1,
03934 -1, -1, -1, -1, -1, -1, -1, 3, 4, 5,
03935 6, 7, -1, -1, -1, 11, 12, 128, 129, 130,
03936 16, -1, 18, 19, 20, 21, 22, 23, 24, -1,
03937 -1, -1, -1, -1, 30, 31, 32, 33, 34, 35,
03938 36, -1, -1, 39, -1, -1, -1, -1, -1, 45,
03939 46, -1, 48, 49, 50, 51, 52, 53, 54, 55,
03940 56, 57, -1, 59, 60, 61, 62, -1, 64, 65,
03941 66, -1, 68, 69, -1, -1, -1, -1, -1, -1,
03942 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03943 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
03944 -1, 97, -1, -1, 100, 101, 102, 103, 104, 105,
03945 106, 107, 108, -1, -1, -1, -1, -1, -1, -1,
03946 -1, -1, 3, 4, 5, -1, 7, -1, -1, -1,
03947 11, 12, 128, 129, 130, 16, -1, 18, 19, 20,
03948 21, 22, 23, 24, -1, -1, -1, -1, -1, 30,
03949 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
03950 -1, -1, -1, -1, -1, 46, -1, -1, 49, 50,
03951 51, 52, 53, 54, 55, 56, 57, 58, 59, 60,
03952 61, 62, -1, 64, 65, 66, -1, 68, 69, -1,
03953 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03954 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
03955 91, 92, -1, 94, 95, -1, 97, 98, 99, 100,
03956 101, 102, 103, 104, 105, 106, 107, 108, -1, -1,
03957 -1, -1, -1, -1, -1, -1, -1, 3, 4, 5,
03958 -1, 7, -1, -1, -1, 11, 12, 128, 129, 130,
03959 16, -1, 18, 19, 20, 21, 22, 23, 24, -1,
03960 -1, -1, -1, -1, 30, 31, 32, 33, 34, 35,
03961 36, -1, -1, 39, -1, -1, -1, -1, -1, -1,
03962 46, -1, -1, 49, 50, 51, 52, 53, 54, 55,
03963 56, 57, 58, 59, 60, 61, 62, -1, 64, 65,
03964 66, -1, 68, 69, -1, -1, -1, -1, -1, -1,
03965 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03966 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
03967 -1, 97, 98, -1, 100, 101, 102, 103, 104, 105,
03968 106, 107, 108, -1, -1, -1, -1, -1, -1, -1,
03969 -1, -1, 3, 4, 5, -1, 7, -1, -1, -1,
03970 11, 12, 128, 129, 130, 16, -1, 18, 19, 20,
03971 21, 22, 23, 24, -1, -1, -1, -1, -1, 30,
03972 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
03973 -1, -1, -1, -1, -1, 46, -1, -1, 49, 50,
03974 51, 52, 53, 54, 55, 56, 57, 58, 59, 60,
03975 61, 62, -1, 64, 65, 66, -1, 68, 69, -1,
03976 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03977 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
03978 91, 92, -1, 94, 95, -1, -1, 98, 99, 100,
03979 101, 102, 103, 104, 105, 106, 107, 108, -1, -1,
03980 -1, -1, -1, -1, -1, -1, -1, 3, 4, 5,
03981 -1, 7, -1, -1, -1, 11, 12, 128, 129, 130,
03982 16, -1, 18, 19, 20, 21, 22, 23, 24, -1,
03983 -1, -1, -1, -1, 30, 31, 32, 33, 34, 35,
03984 36, -1, -1, 39, -1, -1, -1, -1, -1, -1,
03985 46, -1, -1, 49, 50, 51, 52, 53, 54, 55,
03986 56, 57, 58, 59, 60, 61, 62, -1, 64, 65,
03987 66, -1, 68, 69, -1, -1, -1, -1, -1, -1,
03988 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
03989 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
03990 -1, 97, 98, -1, 100, 101, 102, 103, 104, 105,
03991 106, 107, 108, -1, -1, -1, -1, -1, -1, -1,
03992 -1, -1, 3, 4, 5, -1, 7, -1, -1, -1,
03993 11, 12, 128, 129, 130, 16, -1, 18, 19, 20,
03994 21, 22, 23, 24, -1, -1, -1, -1, -1, 30,
03995 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
03996 -1, -1, -1, -1, -1, 46, -1, -1, 49, 50,
03997 51, 52, 53, 54, 55, 56, 57, 58, 59, 60,
03998 61, 62, -1, 64, 65, 66, -1, 68, 69, -1,
03999 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04000 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
04001 91, 92, -1, 94, 95, -1, -1, 98, -1, 100,
04002 101, 102, 103, 104, 105, 106, 107, 108, -1, -1,
04003 -1, -1, -1, -1, -1, -1, -1, 3, 4, 5,
04004 -1, 7, -1, -1, -1, 11, 12, 128, 129, 130,
04005 16, -1, 18, 19, 20, 21, 22, 23, 24, -1,
04006 -1, -1, -1, -1, 30, 31, 32, 33, 34, 35,
04007 36, -1, -1, 39, -1, -1, -1, -1, -1, -1,
04008 46, -1, -1, 49, 50, 51, 52, 53, 54, 55,
04009 56, 57, -1, 59, 60, 61, 62, -1, 64, 65,
04010 66, -1, 68, 69, -1, -1, -1, -1, -1, -1,
04011 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04012 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
04013 -1, 97, -1, -1, 100, 101, 102, 103, 104, 105,
04014 106, 107, 108, -1, -1, -1, -1, -1, -1, -1,
04015 -1, -1, 3, 4, 5, -1, 7, -1, -1, -1,
04016 11, 12, 128, 129, 130, 16, -1, 18, 19, 20,
04017 21, 22, 23, 24, -1, -1, -1, -1, -1, 30,
04018 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
04019 -1, -1, -1, -1, -1, 46, -1, -1, 49, 50,
04020 51, 52, 53, 54, 55, 56, 57, -1, 59, 60,
04021 61, 62, -1, 64, 65, 66, -1, 68, 69, -1,
04022 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04023 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
04024 91, 92, -1, 94, 95, -1, 97, -1, -1, 100,
04025 101, 102, 103, 104, 105, 106, 107, 108, -1, -1,
04026 -1, -1, -1, -1, -1, -1, -1, 3, 4, 5,
04027 -1, 7, -1, -1, -1, 11, 12, 128, 129, 130,
04028 16, -1, 18, 19, 20, 21, 22, 23, 24, -1,
04029 -1, -1, -1, -1, 30, 31, 32, 33, 34, 35,
04030 36, -1, -1, 39, -1, -1, -1, -1, -1, -1,
04031 46, -1, -1, 49, 50, 51, 52, 53, 54, 55,
04032 56, 57, -1, 59, 60, 61, 62, -1, 64, 65,
04033 66, -1, 68, 69, -1, -1, -1, -1, -1, -1,
04034 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04035 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
04036 -1, 97, -1, -1, 100, 101, 102, 103, 104, 105,
04037 106, 107, 108, -1, -1, -1, -1, -1, -1, -1,
04038 -1, -1, 3, 4, 5, -1, 7, -1, -1, -1,
04039 11, 12, 128, 129, 130, 16, -1, 18, 19, 20,
04040 21, 22, 23, 24, -1, -1, -1, -1, -1, 30,
04041 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
04042 -1, -1, -1, -1, -1, 46, -1, -1, 49, 50,
04043 51, 52, 53, 54, 55, 56, 57, -1, 59, 60,
04044 61, 62, -1, 64, 65, 66, -1, 68, 69, -1,
04045 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04046 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
04047 91, 92, -1, 94, 95, -1, 97, -1, -1, 100,
04048 101, 102, 103, 104, 105, 106, 107, 108, -1, -1,
04049 -1, -1, -1, -1, -1, -1, -1, 3, 4, 5,
04050 -1, 7, -1, -1, -1, 11, 12, 128, 129, 130,
04051 16, -1, 18, 19, 20, 21, 22, 23, 24, -1,
04052 -1, -1, -1, -1, 30, 31, 32, 33, 34, 35,
04053 36, -1, -1, 39, -1, -1, -1, -1, -1, -1,
04054 46, -1, -1, 49, 50, 51, 52, 53, 54, 55,
04055 56, 57, -1, 59, 60, 61, 62, -1, 64, 65,
04056 66, -1, 68, 69, -1, -1, -1, -1, -1, -1,
04057 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04058 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
04059 -1, 97, -1, -1, 100, 101, 102, 103, 104, 105,
04060 106, 107, 108, -1, -1, -1, -1, -1, -1, -1,
04061 -1, -1, 3, 4, 5, -1, 7, -1, -1, -1,
04062 11, 12, 128, 129, 130, 16, -1, 18, 19, 20,
04063 21, 22, 23, 24, -1, -1, -1, -1, -1, 30,
04064 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
04065 -1, -1, -1, -1, -1, 46, -1, -1, 49, 50,
04066 51, 52, 53, 54, 55, 56, 57, -1, 59, 60,
04067 61, 62, -1, 64, 65, 66, -1, 68, 69, -1,
04068 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04069 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
04070 91, 92, -1, 94, 95, -1, -1, -1, -1, 100,
04071 101, 102, 103, 104, 105, 106, 107, 108, -1, -1,
04072 -1, -1, -1, -1, -1, -1, -1, 3, 4, 5,
04073 -1, 7, -1, -1, -1, 11, 12, 128, 129, 130,
04074 16, -1, 18, 19, 20, 21, 22, 23, 24, -1,
04075 -1, -1, -1, -1, 30, 31, 32, 33, 34, 35,
04076 36, -1, -1, 39, -1, -1, -1, -1, -1, -1,
04077 46, -1, -1, 49, 50, 51, 52, 53, 54, 55,
04078 56, 57, -1, 59, 60, 61, 62, -1, 64, 65,
04079 66, -1, 68, 69, -1, -1, -1, -1, -1, -1,
04080 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04081 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
04082 -1, -1, -1, -1, 100, 101, 102, 103, 104, 105,
04083 106, 107, 108, -1, -1, -1, -1, -1, -1, -1,
04084 -1, -1, 3, 4, 5, -1, 7, -1, -1, -1,
04085 11, 12, 128, 129, 130, 16, -1, 18, 19, 20,
04086 21, 22, 23, 24, -1, -1, -1, -1, -1, 30,
04087 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
04088 -1, -1, -1, -1, -1, 46, -1, -1, 49, 50,
04089 51, 52, 53, 54, 55, 56, 57, -1, 59, 60,
04090 61, 62, -1, 64, 65, 66, -1, 68, 69, -1,
04091 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04092 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
04093 91, 92, -1, 94, 95, -1, -1, -1, -1, 100,
04094 101, 102, 103, 104, 105, 106, 107, 108, -1, -1,
04095 -1, -1, -1, -1, -1, -1, -1, 3, 4, 5,
04096 -1, 7, -1, -1, -1, 11, 12, 128, 129, 130,
04097 16, -1, 18, 19, 20, 21, 22, 23, 24, -1,
04098 -1, -1, -1, -1, 30, 31, 32, 33, 34, 35,
04099 36, -1, -1, 39, -1, -1, -1, -1, -1, -1,
04100 46, -1, -1, 49, 50, 51, 52, 53, 54, 55,
04101 56, 57, -1, 59, 60, 61, 62, -1, 64, 65,
04102 66, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04103 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04104 -1, -1, 88, -1, -1, 91, 92, -1, 94, 95,
04105 -1, 97, -1, -1, 100, 101, 102, 103, 104, 105,
04106 106, 107, 108, -1, -1, -1, -1, -1, 3, 4,
04107 5, -1, 7, -1, -1, -1, 11, 12, -1, -1,
04108 -1, 16, 128, 18, 19, 20, 21, 22, 23, 24,
04109 -1, -1, -1, -1, -1, 30, 31, 32, 33, 34,
04110 35, 36, -1, -1, 39, -1, -1, -1, -1, -1,
04111 -1, 46, -1, -1, 49, 50, 51, 52, 53, 54,
04112 55, 56, 57, -1, 59, 60, 61, 62, -1, 64,
04113 65, 66, -1, -1, -1, -1, -1, -1, -1, -1,
04114 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04115 -1, -1, -1, 88, -1, -1, 91, 92, -1, 94,
04116 95, -1, 97, -1, -1, 100, 101, 102, 103, 104,
04117 105, 106, 107, 108, -1, -1, -1, -1, -1, 3,
04118 4, 5, -1, 7, -1, -1, -1, 11, 12, -1,
04119 -1, -1, 16, 128, 18, 19, 20, 21, 22, 23,
04120 24, -1, -1, -1, -1, -1, 30, 31, 32, 33,
04121 34, 35, 36, -1, -1, 39, -1, -1, -1, -1,
04122 -1, -1, 46, -1, -1, 49, 50, 51, 52, 53,
04123 54, 55, 56, 57, -1, 59, 60, 61, 62, -1,
04124 64, 65, 66, -1, -1, -1, -1, -1, -1, -1,
04125 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04126 -1, 85, -1, -1, 88, -1, -1, 91, 92, -1,
04127 94, 95, -1, -1, -1, -1, 100, 101, 102, 103,
04128 104, 105, 106, 107, 108, -1, -1, -1, -1, -1,
04129 3, 4, 5, -1, 7, -1, -1, -1, 11, 12,
04130 -1, -1, -1, 16, 128, 18, 19, 20, 21, 22,
04131 23, 24, -1, -1, -1, -1, -1, 30, 31, 32,
04132 33, 34, 35, 36, -1, -1, 39, -1, -1, -1,
04133 -1, -1, -1, 46, -1, -1, 49, 50, 51, 52,
04134 53, 54, 55, 56, 57, -1, 59, 60, 61, 62,
04135 -1, 64, 65, 66, -1, -1, -1, -1, -1, -1,
04136 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04137 -1, -1, -1, -1, -1, 88, -1, -1, 91, 92,
04138 -1, 94, 95, -1, -1, -1, -1, 100, 101, 102,
04139 103, 104, 105, 106, 107, 108, -1, -1, -1, -1,
04140 -1, 3, 4, 5, -1, 7, -1, -1, -1, 11,
04141 12, -1, -1, -1, 16, 128, 18, 19, 20, 21,
04142 22, 23, 24, -1, -1, -1, -1, -1, 30, 31,
04143 32, 33, 34, 35, 36, -1, -1, 39, -1, -1,
04144 -1, -1, -1, -1, 46, -1, -1, 49, 50, 51,
04145 52, 53, 54, 55, 56, 57, -1, 59, 60, 61,
04146 62, -1, 64, 65, 66, -1, -1, -1, -1, -1,
04147 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04148 -1, -1, -1, -1, -1, -1, 88, -1, -1, 91,
04149 92, -1, 94, 95, -1, -1, -1, -1, 100, 101,
04150 102, 103, 104, 105, 106, 107, 108, -1, -1, -1,
04151 -1, -1, 3, 4, 5, -1, 7, -1, -1, -1,
04152 11, 12, -1, -1, -1, 16, 128, 18, 19, 20,
04153 21, 22, 23, 24, -1, -1, -1, -1, -1, 30,
04154 31, 32, 33, 34, 35, 36, -1, -1, 39, -1,
04155 -1, -1, -1, -1, -1, 46, -1, -1, 49, 50,
04156 51, 52, 53, 54, 55, 56, 57, -1, 59, 60,
04157 61, 62, -1, 64, 65, 66, -1, -1, -1, -1,
04158 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04159 -1, -1, -1, -1, -1, -1, -1, 88, -1, -1,
04160 91, 92, -1, 94, 95, -1, -1, -1, -1, 100,
04161 101, 102, 103, 104, 105, 106, 107, 108, -1, -1,
04162 -1, -1, -1, 3, 4, 5, -1, 7, -1, -1,
04163 -1, 11, 12, -1, -1, -1, 16, 128, 18, 19,
04164 20, 21, 22, 23, 24, -1, -1, -1, -1, -1,
04165 30, 31, 32, 33, 34, 35, 36, -1, -1, 39,
04166 -1, -1, -1, -1, -1, -1, 46, -1, -1, 49,
04167 50, 51, 52, 53, 54, 55, 56, 57, -1, 59,
04168 60, 61, 62, -1, 64, 65, 66, -1, -1, -1,
04169 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04170 -1, -1, -1, -1, -1, -1, -1, -1, 88, -1,
04171 -1, 91, 92, -1, 94, 95, -1, -1, -1, -1,
04172 100, 101, 102, 103, 104, 105, 106, 107, 108, -1,
04173 -1, -1, -1, 52, 53, -1, -1, 56, -1, -1,
04174 -1, -1, -1, -1, -1, -1, -1, -1, 128, 68,
04175 69, 70, 71, 72, 73, 74, 75, 76, -1, -1,
04176 79, 80, -1, -1, 83, 84, 85, 86, -1, -1,
04177 -1, -1, -1, -1, -1, -1, -1, -1, 97, 98,
04178 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04179 -1, -1, -1, -1, -1, -1, -1, -1, -1, 118,
04180 119, 120, 121, 122, 123, 124, 125, 126, 127, -1,
04181 129, 130, 52, 53, -1, -1, 56, -1, 137, -1,
04182 -1, -1, -1, -1, -1, -1, -1, -1, 68, 69,
04183 70, 71, 72, 73, 74, 75, 76, -1, -1, 79,
04184 80, -1, -1, 83, 84, 85, 86, -1, -1, -1,
04185 -1, -1, -1, -1, -1, -1, -1, 97, 98, -1,
04186 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04187 -1, -1, -1, -1, -1, -1, -1, -1, 118, 119,
04188 120, 121, 122, 123, 124, 125, 126, 127, -1, 129,
04189 130, 52, 53, -1, -1, 56, -1, 137, -1, -1,
04190 -1, -1, -1, -1, -1, -1, -1, 68, 69, 70,
04191 71, 72, 73, 74, 75, 76, -1, -1, 79, 80,
04192 -1, -1, 83, 84, 85, 86, -1, -1, -1, -1,
04193 -1, -1, -1, -1, -1, -1, 97, 98, -1, -1,
04194 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04195 -1, -1, -1, -1, -1, -1, -1, 118, 119, 120,
04196 121, 122, 123, 124, 125, 126, 127, -1, 129, 130,
04197 52, 53, -1, -1, 56, -1, 137, -1, -1, -1,
04198 -1, -1, -1, -1, -1, -1, 68, 69, 70, 71,
04199 72, 73, 74, 75, 76, -1, -1, 79, 80, -1,
04200 -1, 83, 84, 85, 86, -1, -1, -1, -1, -1,
04201 -1, -1, -1, -1, -1, 97, 98, -1, -1, -1,
04202 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04203 -1, -1, -1, -1, -1, -1, 118, 119, 120, 121,
04204 122, 123, 124, 125, 126, 127, -1, 129, 130, 52,
04205 53, -1, -1, 56, -1, 137, -1, -1, -1, -1,
04206 -1, -1, -1, -1, -1, 68, 69, 70, 71, 72,
04207 73, 74, 75, 76, -1, -1, 79, 80, -1, -1,
04208 83, 84, 85, 86, -1, -1, -1, -1, -1, -1,
04209 -1, -1, -1, -1, 97, 98, -1, -1, -1, -1,
04210 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04211 -1, -1, -1, -1, -1, 118, 119, 120, 121, 122,
04212 123, 124, 125, 126, 127, -1, 129, 130, 52, 53,
04213 -1, -1, 56, -1, 137, -1, -1, -1, -1, -1,
04214 -1, -1, -1, -1, 68, 69, 70, 71, 72, 73,
04215 74, 75, 76, -1, -1, 79, 80, -1, -1, 83,
04216 84, 85, 86, -1, -1, -1, -1, -1, -1, -1,
04217 -1, -1, -1, 97, 98, -1, -1, -1, -1, -1,
04218 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04219 -1, -1, -1, -1, 118, 119, 120, 121, 122, 123,
04220 124, 125, 126, 127, -1, 129, 130, 52, 53, -1,
04221 -1, 56, -1, 137, -1, -1, -1, -1, -1, -1,
04222 -1, -1, -1, 68, 69, 70, 71, 72, 73, 74,
04223 75, 76, -1, -1, 79, 80, -1, -1, 83, 84,
04224 85, 86, -1, -1, -1, -1, -1, -1, -1, -1,
04225 -1, -1, 97, 98, -1, -1, -1, -1, -1, -1,
04226 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04227 -1, -1, -1, 118, 119, 120, 121, 122, 123, 124,
04228 125, 126, 127, -1, 129, 130, 52, 53, -1, -1,
04229 56, -1, 137, -1, -1, -1, -1, -1, -1, -1,
04230 -1, -1, 68, 69, 70, 71, 72, 73, 74, 75,
04231 76, -1, -1, 79, 80, -1, -1, 83, 84, 85,
04232 86, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04233 -1, 97, 98, -1, -1, -1, -1, -1, -1, -1,
04234 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04235 -1, -1, 118, 119, 120, 121, 122, 123, 124, 125,
04236 126, 127, -1, 129, 130, 52, 53, -1, -1, 56,
04237 -1, 137, -1, -1, -1, -1, -1, -1, -1, -1,
04238 -1, 68, 69, 70, 71, 72, 73, 74, 75, 76,
04239 -1, -1, 79, 80, -1, -1, 83, 84, 85, 86,
04240 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04241 97, 98, -1, -1, -1, -1, -1, -1, -1, -1,
04242 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04243 -1, 118, 119, 120, 121, 122, 123, 124, 125, 126,
04244 127, -1, 129, 130, 52, 53, -1, -1, 56, -1,
04245 137, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04246 68, 69, 70, 71, 72, 73, 74, 75, 76, -1,
04247 -1, 79, 80, -1, -1, 83, 84, 85, 86, -1,
04248 -1, -1, -1, -1, -1, -1, -1, -1, -1, 97,
04249 98, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04250 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04251 118, 119, 120, 121, 122, 123, 124, 125, 126, 127,
04252 -1, 129, 130, 52, 53, -1, -1, 56, -1, 137,
04253 -1, -1, -1, -1, -1, -1, -1, -1, -1, 68,
04254 69, 70, 71, 72, 73, 74, 75, 76, -1, -1,
04255 79, 80, -1, -1, 83, 84, 85, 86, -1, -1,
04256 -1, -1, -1, -1, -1, -1, -1, -1, 97, 98,
04257 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04258 -1, -1, -1, -1, -1, -1, -1, -1, -1, 118,
04259 119, 120, 121, 122, 123, 124, 125, 126, 127, -1,
04260 129, 130, 52, 53, -1, -1, 56, -1, 137, -1,
04261 -1, -1, -1, -1, -1, -1, -1, -1, 68, 69,
04262 70, 71, 72, 73, 74, 75, 76, -1, -1, 79,
04263 80, -1, -1, 83, 84, 85, 86, -1, -1, -1,
04264 -1, -1, -1, -1, -1, -1, -1, 97, 98, -1,
04265 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04266 -1, -1, -1, -1, -1, -1, -1, -1, 118, 119,
04267 120, 121, 122, 123, 124, 125, 126, 127, -1, 129,
04268 130, 52, 53, -1, -1, 56, -1, 137, -1, -1,
04269 -1, -1, -1, -1, -1, -1, -1, 68, 69, 70,
04270 71, 72, 73, 74, 75, 76, -1, -1, 79, 80,
04271 -1, -1, 83, 84, 85, 86, -1, -1, -1, -1,
04272 -1, -1, -1, -1, -1, -1, 97, 98, 70, 71,
04273 72, 73, 74, 75, 76, 77, 78, 79, 80, 81,
04274 82, -1, -1, 85, 86, -1, -1, 118, 119, 120,
04275 121, 122, 123, 124, 125, 126, 127, -1, 129, 130,
04276 -1, -1, -1, -1, -1, -1, 137, -1, -1, -1,
04277 -1, -1, -1, -1, 116, -1, 118, 119, 120, 121,
04278 122, 123, 124, 125, 126, 127, -1, -1, -1, -1,
04279 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
04280 -1, 143
04281 };
04282
04283
04284
04285 static const yytype_uint16 yystos[] =
04286 {
04287 0, 145, 146, 0, 1, 3, 4, 5, 6, 7,
04288 11, 12, 16, 18, 19, 20, 21, 22, 23, 24,
04289 30, 31, 32, 33, 34, 35, 36, 39, 45, 46,
04290 47, 48, 49, 50, 51, 52, 53, 54, 55, 56,
04291 57, 59, 60, 61, 62, 64, 65, 66, 68, 69,
04292 88, 91, 92, 94, 95, 97, 100, 101, 102, 103,
04293 104, 105, 106, 107, 108, 128, 129, 130, 147, 148,
04294 149, 156, 158, 159, 161, 162, 165, 166, 167, 169,
04295 170, 171, 173, 174, 184, 199, 218, 219, 220, 221,
04296 222, 223, 224, 225, 226, 227, 228, 254, 255, 269,
04297 270, 271, 272, 273, 274, 275, 278, 280, 281, 293,
04298 295, 296, 297, 298, 299, 300, 301, 302, 335, 346,
04299 149, 3, 4, 5, 6, 7, 8, 9, 10, 11,
04300 12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
04301 22, 23, 24, 25, 26, 30, 31, 32, 33, 34,
04302 35, 36, 37, 38, 39, 45, 46, 47, 48, 49,
04303 50, 51, 52, 53, 56, 68, 69, 70, 71, 72,
04304 73, 74, 75, 76, 79, 80, 83, 84, 85, 86,
04305 97, 98, 118, 119, 120, 121, 122, 123, 124, 125,
04306 126, 127, 129, 130, 137, 177, 178, 179, 180, 182,
04307 183, 293, 295, 39, 58, 88, 91, 97, 98, 99,
04308 129, 166, 174, 184, 186, 191, 194, 196, 218, 298,
04309 299, 301, 302, 333, 334, 191, 191, 138, 192, 193,
04310 138, 188, 192, 138, 143, 340, 54, 179, 340, 150,
04311 132, 21, 22, 30, 31, 32, 165, 184, 218, 184,
04312 56, 1, 47, 91, 152, 153, 154, 156, 168, 169,
04313 346, 201, 202, 187, 196, 333, 346, 186, 332, 333,
04314 346, 46, 88, 128, 136, 173, 199, 218, 298, 299,
04315 302, 246, 247, 54, 55, 57, 177, 285, 294, 284,
04316 285, 286, 142, 276, 142, 282, 142, 279, 142, 283,
04317 297, 161, 184, 184, 141, 143, 339, 344, 345, 40,
04318 41, 42, 43, 44, 37, 38, 26, 132, 188, 192,
04319 260, 28, 252, 115, 136, 91, 97, 170, 115, 70,
04320 71, 72, 73, 74, 75, 76, 77, 78, 79, 80,
04321 81, 82, 85, 86, 116, 118, 119, 120, 121, 122,
04322 123, 124, 125, 126, 127, 87, 134, 135, 200, 159,
04323 160, 160, 205, 207, 160, 339, 345, 88, 167, 174,
04324 218, 234, 298, 299, 302, 52, 56, 85, 88, 175,
04325 176, 218, 298, 299, 302, 176, 33, 34, 35, 36,
04326 49, 50, 51, 52, 56, 138, 177, 300, 330, 87,
04327 135, 338, 260, 272, 89, 89, 136, 186, 56, 186,
04328 186, 186, 115, 90, 136, 195, 346, 87, 134, 135,
04329 89, 89, 136, 195, 191, 340, 341, 191, 190, 191,
04330 196, 333, 346, 159, 341, 159, 54, 65, 66, 157,
04331 138, 185, 132, 152, 87, 135, 89, 156, 155, 168,
04332 139, 339, 345, 341, 341, 159, 140, 136, 143, 343,
04333 136, 343, 133, 343, 340, 56, 297, 170, 172, 136,
04334 87, 134, 135, 248, 63, 109, 111, 112, 287, 112,
04335 287, 112, 67, 287, 112, 112, 277, 287, 112, 63,
04336 112, 112, 112, 277, 112, 63, 112, 70, 141, 149,
04337 160, 160, 160, 160, 156, 159, 159, 262, 261, 96,
04338 163, 253, 97, 161, 186, 196, 197, 198, 168, 136,
04339 173, 136, 158, 161, 174, 184, 186, 198, 184, 184,
04340 184, 184, 184, 184, 184, 184, 184, 184, 184, 184,
04341 184, 184, 184, 184, 184, 184, 184, 184, 184, 184,
04342 184, 184, 184, 184, 52, 53, 56, 182, 259, 336,
04343 337, 190, 52, 53, 56, 182, 258, 336, 151, 152,
04344 13, 230, 344, 230, 160, 160, 339, 17, 263, 56,
04345 87, 134, 135, 25, 159, 52, 56, 175, 1, 119,
04346 303, 344, 87, 134, 135, 214, 331, 215, 338, 52,
04347 56, 336, 161, 184, 161, 184, 181, 184, 186, 97,
04348 186, 194, 333, 52, 56, 190, 52, 56, 334, 341,
04349 139, 341, 136, 136, 341, 179, 204, 184, 147, 133,
04350 336, 336, 184, 132, 341, 154, 203, 333, 136, 172,
04351 52, 56, 190, 52, 56, 52, 54, 55, 56, 57,
04352 58, 70, 91, 97, 98, 99, 122, 125, 138, 250,
04353 307, 309, 310, 311, 312, 313, 314, 315, 318, 319,
04354 320, 321, 324, 325, 326, 327, 328, 289, 288, 142,
04355 287, 142, 142, 142, 184, 78, 120, 241, 242, 346,
04356 241, 164, 241, 186, 136, 341, 172, 136, 115, 44,
04357 340, 89, 89, 188, 192, 257, 340, 342, 89, 89,
04358 188, 192, 256, 10, 229, 8, 265, 346, 152, 13,
04359 152, 27, 231, 344, 231, 263, 196, 229, 52, 56,
04360 190, 52, 56, 209, 212, 344, 304, 211, 52, 56,
04361 175, 190, 151, 159, 138, 305, 306, 216, 188, 189,
04362 192, 346, 44, 179, 186, 195, 89, 89, 342, 89,
04363 89, 333, 159, 133, 147, 341, 343, 170, 342, 91,
04364 97, 235, 236, 237, 311, 309, 249, 115, 136, 308,
04365 186, 136, 329, 346, 52, 136, 329, 136, 308, 52,
04366 136, 308, 52, 290, 54, 55, 57, 292, 302, 238,
04367 240, 243, 311, 313, 314, 316, 317, 320, 322, 323,
04368 326, 328, 340, 152, 152, 241, 152, 97, 186, 172,
04369 184, 117, 161, 184, 161, 184, 163, 188, 140, 89,
04370 161, 184, 161, 184, 163, 189, 186, 198, 266, 346,
04371 15, 233, 346, 14, 232, 233, 233, 206, 208, 229,
04372 136, 230, 342, 160, 344, 160, 151, 342, 229, 341,
04373 309, 151, 309, 177, 260, 252, 184, 89, 136, 341,
04374 133, 237, 136, 311, 136, 341, 243, 29, 113, 251,
04375 186, 307, 312, 324, 326, 315, 320, 328, 313, 321,
04376 326, 311, 313, 291, 243, 120, 115, 136, 239, 88,
04377 218, 136, 329, 329, 136, 239, 136, 239, 141, 10,
04378 133, 152, 10, 186, 184, 161, 184, 90, 267, 346,
04379 152, 9, 268, 346, 160, 229, 229, 152, 152, 186,
04380 152, 231, 213, 344, 229, 341, 229, 344, 217, 341,
04381 236, 136, 97, 235, 139, 152, 152, 136, 308, 136,
04382 308, 329, 136, 308, 136, 308, 308, 152, 120, 218,
04383 238, 323, 326, 56, 87, 316, 320, 313, 322, 326,
04384 313, 52, 244, 245, 310, 133, 88, 174, 218, 298,
04385 299, 302, 230, 152, 230, 229, 229, 233, 263, 264,
04386 210, 151, 305, 136, 236, 136, 311, 10, 133, 313,
04387 326, 313, 313, 110, 136, 239, 136, 239, 52, 56,
04388 329, 136, 239, 136, 239, 239, 136, 340, 56, 87,
04389 134, 135, 152, 152, 152, 229, 151, 236, 136, 308,
04390 136, 308, 308, 308, 313, 326, 313, 313, 245, 52,
04391 56, 190, 52, 56, 265, 232, 229, 229, 236, 313,
04392 239, 136, 239, 239, 239, 342, 308, 313, 239
04393 };
04394
04395 #define yyerrok (yyerrstatus = 0)
04396 #define yyclearin (yychar = YYEMPTY)
04397 #define YYEMPTY (-2)
04398 #define YYEOF 0
04399
04400 #define YYACCEPT goto yyacceptlab
04401 #define YYABORT goto yyabortlab
04402 #define YYERROR goto yyerrorlab
04403
04404
04405
04406
04407
04408
04409
04410
04411
04412 #define YYFAIL goto yyerrlab
04413 #if defined YYFAIL
04414
04415
04416
04417
04418 #endif
04419
04420 #define YYRECOVERING() (!!yyerrstatus)
04421
04422 #define YYBACKUP(Token, Value) \
04423 do \
04424 if (yychar == YYEMPTY && yylen == 1) \
04425 { \
04426 yychar = (Token); \
04427 yylval = (Value); \
04428 YYPOPSTACK (1); \
04429 goto yybackup; \
04430 } \
04431 else \
04432 { \
04433 parser_yyerror (parser, YY_("syntax error: cannot back up")); \
04434 YYERROR; \
04435 } \
04436 while (YYID (0))
04437
04438
04439 #define YYTERROR 1
04440 #define YYERRCODE 256
04441
04442
04443
04444
04445
04446
04447 #define YYRHSLOC(Rhs, K) ((Rhs)[K])
04448 #ifndef YYLLOC_DEFAULT
04449 # define YYLLOC_DEFAULT(Current, Rhs, N) \
04450 do \
04451 if (YYID (N)) \
04452 { \
04453 (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \
04454 (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \
04455 (Current).last_line = YYRHSLOC (Rhs, N).last_line; \
04456 (Current).last_column = YYRHSLOC (Rhs, N).last_column; \
04457 } \
04458 else \
04459 { \
04460 (Current).first_line = (Current).last_line = \
04461 YYRHSLOC (Rhs, 0).last_line; \
04462 (Current).first_column = (Current).last_column = \
04463 YYRHSLOC (Rhs, 0).last_column; \
04464 } \
04465 while (YYID (0))
04466 #endif
04467
04468
04469
04470
04471 #ifndef YY_LOCATION_PRINT
04472 # define YY_LOCATION_PRINT(File, Loc) ((void) 0)
04473 #endif
04474
04475
04476
04477
04478 #ifdef YYLEX_PARAM
04479 # define YYLEX yylex (&yylval, YYLEX_PARAM)
04480 #else
04481 # define YYLEX yylex (&yylval, parser)
04482 #endif
04483
04484
04485 #if YYDEBUG
04486
04487 # ifndef YYFPRINTF
04488 # include <stdio.h>
04489 # define YYFPRINTF fprintf
04490 # endif
04491
04492 # define YYDPRINTF(Args) \
04493 do { \
04494 if (yydebug) \
04495 YYFPRINTF Args; \
04496 } while (YYID (0))
04497
04498 # define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
04499 do { \
04500 if (yydebug) \
04501 { \
04502 YYFPRINTF (stderr, "%s ", Title); \
04503 yy_symbol_print (stderr, \
04504 Type, Value, parser); \
04505 YYFPRINTF (stderr, "\n"); \
04506 } \
04507 } while (YYID (0))
04508
04509
04510
04511
04512
04513
04514
04515 #if (defined __STDC__ || defined __C99__FUNC__ \
04516 || defined __cplusplus || defined _MSC_VER)
04517 static void
04518 yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, struct parser_params *parser)
04519 #else
04520 static void
04521 yy_symbol_value_print (yyoutput, yytype, yyvaluep, parser)
04522 FILE *yyoutput;
04523 int yytype;
04524 YYSTYPE const * const yyvaluep;
04525 struct parser_params *parser;
04526 #endif
04527 {
04528 if (!yyvaluep)
04529 return;
04530 YYUSE (parser);
04531 # ifdef YYPRINT
04532 if (yytype < YYNTOKENS)
04533 YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
04534 # else
04535 YYUSE (yyoutput);
04536 # endif
04537 switch (yytype)
04538 {
04539 default:
04540 break;
04541 }
04542 }
04543
04544
04545
04546
04547
04548
04549 #if (defined __STDC__ || defined __C99__FUNC__ \
04550 || defined __cplusplus || defined _MSC_VER)
04551 static void
04552 yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, struct parser_params *parser)
04553 #else
04554 static void
04555 yy_symbol_print (yyoutput, yytype, yyvaluep, parser)
04556 FILE *yyoutput;
04557 int yytype;
04558 YYSTYPE const * const yyvaluep;
04559 struct parser_params *parser;
04560 #endif
04561 {
04562 if (yytype < YYNTOKENS)
04563 YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
04564 else
04565 YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
04566
04567 yy_symbol_value_print (yyoutput, yytype, yyvaluep, parser);
04568 YYFPRINTF (yyoutput, ")");
04569 }
04570
04571
04572
04573
04574
04575
04576 #if (defined __STDC__ || defined __C99__FUNC__ \
04577 || defined __cplusplus || defined _MSC_VER)
04578 static void
04579 yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop)
04580 #else
04581 static void
04582 yy_stack_print (yybottom, yytop)
04583 yytype_int16 *yybottom;
04584 yytype_int16 *yytop;
04585 #endif
04586 {
04587 YYFPRINTF (stderr, "Stack now");
04588 for (; yybottom <= yytop; yybottom++)
04589 {
04590 int yybot = *yybottom;
04591 YYFPRINTF (stderr, " %d", yybot);
04592 }
04593 YYFPRINTF (stderr, "\n");
04594 }
04595
04596 # define YY_STACK_PRINT(Bottom, Top) \
04597 do { \
04598 if (yydebug) \
04599 yy_stack_print ((Bottom), (Top)); \
04600 } while (YYID (0))
04601
04602
04603
04604
04605
04606
04607 #if (defined __STDC__ || defined __C99__FUNC__ \
04608 || defined __cplusplus || defined _MSC_VER)
04609 static void
04610 yy_reduce_print (YYSTYPE *yyvsp, int yyrule, struct parser_params *parser)
04611 #else
04612 static void
04613 yy_reduce_print (yyvsp, yyrule, parser)
04614 YYSTYPE *yyvsp;
04615 int yyrule;
04616 struct parser_params *parser;
04617 #endif
04618 {
04619 int yynrhs = yyr2[yyrule];
04620 int yyi;
04621 unsigned long int yylno = yyrline[yyrule];
04622 YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
04623 yyrule - 1, yylno);
04624
04625 for (yyi = 0; yyi < yynrhs; yyi++)
04626 {
04627 YYFPRINTF (stderr, " $%d = ", yyi + 1);
04628 yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi],
04629 &(yyvsp[(yyi + 1) - (yynrhs)])
04630 , parser);
04631 YYFPRINTF (stderr, "\n");
04632 }
04633 }
04634
04635 # define YY_REDUCE_PRINT(Rule) \
04636 do { \
04637 if (yydebug) \
04638 yy_reduce_print (yyvsp, Rule, parser); \
04639 } while (YYID (0))
04640
04641
04642
04643 #ifndef yydebug
04644 int yydebug;
04645 #endif
04646 #else
04647 # define YYDPRINTF(Args)
04648 # define YY_SYMBOL_PRINT(Title, Type, Value, Location)
04649 # define YY_STACK_PRINT(Bottom, Top)
04650 # define YY_REDUCE_PRINT(Rule)
04651 #endif
04652
04653
04654
04655 #ifndef YYINITDEPTH
04656 # define YYINITDEPTH 200
04657 #endif
04658
04659
04660
04661
04662
04663
04664
04665
04666 #ifndef YYMAXDEPTH
04667 # define YYMAXDEPTH 10000
04668 #endif
04669
04670
04671 #if YYERROR_VERBOSE
04672
04673 # ifndef yystrlen
04674 # if defined __GLIBC__ && defined _STRING_H
04675 # define yystrlen strlen
04676 # else
04677
04678 #if (defined __STDC__ || defined __C99__FUNC__ \
04679 || defined __cplusplus || defined _MSC_VER)
04680 static YYSIZE_T
04681 yystrlen (const char *yystr)
04682 #else
04683 static YYSIZE_T
04684 yystrlen (yystr)
04685 const char *yystr;
04686 #endif
04687 {
04688 YYSIZE_T yylen;
04689 for (yylen = 0; yystr[yylen]; yylen++)
04690 continue;
04691 return yylen;
04692 }
04693 # endif
04694 # endif
04695
04696 # ifndef yystpcpy
04697 # if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
04698 # define yystpcpy stpcpy
04699 # else
04700
04701
04702 #if (defined __STDC__ || defined __C99__FUNC__ \
04703 || defined __cplusplus || defined _MSC_VER)
04704 static char *
04705 yystpcpy (char *yydest, const char *yysrc)
04706 #else
04707 static char *
04708 yystpcpy (yydest, yysrc)
04709 char *yydest;
04710 const char *yysrc;
04711 #endif
04712 {
04713 char *yyd = yydest;
04714 const char *yys = yysrc;
04715
04716 while ((*yyd++ = *yys++) != '\0')
04717 continue;
04718
04719 return yyd - 1;
04720 }
04721 # endif
04722 # endif
04723
04724 # ifndef yytnamerr
04725
04726
04727
04728
04729
04730
04731
04732 static YYSIZE_T
04733 yytnamerr (char *yyres, const char *yystr)
04734 {
04735 if (*yystr == '"')
04736 {
04737 YYSIZE_T yyn = 0;
04738 char const *yyp = yystr;
04739
04740 for (;;)
04741 switch (*++yyp)
04742 {
04743 case '\'':
04744 case ',':
04745 goto do_not_strip_quotes;
04746
04747 case '\\':
04748 if (*++yyp != '\\')
04749 goto do_not_strip_quotes;
04750
04751 default:
04752 if (yyres)
04753 yyres[yyn] = *yyp;
04754 yyn++;
04755 break;
04756
04757 case '"':
04758 if (yyres)
04759 yyres[yyn] = '\0';
04760 return yyn;
04761 }
04762 do_not_strip_quotes: ;
04763 }
04764
04765 if (! yyres)
04766 return yystrlen (yystr);
04767
04768 return yystpcpy (yyres, yystr) - yyres;
04769 }
04770 # endif
04771
04772
04773
04774
04775
04776
04777
04778
04779
04780 static int
04781 yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
04782 yytype_int16 *yyssp, int yytoken)
04783 {
04784 YYSIZE_T yysize0 = yytnamerr (0, yytname[yytoken]);
04785 YYSIZE_T yysize = yysize0;
04786 YYSIZE_T yysize1;
04787 enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
04788
04789 const char *yyformat = 0;
04790
04791 char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
04792
04793
04794 int yycount = 0;
04795
04796
04797
04798
04799
04800
04801
04802
04803
04804
04805
04806
04807
04808
04809
04810
04811
04812
04813
04814
04815
04816
04817
04818
04819
04820
04821
04822
04823 if (yytoken != YYEMPTY)
04824 {
04825 int yyn = yypact[*yyssp];
04826 yyarg[yycount++] = yytname[yytoken];
04827 if (!yypact_value_is_default (yyn))
04828 {
04829
04830
04831
04832 int yyxbegin = yyn < 0 ? -yyn : 0;
04833
04834 int yychecklim = YYLAST - yyn + 1;
04835 int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
04836 int yyx;
04837
04838 for (yyx = yyxbegin; yyx < yyxend; ++yyx)
04839 if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR
04840 && !yytable_value_is_error (yytable[yyx + yyn]))
04841 {
04842 if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
04843 {
04844 yycount = 1;
04845 yysize = yysize0;
04846 break;
04847 }
04848 yyarg[yycount++] = yytname[yyx];
04849 yysize1 = yysize + yytnamerr (0, yytname[yyx]);
04850 if (! (yysize <= yysize1
04851 && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
04852 return 2;
04853 yysize = yysize1;
04854 }
04855 }
04856 }
04857
04858 switch (yycount)
04859 {
04860 # define YYCASE_(N, S) \
04861 case N: \
04862 yyformat = S; \
04863 break
04864 YYCASE_(0, YY_("syntax error"));
04865 YYCASE_(1, YY_("syntax error, unexpected %s"));
04866 YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s"));
04867 YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s"));
04868 YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s"));
04869 YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"));
04870 # undef YYCASE_
04871 }
04872
04873 yysize1 = yysize + yystrlen (yyformat);
04874 if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
04875 return 2;
04876 yysize = yysize1;
04877
04878 if (*yymsg_alloc < yysize)
04879 {
04880 *yymsg_alloc = 2 * yysize;
04881 if (! (yysize <= *yymsg_alloc
04882 && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM))
04883 *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM;
04884 return 1;
04885 }
04886
04887
04888
04889
04890 {
04891 char *yyp = *yymsg;
04892 int yyi = 0;
04893 while ((*yyp = *yyformat) != '\0')
04894 if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount)
04895 {
04896 yyp += yytnamerr (yyp, yyarg[yyi++]);
04897 yyformat += 2;
04898 }
04899 else
04900 {
04901 yyp++;
04902 yyformat++;
04903 }
04904 }
04905 return 0;
04906 }
04907 #endif
04908
04909
04910
04911
04912
04913
04914 #if (defined __STDC__ || defined __C99__FUNC__ \
04915 || defined __cplusplus || defined _MSC_VER)
04916 static void
04917 yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, struct parser_params *parser)
04918 #else
04919 static void
04920 yydestruct (yymsg, yytype, yyvaluep, parser)
04921 const char *yymsg;
04922 int yytype;
04923 YYSTYPE *yyvaluep;
04924 struct parser_params *parser;
04925 #endif
04926 {
04927 YYUSE (yyvaluep);
04928 YYUSE (parser);
04929
04930 if (!yymsg)
04931 yymsg = "Deleting";
04932 YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
04933
04934 switch (yytype)
04935 {
04936
04937 default:
04938 break;
04939 }
04940 }
04941
04942
04943
04944 #ifdef YYPARSE_PARAM
04945 #if defined __STDC__ || defined __cplusplus
04946 int yyparse (void *YYPARSE_PARAM);
04947 #else
04948 int yyparse ();
04949 #endif
04950 #else
04951 #if defined __STDC__ || defined __cplusplus
04952 int yyparse (struct parser_params *parser);
04953 #else
04954 int yyparse ();
04955 #endif
04956 #endif
04957
04958
04959
04960
04961
04962
04963 #ifdef YYPARSE_PARAM
04964 #if (defined __STDC__ || defined __C99__FUNC__ \
04965 || defined __cplusplus || defined _MSC_VER)
04966 int
04967 yyparse (void *YYPARSE_PARAM)
04968 #else
04969 int
04970 yyparse (YYPARSE_PARAM)
04971 void *YYPARSE_PARAM;
04972 #endif
04973 #else
04974 #if (defined __STDC__ || defined __C99__FUNC__ \
04975 || defined __cplusplus || defined _MSC_VER)
04976 int
04977 yyparse (struct parser_params *parser)
04978 #else
04979 int
04980 yyparse (parser)
04981 struct parser_params *parser;
04982 #endif
04983 #endif
04984 {
04985
04986 int yychar;
04987
04988
04989 YYSTYPE yylval;
04990
04991
04992 int yynerrs;
04993
04994 int yystate;
04995
04996 int yyerrstatus;
04997
04998
04999
05000
05001
05002
05003
05004
05005
05006 yytype_int16 yyssa[YYINITDEPTH];
05007 yytype_int16 *yyss;
05008 yytype_int16 *yyssp;
05009
05010
05011 YYSTYPE yyvsa[YYINITDEPTH];
05012 YYSTYPE *yyvs;
05013 YYSTYPE *yyvsp;
05014
05015 YYSIZE_T yystacksize;
05016
05017 int yyn;
05018 int yyresult;
05019
05020 int yytoken;
05021
05022
05023 YYSTYPE yyval;
05024
05025 #if YYERROR_VERBOSE
05026
05027 char yymsgbuf[128];
05028 char *yymsg = yymsgbuf;
05029 YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
05030 #endif
05031
05032 #define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N))
05033
05034
05035
05036 int yylen = 0;
05037
05038 yytoken = 0;
05039 yyss = yyssa;
05040 yyvs = yyvsa;
05041 yystacksize = YYINITDEPTH;
05042
05043 YYDPRINTF ((stderr, "Starting parse\n"));
05044
05045 yystate = 0;
05046 yyerrstatus = 0;
05047 yynerrs = 0;
05048 yychar = YYEMPTY;
05049
05050
05051
05052
05053
05054 yyssp = yyss;
05055 yyvsp = yyvs;
05056
05057 goto yysetstate;
05058
05059
05060
05061
05062 yynewstate:
05063
05064
05065 yyssp++;
05066
05067 yysetstate:
05068 *yyssp = yystate;
05069
05070 if (yyss + yystacksize - 1 <= yyssp)
05071 {
05072
05073 YYSIZE_T yysize = yyssp - yyss + 1;
05074
05075 #ifdef yyoverflow
05076 {
05077
05078
05079
05080 YYSTYPE *yyvs1 = yyvs;
05081 yytype_int16 *yyss1 = yyss;
05082
05083
05084
05085
05086
05087 yyoverflow (YY_("memory exhausted"),
05088 &yyss1, yysize * sizeof (*yyssp),
05089 &yyvs1, yysize * sizeof (*yyvsp),
05090 &yystacksize);
05091
05092 yyss = yyss1;
05093 yyvs = yyvs1;
05094 }
05095 #else
05096 # ifndef YYSTACK_RELOCATE
05097 goto yyexhaustedlab;
05098 # else
05099
05100 if (YYMAXDEPTH <= yystacksize)
05101 goto yyexhaustedlab;
05102 yystacksize *= 2;
05103 if (YYMAXDEPTH < yystacksize)
05104 yystacksize = YYMAXDEPTH;
05105
05106 {
05107 yytype_int16 *yyss1 = yyss;
05108 union yyalloc *yyptr =
05109 (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
05110 if (! yyptr)
05111 goto yyexhaustedlab;
05112 YYSTACK_RELOCATE (yyss_alloc, yyss);
05113 YYSTACK_RELOCATE (yyvs_alloc, yyvs);
05114 # undef YYSTACK_RELOCATE
05115 if (yyss1 != yyssa)
05116 YYSTACK_FREE (yyss1);
05117 }
05118 # endif
05119 #endif
05120
05121 yyssp = yyss + yysize - 1;
05122 yyvsp = yyvs + yysize - 1;
05123
05124 YYDPRINTF ((stderr, "Stack size increased to %lu\n",
05125 (unsigned long int) yystacksize));
05126
05127 if (yyss + yystacksize - 1 <= yyssp)
05128 YYABORT;
05129 }
05130
05131 YYDPRINTF ((stderr, "Entering state %d\n", yystate));
05132
05133 if (yystate == YYFINAL)
05134 YYACCEPT;
05135
05136 goto yybackup;
05137
05138
05139
05140
05141 yybackup:
05142
05143
05144
05145
05146
05147 yyn = yypact[yystate];
05148 if (yypact_value_is_default (yyn))
05149 goto yydefault;
05150
05151
05152
05153
05154 if (yychar == YYEMPTY)
05155 {
05156 YYDPRINTF ((stderr, "Reading a token: "));
05157 yychar = YYLEX;
05158 }
05159
05160 if (yychar <= YYEOF)
05161 {
05162 yychar = yytoken = YYEOF;
05163 YYDPRINTF ((stderr, "Now at end of input.\n"));
05164 }
05165 else
05166 {
05167 yytoken = YYTRANSLATE (yychar);
05168 YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
05169 }
05170
05171
05172
05173 yyn += yytoken;
05174 if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
05175 goto yydefault;
05176 yyn = yytable[yyn];
05177 if (yyn <= 0)
05178 {
05179 if (yytable_value_is_error (yyn))
05180 goto yyerrlab;
05181 yyn = -yyn;
05182 goto yyreduce;
05183 }
05184
05185
05186
05187 if (yyerrstatus)
05188 yyerrstatus--;
05189
05190
05191 YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
05192
05193
05194 yychar = YYEMPTY;
05195
05196 yystate = yyn;
05197 *++yyvsp = yylval;
05198
05199 goto yynewstate;
05200
05201
05202
05203
05204
05205 yydefault:
05206 yyn = yydefact[yystate];
05207 if (yyn == 0)
05208 goto yyerrlab;
05209 goto yyreduce;
05210
05211
05212
05213
05214
05215 yyreduce:
05216
05217 yylen = yyr2[yyn];
05218
05219
05220
05221
05222
05223
05224
05225
05226
05227 yyval = yyvsp[1-yylen];
05228
05229
05230 YY_REDUCE_PRINT (yyn);
05231 switch (yyn)
05232 {
05233 case 2:
05234
05235
05236 #line 863 "ripper.y"
05237 {
05238 lex_state = EXPR_BEG;
05239 #if 0
05240 local_push(compile_for_eval || rb_parse_in_main());
05241 #endif
05242 local_push(0);
05243
05244 }
05245 break;
05246
05247 case 3:
05248
05249
05250 #line 872 "ripper.y"
05251 {
05252 #if 0
05253 if ((yyvsp[(2) - (2)].val) && !compile_for_eval) {
05254
05255 if (nd_type((yyvsp[(2) - (2)].val)) != NODE_BLOCK) void_expr((yyvsp[(2) - (2)].val));
05256 else {
05257 NODE *node = (yyvsp[(2) - (2)].val);
05258 while (node->nd_next) {
05259 node = node->nd_next;
05260 }
05261 void_expr(node->nd_head);
05262 }
05263 }
05264 ruby_eval_tree = NEW_SCOPE(0, block_append(ruby_eval_tree, (yyvsp[(2) - (2)].val)));
05265 #endif
05266 (yyval.val) = (yyvsp[(2) - (2)].val);
05267 parser->result = dispatch1(program, (yyval.val));
05268
05269 local_pop();
05270 }
05271 break;
05272
05273 case 4:
05274
05275
05276 #line 895 "ripper.y"
05277 {
05278 #if 0
05279 void_stmts((yyvsp[(1) - (2)].val));
05280 fixup_nodes(&deferred_nodes);
05281 #endif
05282
05283 (yyval.val) = (yyvsp[(1) - (2)].val);
05284 }
05285 break;
05286
05287 case 5:
05288
05289
05290 #line 906 "ripper.y"
05291 {
05292 #if 0
05293 (yyval.val) = NEW_BEGIN(0);
05294 #endif
05295 (yyval.val) = dispatch2(stmts_add, dispatch0(stmts_new),
05296 dispatch0(void_stmt));
05297
05298 }
05299 break;
05300
05301 case 6:
05302
05303
05304 #line 915 "ripper.y"
05305 {
05306 #if 0
05307 (yyval.val) = newline_node((yyvsp[(1) - (1)].val));
05308 #endif
05309 (yyval.val) = dispatch2(stmts_add, dispatch0(stmts_new), (yyvsp[(1) - (1)].val));
05310
05311 }
05312 break;
05313
05314 case 7:
05315
05316
05317 #line 923 "ripper.y"
05318 {
05319 #if 0
05320 (yyval.val) = block_append((yyvsp[(1) - (3)].val), newline_node((yyvsp[(3) - (3)].val)));
05321 #endif
05322 (yyval.val) = dispatch2(stmts_add, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05323
05324 }
05325 break;
05326
05327 case 8:
05328
05329
05330 #line 931 "ripper.y"
05331 {
05332 (yyval.val) = remove_begin((yyvsp[(2) - (2)].val));
05333 }
05334 break;
05335
05336 case 10:
05337
05338
05339 #line 938 "ripper.y"
05340 {
05341 #if 0
05342
05343 #endif
05344
05345 }
05346 break;
05347
05348 case 11:
05349
05350
05351 #line 945 "ripper.y"
05352 {
05353 #if 0
05354 ruby_eval_tree_begin = block_append(ruby_eval_tree_begin,
05355 (yyvsp[(4) - (5)].val));
05356
05357
05358 (yyval.val) = NEW_BEGIN(0);
05359 #endif
05360 (yyval.val) = dispatch1(BEGIN, (yyvsp[(4) - (5)].val));
05361
05362 }
05363 break;
05364
05365 case 12:
05366
05367
05368 #line 962 "ripper.y"
05369 {
05370 #if 0
05371 (yyval.val) = (yyvsp[(1) - (4)].val);
05372 if ((yyvsp[(2) - (4)].val)) {
05373 (yyval.val) = NEW_RESCUE((yyvsp[(1) - (4)].val), (yyvsp[(2) - (4)].val), (yyvsp[(3) - (4)].val));
05374 }
05375 else if ((yyvsp[(3) - (4)].val)) {
05376 rb_warn0("else without rescue is useless");
05377 (yyval.val) = block_append((yyval.val), (yyvsp[(3) - (4)].val));
05378 }
05379 if ((yyvsp[(4) - (4)].val)) {
05380 if ((yyval.val)) {
05381 (yyval.val) = NEW_ENSURE((yyval.val), (yyvsp[(4) - (4)].val));
05382 }
05383 else {
05384 (yyval.val) = block_append((yyvsp[(4) - (4)].val), NEW_NIL());
05385 }
05386 }
05387 fixpos((yyval.val), (yyvsp[(1) - (4)].val));
05388 #endif
05389 (yyval.val) = dispatch4(bodystmt,
05390 escape_Qundef((yyvsp[(1) - (4)].val)),
05391 escape_Qundef((yyvsp[(2) - (4)].val)),
05392 escape_Qundef((yyvsp[(3) - (4)].val)),
05393 escape_Qundef((yyvsp[(4) - (4)].val)));
05394
05395 }
05396 break;
05397
05398 case 13:
05399
05400
05401 #line 992 "ripper.y"
05402 {
05403 #if 0
05404 void_stmts((yyvsp[(1) - (2)].val));
05405 fixup_nodes(&deferred_nodes);
05406 #endif
05407
05408 (yyval.val) = (yyvsp[(1) - (2)].val);
05409 }
05410 break;
05411
05412 case 14:
05413
05414
05415 #line 1003 "ripper.y"
05416 {
05417 #if 0
05418 (yyval.val) = NEW_BEGIN(0);
05419 #endif
05420 (yyval.val) = dispatch2(stmts_add, dispatch0(stmts_new),
05421 dispatch0(void_stmt));
05422
05423 }
05424 break;
05425
05426 case 15:
05427
05428
05429 #line 1012 "ripper.y"
05430 {
05431 #if 0
05432 (yyval.val) = newline_node((yyvsp[(1) - (1)].val));
05433 #endif
05434 (yyval.val) = dispatch2(stmts_add, dispatch0(stmts_new), (yyvsp[(1) - (1)].val));
05435
05436 }
05437 break;
05438
05439 case 16:
05440
05441
05442 #line 1020 "ripper.y"
05443 {
05444 #if 0
05445 (yyval.val) = block_append((yyvsp[(1) - (3)].val), newline_node((yyvsp[(3) - (3)].val)));
05446 #endif
05447 (yyval.val) = dispatch2(stmts_add, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05448
05449 }
05450 break;
05451
05452 case 17:
05453
05454
05455 #line 1028 "ripper.y"
05456 {
05457 (yyval.val) = remove_begin((yyvsp[(2) - (2)].val));
05458 }
05459 break;
05460
05461 case 18:
05462
05463
05464 #line 1034 "ripper.y"
05465 {
05466 (yyval.val) = (yyvsp[(1) - (1)].val);
05467 }
05468 break;
05469
05470 case 19:
05471
05472
05473 #line 1038 "ripper.y"
05474 {
05475 yyerror("BEGIN is permitted only at toplevel");
05476 #if 0
05477
05478 #endif
05479
05480 }
05481 break;
05482
05483 case 20:
05484
05485
05486 #line 1046 "ripper.y"
05487 {
05488 #if 0
05489 ruby_eval_tree_begin = block_append(ruby_eval_tree_begin,
05490 (yyvsp[(4) - (5)].val));
05491
05492
05493 (yyval.val) = NEW_BEGIN(0);
05494 #endif
05495 (yyval.val) = dispatch1(BEGIN, (yyvsp[(4) - (5)].val));
05496
05497 }
05498 break;
05499
05500 case 21:
05501
05502
05503 #line 1058 "ripper.y"
05504 {lex_state = EXPR_FNAME;}
05505 break;
05506
05507 case 22:
05508
05509
05510 #line 1059 "ripper.y"
05511 {
05512 #if 0
05513 (yyval.val) = NEW_ALIAS((yyvsp[(2) - (4)].val), (yyvsp[(4) - (4)].val));
05514 #endif
05515 (yyval.val) = dispatch2(alias, (yyvsp[(2) - (4)].val), (yyvsp[(4) - (4)].val));
05516
05517 }
05518 break;
05519
05520 case 23:
05521
05522
05523 #line 1067 "ripper.y"
05524 {
05525 #if 0
05526 (yyval.val) = NEW_VALIAS((yyvsp[(2) - (3)].val), (yyvsp[(3) - (3)].val));
05527 #endif
05528 (yyval.val) = dispatch2(var_alias, (yyvsp[(2) - (3)].val), (yyvsp[(3) - (3)].val));
05529
05530 }
05531 break;
05532
05533 case 24:
05534
05535
05536 #line 1075 "ripper.y"
05537 {
05538 #if 0
05539 char buf[2];
05540 buf[0] = '$';
05541 buf[1] = (char)(yyvsp[(3) - (3)].val)->nd_nth;
05542 (yyval.val) = NEW_VALIAS((yyvsp[(2) - (3)].val), rb_intern2(buf, 2));
05543 #endif
05544 (yyval.val) = dispatch2(var_alias, (yyvsp[(2) - (3)].val), (yyvsp[(3) - (3)].val));
05545
05546 }
05547 break;
05548
05549 case 25:
05550
05551
05552 #line 1086 "ripper.y"
05553 {
05554 #if 0
05555 yyerror("can't make alias for the number variables");
05556 (yyval.val) = NEW_BEGIN(0);
05557 #endif
05558 (yyval.val) = dispatch2(var_alias, (yyvsp[(2) - (3)].val), (yyvsp[(3) - (3)].val));
05559 (yyval.val) = dispatch1(alias_error, (yyval.val));
05560
05561 }
05562 break;
05563
05564 case 26:
05565
05566
05567 #line 1096 "ripper.y"
05568 {
05569 #if 0
05570 (yyval.val) = (yyvsp[(2) - (2)].val);
05571 #endif
05572 (yyval.val) = dispatch1(undef, (yyvsp[(2) - (2)].val));
05573
05574 }
05575 break;
05576
05577 case 27:
05578
05579
05580 #line 1104 "ripper.y"
05581 {
05582 #if 0
05583 (yyval.val) = NEW_IF(cond((yyvsp[(3) - (3)].val)), remove_begin((yyvsp[(1) - (3)].val)), 0);
05584 fixpos((yyval.val), (yyvsp[(3) - (3)].val));
05585 #endif
05586 (yyval.val) = dispatch2(if_mod, (yyvsp[(3) - (3)].val), (yyvsp[(1) - (3)].val));
05587
05588 }
05589 break;
05590
05591 case 28:
05592
05593
05594 #line 1113 "ripper.y"
05595 {
05596 #if 0
05597 (yyval.val) = NEW_UNLESS(cond((yyvsp[(3) - (3)].val)), remove_begin((yyvsp[(1) - (3)].val)), 0);
05598 fixpos((yyval.val), (yyvsp[(3) - (3)].val));
05599 #endif
05600 (yyval.val) = dispatch2(unless_mod, (yyvsp[(3) - (3)].val), (yyvsp[(1) - (3)].val));
05601
05602 }
05603 break;
05604
05605 case 29:
05606
05607
05608 #line 1122 "ripper.y"
05609 {
05610 #if 0
05611 if ((yyvsp[(1) - (3)].val) && nd_type((yyvsp[(1) - (3)].val)) == NODE_BEGIN) {
05612 (yyval.val) = NEW_WHILE(cond((yyvsp[(3) - (3)].val)), (yyvsp[(1) - (3)].val)->nd_body, 0);
05613 }
05614 else {
05615 (yyval.val) = NEW_WHILE(cond((yyvsp[(3) - (3)].val)), (yyvsp[(1) - (3)].val), 1);
05616 }
05617 #endif
05618 (yyval.val) = dispatch2(while_mod, (yyvsp[(3) - (3)].val), (yyvsp[(1) - (3)].val));
05619
05620 }
05621 break;
05622
05623 case 30:
05624
05625
05626 #line 1135 "ripper.y"
05627 {
05628 #if 0
05629 if ((yyvsp[(1) - (3)].val) && nd_type((yyvsp[(1) - (3)].val)) == NODE_BEGIN) {
05630 (yyval.val) = NEW_UNTIL(cond((yyvsp[(3) - (3)].val)), (yyvsp[(1) - (3)].val)->nd_body, 0);
05631 }
05632 else {
05633 (yyval.val) = NEW_UNTIL(cond((yyvsp[(3) - (3)].val)), (yyvsp[(1) - (3)].val), 1);
05634 }
05635 #endif
05636 (yyval.val) = dispatch2(until_mod, (yyvsp[(3) - (3)].val), (yyvsp[(1) - (3)].val));
05637
05638 }
05639 break;
05640
05641 case 31:
05642
05643
05644 #line 1148 "ripper.y"
05645 {
05646 #if 0
05647 NODE *resq = NEW_RESBODY(0, remove_begin((yyvsp[(3) - (3)].val)), 0);
05648 (yyval.val) = NEW_RESCUE(remove_begin((yyvsp[(1) - (3)].val)), resq, 0);
05649 #endif
05650 (yyval.val) = dispatch2(rescue_mod, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05651
05652 }
05653 break;
05654
05655 case 32:
05656
05657
05658 #line 1157 "ripper.y"
05659 {
05660 if (in_def || in_single) {
05661 rb_warn0("END in method; use at_exit");
05662 }
05663 #if 0
05664 (yyval.val) = NEW_POSTEXE(NEW_NODE(
05665 NODE_SCOPE, 0 , (yyvsp[(3) - (4)].val) , 0 ));
05666 #endif
05667 (yyval.val) = dispatch1(END, (yyvsp[(3) - (4)].val));
05668
05669 }
05670 break;
05671
05672 case 34:
05673
05674
05675 #line 1170 "ripper.y"
05676 {
05677 #if 0
05678 value_expr((yyvsp[(3) - (3)].val));
05679 (yyvsp[(1) - (3)].val)->nd_value = (yyvsp[(3) - (3)].val);
05680 (yyval.val) = (yyvsp[(1) - (3)].val);
05681 #endif
05682 (yyval.val) = dispatch2(massign, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05683
05684 }
05685 break;
05686
05687 case 35:
05688
05689
05690 #line 1180 "ripper.y"
05691 {
05692 value_expr((yyvsp[(3) - (3)].val));
05693 (yyval.val) = new_op_assign((yyvsp[(1) - (3)].val), (yyvsp[(2) - (3)].val), (yyvsp[(3) - (3)].val));
05694 }
05695 break;
05696
05697 case 36:
05698
05699
05700 #line 1185 "ripper.y"
05701 {
05702 #if 0
05703 NODE *args;
05704
05705 value_expr((yyvsp[(6) - (6)].val));
05706 if (!(yyvsp[(3) - (6)].val)) (yyvsp[(3) - (6)].val) = NEW_ZARRAY();
05707 args = arg_concat((yyvsp[(3) - (6)].val), (yyvsp[(6) - (6)].val));
05708 if ((yyvsp[(5) - (6)].val) == tOROP) {
05709 (yyvsp[(5) - (6)].val) = 0;
05710 }
05711 else if ((yyvsp[(5) - (6)].val) == tANDOP) {
05712 (yyvsp[(5) - (6)].val) = 1;
05713 }
05714 (yyval.val) = NEW_OP_ASGN1((yyvsp[(1) - (6)].val), (yyvsp[(5) - (6)].val), args);
05715 fixpos((yyval.val), (yyvsp[(1) - (6)].val));
05716 #endif
05717 (yyval.val) = dispatch2(aref_field, (yyvsp[(1) - (6)].val), escape_Qundef((yyvsp[(3) - (6)].val)));
05718 (yyval.val) = dispatch3(opassign, (yyval.val), (yyvsp[(5) - (6)].val), (yyvsp[(6) - (6)].val));
05719
05720 }
05721 break;
05722
05723 case 37:
05724
05725
05726 #line 1206 "ripper.y"
05727 {
05728 value_expr((yyvsp[(5) - (5)].val));
05729 (yyval.val) = new_attr_op_assign((yyvsp[(1) - (5)].val), ripper_id2sym('.'), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
05730 }
05731 break;
05732
05733 case 38:
05734
05735
05736 #line 1211 "ripper.y"
05737 {
05738 value_expr((yyvsp[(5) - (5)].val));
05739 (yyval.val) = new_attr_op_assign((yyvsp[(1) - (5)].val), ripper_id2sym('.'), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
05740 }
05741 break;
05742
05743 case 39:
05744
05745
05746 #line 1216 "ripper.y"
05747 {
05748 #if 0
05749 (yyval.val) = NEW_COLON2((yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val));
05750 (yyval.val) = new_const_op_assign((yyval.val), (yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
05751 #endif
05752 (yyval.val) = dispatch2(const_path_field, (yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val));
05753 (yyval.val) = dispatch3(opassign, (yyval.val), (yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
05754
05755 }
05756 break;
05757
05758 case 40:
05759
05760
05761 #line 1226 "ripper.y"
05762 {
05763 value_expr((yyvsp[(5) - (5)].val));
05764 (yyval.val) = new_attr_op_assign((yyvsp[(1) - (5)].val), ripper_intern("::"), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
05765 }
05766 break;
05767
05768 case 41:
05769
05770
05771 #line 1231 "ripper.y"
05772 {
05773 #if 0
05774 rb_backref_error((yyvsp[(1) - (3)].val));
05775 (yyval.val) = NEW_BEGIN(0);
05776 #endif
05777 (yyval.val) = dispatch2(assign, dispatch1(var_field, (yyvsp[(1) - (3)].val)), (yyvsp[(3) - (3)].val));
05778 (yyval.val) = dispatch1(assign_error, (yyval.val));
05779
05780 }
05781 break;
05782
05783 case 42:
05784
05785
05786 #line 1241 "ripper.y"
05787 {
05788 #if 0
05789 value_expr((yyvsp[(3) - (3)].val));
05790 (yyval.val) = node_assign((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05791 #endif
05792 (yyval.val) = dispatch2(assign, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05793
05794 }
05795 break;
05796
05797 case 43:
05798
05799
05800 #line 1250 "ripper.y"
05801 {
05802 #if 0
05803 (yyvsp[(1) - (3)].val)->nd_value = (yyvsp[(3) - (3)].val);
05804 (yyval.val) = (yyvsp[(1) - (3)].val);
05805 #endif
05806 (yyval.val) = dispatch2(massign, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05807
05808 }
05809 break;
05810
05811 case 45:
05812
05813
05814 #line 1262 "ripper.y"
05815 {
05816 #if 0
05817 value_expr((yyvsp[(3) - (3)].val));
05818 (yyval.val) = node_assign((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05819 #endif
05820 (yyval.val) = dispatch2(assign, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05821
05822 }
05823 break;
05824
05825 case 46:
05826
05827
05828 #line 1271 "ripper.y"
05829 {
05830 #if 0
05831 value_expr((yyvsp[(3) - (3)].val));
05832 (yyval.val) = node_assign((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05833 #endif
05834 (yyval.val) = dispatch2(assign, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05835
05836 }
05837 break;
05838
05839 case 48:
05840
05841
05842 #line 1284 "ripper.y"
05843 {
05844 #if 0
05845 (yyval.val) = logop(NODE_AND, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05846 #endif
05847 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("and"), (yyvsp[(3) - (3)].val));
05848
05849 }
05850 break;
05851
05852 case 49:
05853
05854
05855 #line 1292 "ripper.y"
05856 {
05857 #if 0
05858 (yyval.val) = logop(NODE_OR, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
05859 #endif
05860 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("or"), (yyvsp[(3) - (3)].val));
05861
05862 }
05863 break;
05864
05865 case 50:
05866
05867
05868 #line 1300 "ripper.y"
05869 {
05870 #if 0
05871 (yyval.val) = call_uni_op(cond((yyvsp[(3) - (3)].val)), '!');
05872 #endif
05873 (yyval.val) = dispatch2(unary, ripper_intern("not"), (yyvsp[(3) - (3)].val));
05874
05875 }
05876 break;
05877
05878 case 51:
05879
05880
05881 #line 1308 "ripper.y"
05882 {
05883 #if 0
05884 (yyval.val) = call_uni_op(cond((yyvsp[(2) - (2)].val)), '!');
05885 #endif
05886 (yyval.val) = dispatch2(unary, ripper_id2sym('!'), (yyvsp[(2) - (2)].val));
05887
05888 }
05889 break;
05890
05891 case 53:
05892
05893
05894 #line 1319 "ripper.y"
05895 {
05896 #if 0
05897 value_expr((yyvsp[(1) - (1)].val));
05898 (yyval.val) = (yyvsp[(1) - (1)].val);
05899 if (!(yyval.val)) (yyval.val) = NEW_NIL();
05900 #endif
05901 (yyval.val) = (yyvsp[(1) - (1)].val);
05902
05903 }
05904 break;
05905
05906 case 57:
05907
05908
05909 #line 1336 "ripper.y"
05910 {
05911 #if 0
05912 (yyval.val) = NEW_CALL((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
05913 #endif
05914 (yyval.val) = dispatch3(call, (yyvsp[(1) - (4)].val), (yyvsp[(2) - (4)].val), (yyvsp[(3) - (4)].val));
05915 (yyval.val) = method_arg((yyval.val), (yyvsp[(4) - (4)].val));
05916
05917 }
05918 break;
05919
05920 case 58:
05921
05922
05923 #line 1347 "ripper.y"
05924 {
05925 (yyvsp[(1) - (1)].vars) = dyna_push();
05926 #if 0
05927 (yyval.num) = ruby_sourceline;
05928 #endif
05929
05930 }
05931 break;
05932
05933 case 59:
05934
05935
05936 #line 1357 "ripper.y"
05937 {
05938 #if 0
05939 (yyval.val) = NEW_ITER((yyvsp[(3) - (5)].val),(yyvsp[(4) - (5)].val));
05940 nd_set_line((yyval.val), (yyvsp[(2) - (5)].num));
05941 #endif
05942 (yyval.val) = dispatch2(brace_block, escape_Qundef((yyvsp[(3) - (5)].val)), (yyvsp[(4) - (5)].val));
05943
05944 dyna_pop((yyvsp[(1) - (5)].vars));
05945 }
05946 break;
05947
05948 case 60:
05949
05950
05951 #line 1369 "ripper.y"
05952 {
05953 #if 0
05954 (yyval.val) = NEW_FCALL((yyvsp[(1) - (1)].val), 0);
05955 nd_set_line((yyval.val), tokline);
05956 #endif
05957
05958 }
05959 break;
05960
05961 case 61:
05962
05963
05964 #line 1379 "ripper.y"
05965 {
05966 #if 0
05967 (yyval.val) = (yyvsp[(1) - (2)].val);
05968 (yyval.val)->nd_args = (yyvsp[(2) - (2)].val);
05969 #endif
05970 (yyval.val) = dispatch2(command, (yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
05971
05972 }
05973 break;
05974
05975 case 62:
05976
05977
05978 #line 1388 "ripper.y"
05979 {
05980 #if 0
05981 block_dup_check((yyvsp[(2) - (3)].val),(yyvsp[(3) - (3)].val));
05982 (yyvsp[(1) - (3)].val)->nd_args = (yyvsp[(2) - (3)].val);
05983 (yyvsp[(3) - (3)].val)->nd_iter = (yyvsp[(1) - (3)].val);
05984 (yyval.val) = (yyvsp[(3) - (3)].val);
05985 fixpos((yyval.val), (yyvsp[(1) - (3)].val));
05986 #endif
05987 (yyval.val) = dispatch2(command, (yyvsp[(1) - (3)].val), (yyvsp[(2) - (3)].val));
05988 (yyval.val) = method_add_block((yyval.val), (yyvsp[(3) - (3)].val));
05989
05990 }
05991 break;
05992
05993 case 63:
05994
05995
05996 #line 1401 "ripper.y"
05997 {
05998 #if 0
05999 (yyval.val) = NEW_CALL((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
06000 fixpos((yyval.val), (yyvsp[(1) - (4)].val));
06001 #endif
06002 (yyval.val) = dispatch4(command_call, (yyvsp[(1) - (4)].val), ripper_id2sym('.'), (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
06003
06004 }
06005 break;
06006
06007 case 64:
06008
06009
06010 #line 1410 "ripper.y"
06011 {
06012 #if 0
06013 block_dup_check((yyvsp[(4) - (5)].val),(yyvsp[(5) - (5)].val));
06014 (yyvsp[(5) - (5)].val)->nd_iter = NEW_CALL((yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val));
06015 (yyval.val) = (yyvsp[(5) - (5)].val);
06016 fixpos((yyval.val), (yyvsp[(1) - (5)].val));
06017 #endif
06018 (yyval.val) = dispatch4(command_call, (yyvsp[(1) - (5)].val), ripper_id2sym('.'), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val));
06019 (yyval.val) = method_add_block((yyval.val), (yyvsp[(5) - (5)].val));
06020
06021 }
06022 break;
06023
06024 case 65:
06025
06026
06027 #line 1422 "ripper.y"
06028 {
06029 #if 0
06030 (yyval.val) = NEW_CALL((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
06031 fixpos((yyval.val), (yyvsp[(1) - (4)].val));
06032 #endif
06033 (yyval.val) = dispatch4(command_call, (yyvsp[(1) - (4)].val), ripper_intern("::"), (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
06034
06035 }
06036 break;
06037
06038 case 66:
06039
06040
06041 #line 1431 "ripper.y"
06042 {
06043 #if 0
06044 block_dup_check((yyvsp[(4) - (5)].val),(yyvsp[(5) - (5)].val));
06045 (yyvsp[(5) - (5)].val)->nd_iter = NEW_CALL((yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val));
06046 (yyval.val) = (yyvsp[(5) - (5)].val);
06047 fixpos((yyval.val), (yyvsp[(1) - (5)].val));
06048 #endif
06049 (yyval.val) = dispatch4(command_call, (yyvsp[(1) - (5)].val), ripper_intern("::"), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val));
06050 (yyval.val) = method_add_block((yyval.val), (yyvsp[(5) - (5)].val));
06051
06052 }
06053 break;
06054
06055 case 67:
06056
06057
06058 #line 1443 "ripper.y"
06059 {
06060 #if 0
06061 (yyval.val) = NEW_SUPER((yyvsp[(2) - (2)].val));
06062 fixpos((yyval.val), (yyvsp[(2) - (2)].val));
06063 #endif
06064 (yyval.val) = dispatch1(super, (yyvsp[(2) - (2)].val));
06065
06066 }
06067 break;
06068
06069 case 68:
06070
06071
06072 #line 1452 "ripper.y"
06073 {
06074 #if 0
06075 (yyval.val) = new_yield((yyvsp[(2) - (2)].val));
06076 fixpos((yyval.val), (yyvsp[(2) - (2)].val));
06077 #endif
06078 (yyval.val) = dispatch1(yield, (yyvsp[(2) - (2)].val));
06079
06080 }
06081 break;
06082
06083 case 69:
06084
06085
06086 #line 1461 "ripper.y"
06087 {
06088 #if 0
06089 (yyval.val) = NEW_RETURN(ret_args((yyvsp[(2) - (2)].val)));
06090 #endif
06091 (yyval.val) = dispatch1(return, (yyvsp[(2) - (2)].val));
06092
06093 }
06094 break;
06095
06096 case 70:
06097
06098
06099 #line 1469 "ripper.y"
06100 {
06101 #if 0
06102 (yyval.val) = NEW_BREAK(ret_args((yyvsp[(2) - (2)].val)));
06103 #endif
06104 (yyval.val) = dispatch1(break, (yyvsp[(2) - (2)].val));
06105
06106 }
06107 break;
06108
06109 case 71:
06110
06111
06112 #line 1477 "ripper.y"
06113 {
06114 #if 0
06115 (yyval.val) = NEW_NEXT(ret_args((yyvsp[(2) - (2)].val)));
06116 #endif
06117 (yyval.val) = dispatch1(next, (yyvsp[(2) - (2)].val));
06118
06119 }
06120 break;
06121
06122 case 73:
06123
06124
06125 #line 1488 "ripper.y"
06126 {
06127 #if 0
06128 (yyval.val) = (yyvsp[(2) - (3)].val);
06129 #endif
06130 (yyval.val) = dispatch1(mlhs_paren, (yyvsp[(2) - (3)].val));
06131
06132 }
06133 break;
06134
06135 case 75:
06136
06137
06138 #line 1499 "ripper.y"
06139 {
06140 #if 0
06141 (yyval.val) = NEW_MASGN(NEW_LIST((yyvsp[(2) - (3)].val)), 0);
06142 #endif
06143 (yyval.val) = dispatch1(mlhs_paren, (yyvsp[(2) - (3)].val));
06144
06145 }
06146 break;
06147
06148 case 76:
06149
06150
06151 #line 1509 "ripper.y"
06152 {
06153 #if 0
06154 (yyval.val) = NEW_MASGN((yyvsp[(1) - (1)].val), 0);
06155 #endif
06156 (yyval.val) = (yyvsp[(1) - (1)].val);
06157
06158 }
06159 break;
06160
06161 case 77:
06162
06163
06164 #line 1517 "ripper.y"
06165 {
06166 #if 0
06167 (yyval.val) = NEW_MASGN(list_append((yyvsp[(1) - (2)].val),(yyvsp[(2) - (2)].val)), 0);
06168 #endif
06169 (yyval.val) = mlhs_add((yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
06170
06171 }
06172 break;
06173
06174 case 78:
06175
06176
06177 #line 1525 "ripper.y"
06178 {
06179 #if 0
06180 (yyval.val) = NEW_MASGN((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06181 #endif
06182 (yyval.val) = mlhs_add_star((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06183
06184 }
06185 break;
06186
06187 case 79:
06188
06189
06190 #line 1533 "ripper.y"
06191 {
06192 #if 0
06193 (yyval.val) = NEW_MASGN((yyvsp[(1) - (5)].val), NEW_POSTARG((yyvsp[(3) - (5)].val),(yyvsp[(5) - (5)].val)));
06194 #endif
06195 (yyvsp[(1) - (5)].val) = mlhs_add_star((yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val));
06196 (yyval.val) = mlhs_add((yyvsp[(1) - (5)].val), (yyvsp[(5) - (5)].val));
06197
06198 }
06199 break;
06200
06201 case 80:
06202
06203
06204 #line 1542 "ripper.y"
06205 {
06206 #if 0
06207 (yyval.val) = NEW_MASGN((yyvsp[(1) - (2)].val), -1);
06208 #endif
06209 (yyval.val) = mlhs_add_star((yyvsp[(1) - (2)].val), Qnil);
06210
06211 }
06212 break;
06213
06214 case 81:
06215
06216
06217 #line 1550 "ripper.y"
06218 {
06219 #if 0
06220 (yyval.val) = NEW_MASGN((yyvsp[(1) - (4)].val), NEW_POSTARG(-1, (yyvsp[(4) - (4)].val)));
06221 #endif
06222 (yyvsp[(1) - (4)].val) = mlhs_add_star((yyvsp[(1) - (4)].val), Qnil);
06223 (yyval.val) = mlhs_add((yyvsp[(1) - (4)].val), (yyvsp[(4) - (4)].val));
06224
06225 }
06226 break;
06227
06228 case 82:
06229
06230
06231 #line 1559 "ripper.y"
06232 {
06233 #if 0
06234 (yyval.val) = NEW_MASGN(0, (yyvsp[(2) - (2)].val));
06235 #endif
06236 (yyval.val) = mlhs_add_star(mlhs_new(), (yyvsp[(2) - (2)].val));
06237
06238 }
06239 break;
06240
06241 case 83:
06242
06243
06244 #line 1567 "ripper.y"
06245 {
06246 #if 0
06247 (yyval.val) = NEW_MASGN(0, NEW_POSTARG((yyvsp[(2) - (4)].val),(yyvsp[(4) - (4)].val)));
06248 #endif
06249 (yyvsp[(2) - (4)].val) = mlhs_add_star(mlhs_new(), (yyvsp[(2) - (4)].val));
06250 (yyval.val) = mlhs_add((yyvsp[(2) - (4)].val), (yyvsp[(4) - (4)].val));
06251
06252 }
06253 break;
06254
06255 case 84:
06256
06257
06258 #line 1576 "ripper.y"
06259 {
06260 #if 0
06261 (yyval.val) = NEW_MASGN(0, -1);
06262 #endif
06263 (yyval.val) = mlhs_add_star(mlhs_new(), Qnil);
06264
06265 }
06266 break;
06267
06268 case 85:
06269
06270
06271 #line 1584 "ripper.y"
06272 {
06273 #if 0
06274 (yyval.val) = NEW_MASGN(0, NEW_POSTARG(-1, (yyvsp[(3) - (3)].val)));
06275 #endif
06276 (yyval.val) = mlhs_add_star(mlhs_new(), Qnil);
06277 (yyval.val) = mlhs_add((yyval.val), (yyvsp[(3) - (3)].val));
06278
06279 }
06280 break;
06281
06282 case 87:
06283
06284
06285 #line 1596 "ripper.y"
06286 {
06287 #if 0
06288 (yyval.val) = (yyvsp[(2) - (3)].val);
06289 #endif
06290 (yyval.val) = dispatch1(mlhs_paren, (yyvsp[(2) - (3)].val));
06291
06292 }
06293 break;
06294
06295 case 88:
06296
06297
06298 #line 1606 "ripper.y"
06299 {
06300 #if 0
06301 (yyval.val) = NEW_LIST((yyvsp[(1) - (2)].val));
06302 #endif
06303 (yyval.val) = mlhs_add(mlhs_new(), (yyvsp[(1) - (2)].val));
06304
06305 }
06306 break;
06307
06308 case 89:
06309
06310
06311 #line 1614 "ripper.y"
06312 {
06313 #if 0
06314 (yyval.val) = list_append((yyvsp[(1) - (3)].val), (yyvsp[(2) - (3)].val));
06315 #endif
06316 (yyval.val) = mlhs_add((yyvsp[(1) - (3)].val), (yyvsp[(2) - (3)].val));
06317
06318 }
06319 break;
06320
06321 case 90:
06322
06323
06324 #line 1624 "ripper.y"
06325 {
06326 #if 0
06327 (yyval.val) = NEW_LIST((yyvsp[(1) - (1)].val));
06328 #endif
06329 (yyval.val) = mlhs_add(mlhs_new(), (yyvsp[(1) - (1)].val));
06330
06331 }
06332 break;
06333
06334 case 91:
06335
06336
06337 #line 1632 "ripper.y"
06338 {
06339 #if 0
06340 (yyval.val) = list_append((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06341 #endif
06342 (yyval.val) = mlhs_add((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06343
06344 }
06345 break;
06346
06347 case 92:
06348
06349
06350 #line 1642 "ripper.y"
06351 {
06352 (yyval.val) = assignable((yyvsp[(1) - (1)].val), 0);
06353 }
06354 break;
06355
06356 case 93:
06357
06358
06359 #line 1646 "ripper.y"
06360 {
06361 (yyval.val) = assignable((yyvsp[(1) - (1)].val), 0);
06362 }
06363 break;
06364
06365 case 94:
06366
06367
06368 #line 1650 "ripper.y"
06369 {
06370 #if 0
06371 (yyval.val) = aryset((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val));
06372 #endif
06373 (yyval.val) = dispatch2(aref_field, (yyvsp[(1) - (4)].val), escape_Qundef((yyvsp[(3) - (4)].val)));
06374
06375 }
06376 break;
06377
06378 case 95:
06379
06380
06381 #line 1658 "ripper.y"
06382 {
06383 #if 0
06384 (yyval.val) = attrset((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06385 #endif
06386 (yyval.val) = dispatch3(field, (yyvsp[(1) - (3)].val), ripper_id2sym('.'), (yyvsp[(3) - (3)].val));
06387
06388 }
06389 break;
06390
06391 case 96:
06392
06393
06394 #line 1666 "ripper.y"
06395 {
06396 #if 0
06397 (yyval.val) = attrset((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06398 #endif
06399 (yyval.val) = dispatch2(const_path_field, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06400
06401 }
06402 break;
06403
06404 case 97:
06405
06406
06407 #line 1674 "ripper.y"
06408 {
06409 #if 0
06410 (yyval.val) = attrset((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06411 #endif
06412 (yyval.val) = dispatch3(field, (yyvsp[(1) - (3)].val), ripper_id2sym('.'), (yyvsp[(3) - (3)].val));
06413
06414 }
06415 break;
06416
06417 case 98:
06418
06419
06420 #line 1682 "ripper.y"
06421 {
06422 #if 0
06423 if (in_def || in_single)
06424 yyerror("dynamic constant assignment");
06425 (yyval.val) = NEW_CDECL(0, 0, NEW_COLON2((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val)));
06426 #endif
06427 if (in_def || in_single)
06428 yyerror("dynamic constant assignment");
06429 (yyval.val) = dispatch2(const_path_field, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06430
06431 }
06432 break;
06433
06434 case 99:
06435
06436
06437 #line 1694 "ripper.y"
06438 {
06439 #if 0
06440 if (in_def || in_single)
06441 yyerror("dynamic constant assignment");
06442 (yyval.val) = NEW_CDECL(0, 0, NEW_COLON3((yyvsp[(2) - (2)].val)));
06443 #endif
06444 (yyval.val) = dispatch1(top_const_field, (yyvsp[(2) - (2)].val));
06445
06446 }
06447 break;
06448
06449 case 100:
06450
06451
06452 #line 1704 "ripper.y"
06453 {
06454 #if 0
06455 rb_backref_error((yyvsp[(1) - (1)].val));
06456 (yyval.val) = NEW_BEGIN(0);
06457 #endif
06458 (yyval.val) = dispatch1(var_field, (yyvsp[(1) - (1)].val));
06459 (yyval.val) = dispatch1(assign_error, (yyval.val));
06460
06461 }
06462 break;
06463
06464 case 101:
06465
06466
06467 #line 1716 "ripper.y"
06468 {
06469 (yyval.val) = assignable((yyvsp[(1) - (1)].val), 0);
06470 #if 0
06471 if (!(yyval.val)) (yyval.val) = NEW_BEGIN(0);
06472 #endif
06473 (yyval.val) = dispatch1(var_field, (yyval.val));
06474
06475 }
06476 break;
06477
06478 case 102:
06479
06480
06481 #line 1725 "ripper.y"
06482 {
06483 (yyval.val) = assignable((yyvsp[(1) - (1)].val), 0);
06484 #if 0
06485 if (!(yyval.val)) (yyval.val) = NEW_BEGIN(0);
06486 #endif
06487 (yyval.val) = dispatch1(var_field, (yyval.val));
06488
06489 }
06490 break;
06491
06492 case 103:
06493
06494
06495 #line 1734 "ripper.y"
06496 {
06497 #if 0
06498 (yyval.val) = aryset((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val));
06499 #endif
06500 (yyval.val) = dispatch2(aref_field, (yyvsp[(1) - (4)].val), escape_Qundef((yyvsp[(3) - (4)].val)));
06501
06502 }
06503 break;
06504
06505 case 104:
06506
06507
06508 #line 1742 "ripper.y"
06509 {
06510 #if 0
06511 (yyval.val) = attrset((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06512 #endif
06513 (yyval.val) = dispatch3(field, (yyvsp[(1) - (3)].val), ripper_id2sym('.'), (yyvsp[(3) - (3)].val));
06514
06515 }
06516 break;
06517
06518 case 105:
06519
06520
06521 #line 1750 "ripper.y"
06522 {
06523 #if 0
06524 (yyval.val) = attrset((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06525 #endif
06526 (yyval.val) = dispatch3(field, (yyvsp[(1) - (3)].val), ripper_intern("::"), (yyvsp[(3) - (3)].val));
06527
06528 }
06529 break;
06530
06531 case 106:
06532
06533
06534 #line 1758 "ripper.y"
06535 {
06536 #if 0
06537 (yyval.val) = attrset((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06538 #endif
06539 (yyval.val) = dispatch3(field, (yyvsp[(1) - (3)].val), ripper_id2sym('.'), (yyvsp[(3) - (3)].val));
06540
06541 }
06542 break;
06543
06544 case 107:
06545
06546
06547 #line 1766 "ripper.y"
06548 {
06549 #if 0
06550 if (in_def || in_single)
06551 yyerror("dynamic constant assignment");
06552 (yyval.val) = NEW_CDECL(0, 0, NEW_COLON2((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val)));
06553 #endif
06554 (yyval.val) = dispatch2(const_path_field, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06555 if (in_def || in_single) {
06556 (yyval.val) = dispatch1(assign_error, (yyval.val));
06557 }
06558
06559 }
06560 break;
06561
06562 case 108:
06563
06564
06565 #line 1779 "ripper.y"
06566 {
06567 #if 0
06568 if (in_def || in_single)
06569 yyerror("dynamic constant assignment");
06570 (yyval.val) = NEW_CDECL(0, 0, NEW_COLON3((yyvsp[(2) - (2)].val)));
06571 #endif
06572 (yyval.val) = dispatch1(top_const_field, (yyvsp[(2) - (2)].val));
06573 if (in_def || in_single) {
06574 (yyval.val) = dispatch1(assign_error, (yyval.val));
06575 }
06576
06577 }
06578 break;
06579
06580 case 109:
06581
06582
06583 #line 1792 "ripper.y"
06584 {
06585 #if 0
06586 rb_backref_error((yyvsp[(1) - (1)].val));
06587 (yyval.val) = NEW_BEGIN(0);
06588 #endif
06589 (yyval.val) = dispatch1(assign_error, (yyvsp[(1) - (1)].val));
06590
06591 }
06592 break;
06593
06594 case 110:
06595
06596
06597 #line 1803 "ripper.y"
06598 {
06599 #if 0
06600 yyerror("class/module name must be CONSTANT");
06601 #endif
06602 (yyval.val) = dispatch1(class_name_error, (yyvsp[(1) - (1)].val));
06603
06604 }
06605 break;
06606
06607 case 112:
06608
06609
06610 #line 1814 "ripper.y"
06611 {
06612 #if 0
06613 (yyval.val) = NEW_COLON3((yyvsp[(2) - (2)].val));
06614 #endif
06615 (yyval.val) = dispatch1(top_const_ref, (yyvsp[(2) - (2)].val));
06616
06617 }
06618 break;
06619
06620 case 113:
06621
06622
06623 #line 1822 "ripper.y"
06624 {
06625 #if 0
06626 (yyval.val) = NEW_COLON2(0, (yyval.val));
06627 #endif
06628 (yyval.val) = dispatch1(const_ref, (yyvsp[(1) - (1)].val));
06629
06630 }
06631 break;
06632
06633 case 114:
06634
06635
06636 #line 1830 "ripper.y"
06637 {
06638 #if 0
06639 (yyval.val) = NEW_COLON2((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06640 #endif
06641 (yyval.val) = dispatch2(const_path_ref, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06642
06643 }
06644 break;
06645
06646 case 118:
06647
06648
06649 #line 1843 "ripper.y"
06650 {
06651 lex_state = EXPR_ENDFN;
06652 (yyval.val) = (yyvsp[(1) - (1)].val);
06653 }
06654 break;
06655
06656 case 119:
06657
06658
06659 #line 1848 "ripper.y"
06660 {
06661 lex_state = EXPR_ENDFN;
06662 #if 0
06663 (yyval.val) = (yyvsp[(1) - (1)].id);
06664 #endif
06665 (yyval.val) = (yyvsp[(1) - (1)].val);
06666
06667 }
06668 break;
06669
06670 case 122:
06671
06672
06673 #line 1863 "ripper.y"
06674 {
06675 #if 0
06676 (yyval.val) = NEW_LIT(ID2SYM((yyvsp[(1) - (1)].val)));
06677 #endif
06678 (yyval.val) = dispatch1(symbol_literal, (yyvsp[(1) - (1)].val));
06679
06680 }
06681 break;
06682
06683 case 124:
06684
06685
06686 #line 1874 "ripper.y"
06687 {
06688 #if 0
06689 (yyval.val) = NEW_UNDEF((yyvsp[(1) - (1)].val));
06690 #endif
06691 (yyval.val) = rb_ary_new3(1, (yyvsp[(1) - (1)].val));
06692
06693 }
06694 break;
06695
06696 case 125:
06697
06698
06699 #line 1881 "ripper.y"
06700 {lex_state = EXPR_FNAME;}
06701 break;
06702
06703 case 126:
06704
06705
06706 #line 1882 "ripper.y"
06707 {
06708 #if 0
06709 (yyval.val) = block_append((yyvsp[(1) - (4)].val), NEW_UNDEF((yyvsp[(4) - (4)].val)));
06710 #endif
06711 rb_ary_push((yyvsp[(1) - (4)].val), (yyvsp[(4) - (4)].val));
06712
06713 }
06714 break;
06715
06716 case 127:
06717
06718
06719 #line 1891 "ripper.y"
06720 { ifndef_ripper((yyval.val) = '|'); }
06721 break;
06722
06723 case 128:
06724
06725
06726 #line 1892 "ripper.y"
06727 { ifndef_ripper((yyval.val) = '^'); }
06728 break;
06729
06730 case 129:
06731
06732
06733 #line 1893 "ripper.y"
06734 { ifndef_ripper((yyval.val) = '&'); }
06735 break;
06736
06737 case 130:
06738
06739
06740 #line 1894 "ripper.y"
06741 { ifndef_ripper((yyval.val) = tCMP); }
06742 break;
06743
06744 case 131:
06745
06746
06747 #line 1895 "ripper.y"
06748 { ifndef_ripper((yyval.val) = tEQ); }
06749 break;
06750
06751 case 132:
06752
06753
06754 #line 1896 "ripper.y"
06755 { ifndef_ripper((yyval.val) = tEQQ); }
06756 break;
06757
06758 case 133:
06759
06760
06761 #line 1897 "ripper.y"
06762 { ifndef_ripper((yyval.val) = tMATCH); }
06763 break;
06764
06765 case 134:
06766
06767
06768 #line 1898 "ripper.y"
06769 { ifndef_ripper((yyval.val) = tNMATCH); }
06770 break;
06771
06772 case 135:
06773
06774
06775 #line 1899 "ripper.y"
06776 { ifndef_ripper((yyval.val) = '>'); }
06777 break;
06778
06779 case 136:
06780
06781
06782 #line 1900 "ripper.y"
06783 { ifndef_ripper((yyval.val) = tGEQ); }
06784 break;
06785
06786 case 137:
06787
06788
06789 #line 1901 "ripper.y"
06790 { ifndef_ripper((yyval.val) = '<'); }
06791 break;
06792
06793 case 138:
06794
06795
06796 #line 1902 "ripper.y"
06797 { ifndef_ripper((yyval.val) = tLEQ); }
06798 break;
06799
06800 case 139:
06801
06802
06803 #line 1903 "ripper.y"
06804 { ifndef_ripper((yyval.val) = tNEQ); }
06805 break;
06806
06807 case 140:
06808
06809
06810 #line 1904 "ripper.y"
06811 { ifndef_ripper((yyval.val) = tLSHFT); }
06812 break;
06813
06814 case 141:
06815
06816
06817 #line 1905 "ripper.y"
06818 { ifndef_ripper((yyval.val) = tRSHFT); }
06819 break;
06820
06821 case 142:
06822
06823
06824 #line 1906 "ripper.y"
06825 { ifndef_ripper((yyval.val) = '+'); }
06826 break;
06827
06828 case 143:
06829
06830
06831 #line 1907 "ripper.y"
06832 { ifndef_ripper((yyval.val) = '-'); }
06833 break;
06834
06835 case 144:
06836
06837
06838 #line 1908 "ripper.y"
06839 { ifndef_ripper((yyval.val) = '*'); }
06840 break;
06841
06842 case 145:
06843
06844
06845 #line 1909 "ripper.y"
06846 { ifndef_ripper((yyval.val) = '*'); }
06847 break;
06848
06849 case 146:
06850
06851
06852 #line 1910 "ripper.y"
06853 { ifndef_ripper((yyval.val) = '/'); }
06854 break;
06855
06856 case 147:
06857
06858
06859 #line 1911 "ripper.y"
06860 { ifndef_ripper((yyval.val) = '%'); }
06861 break;
06862
06863 case 148:
06864
06865
06866 #line 1912 "ripper.y"
06867 { ifndef_ripper((yyval.val) = tPOW); }
06868 break;
06869
06870 case 149:
06871
06872
06873 #line 1913 "ripper.y"
06874 { ifndef_ripper((yyval.val) = tDSTAR); }
06875 break;
06876
06877 case 150:
06878
06879
06880 #line 1914 "ripper.y"
06881 { ifndef_ripper((yyval.val) = '!'); }
06882 break;
06883
06884 case 151:
06885
06886
06887 #line 1915 "ripper.y"
06888 { ifndef_ripper((yyval.val) = '~'); }
06889 break;
06890
06891 case 152:
06892
06893
06894 #line 1916 "ripper.y"
06895 { ifndef_ripper((yyval.val) = tUPLUS); }
06896 break;
06897
06898 case 153:
06899
06900
06901 #line 1917 "ripper.y"
06902 { ifndef_ripper((yyval.val) = tUMINUS); }
06903 break;
06904
06905 case 154:
06906
06907
06908 #line 1918 "ripper.y"
06909 { ifndef_ripper((yyval.val) = tAREF); }
06910 break;
06911
06912 case 155:
06913
06914
06915 #line 1919 "ripper.y"
06916 { ifndef_ripper((yyval.val) = tASET); }
06917 break;
06918
06919 case 156:
06920
06921
06922 #line 1920 "ripper.y"
06923 { ifndef_ripper((yyval.val) = '`'); }
06924 break;
06925
06926 case 198:
06927
06928
06929 #line 1938 "ripper.y"
06930 {
06931 #if 0
06932 value_expr((yyvsp[(3) - (3)].val));
06933 (yyval.val) = node_assign((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06934 #endif
06935 (yyval.val) = dispatch2(assign, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
06936
06937 }
06938 break;
06939
06940 case 199:
06941
06942
06943 #line 1947 "ripper.y"
06944 {
06945 #if 0
06946 value_expr((yyvsp[(3) - (5)].val));
06947 (yyvsp[(3) - (5)].val) = NEW_RESCUE((yyvsp[(3) - (5)].val), NEW_RESBODY(0,(yyvsp[(5) - (5)].val),0), 0);
06948 (yyval.val) = node_assign((yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val));
06949 #endif
06950 (yyval.val) = dispatch2(assign, (yyvsp[(1) - (5)].val), dispatch2(rescue_mod, (yyvsp[(3) - (5)].val), (yyvsp[(5) - (5)].val)));
06951
06952 }
06953 break;
06954
06955 case 200:
06956
06957
06958 #line 1957 "ripper.y"
06959 {
06960 value_expr((yyvsp[(3) - (3)].val));
06961 (yyval.val) = new_op_assign((yyvsp[(1) - (3)].val), (yyvsp[(2) - (3)].val), (yyvsp[(3) - (3)].val));
06962 }
06963 break;
06964
06965 case 201:
06966
06967
06968 #line 1962 "ripper.y"
06969 {
06970 #if 0
06971 value_expr((yyvsp[(3) - (5)].val));
06972 (yyvsp[(3) - (5)].val) = NEW_RESCUE((yyvsp[(3) - (5)].val), NEW_RESBODY(0,(yyvsp[(5) - (5)].val),0), 0);
06973 #endif
06974 (yyvsp[(3) - (5)].val) = dispatch2(rescue_mod, (yyvsp[(3) - (5)].val), (yyvsp[(5) - (5)].val));
06975
06976 (yyval.val) = new_op_assign((yyvsp[(1) - (5)].val), (yyvsp[(2) - (5)].val), (yyvsp[(3) - (5)].val));
06977 }
06978 break;
06979
06980 case 202:
06981
06982
06983 #line 1972 "ripper.y"
06984 {
06985 #if 0
06986 NODE *args;
06987
06988 value_expr((yyvsp[(6) - (6)].val));
06989 if (!(yyvsp[(3) - (6)].val)) (yyvsp[(3) - (6)].val) = NEW_ZARRAY();
06990 if (nd_type((yyvsp[(3) - (6)].val)) == NODE_BLOCK_PASS) {
06991 args = NEW_ARGSCAT((yyvsp[(3) - (6)].val), (yyvsp[(6) - (6)].val));
06992 }
06993 else {
06994 args = arg_concat((yyvsp[(3) - (6)].val), (yyvsp[(6) - (6)].val));
06995 }
06996 if ((yyvsp[(5) - (6)].val) == tOROP) {
06997 (yyvsp[(5) - (6)].val) = 0;
06998 }
06999 else if ((yyvsp[(5) - (6)].val) == tANDOP) {
07000 (yyvsp[(5) - (6)].val) = 1;
07001 }
07002 (yyval.val) = NEW_OP_ASGN1((yyvsp[(1) - (6)].val), (yyvsp[(5) - (6)].val), args);
07003 fixpos((yyval.val), (yyvsp[(1) - (6)].val));
07004 #endif
07005 (yyvsp[(1) - (6)].val) = dispatch2(aref_field, (yyvsp[(1) - (6)].val), escape_Qundef((yyvsp[(3) - (6)].val)));
07006 (yyval.val) = dispatch3(opassign, (yyvsp[(1) - (6)].val), (yyvsp[(5) - (6)].val), (yyvsp[(6) - (6)].val));
07007
07008 }
07009 break;
07010
07011 case 203:
07012
07013
07014 #line 1998 "ripper.y"
07015 {
07016 value_expr((yyvsp[(5) - (5)].val));
07017 (yyval.val) = new_attr_op_assign((yyvsp[(1) - (5)].val), ripper_id2sym('.'), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
07018 }
07019 break;
07020
07021 case 204:
07022
07023
07024 #line 2003 "ripper.y"
07025 {
07026 value_expr((yyvsp[(5) - (5)].val));
07027 (yyval.val) = new_attr_op_assign((yyvsp[(1) - (5)].val), ripper_id2sym('.'), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
07028 }
07029 break;
07030
07031 case 205:
07032
07033
07034 #line 2008 "ripper.y"
07035 {
07036 value_expr((yyvsp[(5) - (5)].val));
07037 (yyval.val) = new_attr_op_assign((yyvsp[(1) - (5)].val), ripper_intern("::"), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
07038 }
07039 break;
07040
07041 case 206:
07042
07043
07044 #line 2013 "ripper.y"
07045 {
07046 #if 0
07047 (yyval.val) = NEW_COLON2((yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val));
07048 (yyval.val) = new_const_op_assign((yyval.val), (yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
07049 #endif
07050 (yyval.val) = dispatch2(const_path_field, (yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val));
07051 (yyval.val) = dispatch3(opassign, (yyval.val), (yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
07052
07053 }
07054 break;
07055
07056 case 207:
07057
07058
07059 #line 2023 "ripper.y"
07060 {
07061 #if 0
07062 (yyval.val) = NEW_COLON3((yyvsp[(2) - (4)].val));
07063 (yyval.val) = new_const_op_assign((yyval.val), (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
07064 #endif
07065 (yyval.val) = dispatch1(top_const_field, (yyvsp[(2) - (4)].val));
07066 (yyval.val) = dispatch3(opassign, (yyval.val), (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
07067
07068 }
07069 break;
07070
07071 case 208:
07072
07073
07074 #line 2033 "ripper.y"
07075 {
07076 #if 0
07077 rb_backref_error((yyvsp[(1) - (3)].val));
07078 (yyval.val) = NEW_BEGIN(0);
07079 #endif
07080 (yyval.val) = dispatch1(var_field, (yyvsp[(1) - (3)].val));
07081 (yyval.val) = dispatch3(opassign, (yyval.val), (yyvsp[(2) - (3)].val), (yyvsp[(3) - (3)].val));
07082 (yyval.val) = dispatch1(assign_error, (yyval.val));
07083
07084 }
07085 break;
07086
07087 case 209:
07088
07089
07090 #line 2044 "ripper.y"
07091 {
07092 #if 0
07093 value_expr((yyvsp[(1) - (3)].val));
07094 value_expr((yyvsp[(3) - (3)].val));
07095 (yyval.val) = NEW_DOT2((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
07096 if (nd_type((yyvsp[(1) - (3)].val)) == NODE_LIT && FIXNUM_P((yyvsp[(1) - (3)].val)->nd_lit) &&
07097 nd_type((yyvsp[(3) - (3)].val)) == NODE_LIT && FIXNUM_P((yyvsp[(3) - (3)].val)->nd_lit)) {
07098 deferred_nodes = list_append(deferred_nodes, (yyval.val));
07099 }
07100 #endif
07101 (yyval.val) = dispatch2(dot2, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
07102
07103 }
07104 break;
07105
07106 case 210:
07107
07108
07109 #line 2058 "ripper.y"
07110 {
07111 #if 0
07112 value_expr((yyvsp[(1) - (3)].val));
07113 value_expr((yyvsp[(3) - (3)].val));
07114 (yyval.val) = NEW_DOT3((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
07115 if (nd_type((yyvsp[(1) - (3)].val)) == NODE_LIT && FIXNUM_P((yyvsp[(1) - (3)].val)->nd_lit) &&
07116 nd_type((yyvsp[(3) - (3)].val)) == NODE_LIT && FIXNUM_P((yyvsp[(3) - (3)].val)->nd_lit)) {
07117 deferred_nodes = list_append(deferred_nodes, (yyval.val));
07118 }
07119 #endif
07120 (yyval.val) = dispatch2(dot3, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
07121
07122 }
07123 break;
07124
07125 case 211:
07126
07127
07128 #line 2072 "ripper.y"
07129 {
07130 #if 0
07131 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), '+', (yyvsp[(3) - (3)].val));
07132 #endif
07133 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ID2SYM('+'), (yyvsp[(3) - (3)].val));
07134
07135 }
07136 break;
07137
07138 case 212:
07139
07140
07141 #line 2080 "ripper.y"
07142 {
07143 #if 0
07144 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), '-', (yyvsp[(3) - (3)].val));
07145 #endif
07146 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ID2SYM('-'), (yyvsp[(3) - (3)].val));
07147
07148 }
07149 break;
07150
07151 case 213:
07152
07153
07154 #line 2088 "ripper.y"
07155 {
07156 #if 0
07157 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), '*', (yyvsp[(3) - (3)].val));
07158 #endif
07159 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ID2SYM('*'), (yyvsp[(3) - (3)].val));
07160
07161 }
07162 break;
07163
07164 case 214:
07165
07166
07167 #line 2096 "ripper.y"
07168 {
07169 #if 0
07170 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), '/', (yyvsp[(3) - (3)].val));
07171 #endif
07172 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ID2SYM('/'), (yyvsp[(3) - (3)].val));
07173
07174 }
07175 break;
07176
07177 case 215:
07178
07179
07180 #line 2104 "ripper.y"
07181 {
07182 #if 0
07183 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), '%', (yyvsp[(3) - (3)].val));
07184 #endif
07185 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ID2SYM('%'), (yyvsp[(3) - (3)].val));
07186
07187 }
07188 break;
07189
07190 case 216:
07191
07192
07193 #line 2112 "ripper.y"
07194 {
07195 #if 0
07196 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), tPOW, (yyvsp[(3) - (3)].val));
07197 #endif
07198 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("**"), (yyvsp[(3) - (3)].val));
07199
07200 }
07201 break;
07202
07203 case 217:
07204
07205
07206 #line 2120 "ripper.y"
07207 {
07208 #if 0
07209 (yyval.val) = NEW_CALL(call_bin_op((yyvsp[(2) - (4)].val), tPOW, (yyvsp[(4) - (4)].val)), tUMINUS, 0);
07210 #endif
07211 (yyval.val) = dispatch3(binary, (yyvsp[(2) - (4)].val), ripper_intern("**"), (yyvsp[(4) - (4)].val));
07212 (yyval.val) = dispatch2(unary, ripper_intern("-@"), (yyval.val));
07213
07214 }
07215 break;
07216
07217 case 218:
07218
07219
07220 #line 2129 "ripper.y"
07221 {
07222 #if 0
07223 (yyval.val) = call_uni_op((yyvsp[(2) - (2)].val), tUPLUS);
07224 #endif
07225 (yyval.val) = dispatch2(unary, ripper_intern("+@"), (yyvsp[(2) - (2)].val));
07226
07227 }
07228 break;
07229
07230 case 219:
07231
07232
07233 #line 2137 "ripper.y"
07234 {
07235 #if 0
07236 (yyval.val) = call_uni_op((yyvsp[(2) - (2)].val), tUMINUS);
07237 #endif
07238 (yyval.val) = dispatch2(unary, ripper_intern("-@"), (yyvsp[(2) - (2)].val));
07239
07240 }
07241 break;
07242
07243 case 220:
07244
07245
07246 #line 2145 "ripper.y"
07247 {
07248 #if 0
07249 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), '|', (yyvsp[(3) - (3)].val));
07250 #endif
07251 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ID2SYM('|'), (yyvsp[(3) - (3)].val));
07252
07253 }
07254 break;
07255
07256 case 221:
07257
07258
07259 #line 2153 "ripper.y"
07260 {
07261 #if 0
07262 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), '^', (yyvsp[(3) - (3)].val));
07263 #endif
07264 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ID2SYM('^'), (yyvsp[(3) - (3)].val));
07265
07266 }
07267 break;
07268
07269 case 222:
07270
07271
07272 #line 2161 "ripper.y"
07273 {
07274 #if 0
07275 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), '&', (yyvsp[(3) - (3)].val));
07276 #endif
07277 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ID2SYM('&'), (yyvsp[(3) - (3)].val));
07278
07279 }
07280 break;
07281
07282 case 223:
07283
07284
07285 #line 2169 "ripper.y"
07286 {
07287 #if 0
07288 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), tCMP, (yyvsp[(3) - (3)].val));
07289 #endif
07290 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("<=>"), (yyvsp[(3) - (3)].val));
07291
07292 }
07293 break;
07294
07295 case 224:
07296
07297
07298 #line 2177 "ripper.y"
07299 {
07300 #if 0
07301 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), '>', (yyvsp[(3) - (3)].val));
07302 #endif
07303 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ID2SYM('>'), (yyvsp[(3) - (3)].val));
07304
07305 }
07306 break;
07307
07308 case 225:
07309
07310
07311 #line 2185 "ripper.y"
07312 {
07313 #if 0
07314 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), tGEQ, (yyvsp[(3) - (3)].val));
07315 #endif
07316 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern(">="), (yyvsp[(3) - (3)].val));
07317
07318 }
07319 break;
07320
07321 case 226:
07322
07323
07324 #line 2193 "ripper.y"
07325 {
07326 #if 0
07327 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), '<', (yyvsp[(3) - (3)].val));
07328 #endif
07329 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ID2SYM('<'), (yyvsp[(3) - (3)].val));
07330
07331 }
07332 break;
07333
07334 case 227:
07335
07336
07337 #line 2201 "ripper.y"
07338 {
07339 #if 0
07340 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), tLEQ, (yyvsp[(3) - (3)].val));
07341 #endif
07342 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("<="), (yyvsp[(3) - (3)].val));
07343
07344 }
07345 break;
07346
07347 case 228:
07348
07349
07350 #line 2209 "ripper.y"
07351 {
07352 #if 0
07353 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), tEQ, (yyvsp[(3) - (3)].val));
07354 #endif
07355 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("=="), (yyvsp[(3) - (3)].val));
07356
07357 }
07358 break;
07359
07360 case 229:
07361
07362
07363 #line 2217 "ripper.y"
07364 {
07365 #if 0
07366 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), tEQQ, (yyvsp[(3) - (3)].val));
07367 #endif
07368 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("==="), (yyvsp[(3) - (3)].val));
07369
07370 }
07371 break;
07372
07373 case 230:
07374
07375
07376 #line 2225 "ripper.y"
07377 {
07378 #if 0
07379 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), tNEQ, (yyvsp[(3) - (3)].val));
07380 #endif
07381 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("!="), (yyvsp[(3) - (3)].val));
07382
07383 }
07384 break;
07385
07386 case 231:
07387
07388
07389 #line 2233 "ripper.y"
07390 {
07391 #if 0
07392 (yyval.val) = match_op((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
07393 if (nd_type((yyvsp[(1) - (3)].val)) == NODE_LIT && RB_TYPE_P((yyvsp[(1) - (3)].val)->nd_lit, T_REGEXP)) {
07394 (yyval.val) = reg_named_capture_assign((yyvsp[(1) - (3)].val)->nd_lit, (yyval.val));
07395 }
07396 #endif
07397 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("=~"), (yyvsp[(3) - (3)].val));
07398
07399 }
07400 break;
07401
07402 case 232:
07403
07404
07405 #line 2244 "ripper.y"
07406 {
07407 #if 0
07408 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), tNMATCH, (yyvsp[(3) - (3)].val));
07409 #endif
07410 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("!~"), (yyvsp[(3) - (3)].val));
07411
07412 }
07413 break;
07414
07415 case 233:
07416
07417
07418 #line 2252 "ripper.y"
07419 {
07420 #if 0
07421 (yyval.val) = call_uni_op(cond((yyvsp[(2) - (2)].val)), '!');
07422 #endif
07423 (yyval.val) = dispatch2(unary, ID2SYM('!'), (yyvsp[(2) - (2)].val));
07424
07425 }
07426 break;
07427
07428 case 234:
07429
07430
07431 #line 2260 "ripper.y"
07432 {
07433 #if 0
07434 (yyval.val) = call_uni_op((yyvsp[(2) - (2)].val), '~');
07435 #endif
07436 (yyval.val) = dispatch2(unary, ID2SYM('~'), (yyvsp[(2) - (2)].val));
07437
07438 }
07439 break;
07440
07441 case 235:
07442
07443
07444 #line 2268 "ripper.y"
07445 {
07446 #if 0
07447 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), tLSHFT, (yyvsp[(3) - (3)].val));
07448 #endif
07449 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("<<"), (yyvsp[(3) - (3)].val));
07450
07451 }
07452 break;
07453
07454 case 236:
07455
07456
07457 #line 2276 "ripper.y"
07458 {
07459 #if 0
07460 (yyval.val) = call_bin_op((yyvsp[(1) - (3)].val), tRSHFT, (yyvsp[(3) - (3)].val));
07461 #endif
07462 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern(">>"), (yyvsp[(3) - (3)].val));
07463
07464 }
07465 break;
07466
07467 case 237:
07468
07469
07470 #line 2284 "ripper.y"
07471 {
07472 #if 0
07473 (yyval.val) = logop(NODE_AND, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
07474 #endif
07475 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("&&"), (yyvsp[(3) - (3)].val));
07476
07477 }
07478 break;
07479
07480 case 238:
07481
07482
07483 #line 2292 "ripper.y"
07484 {
07485 #if 0
07486 (yyval.val) = logop(NODE_OR, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
07487 #endif
07488 (yyval.val) = dispatch3(binary, (yyvsp[(1) - (3)].val), ripper_intern("||"), (yyvsp[(3) - (3)].val));
07489
07490 }
07491 break;
07492
07493 case 239:
07494
07495
07496 #line 2299 "ripper.y"
07497 {in_defined = 1;}
07498 break;
07499
07500 case 240:
07501
07502
07503 #line 2300 "ripper.y"
07504 {
07505 #if 0
07506 in_defined = 0;
07507 (yyval.val) = new_defined((yyvsp[(4) - (4)].val));
07508 #endif
07509 in_defined = 0;
07510 (yyval.val) = dispatch1(defined, (yyvsp[(4) - (4)].val));
07511
07512 }
07513 break;
07514
07515 case 241:
07516
07517
07518 #line 2310 "ripper.y"
07519 {
07520 #if 0
07521 value_expr((yyvsp[(1) - (6)].val));
07522 (yyval.val) = NEW_IF(cond((yyvsp[(1) - (6)].val)), (yyvsp[(3) - (6)].val), (yyvsp[(6) - (6)].val));
07523 fixpos((yyval.val), (yyvsp[(1) - (6)].val));
07524 #endif
07525 (yyval.val) = dispatch3(ifop, (yyvsp[(1) - (6)].val), (yyvsp[(3) - (6)].val), (yyvsp[(6) - (6)].val));
07526
07527 }
07528 break;
07529
07530 case 242:
07531
07532
07533 #line 2320 "ripper.y"
07534 {
07535 (yyval.val) = (yyvsp[(1) - (1)].val);
07536 }
07537 break;
07538
07539 case 243:
07540
07541
07542 #line 2326 "ripper.y"
07543 {
07544 #if 0
07545 value_expr((yyvsp[(1) - (1)].val));
07546 (yyval.val) = (yyvsp[(1) - (1)].val);
07547 if (!(yyval.val)) (yyval.val) = NEW_NIL();
07548 #endif
07549 (yyval.val) = (yyvsp[(1) - (1)].val);
07550
07551 }
07552 break;
07553
07554 case 245:
07555
07556
07557 #line 2339 "ripper.y"
07558 {
07559 (yyval.val) = (yyvsp[(1) - (2)].val);
07560 }
07561 break;
07562
07563 case 246:
07564
07565
07566 #line 2343 "ripper.y"
07567 {
07568 #if 0
07569 (yyval.val) = arg_append((yyvsp[(1) - (4)].val), NEW_HASH((yyvsp[(3) - (4)].val)));
07570 #endif
07571 (yyval.val) = arg_add_assocs((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val));
07572
07573 }
07574 break;
07575
07576 case 247:
07577
07578
07579 #line 2351 "ripper.y"
07580 {
07581 #if 0
07582 (yyval.val) = NEW_LIST(NEW_HASH((yyvsp[(1) - (2)].val)));
07583 #endif
07584 (yyval.val) = arg_add_assocs(arg_new(), (yyvsp[(1) - (2)].val));
07585
07586 }
07587 break;
07588
07589 case 248:
07590
07591
07592 #line 2361 "ripper.y"
07593 {
07594 #if 0
07595 (yyval.val) = (yyvsp[(2) - (3)].val);
07596 #endif
07597 (yyval.val) = dispatch1(arg_paren, escape_Qundef((yyvsp[(2) - (3)].val)));
07598
07599 }
07600 break;
07601
07602 case 253:
07603
07604
07605 #line 2377 "ripper.y"
07606 {
07607 (yyval.val) = (yyvsp[(1) - (2)].val);
07608 }
07609 break;
07610
07611 case 254:
07612
07613
07614 #line 2381 "ripper.y"
07615 {
07616 #if 0
07617 (yyval.val) = arg_append((yyvsp[(1) - (4)].val), NEW_HASH((yyvsp[(3) - (4)].val)));
07618 #endif
07619 (yyval.val) = arg_add_assocs((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val));
07620
07621 }
07622 break;
07623
07624 case 255:
07625
07626
07627 #line 2389 "ripper.y"
07628 {
07629 #if 0
07630 (yyval.val) = NEW_LIST(NEW_HASH((yyvsp[(1) - (2)].val)));
07631 #endif
07632 (yyval.val) = arg_add_assocs(arg_new(), (yyvsp[(1) - (2)].val));
07633
07634 }
07635 break;
07636
07637 case 256:
07638
07639
07640 #line 2399 "ripper.y"
07641 {
07642 #if 0
07643 value_expr((yyvsp[(1) - (1)].val));
07644 (yyval.val) = NEW_LIST((yyvsp[(1) - (1)].val));
07645 #endif
07646 (yyval.val) = arg_add(arg_new(), (yyvsp[(1) - (1)].val));
07647
07648 }
07649 break;
07650
07651 case 257:
07652
07653
07654 #line 2408 "ripper.y"
07655 {
07656 #if 0
07657 (yyval.val) = arg_blk_pass((yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
07658 #endif
07659 (yyval.val) = arg_add_optblock((yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
07660
07661 }
07662 break;
07663
07664 case 258:
07665
07666
07667 #line 2416 "ripper.y"
07668 {
07669 #if 0
07670 (yyval.val) = NEW_LIST(NEW_HASH((yyvsp[(1) - (2)].val)));
07671 (yyval.val) = arg_blk_pass((yyval.val), (yyvsp[(2) - (2)].val));
07672 #endif
07673 (yyval.val) = arg_add_assocs(arg_new(), (yyvsp[(1) - (2)].val));
07674 (yyval.val) = arg_add_optblock((yyval.val), (yyvsp[(2) - (2)].val));
07675
07676 }
07677 break;
07678
07679 case 259:
07680
07681
07682 #line 2426 "ripper.y"
07683 {
07684 #if 0
07685 (yyval.val) = arg_append((yyvsp[(1) - (4)].val), NEW_HASH((yyvsp[(3) - (4)].val)));
07686 (yyval.val) = arg_blk_pass((yyval.val), (yyvsp[(4) - (4)].val));
07687 #endif
07688 (yyval.val) = arg_add_optblock(arg_add_assocs((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val)), (yyvsp[(4) - (4)].val));
07689
07690 }
07691 break;
07692
07693 case 260:
07694
07695
07696 #line 2437 "ripper.y"
07697 {
07698 (yyval.val) = arg_add_block(arg_new(), (yyvsp[(1) - (1)].val));
07699 }
07700 break;
07701
07702 case 261:
07703
07704
07705 #line 2443 "ripper.y"
07706 {
07707 (yyval.val) = cmdarg_stack;
07708 CMDARG_PUSH(1);
07709 }
07710 break;
07711
07712 case 262:
07713
07714
07715 #line 2448 "ripper.y"
07716 {
07717
07718 cmdarg_stack = (yyvsp[(1) - (2)].val);
07719 (yyval.val) = (yyvsp[(2) - (2)].val);
07720 }
07721 break;
07722
07723 case 263:
07724
07725
07726 #line 2456 "ripper.y"
07727 {
07728 #if 0
07729 (yyval.val) = NEW_BLOCK_PASS((yyvsp[(2) - (2)].val));
07730 #endif
07731 (yyval.val) = (yyvsp[(2) - (2)].val);
07732
07733 }
07734 break;
07735
07736 case 264:
07737
07738
07739 #line 2466 "ripper.y"
07740 {
07741 (yyval.val) = (yyvsp[(2) - (2)].val);
07742 }
07743 break;
07744
07745 case 265:
07746
07747
07748 #line 2470 "ripper.y"
07749 {
07750 (yyval.val) = 0;
07751 }
07752 break;
07753
07754 case 266:
07755
07756
07757 #line 2476 "ripper.y"
07758 {
07759 #if 0
07760 (yyval.val) = NEW_LIST((yyvsp[(1) - (1)].val));
07761 #endif
07762 (yyval.val) = arg_add(arg_new(), (yyvsp[(1) - (1)].val));
07763
07764 }
07765 break;
07766
07767 case 267:
07768
07769
07770 #line 2484 "ripper.y"
07771 {
07772 #if 0
07773 (yyval.val) = NEW_SPLAT((yyvsp[(2) - (2)].val));
07774 #endif
07775 (yyval.val) = arg_add_star(arg_new(), (yyvsp[(2) - (2)].val));
07776
07777 }
07778 break;
07779
07780 case 268:
07781
07782
07783 #line 2492 "ripper.y"
07784 {
07785 #if 0
07786 NODE *n1;
07787 if ((n1 = splat_array((yyvsp[(1) - (3)].val))) != 0) {
07788 (yyval.val) = list_append(n1, (yyvsp[(3) - (3)].val));
07789 }
07790 else {
07791 (yyval.val) = arg_append((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
07792 }
07793 #endif
07794 (yyval.val) = arg_add((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
07795
07796 }
07797 break;
07798
07799 case 269:
07800
07801
07802 #line 2506 "ripper.y"
07803 {
07804 #if 0
07805 NODE *n1;
07806 if ((nd_type((yyvsp[(4) - (4)].val)) == NODE_ARRAY) && (n1 = splat_array((yyvsp[(1) - (4)].val))) != 0) {
07807 (yyval.val) = list_concat(n1, (yyvsp[(4) - (4)].val));
07808 }
07809 else {
07810 (yyval.val) = arg_concat((yyvsp[(1) - (4)].val), (yyvsp[(4) - (4)].val));
07811 }
07812 #endif
07813 (yyval.val) = arg_add_star((yyvsp[(1) - (4)].val), (yyvsp[(4) - (4)].val));
07814
07815 }
07816 break;
07817
07818 case 272:
07819
07820
07821 #line 2526 "ripper.y"
07822 {
07823 #if 0
07824 NODE *n1;
07825 if ((n1 = splat_array((yyvsp[(1) - (3)].val))) != 0) {
07826 (yyval.val) = list_append(n1, (yyvsp[(3) - (3)].val));
07827 }
07828 else {
07829 (yyval.val) = arg_append((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
07830 }
07831 #endif
07832 (yyval.val) = mrhs_add(args2mrhs((yyvsp[(1) - (3)].val)), (yyvsp[(3) - (3)].val));
07833
07834 }
07835 break;
07836
07837 case 273:
07838
07839
07840 #line 2540 "ripper.y"
07841 {
07842 #if 0
07843 NODE *n1;
07844 if (nd_type((yyvsp[(4) - (4)].val)) == NODE_ARRAY &&
07845 (n1 = splat_array((yyvsp[(1) - (4)].val))) != 0) {
07846 (yyval.val) = list_concat(n1, (yyvsp[(4) - (4)].val));
07847 }
07848 else {
07849 (yyval.val) = arg_concat((yyvsp[(1) - (4)].val), (yyvsp[(4) - (4)].val));
07850 }
07851 #endif
07852 (yyval.val) = mrhs_add_star(args2mrhs((yyvsp[(1) - (4)].val)), (yyvsp[(4) - (4)].val));
07853
07854 }
07855 break;
07856
07857 case 274:
07858
07859
07860 #line 2555 "ripper.y"
07861 {
07862 #if 0
07863 (yyval.val) = NEW_SPLAT((yyvsp[(2) - (2)].val));
07864 #endif
07865 (yyval.val) = mrhs_add_star(mrhs_new(), (yyvsp[(2) - (2)].val));
07866
07867 }
07868 break;
07869
07870 case 285:
07871
07872
07873 #line 2575 "ripper.y"
07874 {
07875 #if 0
07876 (yyval.val) = NEW_FCALL((yyvsp[(1) - (1)].val), 0);
07877 #endif
07878 (yyval.val) = method_arg(dispatch1(fcall, (yyvsp[(1) - (1)].val)), arg_new());
07879
07880 }
07881 break;
07882
07883 case 286:
07884
07885
07886 #line 2583 "ripper.y"
07887 {
07888 (yyvsp[(1) - (1)].val) = cmdarg_stack;
07889 cmdarg_stack = 0;
07890 #if 0
07891 (yyval.num) = ruby_sourceline;
07892 #endif
07893
07894 }
07895 break;
07896
07897 case 287:
07898
07899
07900 #line 2593 "ripper.y"
07901 {
07902 cmdarg_stack = (yyvsp[(1) - (4)].val);
07903 #if 0
07904 if ((yyvsp[(3) - (4)].val) == NULL) {
07905 (yyval.val) = NEW_NIL();
07906 }
07907 else {
07908 if (nd_type((yyvsp[(3) - (4)].val)) == NODE_RESCUE ||
07909 nd_type((yyvsp[(3) - (4)].val)) == NODE_ENSURE)
07910 nd_set_line((yyvsp[(3) - (4)].val), (yyvsp[(2) - (4)].num));
07911 (yyval.val) = NEW_BEGIN((yyvsp[(3) - (4)].val));
07912 }
07913 nd_set_line((yyval.val), (yyvsp[(2) - (4)].num));
07914 #endif
07915 (yyval.val) = dispatch1(begin, (yyvsp[(3) - (4)].val));
07916
07917 }
07918 break;
07919
07920 case 288:
07921
07922
07923 #line 2610 "ripper.y"
07924 {lex_state = EXPR_ENDARG;}
07925 break;
07926
07927 case 289:
07928
07929
07930 #line 2611 "ripper.y"
07931 {
07932 #if 0
07933 (yyval.val) = 0;
07934 #endif
07935 (yyval.val) = dispatch1(paren, 0);
07936
07937 }
07938 break;
07939
07940 case 290:
07941
07942
07943 #line 2619 "ripper.y"
07944 {
07945 (yyvsp[(1) - (1)].val) = cmdarg_stack;
07946 cmdarg_stack = 0;
07947 }
07948 break;
07949
07950 case 291:
07951
07952
07953 #line 2623 "ripper.y"
07954 {lex_state = EXPR_ENDARG;}
07955 break;
07956
07957 case 292:
07958
07959
07960 #line 2624 "ripper.y"
07961 {
07962 cmdarg_stack = (yyvsp[(1) - (5)].val);
07963 #if 0
07964 (yyval.val) = (yyvsp[(3) - (5)].val);
07965 #endif
07966 (yyval.val) = dispatch1(paren, (yyvsp[(3) - (5)].val));
07967
07968 }
07969 break;
07970
07971 case 293:
07972
07973
07974 #line 2633 "ripper.y"
07975 {
07976 #if 0
07977 (yyval.val) = (yyvsp[(2) - (3)].val);
07978 #endif
07979 (yyval.val) = dispatch1(paren, (yyvsp[(2) - (3)].val));
07980
07981 }
07982 break;
07983
07984 case 294:
07985
07986
07987 #line 2641 "ripper.y"
07988 {
07989 #if 0
07990 (yyval.val) = NEW_COLON2((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
07991 #endif
07992 (yyval.val) = dispatch2(const_path_ref, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
07993
07994 }
07995 break;
07996
07997 case 295:
07998
07999
08000 #line 2649 "ripper.y"
08001 {
08002 #if 0
08003 (yyval.val) = NEW_COLON3((yyvsp[(2) - (2)].val));
08004 #endif
08005 (yyval.val) = dispatch1(top_const_ref, (yyvsp[(2) - (2)].val));
08006
08007 }
08008 break;
08009
08010 case 296:
08011
08012
08013 #line 2657 "ripper.y"
08014 {
08015 #if 0
08016 if ((yyvsp[(2) - (3)].val) == 0) {
08017 (yyval.val) = NEW_ZARRAY();
08018 }
08019 else {
08020 (yyval.val) = (yyvsp[(2) - (3)].val);
08021 }
08022 #endif
08023 (yyval.val) = dispatch1(array, escape_Qundef((yyvsp[(2) - (3)].val)));
08024
08025 }
08026 break;
08027
08028 case 297:
08029
08030
08031 #line 2670 "ripper.y"
08032 {
08033 #if 0
08034 (yyval.val) = NEW_HASH((yyvsp[(2) - (3)].val));
08035 #endif
08036 (yyval.val) = dispatch1(hash, escape_Qundef((yyvsp[(2) - (3)].val)));
08037
08038 }
08039 break;
08040
08041 case 298:
08042
08043
08044 #line 2678 "ripper.y"
08045 {
08046 #if 0
08047 (yyval.val) = NEW_RETURN(0);
08048 #endif
08049 (yyval.val) = dispatch0(return0);
08050
08051 }
08052 break;
08053
08054 case 299:
08055
08056
08057 #line 2686 "ripper.y"
08058 {
08059 #if 0
08060 (yyval.val) = new_yield((yyvsp[(3) - (4)].val));
08061 #endif
08062 (yyval.val) = dispatch1(yield, dispatch1(paren, (yyvsp[(3) - (4)].val)));
08063
08064 }
08065 break;
08066
08067 case 300:
08068
08069
08070 #line 2694 "ripper.y"
08071 {
08072 #if 0
08073 (yyval.val) = NEW_YIELD(0);
08074 #endif
08075 (yyval.val) = dispatch1(yield, dispatch1(paren, arg_new()));
08076
08077 }
08078 break;
08079
08080 case 301:
08081
08082
08083 #line 2702 "ripper.y"
08084 {
08085 #if 0
08086 (yyval.val) = NEW_YIELD(0);
08087 #endif
08088 (yyval.val) = dispatch0(yield0);
08089
08090 }
08091 break;
08092
08093 case 302:
08094
08095
08096 #line 2709 "ripper.y"
08097 {in_defined = 1;}
08098 break;
08099
08100 case 303:
08101
08102
08103 #line 2710 "ripper.y"
08104 {
08105 #if 0
08106 in_defined = 0;
08107 (yyval.val) = new_defined((yyvsp[(5) - (6)].val));
08108 #endif
08109 in_defined = 0;
08110 (yyval.val) = dispatch1(defined, (yyvsp[(5) - (6)].val));
08111
08112 }
08113 break;
08114
08115 case 304:
08116
08117
08118 #line 2720 "ripper.y"
08119 {
08120 #if 0
08121 (yyval.val) = call_uni_op(cond((yyvsp[(3) - (4)].val)), '!');
08122 #endif
08123 (yyval.val) = dispatch2(unary, ripper_intern("not"), (yyvsp[(3) - (4)].val));
08124
08125 }
08126 break;
08127
08128 case 305:
08129
08130
08131 #line 2728 "ripper.y"
08132 {
08133 #if 0
08134 (yyval.val) = call_uni_op(cond(NEW_NIL()), '!');
08135 #endif
08136 (yyval.val) = dispatch2(unary, ripper_intern("not"), Qnil);
08137
08138 }
08139 break;
08140
08141 case 306:
08142
08143
08144 #line 2736 "ripper.y"
08145 {
08146 #if 0
08147 (yyvsp[(2) - (2)].val)->nd_iter = (yyvsp[(1) - (2)].val);
08148 (yyval.val) = (yyvsp[(2) - (2)].val);
08149 #endif
08150 (yyval.val) = method_arg(dispatch1(fcall, (yyvsp[(1) - (2)].val)), arg_new());
08151 (yyval.val) = method_add_block((yyval.val), (yyvsp[(2) - (2)].val));
08152
08153 }
08154 break;
08155
08156 case 308:
08157
08158
08159 #line 2747 "ripper.y"
08160 {
08161 #if 0
08162 block_dup_check((yyvsp[(1) - (2)].val)->nd_args, (yyvsp[(2) - (2)].val));
08163 (yyvsp[(2) - (2)].val)->nd_iter = (yyvsp[(1) - (2)].val);
08164 (yyval.val) = (yyvsp[(2) - (2)].val);
08165 #endif
08166 (yyval.val) = method_add_block((yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
08167
08168 }
08169 break;
08170
08171 case 309:
08172
08173
08174 #line 2757 "ripper.y"
08175 {
08176 (yyval.val) = (yyvsp[(2) - (2)].val);
08177 }
08178 break;
08179
08180 case 310:
08181
08182
08183 #line 2764 "ripper.y"
08184 {
08185 #if 0
08186 (yyval.val) = NEW_IF(cond((yyvsp[(2) - (6)].val)), (yyvsp[(4) - (6)].val), (yyvsp[(5) - (6)].val));
08187 fixpos((yyval.val), (yyvsp[(2) - (6)].val));
08188 #endif
08189 (yyval.val) = dispatch3(if, (yyvsp[(2) - (6)].val), (yyvsp[(4) - (6)].val), escape_Qundef((yyvsp[(5) - (6)].val)));
08190
08191 }
08192 break;
08193
08194 case 311:
08195
08196
08197 #line 2776 "ripper.y"
08198 {
08199 #if 0
08200 (yyval.val) = NEW_UNLESS(cond((yyvsp[(2) - (6)].val)), (yyvsp[(4) - (6)].val), (yyvsp[(5) - (6)].val));
08201 fixpos((yyval.val), (yyvsp[(2) - (6)].val));
08202 #endif
08203 (yyval.val) = dispatch3(unless, (yyvsp[(2) - (6)].val), (yyvsp[(4) - (6)].val), escape_Qundef((yyvsp[(5) - (6)].val)));
08204
08205 }
08206 break;
08207
08208 case 312:
08209
08210
08211 #line 2784 "ripper.y"
08212 {COND_PUSH(1);}
08213 break;
08214
08215 case 313:
08216
08217
08218 #line 2784 "ripper.y"
08219 {COND_POP();}
08220 break;
08221
08222 case 314:
08223
08224
08225 #line 2787 "ripper.y"
08226 {
08227 #if 0
08228 (yyval.val) = NEW_WHILE(cond((yyvsp[(3) - (7)].val)), (yyvsp[(6) - (7)].val), 1);
08229 fixpos((yyval.val), (yyvsp[(3) - (7)].val));
08230 #endif
08231 (yyval.val) = dispatch2(while, (yyvsp[(3) - (7)].val), (yyvsp[(6) - (7)].val));
08232
08233 }
08234 break;
08235
08236 case 315:
08237
08238
08239 #line 2795 "ripper.y"
08240 {COND_PUSH(1);}
08241 break;
08242
08243 case 316:
08244
08245
08246 #line 2795 "ripper.y"
08247 {COND_POP();}
08248 break;
08249
08250 case 317:
08251
08252
08253 #line 2798 "ripper.y"
08254 {
08255 #if 0
08256 (yyval.val) = NEW_UNTIL(cond((yyvsp[(3) - (7)].val)), (yyvsp[(6) - (7)].val), 1);
08257 fixpos((yyval.val), (yyvsp[(3) - (7)].val));
08258 #endif
08259 (yyval.val) = dispatch2(until, (yyvsp[(3) - (7)].val), (yyvsp[(6) - (7)].val));
08260
08261 }
08262 break;
08263
08264 case 318:
08265
08266
08267 #line 2809 "ripper.y"
08268 {
08269 #if 0
08270 (yyval.val) = NEW_CASE((yyvsp[(2) - (5)].val), (yyvsp[(4) - (5)].val));
08271 fixpos((yyval.val), (yyvsp[(2) - (5)].val));
08272 #endif
08273 (yyval.val) = dispatch2(case, (yyvsp[(2) - (5)].val), (yyvsp[(4) - (5)].val));
08274
08275 }
08276 break;
08277
08278 case 319:
08279
08280
08281 #line 2818 "ripper.y"
08282 {
08283 #if 0
08284 (yyval.val) = NEW_CASE(0, (yyvsp[(3) - (4)].val));
08285 #endif
08286 (yyval.val) = dispatch2(case, Qnil, (yyvsp[(3) - (4)].val));
08287
08288 }
08289 break;
08290
08291 case 320:
08292
08293
08294 #line 2826 "ripper.y"
08295 {COND_PUSH(1);}
08296 break;
08297
08298 case 321:
08299
08300
08301 #line 2828 "ripper.y"
08302 {COND_POP();}
08303 break;
08304
08305 case 322:
08306
08307
08308 #line 2831 "ripper.y"
08309 {
08310 #if 0
08311
08312
08313
08314
08315
08316
08317
08318
08319
08320 ID id = internal_id();
08321 ID *tbl = ALLOC_N(ID, 2);
08322 NODE *m = NEW_ARGS_AUX(0, 0);
08323 NODE *args, *scope;
08324
08325 if (nd_type((yyvsp[(2) - (9)].val)) == NODE_MASGN) {
08326
08327
08328
08329
08330 NODE *one = NEW_LIST(NEW_LIT(INT2FIX(1)));
08331 NODE *zero = NEW_LIST(NEW_LIT(INT2FIX(0)));
08332 m->nd_next = block_append(
08333 NEW_IF(
08334 NEW_NODE(NODE_AND,
08335 NEW_CALL(NEW_CALL(NEW_DVAR(id), idLength, 0),
08336 idEq, one),
08337 NEW_CALL(NEW_CALL(NEW_DVAR(id), idAREF, zero),
08338 rb_intern("kind_of?"), NEW_LIST(NEW_LIT(rb_cArray))),
08339 0),
08340 NEW_DASGN_CURR(id,
08341 NEW_CALL(NEW_DVAR(id), idAREF, zero)),
08342 0),
08343 node_assign((yyvsp[(2) - (9)].val), NEW_DVAR(id)));
08344
08345 args = new_args(m, 0, id, 0, new_args_tail(0, 0, 0));
08346 }
08347 else {
08348 if (nd_type((yyvsp[(2) - (9)].val)) == NODE_LASGN ||
08349 nd_type((yyvsp[(2) - (9)].val)) == NODE_DASGN ||
08350 nd_type((yyvsp[(2) - (9)].val)) == NODE_DASGN_CURR) {
08351 (yyvsp[(2) - (9)].val)->nd_value = NEW_DVAR(id);
08352 m->nd_plen = 1;
08353 m->nd_next = (yyvsp[(2) - (9)].val);
08354 args = new_args(m, 0, 0, 0, new_args_tail(0, 0, 0));
08355 }
08356 else {
08357 m->nd_next = node_assign(NEW_MASGN(NEW_LIST((yyvsp[(2) - (9)].val)), 0), NEW_DVAR(id));
08358 args = new_args(m, 0, id, 0, new_args_tail(0, 0, 0));
08359 }
08360 }
08361 scope = NEW_NODE(NODE_SCOPE, tbl, (yyvsp[(8) - (9)].val), args);
08362 tbl[0] = 1; tbl[1] = id;
08363 (yyval.val) = NEW_FOR(0, (yyvsp[(5) - (9)].val), scope);
08364 fixpos((yyval.val), (yyvsp[(2) - (9)].val));
08365 #endif
08366 (yyval.val) = dispatch3(for, (yyvsp[(2) - (9)].val), (yyvsp[(5) - (9)].val), (yyvsp[(8) - (9)].val));
08367
08368 }
08369 break;
08370
08371 case 323:
08372
08373
08374 #line 2892 "ripper.y"
08375 {
08376 if (in_def || in_single)
08377 yyerror("class definition in method body");
08378 local_push(0);
08379 #if 0
08380 (yyval.num) = ruby_sourceline;
08381 #endif
08382
08383 }
08384 break;
08385
08386 case 324:
08387
08388
08389 #line 2903 "ripper.y"
08390 {
08391 #if 0
08392 (yyval.val) = NEW_CLASS((yyvsp[(2) - (6)].val), (yyvsp[(5) - (6)].val), (yyvsp[(3) - (6)].val));
08393 nd_set_line((yyval.val), (yyvsp[(4) - (6)].num));
08394 #endif
08395 (yyval.val) = dispatch3(class, (yyvsp[(2) - (6)].val), (yyvsp[(3) - (6)].val), (yyvsp[(5) - (6)].val));
08396
08397 local_pop();
08398 }
08399 break;
08400
08401 case 325:
08402
08403
08404 #line 2913 "ripper.y"
08405 {
08406 (yyval.num) = in_def;
08407 in_def = 0;
08408 }
08409 break;
08410
08411 case 326:
08412
08413
08414 #line 2918 "ripper.y"
08415 {
08416 (yyval.num) = in_single;
08417 in_single = 0;
08418 local_push(0);
08419 }
08420 break;
08421
08422 case 327:
08423
08424
08425 #line 2925 "ripper.y"
08426 {
08427 #if 0
08428 (yyval.val) = NEW_SCLASS((yyvsp[(3) - (8)].val), (yyvsp[(7) - (8)].val));
08429 fixpos((yyval.val), (yyvsp[(3) - (8)].val));
08430 #endif
08431 (yyval.val) = dispatch2(sclass, (yyvsp[(3) - (8)].val), (yyvsp[(7) - (8)].val));
08432
08433 local_pop();
08434 in_def = (yyvsp[(4) - (8)].num);
08435 in_single = (yyvsp[(6) - (8)].num);
08436 }
08437 break;
08438
08439 case 328:
08440
08441
08442 #line 2937 "ripper.y"
08443 {
08444 if (in_def || in_single)
08445 yyerror("module definition in method body");
08446 local_push(0);
08447 #if 0
08448 (yyval.num) = ruby_sourceline;
08449 #endif
08450
08451 }
08452 break;
08453
08454 case 329:
08455
08456
08457 #line 2948 "ripper.y"
08458 {
08459 #if 0
08460 (yyval.val) = NEW_MODULE((yyvsp[(2) - (5)].val), (yyvsp[(4) - (5)].val));
08461 nd_set_line((yyval.val), (yyvsp[(3) - (5)].num));
08462 #endif
08463 (yyval.val) = dispatch2(module, (yyvsp[(2) - (5)].val), (yyvsp[(4) - (5)].val));
08464
08465 local_pop();
08466 }
08467 break;
08468
08469 case 330:
08470
08471
08472 #line 2958 "ripper.y"
08473 {
08474 (yyval.id) = cur_mid;
08475 cur_mid = (yyvsp[(2) - (2)].val);
08476 in_def++;
08477 local_push(0);
08478 }
08479 break;
08480
08481 case 331:
08482
08483
08484 #line 2967 "ripper.y"
08485 {
08486 #if 0
08487 NODE *body = remove_begin((yyvsp[(5) - (6)].val));
08488 reduce_nodes(&body);
08489 (yyval.val) = NEW_DEFN((yyvsp[(2) - (6)].val), (yyvsp[(4) - (6)].val), body, NOEX_PRIVATE);
08490 nd_set_line((yyval.val), (yyvsp[(1) - (6)].num));
08491 #endif
08492 (yyval.val) = dispatch3(def, (yyvsp[(2) - (6)].val), (yyvsp[(4) - (6)].val), (yyvsp[(5) - (6)].val));
08493
08494 local_pop();
08495 in_def--;
08496 cur_mid = (yyvsp[(3) - (6)].id);
08497 }
08498 break;
08499
08500 case 332:
08501
08502
08503 #line 2980 "ripper.y"
08504 {lex_state = EXPR_FNAME;}
08505 break;
08506
08507 case 333:
08508
08509
08510 #line 2981 "ripper.y"
08511 {
08512 in_single++;
08513 lex_state = EXPR_ENDFN;
08514 local_push(0);
08515 }
08516 break;
08517
08518 case 334:
08519
08520
08521 #line 2989 "ripper.y"
08522 {
08523 #if 0
08524 NODE *body = remove_begin((yyvsp[(8) - (9)].val));
08525 reduce_nodes(&body);
08526 (yyval.val) = NEW_DEFS((yyvsp[(2) - (9)].val), (yyvsp[(5) - (9)].val), (yyvsp[(7) - (9)].val), body);
08527 nd_set_line((yyval.val), (yyvsp[(1) - (9)].num));
08528 #endif
08529 (yyval.val) = dispatch5(defs, (yyvsp[(2) - (9)].val), (yyvsp[(3) - (9)].val), (yyvsp[(5) - (9)].val), (yyvsp[(7) - (9)].val), (yyvsp[(8) - (9)].val));
08530
08531 local_pop();
08532 in_single--;
08533 }
08534 break;
08535
08536 case 335:
08537
08538
08539 #line 3002 "ripper.y"
08540 {
08541 #if 0
08542 (yyval.val) = NEW_BREAK(0);
08543 #endif
08544 (yyval.val) = dispatch1(break, arg_new());
08545
08546 }
08547 break;
08548
08549 case 336:
08550
08551
08552 #line 3010 "ripper.y"
08553 {
08554 #if 0
08555 (yyval.val) = NEW_NEXT(0);
08556 #endif
08557 (yyval.val) = dispatch1(next, arg_new());
08558
08559 }
08560 break;
08561
08562 case 337:
08563
08564
08565 #line 3018 "ripper.y"
08566 {
08567 #if 0
08568 (yyval.val) = NEW_REDO();
08569 #endif
08570 (yyval.val) = dispatch0(redo);
08571
08572 }
08573 break;
08574
08575 case 338:
08576
08577
08578 #line 3026 "ripper.y"
08579 {
08580 #if 0
08581 (yyval.val) = NEW_RETRY();
08582 #endif
08583 (yyval.val) = dispatch0(retry);
08584
08585 }
08586 break;
08587
08588 case 339:
08589
08590
08591 #line 3036 "ripper.y"
08592 {
08593 #if 0
08594 value_expr((yyvsp[(1) - (1)].val));
08595 (yyval.val) = (yyvsp[(1) - (1)].val);
08596 if (!(yyval.val)) (yyval.val) = NEW_NIL();
08597 #endif
08598 (yyval.val) = (yyvsp[(1) - (1)].val);
08599
08600 }
08601 break;
08602
08603 case 340:
08604
08605
08606 #line 3048 "ripper.y"
08607 {
08608 token_info_push("begin");
08609 }
08610 break;
08611
08612 case 341:
08613
08614
08615 #line 3054 "ripper.y"
08616 {
08617 token_info_push("if");
08618 }
08619 break;
08620
08621 case 342:
08622
08623
08624 #line 3060 "ripper.y"
08625 {
08626 token_info_push("unless");
08627 }
08628 break;
08629
08630 case 343:
08631
08632
08633 #line 3066 "ripper.y"
08634 {
08635 token_info_push("while");
08636 }
08637 break;
08638
08639 case 344:
08640
08641
08642 #line 3072 "ripper.y"
08643 {
08644 token_info_push("until");
08645 }
08646 break;
08647
08648 case 345:
08649
08650
08651 #line 3078 "ripper.y"
08652 {
08653 token_info_push("case");
08654 }
08655 break;
08656
08657 case 346:
08658
08659
08660 #line 3084 "ripper.y"
08661 {
08662 token_info_push("for");
08663 }
08664 break;
08665
08666 case 347:
08667
08668
08669 #line 3090 "ripper.y"
08670 {
08671 token_info_push("class");
08672 }
08673 break;
08674
08675 case 348:
08676
08677
08678 #line 3096 "ripper.y"
08679 {
08680 token_info_push("module");
08681 }
08682 break;
08683
08684 case 349:
08685
08686
08687 #line 3102 "ripper.y"
08688 {
08689 token_info_push("def");
08690 #if 0
08691 (yyval.num) = ruby_sourceline;
08692 #endif
08693
08694 }
08695 break;
08696
08697 case 350:
08698
08699
08700 #line 3112 "ripper.y"
08701 {
08702 token_info_pop("end");
08703 }
08704 break;
08705
08706 case 351:
08707
08708
08709 #line 3120 "ripper.y"
08710 { (yyval.val) = Qnil; }
08711 break;
08712
08713 case 353:
08714
08715
08716 #line 3126 "ripper.y"
08717 { (yyval.val) = (yyvsp[(2) - (2)].val); }
08718 break;
08719
08720 case 354:
08721
08722
08723 #line 3133 "ripper.y"
08724 { (yyval.val) = Qnil; }
08725 break;
08726
08727 case 357:
08728
08729
08730 #line 3142 "ripper.y"
08731 {
08732 #if 0
08733 (yyval.val) = NEW_IF(cond((yyvsp[(2) - (5)].val)), (yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
08734 fixpos((yyval.val), (yyvsp[(2) - (5)].val));
08735 #endif
08736 (yyval.val) = dispatch3(elsif, (yyvsp[(2) - (5)].val), (yyvsp[(4) - (5)].val), escape_Qundef((yyvsp[(5) - (5)].val)));
08737
08738 }
08739 break;
08740
08741 case 359:
08742
08743
08744 #line 3154 "ripper.y"
08745 {
08746 #if 0
08747 (yyval.val) = (yyvsp[(2) - (2)].val);
08748 #endif
08749 (yyval.val) = dispatch1(else, (yyvsp[(2) - (2)].val));
08750
08751 }
08752 break;
08753
08754 case 362:
08755
08756
08757 #line 3168 "ripper.y"
08758 {
08759 (yyval.val) = assignable((yyvsp[(1) - (1)].val), 0);
08760 #if 0
08761 #endif
08762 (yyval.val) = dispatch1(mlhs_paren, (yyval.val));
08763
08764 }
08765 break;
08766
08767 case 363:
08768
08769
08770 #line 3176 "ripper.y"
08771 {
08772 #if 0
08773 (yyval.val) = (yyvsp[(2) - (3)].val);
08774 #endif
08775 (yyval.val) = dispatch1(mlhs_paren, (yyvsp[(2) - (3)].val));
08776
08777 }
08778 break;
08779
08780 case 364:
08781
08782
08783 #line 3186 "ripper.y"
08784 {
08785 #if 0
08786 (yyval.val) = NEW_LIST((yyvsp[(1) - (1)].val));
08787 #endif
08788 (yyval.val) = mlhs_add(mlhs_new(), (yyvsp[(1) - (1)].val));
08789
08790 }
08791 break;
08792
08793 case 365:
08794
08795
08796 #line 3194 "ripper.y"
08797 {
08798 #if 0
08799 (yyval.val) = list_append((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
08800 #endif
08801 (yyval.val) = mlhs_add((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
08802
08803 }
08804 break;
08805
08806 case 366:
08807
08808
08809 #line 3204 "ripper.y"
08810 {
08811 #if 0
08812 (yyval.val) = NEW_MASGN((yyvsp[(1) - (1)].val), 0);
08813 #endif
08814 (yyval.val) = (yyvsp[(1) - (1)].val);
08815
08816 }
08817 break;
08818
08819 case 367:
08820
08821
08822 #line 3212 "ripper.y"
08823 {
08824 (yyval.val) = assignable((yyvsp[(4) - (4)].val), 0);
08825 #if 0
08826 (yyval.val) = NEW_MASGN((yyvsp[(1) - (4)].val), (yyval.val));
08827 #endif
08828 (yyval.val) = mlhs_add_star((yyvsp[(1) - (4)].val), (yyval.val));
08829
08830 }
08831 break;
08832
08833 case 368:
08834
08835
08836 #line 3221 "ripper.y"
08837 {
08838 (yyval.val) = assignable((yyvsp[(4) - (6)].val), 0);
08839 #if 0
08840 (yyval.val) = NEW_MASGN((yyvsp[(1) - (6)].val), NEW_POSTARG((yyval.val), (yyvsp[(6) - (6)].val)));
08841 #endif
08842 (yyval.val) = mlhs_add_star((yyvsp[(1) - (6)].val), (yyval.val));
08843
08844 }
08845 break;
08846
08847 case 369:
08848
08849
08850 #line 3230 "ripper.y"
08851 {
08852 #if 0
08853 (yyval.val) = NEW_MASGN((yyvsp[(1) - (3)].val), -1);
08854 #endif
08855 (yyval.val) = mlhs_add_star((yyvsp[(1) - (3)].val), Qnil);
08856
08857 }
08858 break;
08859
08860 case 370:
08861
08862
08863 #line 3238 "ripper.y"
08864 {
08865 #if 0
08866 (yyval.val) = NEW_MASGN((yyvsp[(1) - (5)].val), NEW_POSTARG(-1, (yyvsp[(5) - (5)].val)));
08867 #endif
08868 (yyval.val) = mlhs_add_star((yyvsp[(1) - (5)].val), (yyvsp[(5) - (5)].val));
08869
08870 }
08871 break;
08872
08873 case 371:
08874
08875
08876 #line 3246 "ripper.y"
08877 {
08878 (yyval.val) = assignable((yyvsp[(2) - (2)].val), 0);
08879 #if 0
08880 (yyval.val) = NEW_MASGN(0, (yyval.val));
08881 #endif
08882 (yyval.val) = mlhs_add_star(mlhs_new(), (yyval.val));
08883
08884 }
08885 break;
08886
08887 case 372:
08888
08889
08890 #line 3255 "ripper.y"
08891 {
08892 (yyval.val) = assignable((yyvsp[(2) - (4)].val), 0);
08893 #if 0
08894 (yyval.val) = NEW_MASGN(0, NEW_POSTARG((yyval.val), (yyvsp[(4) - (4)].val)));
08895 #endif
08896 #if 0
08897 TODO: Check me
08898 #endif
08899 (yyval.val) = mlhs_add_star((yyval.val), (yyvsp[(4) - (4)].val));
08900
08901 }
08902 break;
08903
08904 case 373:
08905
08906
08907 #line 3267 "ripper.y"
08908 {
08909 #if 0
08910 (yyval.val) = NEW_MASGN(0, -1);
08911 #endif
08912 (yyval.val) = mlhs_add_star(mlhs_new(), Qnil);
08913
08914 }
08915 break;
08916
08917 case 374:
08918
08919
08920 #line 3275 "ripper.y"
08921 {
08922 #if 0
08923 (yyval.val) = NEW_MASGN(0, NEW_POSTARG(-1, (yyvsp[(3) - (3)].val)));
08924 #endif
08925 (yyval.val) = mlhs_add_star(mlhs_new(), Qnil);
08926
08927 }
08928 break;
08929
08930 case 375:
08931
08932
08933 #line 3286 "ripper.y"
08934 {
08935 (yyval.val) = new_args_tail((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
08936 }
08937 break;
08938
08939 case 376:
08940
08941
08942 #line 3290 "ripper.y"
08943 {
08944 (yyval.val) = new_args_tail((yyvsp[(1) - (2)].val), Qnone, (yyvsp[(2) - (2)].val));
08945 }
08946 break;
08947
08948 case 377:
08949
08950
08951 #line 3294 "ripper.y"
08952 {
08953 (yyval.val) = new_args_tail(Qnone, (yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
08954 }
08955 break;
08956
08957 case 378:
08958
08959
08960 #line 3298 "ripper.y"
08961 {
08962 (yyval.val) = new_args_tail(Qnone, Qnone, (yyvsp[(1) - (1)].val));
08963 }
08964 break;
08965
08966 case 379:
08967
08968
08969 #line 3304 "ripper.y"
08970 {
08971 (yyval.val) = (yyvsp[(2) - (2)].val);
08972 }
08973 break;
08974
08975 case 380:
08976
08977
08978 #line 3308 "ripper.y"
08979 {
08980 (yyval.val) = new_args_tail(Qnone, Qnone, Qnone);
08981 }
08982 break;
08983
08984 case 381:
08985
08986
08987 #line 3314 "ripper.y"
08988 {
08989 (yyval.val) = new_args((yyvsp[(1) - (6)].val), (yyvsp[(3) - (6)].val), (yyvsp[(5) - (6)].val), Qnone, (yyvsp[(6) - (6)].val));
08990 }
08991 break;
08992
08993 case 382:
08994
08995
08996 #line 3318 "ripper.y"
08997 {
08998 (yyval.val) = new_args((yyvsp[(1) - (8)].val), (yyvsp[(3) - (8)].val), (yyvsp[(5) - (8)].val), (yyvsp[(7) - (8)].val), (yyvsp[(8) - (8)].val));
08999 }
09000 break;
09001
09002 case 383:
09003
09004
09005 #line 3322 "ripper.y"
09006 {
09007 (yyval.val) = new_args((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val), Qnone, Qnone, (yyvsp[(4) - (4)].val));
09008 }
09009 break;
09010
09011 case 384:
09012
09013
09014 #line 3326 "ripper.y"
09015 {
09016 (yyval.val) = new_args((yyvsp[(1) - (6)].val), (yyvsp[(3) - (6)].val), Qnone, (yyvsp[(5) - (6)].val), (yyvsp[(6) - (6)].val));
09017 }
09018 break;
09019
09020 case 385:
09021
09022
09023 #line 3330 "ripper.y"
09024 {
09025 (yyval.val) = new_args((yyvsp[(1) - (4)].val), Qnone, (yyvsp[(3) - (4)].val), Qnone, (yyvsp[(4) - (4)].val));
09026 }
09027 break;
09028
09029 case 386:
09030
09031
09032 #line 3334 "ripper.y"
09033 {
09034 (yyval.val) = new_args((yyvsp[(1) - (2)].val), Qnone, 1, Qnone, new_args_tail(Qnone, Qnone, Qnone));
09035 #if 0
09036 #endif
09037 dispatch1(excessed_comma, (yyval.val));
09038
09039 }
09040 break;
09041
09042 case 387:
09043
09044
09045 #line 3342 "ripper.y"
09046 {
09047 (yyval.val) = new_args((yyvsp[(1) - (6)].val), Qnone, (yyvsp[(3) - (6)].val), (yyvsp[(5) - (6)].val), (yyvsp[(6) - (6)].val));
09048 }
09049 break;
09050
09051 case 388:
09052
09053
09054 #line 3346 "ripper.y"
09055 {
09056 (yyval.val) = new_args((yyvsp[(1) - (2)].val), Qnone, Qnone, Qnone, (yyvsp[(2) - (2)].val));
09057 }
09058 break;
09059
09060 case 389:
09061
09062
09063 #line 3350 "ripper.y"
09064 {
09065 (yyval.val) = new_args(Qnone, (yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val), Qnone, (yyvsp[(4) - (4)].val));
09066 }
09067 break;
09068
09069 case 390:
09070
09071
09072 #line 3354 "ripper.y"
09073 {
09074 (yyval.val) = new_args(Qnone, (yyvsp[(1) - (6)].val), (yyvsp[(3) - (6)].val), (yyvsp[(5) - (6)].val), (yyvsp[(6) - (6)].val));
09075 }
09076 break;
09077
09078 case 391:
09079
09080
09081 #line 3358 "ripper.y"
09082 {
09083 (yyval.val) = new_args(Qnone, (yyvsp[(1) - (2)].val), Qnone, Qnone, (yyvsp[(2) - (2)].val));
09084 }
09085 break;
09086
09087 case 392:
09088
09089
09090 #line 3362 "ripper.y"
09091 {
09092 (yyval.val) = new_args(Qnone, (yyvsp[(1) - (4)].val), Qnone, (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
09093 }
09094 break;
09095
09096 case 393:
09097
09098
09099 #line 3366 "ripper.y"
09100 {
09101 (yyval.val) = new_args(Qnone, Qnone, (yyvsp[(1) - (2)].val), Qnone, (yyvsp[(2) - (2)].val));
09102 }
09103 break;
09104
09105 case 394:
09106
09107
09108 #line 3370 "ripper.y"
09109 {
09110 (yyval.val) = new_args(Qnone, Qnone, (yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
09111 }
09112 break;
09113
09114 case 395:
09115
09116
09117 #line 3374 "ripper.y"
09118 {
09119 (yyval.val) = new_args(Qnone, Qnone, Qnone, Qnone, (yyvsp[(1) - (1)].val));
09120 }
09121 break;
09122
09123 case 397:
09124
09125
09126 #line 3381 "ripper.y"
09127 {
09128 command_start = TRUE;
09129 }
09130 break;
09131
09132 case 398:
09133
09134
09135 #line 3387 "ripper.y"
09136 {
09137 #if 0
09138 (yyval.val) = 0;
09139 #endif
09140 (yyval.val) = blockvar_new(params_new(Qnil,Qnil,Qnil,Qnil,Qnil,Qnil,Qnil),
09141 escape_Qundef((yyvsp[(2) - (3)].val)));
09142
09143 }
09144 break;
09145
09146 case 399:
09147
09148
09149 #line 3396 "ripper.y"
09150 {
09151 #if 0
09152 (yyval.val) = 0;
09153 #endif
09154 (yyval.val) = blockvar_new(params_new(Qnil,Qnil,Qnil,Qnil,Qnil,Qnil,Qnil),
09155 Qnil);
09156
09157 }
09158 break;
09159
09160 case 400:
09161
09162
09163 #line 3405 "ripper.y"
09164 {
09165 #if 0
09166 (yyval.val) = (yyvsp[(2) - (4)].val);
09167 #endif
09168 (yyval.val) = blockvar_new(escape_Qundef((yyvsp[(2) - (4)].val)), escape_Qundef((yyvsp[(3) - (4)].val)));
09169
09170 }
09171 break;
09172
09173 case 401:
09174
09175
09176 #line 3416 "ripper.y"
09177 {
09178 (yyval.val) = 0;
09179 }
09180 break;
09181
09182 case 402:
09183
09184
09185 #line 3420 "ripper.y"
09186 {
09187 #if 0
09188 (yyval.val) = 0;
09189 #endif
09190 (yyval.val) = (yyvsp[(3) - (4)].val);
09191
09192 }
09193 break;
09194
09195 case 403:
09196
09197
09198 #line 3432 "ripper.y"
09199 {
09200 (yyval.val) = rb_ary_new3(1, (yyvsp[(1) - (1)].val));
09201 }
09202 break;
09203
09204 case 404:
09205
09206
09207 #line 3439 "ripper.y"
09208 {
09209 rb_ary_push((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
09210 }
09211 break;
09212
09213 case 405:
09214
09215
09216 #line 3446 "ripper.y"
09217 {
09218 new_bv(get_id((yyvsp[(1) - (1)].val)));
09219 #if 0
09220 #endif
09221 (yyval.val) = get_value((yyvsp[(1) - (1)].val));
09222
09223 }
09224 break;
09225
09226 case 406:
09227
09228
09229 #line 3454 "ripper.y"
09230 {
09231 (yyval.val) = 0;
09232 }
09233 break;
09234
09235 case 407:
09236
09237
09238 #line 3459 "ripper.y"
09239 {
09240 (yyval.vars) = dyna_push();
09241 }
09242 break;
09243
09244 case 408:
09245
09246
09247 #line 3462 "ripper.y"
09248 {
09249 (yyval.num) = lpar_beg;
09250 lpar_beg = ++paren_nest;
09251 }
09252 break;
09253
09254 case 409:
09255
09256
09257 #line 3467 "ripper.y"
09258 {
09259 (yyval.num) = ruby_sourceline;
09260 }
09261 break;
09262
09263 case 410:
09264
09265
09266 #line 3471 "ripper.y"
09267 {
09268 lpar_beg = (yyvsp[(2) - (5)].num);
09269 #if 0
09270 (yyval.val) = NEW_LAMBDA((yyvsp[(3) - (5)].val), (yyvsp[(5) - (5)].val));
09271 nd_set_line((yyval.val), (yyvsp[(4) - (5)].num));
09272 #endif
09273 (yyval.val) = dispatch2(lambda, (yyvsp[(3) - (5)].val), (yyvsp[(5) - (5)].val));
09274
09275 dyna_pop((yyvsp[(1) - (5)].vars));
09276 }
09277 break;
09278
09279 case 411:
09280
09281
09282 #line 3484 "ripper.y"
09283 {
09284 #if 0
09285 (yyval.val) = (yyvsp[(2) - (4)].val);
09286 #endif
09287 (yyval.val) = dispatch1(paren, (yyvsp[(2) - (4)].val));
09288
09289 }
09290 break;
09291
09292 case 412:
09293
09294
09295 #line 3492 "ripper.y"
09296 {
09297 (yyval.val) = (yyvsp[(1) - (1)].val);
09298 }
09299 break;
09300
09301 case 413:
09302
09303
09304 #line 3498 "ripper.y"
09305 {
09306 (yyval.val) = (yyvsp[(2) - (3)].val);
09307 }
09308 break;
09309
09310 case 414:
09311
09312
09313 #line 3502 "ripper.y"
09314 {
09315 (yyval.val) = (yyvsp[(2) - (3)].val);
09316 }
09317 break;
09318
09319 case 415:
09320
09321
09322 #line 3508 "ripper.y"
09323 {
09324 (yyvsp[(1) - (1)].vars) = dyna_push();
09325 #if 0
09326 (yyval.num) = ruby_sourceline;
09327 #endif
09328 }
09329 break;
09330
09331 case 416:
09332
09333
09334 #line 3517 "ripper.y"
09335 {
09336 #if 0
09337 (yyval.val) = NEW_ITER((yyvsp[(3) - (5)].val),(yyvsp[(4) - (5)].val));
09338 nd_set_line((yyval.val), (yyvsp[(2) - (5)].num));
09339 #endif
09340 (yyval.val) = dispatch2(do_block, escape_Qundef((yyvsp[(3) - (5)].val)), (yyvsp[(4) - (5)].val));
09341
09342 dyna_pop((yyvsp[(1) - (5)].vars));
09343 }
09344 break;
09345
09346 case 417:
09347
09348
09349 #line 3529 "ripper.y"
09350 {
09351 #if 0
09352 if (nd_type((yyvsp[(1) - (2)].val)) == NODE_YIELD) {
09353 compile_error(PARSER_ARG "block given to yield");
09354 }
09355 else {
09356 block_dup_check((yyvsp[(1) - (2)].val)->nd_args, (yyvsp[(2) - (2)].val));
09357 }
09358 (yyvsp[(2) - (2)].val)->nd_iter = (yyvsp[(1) - (2)].val);
09359 (yyval.val) = (yyvsp[(2) - (2)].val);
09360 fixpos((yyval.val), (yyvsp[(1) - (2)].val));
09361 #endif
09362 (yyval.val) = method_add_block((yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
09363
09364 }
09365 break;
09366
09367 case 418:
09368
09369
09370 #line 3545 "ripper.y"
09371 {
09372 #if 0
09373 (yyval.val) = NEW_CALL((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
09374 #endif
09375 (yyval.val) = dispatch3(call, (yyvsp[(1) - (4)].val), (yyvsp[(2) - (4)].val), (yyvsp[(3) - (4)].val));
09376 (yyval.val) = method_optarg((yyval.val), (yyvsp[(4) - (4)].val));
09377
09378 }
09379 break;
09380
09381 case 419:
09382
09383
09384 #line 3554 "ripper.y"
09385 {
09386 #if 0
09387 block_dup_check((yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
09388 (yyvsp[(5) - (5)].val)->nd_iter = NEW_CALL((yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val));
09389 (yyval.val) = (yyvsp[(5) - (5)].val);
09390 fixpos((yyval.val), (yyvsp[(1) - (5)].val));
09391 #endif
09392 (yyval.val) = dispatch4(command_call, (yyvsp[(1) - (5)].val), (yyvsp[(2) - (5)].val), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val));
09393 (yyval.val) = method_add_block((yyval.val), (yyvsp[(5) - (5)].val));
09394
09395 }
09396 break;
09397
09398 case 420:
09399
09400
09401 #line 3566 "ripper.y"
09402 {
09403 #if 0
09404 block_dup_check((yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
09405 (yyvsp[(5) - (5)].val)->nd_iter = NEW_CALL((yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val));
09406 (yyval.val) = (yyvsp[(5) - (5)].val);
09407 fixpos((yyval.val), (yyvsp[(1) - (5)].val));
09408 #endif
09409 (yyval.val) = dispatch4(command_call, (yyvsp[(1) - (5)].val), (yyvsp[(2) - (5)].val), (yyvsp[(3) - (5)].val), (yyvsp[(4) - (5)].val));
09410 (yyval.val) = method_add_block((yyval.val), (yyvsp[(5) - (5)].val));
09411
09412 }
09413 break;
09414
09415 case 421:
09416
09417
09418 #line 3580 "ripper.y"
09419 {
09420 #if 0
09421 (yyval.val) = (yyvsp[(1) - (2)].val);
09422 (yyval.val)->nd_args = (yyvsp[(2) - (2)].val);
09423 #endif
09424 (yyval.val) = method_arg(dispatch1(fcall, (yyvsp[(1) - (2)].val)), (yyvsp[(2) - (2)].val));
09425
09426 }
09427 break;
09428
09429 case 422:
09430
09431
09432 #line 3589 "ripper.y"
09433 {
09434 #if 0
09435 (yyval.num) = ruby_sourceline;
09436 #endif
09437 }
09438 break;
09439
09440 case 423:
09441
09442
09443 #line 3595 "ripper.y"
09444 {
09445 #if 0
09446 (yyval.val) = NEW_CALL((yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val), (yyvsp[(5) - (5)].val));
09447 nd_set_line((yyval.val), (yyvsp[(4) - (5)].num));
09448 #endif
09449 (yyval.val) = dispatch3(call, (yyvsp[(1) - (5)].val), ripper_id2sym('.'), (yyvsp[(3) - (5)].val));
09450 (yyval.val) = method_optarg((yyval.val), (yyvsp[(5) - (5)].val));
09451
09452 }
09453 break;
09454
09455 case 424:
09456
09457
09458 #line 3605 "ripper.y"
09459 {
09460 #if 0
09461 (yyval.num) = ruby_sourceline;
09462 #endif
09463 }
09464 break;
09465
09466 case 425:
09467
09468
09469 #line 3611 "ripper.y"
09470 {
09471 #if 0
09472 (yyval.val) = NEW_CALL((yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val), (yyvsp[(5) - (5)].val));
09473 nd_set_line((yyval.val), (yyvsp[(4) - (5)].num));
09474 #endif
09475 (yyval.val) = dispatch3(call, (yyvsp[(1) - (5)].val), ripper_id2sym('.'), (yyvsp[(3) - (5)].val));
09476 (yyval.val) = method_optarg((yyval.val), (yyvsp[(5) - (5)].val));
09477
09478 }
09479 break;
09480
09481 case 426:
09482
09483
09484 #line 3621 "ripper.y"
09485 {
09486 #if 0
09487 (yyval.val) = NEW_CALL((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val), 0);
09488 #endif
09489 (yyval.val) = dispatch3(call, (yyvsp[(1) - (3)].val), ripper_intern("::"), (yyvsp[(3) - (3)].val));
09490
09491 }
09492 break;
09493
09494 case 427:
09495
09496
09497 #line 3629 "ripper.y"
09498 {
09499 #if 0
09500 (yyval.num) = ruby_sourceline;
09501 #endif
09502 }
09503 break;
09504
09505 case 428:
09506
09507
09508 #line 3635 "ripper.y"
09509 {
09510 #if 0
09511 (yyval.val) = NEW_CALL((yyvsp[(1) - (4)].val), rb_intern("call"), (yyvsp[(4) - (4)].val));
09512 nd_set_line((yyval.val), (yyvsp[(3) - (4)].num));
09513 #endif
09514 (yyval.val) = dispatch3(call, (yyvsp[(1) - (4)].val), ripper_id2sym('.'),
09515 ripper_intern("call"));
09516 (yyval.val) = method_optarg((yyval.val), (yyvsp[(4) - (4)].val));
09517
09518 }
09519 break;
09520
09521 case 429:
09522
09523
09524 #line 3646 "ripper.y"
09525 {
09526 #if 0
09527 (yyval.num) = ruby_sourceline;
09528 #endif
09529 }
09530 break;
09531
09532 case 430:
09533
09534
09535 #line 3652 "ripper.y"
09536 {
09537 #if 0
09538 (yyval.val) = NEW_CALL((yyvsp[(1) - (4)].val), rb_intern("call"), (yyvsp[(4) - (4)].val));
09539 nd_set_line((yyval.val), (yyvsp[(3) - (4)].num));
09540 #endif
09541 (yyval.val) = dispatch3(call, (yyvsp[(1) - (4)].val), ripper_intern("::"),
09542 ripper_intern("call"));
09543 (yyval.val) = method_optarg((yyval.val), (yyvsp[(4) - (4)].val));
09544
09545 }
09546 break;
09547
09548 case 431:
09549
09550
09551 #line 3663 "ripper.y"
09552 {
09553 #if 0
09554 (yyval.val) = NEW_SUPER((yyvsp[(2) - (2)].val));
09555 #endif
09556 (yyval.val) = dispatch1(super, (yyvsp[(2) - (2)].val));
09557
09558 }
09559 break;
09560
09561 case 432:
09562
09563
09564 #line 3671 "ripper.y"
09565 {
09566 #if 0
09567 (yyval.val) = NEW_ZSUPER();
09568 #endif
09569 (yyval.val) = dispatch0(zsuper);
09570
09571 }
09572 break;
09573
09574 case 433:
09575
09576
09577 #line 3679 "ripper.y"
09578 {
09579 #if 0
09580 if ((yyvsp[(1) - (4)].val) && nd_type((yyvsp[(1) - (4)].val)) == NODE_SELF)
09581 (yyval.val) = NEW_FCALL(tAREF, (yyvsp[(3) - (4)].val));
09582 else
09583 (yyval.val) = NEW_CALL((yyvsp[(1) - (4)].val), tAREF, (yyvsp[(3) - (4)].val));
09584 fixpos((yyval.val), (yyvsp[(1) - (4)].val));
09585 #endif
09586 (yyval.val) = dispatch2(aref, (yyvsp[(1) - (4)].val), escape_Qundef((yyvsp[(3) - (4)].val)));
09587
09588 }
09589 break;
09590
09591 case 434:
09592
09593
09594 #line 3693 "ripper.y"
09595 {
09596 (yyvsp[(1) - (1)].vars) = dyna_push();
09597 #if 0
09598 (yyval.num) = ruby_sourceline;
09599 #endif
09600
09601 }
09602 break;
09603
09604 case 435:
09605
09606
09607 #line 3702 "ripper.y"
09608 {
09609 #if 0
09610 (yyval.val) = NEW_ITER((yyvsp[(3) - (5)].val),(yyvsp[(4) - (5)].val));
09611 nd_set_line((yyval.val), (yyvsp[(2) - (5)].num));
09612 #endif
09613 (yyval.val) = dispatch2(brace_block, escape_Qundef((yyvsp[(3) - (5)].val)), (yyvsp[(4) - (5)].val));
09614
09615 dyna_pop((yyvsp[(1) - (5)].vars));
09616 }
09617 break;
09618
09619 case 436:
09620
09621
09622 #line 3712 "ripper.y"
09623 {
09624 (yyvsp[(1) - (1)].vars) = dyna_push();
09625 #if 0
09626 (yyval.num) = ruby_sourceline;
09627 #endif
09628
09629 }
09630 break;
09631
09632 case 437:
09633
09634
09635 #line 3721 "ripper.y"
09636 {
09637 #if 0
09638 (yyval.val) = NEW_ITER((yyvsp[(3) - (5)].val),(yyvsp[(4) - (5)].val));
09639 nd_set_line((yyval.val), (yyvsp[(2) - (5)].num));
09640 #endif
09641 (yyval.val) = dispatch2(do_block, escape_Qundef((yyvsp[(3) - (5)].val)), (yyvsp[(4) - (5)].val));
09642
09643 dyna_pop((yyvsp[(1) - (5)].vars));
09644 }
09645 break;
09646
09647 case 438:
09648
09649
09650 #line 3735 "ripper.y"
09651 {
09652 #if 0
09653 (yyval.val) = NEW_WHEN((yyvsp[(2) - (5)].val), (yyvsp[(4) - (5)].val), (yyvsp[(5) - (5)].val));
09654 #endif
09655 (yyval.val) = dispatch3(when, (yyvsp[(2) - (5)].val), (yyvsp[(4) - (5)].val), escape_Qundef((yyvsp[(5) - (5)].val)));
09656
09657 }
09658 break;
09659
09660 case 441:
09661
09662
09663 #line 3751 "ripper.y"
09664 {
09665 #if 0
09666 if ((yyvsp[(3) - (6)].val)) {
09667 (yyvsp[(3) - (6)].val) = node_assign((yyvsp[(3) - (6)].val), NEW_ERRINFO());
09668 (yyvsp[(5) - (6)].val) = block_append((yyvsp[(3) - (6)].val), (yyvsp[(5) - (6)].val));
09669 }
09670 (yyval.val) = NEW_RESBODY((yyvsp[(2) - (6)].val), (yyvsp[(5) - (6)].val), (yyvsp[(6) - (6)].val));
09671 fixpos((yyval.val), (yyvsp[(2) - (6)].val)?(yyvsp[(2) - (6)].val):(yyvsp[(5) - (6)].val));
09672 #endif
09673 (yyval.val) = dispatch4(rescue,
09674 escape_Qundef((yyvsp[(2) - (6)].val)),
09675 escape_Qundef((yyvsp[(3) - (6)].val)),
09676 escape_Qundef((yyvsp[(5) - (6)].val)),
09677 escape_Qundef((yyvsp[(6) - (6)].val)));
09678
09679 }
09680 break;
09681
09682 case 443:
09683
09684
09685 #line 3771 "ripper.y"
09686 {
09687 #if 0
09688 (yyval.val) = NEW_LIST((yyvsp[(1) - (1)].val));
09689 #endif
09690 (yyval.val) = rb_ary_new3(1, (yyvsp[(1) - (1)].val));
09691
09692 }
09693 break;
09694
09695 case 444:
09696
09697
09698 #line 3779 "ripper.y"
09699 {
09700 #if 0
09701 if (!((yyval.val) = splat_array((yyvsp[(1) - (1)].val)))) (yyval.val) = (yyvsp[(1) - (1)].val);
09702 #endif
09703 (yyval.val) = (yyvsp[(1) - (1)].val);
09704
09705 }
09706 break;
09707
09708 case 446:
09709
09710
09711 #line 3790 "ripper.y"
09712 {
09713 (yyval.val) = (yyvsp[(2) - (2)].val);
09714 }
09715 break;
09716
09717 case 448:
09718
09719
09720 #line 3797 "ripper.y"
09721 {
09722 #if 0
09723 (yyval.val) = (yyvsp[(2) - (2)].val);
09724 #endif
09725 (yyval.val) = dispatch1(ensure, (yyvsp[(2) - (2)].val));
09726
09727 }
09728 break;
09729
09730 case 451:
09731
09732
09733 #line 3809 "ripper.y"
09734 {
09735 #if 0
09736 (yyval.val) = NEW_LIT(ID2SYM((yyvsp[(1) - (1)].val)));
09737 #endif
09738 (yyval.val) = dispatch1(symbol_literal, (yyvsp[(1) - (1)].val));
09739
09740 }
09741 break;
09742
09743 case 453:
09744
09745
09746 #line 3820 "ripper.y"
09747 {
09748 #if 0
09749 NODE *node = (yyvsp[(1) - (1)].val);
09750 if (!node) {
09751 node = NEW_STR(STR_NEW0());
09752 }
09753 else {
09754 node = evstr2dstr(node);
09755 }
09756 (yyval.val) = node;
09757 #endif
09758 (yyval.val) = (yyvsp[(1) - (1)].val);
09759
09760 }
09761 break;
09762
09763 case 456:
09764
09765
09766 #line 3839 "ripper.y"
09767 {
09768 #if 0
09769 (yyval.val) = literal_concat((yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
09770 #endif
09771 (yyval.val) = dispatch2(string_concat, (yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
09772
09773 }
09774 break;
09775
09776 case 457:
09777
09778
09779 #line 3849 "ripper.y"
09780 {
09781 #if 0
09782 (yyval.val) = (yyvsp[(2) - (3)].val);
09783 #endif
09784 (yyval.val) = dispatch1(string_literal, (yyvsp[(2) - (3)].val));
09785
09786 }
09787 break;
09788
09789 case 458:
09790
09791
09792 #line 3859 "ripper.y"
09793 {
09794 #if 0
09795 NODE *node = (yyvsp[(2) - (3)].val);
09796 if (!node) {
09797 node = NEW_XSTR(STR_NEW0());
09798 }
09799 else {
09800 switch (nd_type(node)) {
09801 case NODE_STR:
09802 nd_set_type(node, NODE_XSTR);
09803 break;
09804 case NODE_DSTR:
09805 nd_set_type(node, NODE_DXSTR);
09806 break;
09807 default:
09808 node = NEW_NODE(NODE_DXSTR, Qnil, 1, NEW_LIST(node));
09809 break;
09810 }
09811 }
09812 (yyval.val) = node;
09813 #endif
09814 (yyval.val) = dispatch1(xstring_literal, (yyvsp[(2) - (3)].val));
09815
09816 }
09817 break;
09818
09819 case 459:
09820
09821
09822 #line 3886 "ripper.y"
09823 {
09824 #if 0
09825 int options = (yyvsp[(3) - (3)].val);
09826 NODE *node = (yyvsp[(2) - (3)].val);
09827 NODE *list, *prev;
09828 if (!node) {
09829 node = NEW_LIT(reg_compile(STR_NEW0(), options));
09830 }
09831 else switch (nd_type(node)) {
09832 case NODE_STR:
09833 {
09834 VALUE src = node->nd_lit;
09835 nd_set_type(node, NODE_LIT);
09836 node->nd_lit = reg_compile(src, options);
09837 }
09838 break;
09839 default:
09840 node = NEW_NODE(NODE_DSTR, STR_NEW0(), 1, NEW_LIST(node));
09841 case NODE_DSTR:
09842 if (options & RE_OPTION_ONCE) {
09843 nd_set_type(node, NODE_DREGX_ONCE);
09844 }
09845 else {
09846 nd_set_type(node, NODE_DREGX);
09847 }
09848 node->nd_cflag = options & RE_OPTION_MASK;
09849 if (!NIL_P(node->nd_lit)) reg_fragment_check(node->nd_lit, options);
09850 for (list = (prev = node)->nd_next; list; list = list->nd_next) {
09851 if (nd_type(list->nd_head) == NODE_STR) {
09852 VALUE tail = list->nd_head->nd_lit;
09853 if (reg_fragment_check(tail, options) && prev && !NIL_P(prev->nd_lit)) {
09854 VALUE lit = prev == node ? prev->nd_lit : prev->nd_head->nd_lit;
09855 if (!literal_concat0(parser, lit, tail)) {
09856 node = 0;
09857 break;
09858 }
09859 rb_str_resize(tail, 0);
09860 prev->nd_next = list->nd_next;
09861 rb_gc_force_recycle((VALUE)list->nd_head);
09862 rb_gc_force_recycle((VALUE)list);
09863 list = prev;
09864 }
09865 else {
09866 prev = list;
09867 }
09868 }
09869 else {
09870 prev = 0;
09871 }
09872 }
09873 if (!node->nd_next) {
09874 VALUE src = node->nd_lit;
09875 nd_set_type(node, NODE_LIT);
09876 node->nd_lit = reg_compile(src, options);
09877 }
09878 break;
09879 }
09880 (yyval.val) = node;
09881 #endif
09882 (yyval.val) = dispatch2(regexp_literal, (yyvsp[(2) - (3)].val), (yyvsp[(3) - (3)].val));
09883
09884 }
09885 break;
09886
09887 case 460:
09888
09889
09890 #line 3951 "ripper.y"
09891 {
09892 #if 0
09893 (yyval.val) = NEW_ZARRAY();
09894 #endif
09895 (yyval.val) = dispatch0(words_new);
09896 (yyval.val) = dispatch1(array, (yyval.val));
09897
09898 }
09899 break;
09900
09901 case 461:
09902
09903
09904 #line 3960 "ripper.y"
09905 {
09906 #if 0
09907 (yyval.val) = (yyvsp[(2) - (3)].val);
09908 #endif
09909 (yyval.val) = dispatch1(array, (yyvsp[(2) - (3)].val));
09910
09911 }
09912 break;
09913
09914 case 462:
09915
09916
09917 #line 3970 "ripper.y"
09918 {
09919 #if 0
09920 (yyval.val) = 0;
09921 #endif
09922 (yyval.val) = dispatch0(words_new);
09923
09924 }
09925 break;
09926
09927 case 463:
09928
09929
09930 #line 3978 "ripper.y"
09931 {
09932 #if 0
09933 (yyval.val) = list_append((yyvsp[(1) - (3)].val), evstr2dstr((yyvsp[(2) - (3)].val)));
09934 #endif
09935 (yyval.val) = dispatch2(words_add, (yyvsp[(1) - (3)].val), (yyvsp[(2) - (3)].val));
09936
09937 }
09938 break;
09939
09940 case 464:
09941
09942
09943 #line 3990 "ripper.y"
09944 {
09945 (yyval.val) = dispatch0(word_new);
09946 (yyval.val) = dispatch2(word_add, (yyval.val), (yyvsp[(1) - (1)].val));
09947 }
09948 break;
09949
09950 case 465:
09951
09952
09953 #line 3996 "ripper.y"
09954 {
09955 #if 0
09956 (yyval.val) = literal_concat((yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
09957 #endif
09958 (yyval.val) = dispatch2(word_add, (yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
09959
09960 }
09961 break;
09962
09963 case 466:
09964
09965
09966 #line 4006 "ripper.y"
09967 {
09968 #if 0
09969 (yyval.val) = NEW_ZARRAY();
09970 #endif
09971 (yyval.val) = dispatch0(symbols_new);
09972 (yyval.val) = dispatch1(array, (yyval.val));
09973
09974 }
09975 break;
09976
09977 case 467:
09978
09979
09980 #line 4015 "ripper.y"
09981 {
09982 #if 0
09983 (yyval.val) = (yyvsp[(2) - (3)].val);
09984 #endif
09985 (yyval.val) = dispatch1(array, (yyvsp[(2) - (3)].val));
09986
09987 }
09988 break;
09989
09990 case 468:
09991
09992
09993 #line 4025 "ripper.y"
09994 {
09995 #if 0
09996 (yyval.val) = 0;
09997 #endif
09998 (yyval.val) = dispatch0(symbols_new);
09999
10000 }
10001 break;
10002
10003 case 469:
10004
10005
10006 #line 4033 "ripper.y"
10007 {
10008 #if 0
10009 (yyvsp[(2) - (3)].val) = evstr2dstr((yyvsp[(2) - (3)].val));
10010 nd_set_type((yyvsp[(2) - (3)].val), NODE_DSYM);
10011 (yyval.val) = list_append((yyvsp[(1) - (3)].val), (yyvsp[(2) - (3)].val));
10012 #endif
10013 (yyval.val) = dispatch2(symbols_add, (yyvsp[(1) - (3)].val), (yyvsp[(2) - (3)].val));
10014
10015 }
10016 break;
10017
10018 case 470:
10019
10020
10021 #line 4045 "ripper.y"
10022 {
10023 #if 0
10024 (yyval.val) = NEW_ZARRAY();
10025 #endif
10026 (yyval.val) = dispatch0(qwords_new);
10027 (yyval.val) = dispatch1(array, (yyval.val));
10028
10029 }
10030 break;
10031
10032 case 471:
10033
10034
10035 #line 4054 "ripper.y"
10036 {
10037 #if 0
10038 (yyval.val) = (yyvsp[(2) - (3)].val);
10039 #endif
10040 (yyval.val) = dispatch1(array, (yyvsp[(2) - (3)].val));
10041
10042 }
10043 break;
10044
10045 case 472:
10046
10047
10048 #line 4064 "ripper.y"
10049 {
10050 #if 0
10051 (yyval.val) = NEW_ZARRAY();
10052 #endif
10053 (yyval.val) = dispatch0(qsymbols_new);
10054 (yyval.val) = dispatch1(array, (yyval.val));
10055
10056 }
10057 break;
10058
10059 case 473:
10060
10061
10062 #line 4073 "ripper.y"
10063 {
10064 #if 0
10065 (yyval.val) = (yyvsp[(2) - (3)].val);
10066 #endif
10067 (yyval.val) = dispatch1(array, (yyvsp[(2) - (3)].val));
10068
10069 }
10070 break;
10071
10072 case 474:
10073
10074
10075 #line 4083 "ripper.y"
10076 {
10077 #if 0
10078 (yyval.val) = 0;
10079 #endif
10080 (yyval.val) = dispatch0(qwords_new);
10081
10082 }
10083 break;
10084
10085 case 475:
10086
10087
10088 #line 4091 "ripper.y"
10089 {
10090 #if 0
10091 (yyval.val) = list_append((yyvsp[(1) - (3)].val), (yyvsp[(2) - (3)].val));
10092 #endif
10093 (yyval.val) = dispatch2(qwords_add, (yyvsp[(1) - (3)].val), (yyvsp[(2) - (3)].val));
10094
10095 }
10096 break;
10097
10098 case 476:
10099
10100
10101 #line 4101 "ripper.y"
10102 {
10103 #if 0
10104 (yyval.val) = 0;
10105 #endif
10106 (yyval.val) = dispatch0(qsymbols_new);
10107
10108 }
10109 break;
10110
10111 case 477:
10112
10113
10114 #line 4109 "ripper.y"
10115 {
10116 #if 0
10117 VALUE lit;
10118 lit = (yyvsp[(2) - (3)].val)->nd_lit;
10119 (yyvsp[(2) - (3)].val)->nd_lit = ID2SYM(rb_intern_str(lit));
10120 nd_set_type((yyvsp[(2) - (3)].val), NODE_LIT);
10121 (yyval.val) = list_append((yyvsp[(1) - (3)].val), (yyvsp[(2) - (3)].val));
10122 #endif
10123 (yyval.val) = dispatch2(qsymbols_add, (yyvsp[(1) - (3)].val), (yyvsp[(2) - (3)].val));
10124
10125 }
10126 break;
10127
10128 case 478:
10129
10130
10131 #line 4123 "ripper.y"
10132 {
10133 #if 0
10134 (yyval.val) = 0;
10135 #endif
10136 (yyval.val) = dispatch0(string_content);
10137
10138 }
10139 break;
10140
10141 case 479:
10142
10143
10144 #line 4131 "ripper.y"
10145 {
10146 #if 0
10147 (yyval.val) = literal_concat((yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
10148 #endif
10149 (yyval.val) = dispatch2(string_add, (yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
10150
10151 }
10152 break;
10153
10154 case 480:
10155
10156
10157 #line 4141 "ripper.y"
10158 {
10159 #if 0
10160 (yyval.val) = 0;
10161 #endif
10162 (yyval.val) = dispatch0(xstring_new);
10163
10164 }
10165 break;
10166
10167 case 481:
10168
10169
10170 #line 4149 "ripper.y"
10171 {
10172 #if 0
10173 (yyval.val) = literal_concat((yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
10174 #endif
10175 (yyval.val) = dispatch2(xstring_add, (yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
10176
10177 }
10178 break;
10179
10180 case 482:
10181
10182
10183 #line 4159 "ripper.y"
10184 {
10185 #if 0
10186 (yyval.val) = 0;
10187 #endif
10188 (yyval.val) = dispatch0(regexp_new);
10189
10190 }
10191 break;
10192
10193 case 483:
10194
10195
10196 #line 4167 "ripper.y"
10197 {
10198 #if 0
10199 NODE *head = (yyvsp[(1) - (2)].val), *tail = (yyvsp[(2) - (2)].val);
10200 if (!head) {
10201 (yyval.val) = tail;
10202 }
10203 else if (!tail) {
10204 (yyval.val) = head;
10205 }
10206 else {
10207 switch (nd_type(head)) {
10208 case NODE_STR:
10209 nd_set_type(head, NODE_DSTR);
10210 break;
10211 case NODE_DSTR:
10212 break;
10213 default:
10214 head = list_append(NEW_DSTR(Qnil), head);
10215 break;
10216 }
10217 (yyval.val) = list_append(head, tail);
10218 }
10219 #endif
10220 (yyval.val) = dispatch2(regexp_add, (yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
10221
10222 }
10223 break;
10224
10225 case 485:
10226
10227
10228 #line 4197 "ripper.y"
10229 {
10230 (yyval.node) = lex_strterm;
10231 lex_strterm = 0;
10232 lex_state = EXPR_BEG;
10233 }
10234 break;
10235
10236 case 486:
10237
10238
10239 #line 4203 "ripper.y"
10240 {
10241 #if 0
10242 lex_strterm = (yyvsp[(2) - (3)].node);
10243 (yyval.val) = NEW_EVSTR((yyvsp[(3) - (3)].val));
10244 #endif
10245 lex_strterm = (yyvsp[(2) - (3)].node);
10246 (yyval.val) = dispatch1(string_dvar, (yyvsp[(3) - (3)].val));
10247
10248 }
10249 break;
10250
10251 case 487:
10252
10253
10254 #line 4213 "ripper.y"
10255 {
10256 (yyvsp[(1) - (1)].val) = cond_stack;
10257 (yyval.val) = cmdarg_stack;
10258 cond_stack = 0;
10259 cmdarg_stack = 0;
10260 }
10261 break;
10262
10263 case 488:
10264
10265
10266 #line 4219 "ripper.y"
10267 {
10268 (yyval.node) = lex_strterm;
10269 lex_strterm = 0;
10270 lex_state = EXPR_BEG;
10271 }
10272 break;
10273
10274 case 489:
10275
10276
10277 #line 4224 "ripper.y"
10278 {
10279 (yyval.num) = brace_nest;
10280 brace_nest = 0;
10281 }
10282 break;
10283
10284 case 490:
10285
10286
10287 #line 4229 "ripper.y"
10288 {
10289 cond_stack = (yyvsp[(1) - (6)].val);
10290 cmdarg_stack = (yyvsp[(2) - (6)].val);
10291 lex_strterm = (yyvsp[(3) - (6)].node);
10292 brace_nest = (yyvsp[(4) - (6)].num);
10293 #if 0
10294 if ((yyvsp[(5) - (6)].val)) (yyvsp[(5) - (6)].val)->flags &= ~NODE_FL_NEWLINE;
10295 (yyval.val) = new_evstr((yyvsp[(5) - (6)].val));
10296 #endif
10297 (yyval.val) = dispatch1(string_embexpr, (yyvsp[(5) - (6)].val));
10298
10299 }
10300 break;
10301
10302 case 491:
10303
10304
10305 #line 4244 "ripper.y"
10306 {
10307 #if 0
10308 (yyval.val) = NEW_GVAR((yyvsp[(1) - (1)].val));
10309 #endif
10310 (yyval.val) = dispatch1(var_ref, (yyvsp[(1) - (1)].val));
10311
10312 }
10313 break;
10314
10315 case 492:
10316
10317
10318 #line 4252 "ripper.y"
10319 {
10320 #if 0
10321 (yyval.val) = NEW_IVAR((yyvsp[(1) - (1)].val));
10322 #endif
10323 (yyval.val) = dispatch1(var_ref, (yyvsp[(1) - (1)].val));
10324
10325 }
10326 break;
10327
10328 case 493:
10329
10330
10331 #line 4260 "ripper.y"
10332 {
10333 #if 0
10334 (yyval.val) = NEW_CVAR((yyvsp[(1) - (1)].val));
10335 #endif
10336 (yyval.val) = dispatch1(var_ref, (yyvsp[(1) - (1)].val));
10337
10338 }
10339 break;
10340
10341 case 495:
10342
10343
10344 #line 4271 "ripper.y"
10345 {
10346 lex_state = EXPR_END;
10347 #if 0
10348 (yyval.val) = (yyvsp[(2) - (2)].val);
10349 #endif
10350 (yyval.val) = dispatch1(symbol, (yyvsp[(2) - (2)].val));
10351
10352 }
10353 break;
10354
10355 case 500:
10356
10357
10358 #line 4288 "ripper.y"
10359 {
10360 lex_state = EXPR_END;
10361 #if 0
10362 (yyval.val) = dsym_node((yyvsp[(2) - (3)].val));
10363 #endif
10364 (yyval.val) = dispatch1(dyna_symbol, (yyvsp[(2) - (3)].val));
10365
10366 }
10367 break;
10368
10369 case 502:
10370
10371
10372 #line 4300 "ripper.y"
10373 {
10374 #if 0
10375 (yyval.val) = negate_lit((yyvsp[(2) - (2)].val));
10376 #endif
10377 (yyval.val) = dispatch2(unary, ripper_intern("-@"), (yyvsp[(2) - (2)].val));
10378
10379 }
10380 break;
10381
10382 case 512:
10383
10384
10385 #line 4322 "ripper.y"
10386 {ifndef_ripper((yyval.val) = keyword_nil);}
10387 break;
10388
10389 case 513:
10390
10391
10392 #line 4323 "ripper.y"
10393 {ifndef_ripper((yyval.val) = keyword_self);}
10394 break;
10395
10396 case 514:
10397
10398
10399 #line 4324 "ripper.y"
10400 {ifndef_ripper((yyval.val) = keyword_true);}
10401 break;
10402
10403 case 515:
10404
10405
10406 #line 4325 "ripper.y"
10407 {ifndef_ripper((yyval.val) = keyword_false);}
10408 break;
10409
10410 case 516:
10411
10412
10413 #line 4326 "ripper.y"
10414 {ifndef_ripper((yyval.val) = keyword__FILE__);}
10415 break;
10416
10417 case 517:
10418
10419
10420 #line 4327 "ripper.y"
10421 {ifndef_ripper((yyval.val) = keyword__LINE__);}
10422 break;
10423
10424 case 518:
10425
10426
10427 #line 4328 "ripper.y"
10428 {ifndef_ripper((yyval.val) = keyword__ENCODING__);}
10429 break;
10430
10431 case 519:
10432
10433
10434 #line 4332 "ripper.y"
10435 {
10436 #if 0
10437 if (!((yyval.val) = gettable((yyvsp[(1) - (1)].val)))) (yyval.val) = NEW_BEGIN(0);
10438 #endif
10439 if (id_is_var(get_id((yyvsp[(1) - (1)].val)))) {
10440 (yyval.val) = dispatch1(var_ref, (yyvsp[(1) - (1)].val));
10441 }
10442 else {
10443 (yyval.val) = dispatch1(vcall, (yyvsp[(1) - (1)].val));
10444 }
10445
10446 }
10447 break;
10448
10449 case 520:
10450
10451
10452 #line 4345 "ripper.y"
10453 {
10454 #if 0
10455 if (!((yyval.val) = gettable((yyvsp[(1) - (1)].val)))) (yyval.val) = NEW_BEGIN(0);
10456 #endif
10457 (yyval.val) = dispatch1(var_ref, (yyvsp[(1) - (1)].val));
10458
10459 }
10460 break;
10461
10462 case 521:
10463
10464
10465 #line 4355 "ripper.y"
10466 {
10467 (yyval.val) = assignable((yyvsp[(1) - (1)].val), 0);
10468 #if 0
10469 #endif
10470 (yyval.val) = dispatch1(var_field, (yyval.val));
10471
10472 }
10473 break;
10474
10475 case 522:
10476
10477
10478 #line 4363 "ripper.y"
10479 {
10480 (yyval.val) = assignable((yyvsp[(1) - (1)].val), 0);
10481 #if 0
10482 #endif
10483 (yyval.val) = dispatch1(var_field, (yyval.val));
10484
10485 }
10486 break;
10487
10488 case 525:
10489
10490
10491 #line 4377 "ripper.y"
10492 {
10493 #if 0
10494 (yyval.val) = 0;
10495 #endif
10496 (yyval.val) = Qnil;
10497
10498 }
10499 break;
10500
10501 case 526:
10502
10503
10504 #line 4385 "ripper.y"
10505 {
10506 lex_state = EXPR_BEG;
10507 command_start = TRUE;
10508 }
10509 break;
10510
10511 case 527:
10512
10513
10514 #line 4390 "ripper.y"
10515 {
10516 (yyval.val) = (yyvsp[(3) - (4)].val);
10517 }
10518 break;
10519
10520 case 528:
10521
10522
10523 #line 4394 "ripper.y"
10524 {
10525 #if 0
10526 yyerrok;
10527 (yyval.val) = 0;
10528 #endif
10529 yyerrok;
10530 (yyval.val) = Qnil;
10531
10532 }
10533 break;
10534
10535 case 529:
10536
10537
10538 #line 4406 "ripper.y"
10539 {
10540 #if 0
10541 (yyval.val) = (yyvsp[(2) - (3)].val);
10542 #endif
10543 (yyval.val) = dispatch1(paren, (yyvsp[(2) - (3)].val));
10544
10545 lex_state = EXPR_BEG;
10546 command_start = TRUE;
10547 }
10548 break;
10549
10550 case 530:
10551
10552
10553 #line 4415 "ripper.y"
10554 {
10555 (yyval.num) = parser->parser_in_kwarg;
10556 parser->parser_in_kwarg = 1;
10557 }
10558 break;
10559
10560 case 531:
10561
10562
10563 #line 4420 "ripper.y"
10564 {
10565 parser->parser_in_kwarg = (yyvsp[(1) - (3)].num);
10566 (yyval.val) = (yyvsp[(2) - (3)].val);
10567 lex_state = EXPR_BEG;
10568 command_start = TRUE;
10569 }
10570 break;
10571
10572 case 532:
10573
10574
10575 #line 4429 "ripper.y"
10576 {
10577 (yyval.val) = new_args_tail((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
10578 }
10579 break;
10580
10581 case 533:
10582
10583
10584 #line 4433 "ripper.y"
10585 {
10586 (yyval.val) = new_args_tail((yyvsp[(1) - (2)].val), Qnone, (yyvsp[(2) - (2)].val));
10587 }
10588 break;
10589
10590 case 534:
10591
10592
10593 #line 4437 "ripper.y"
10594 {
10595 (yyval.val) = new_args_tail(Qnone, (yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
10596 }
10597 break;
10598
10599 case 535:
10600
10601
10602 #line 4441 "ripper.y"
10603 {
10604 (yyval.val) = new_args_tail(Qnone, Qnone, (yyvsp[(1) - (1)].val));
10605 }
10606 break;
10607
10608 case 536:
10609
10610
10611 #line 4447 "ripper.y"
10612 {
10613 (yyval.val) = (yyvsp[(2) - (2)].val);
10614 }
10615 break;
10616
10617 case 537:
10618
10619
10620 #line 4451 "ripper.y"
10621 {
10622 (yyval.val) = new_args_tail(Qnone, Qnone, Qnone);
10623 }
10624 break;
10625
10626 case 538:
10627
10628
10629 #line 4457 "ripper.y"
10630 {
10631 (yyval.val) = new_args((yyvsp[(1) - (6)].val), (yyvsp[(3) - (6)].val), (yyvsp[(5) - (6)].val), Qnone, (yyvsp[(6) - (6)].val));
10632 }
10633 break;
10634
10635 case 539:
10636
10637
10638 #line 4461 "ripper.y"
10639 {
10640 (yyval.val) = new_args((yyvsp[(1) - (8)].val), (yyvsp[(3) - (8)].val), (yyvsp[(5) - (8)].val), (yyvsp[(7) - (8)].val), (yyvsp[(8) - (8)].val));
10641 }
10642 break;
10643
10644 case 540:
10645
10646
10647 #line 4465 "ripper.y"
10648 {
10649 (yyval.val) = new_args((yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val), Qnone, Qnone, (yyvsp[(4) - (4)].val));
10650 }
10651 break;
10652
10653 case 541:
10654
10655
10656 #line 4469 "ripper.y"
10657 {
10658 (yyval.val) = new_args((yyvsp[(1) - (6)].val), (yyvsp[(3) - (6)].val), Qnone, (yyvsp[(5) - (6)].val), (yyvsp[(6) - (6)].val));
10659 }
10660 break;
10661
10662 case 542:
10663
10664
10665 #line 4473 "ripper.y"
10666 {
10667 (yyval.val) = new_args((yyvsp[(1) - (4)].val), Qnone, (yyvsp[(3) - (4)].val), Qnone, (yyvsp[(4) - (4)].val));
10668 }
10669 break;
10670
10671 case 543:
10672
10673
10674 #line 4477 "ripper.y"
10675 {
10676 (yyval.val) = new_args((yyvsp[(1) - (6)].val), Qnone, (yyvsp[(3) - (6)].val), (yyvsp[(5) - (6)].val), (yyvsp[(6) - (6)].val));
10677 }
10678 break;
10679
10680 case 544:
10681
10682
10683 #line 4481 "ripper.y"
10684 {
10685 (yyval.val) = new_args((yyvsp[(1) - (2)].val), Qnone, Qnone, Qnone, (yyvsp[(2) - (2)].val));
10686 }
10687 break;
10688
10689 case 545:
10690
10691
10692 #line 4485 "ripper.y"
10693 {
10694 (yyval.val) = new_args(Qnone, (yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val), Qnone, (yyvsp[(4) - (4)].val));
10695 }
10696 break;
10697
10698 case 546:
10699
10700
10701 #line 4489 "ripper.y"
10702 {
10703 (yyval.val) = new_args(Qnone, (yyvsp[(1) - (6)].val), (yyvsp[(3) - (6)].val), (yyvsp[(5) - (6)].val), (yyvsp[(6) - (6)].val));
10704 }
10705 break;
10706
10707 case 547:
10708
10709
10710 #line 4493 "ripper.y"
10711 {
10712 (yyval.val) = new_args(Qnone, (yyvsp[(1) - (2)].val), Qnone, Qnone, (yyvsp[(2) - (2)].val));
10713 }
10714 break;
10715
10716 case 548:
10717
10718
10719 #line 4497 "ripper.y"
10720 {
10721 (yyval.val) = new_args(Qnone, (yyvsp[(1) - (4)].val), Qnone, (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
10722 }
10723 break;
10724
10725 case 549:
10726
10727
10728 #line 4501 "ripper.y"
10729 {
10730 (yyval.val) = new_args(Qnone, Qnone, (yyvsp[(1) - (2)].val), Qnone, (yyvsp[(2) - (2)].val));
10731 }
10732 break;
10733
10734 case 550:
10735
10736
10737 #line 4505 "ripper.y"
10738 {
10739 (yyval.val) = new_args(Qnone, Qnone, (yyvsp[(1) - (4)].val), (yyvsp[(3) - (4)].val), (yyvsp[(4) - (4)].val));
10740 }
10741 break;
10742
10743 case 551:
10744
10745
10746 #line 4509 "ripper.y"
10747 {
10748 (yyval.val) = new_args(Qnone, Qnone, Qnone, Qnone, (yyvsp[(1) - (1)].val));
10749 }
10750 break;
10751
10752 case 552:
10753
10754
10755 #line 4513 "ripper.y"
10756 {
10757 (yyval.val) = new_args_tail(Qnone, Qnone, Qnone);
10758 (yyval.val) = new_args(Qnone, Qnone, Qnone, Qnone, (yyval.val));
10759 }
10760 break;
10761
10762 case 553:
10763
10764
10765 #line 4520 "ripper.y"
10766 {
10767 #if 0
10768 yyerror("formal argument cannot be a constant");
10769 (yyval.val) = 0;
10770 #endif
10771 (yyval.val) = dispatch1(param_error, (yyvsp[(1) - (1)].val));
10772
10773 }
10774 break;
10775
10776 case 554:
10777
10778
10779 #line 4529 "ripper.y"
10780 {
10781 #if 0
10782 yyerror("formal argument cannot be an instance variable");
10783 (yyval.val) = 0;
10784 #endif
10785 (yyval.val) = dispatch1(param_error, (yyvsp[(1) - (1)].val));
10786
10787 }
10788 break;
10789
10790 case 555:
10791
10792
10793 #line 4538 "ripper.y"
10794 {
10795 #if 0
10796 yyerror("formal argument cannot be a global variable");
10797 (yyval.val) = 0;
10798 #endif
10799 (yyval.val) = dispatch1(param_error, (yyvsp[(1) - (1)].val));
10800
10801 }
10802 break;
10803
10804 case 556:
10805
10806
10807 #line 4547 "ripper.y"
10808 {
10809 #if 0
10810 yyerror("formal argument cannot be a class variable");
10811 (yyval.val) = 0;
10812 #endif
10813 (yyval.val) = dispatch1(param_error, (yyvsp[(1) - (1)].val));
10814
10815 }
10816 break;
10817
10818 case 558:
10819
10820
10821 #line 4559 "ripper.y"
10822 {
10823 formal_argument(get_id((yyvsp[(1) - (1)].val)));
10824 (yyval.val) = (yyvsp[(1) - (1)].val);
10825 }
10826 break;
10827
10828 case 559:
10829
10830
10831 #line 4566 "ripper.y"
10832 {
10833 arg_var(get_id((yyvsp[(1) - (1)].val)));
10834 #if 0
10835 (yyval.val) = NEW_ARGS_AUX((yyvsp[(1) - (1)].val), 1);
10836 #endif
10837 (yyval.val) = get_value((yyvsp[(1) - (1)].val));
10838
10839 }
10840 break;
10841
10842 case 560:
10843
10844
10845 #line 4575 "ripper.y"
10846 {
10847 ID tid = internal_id();
10848 arg_var(tid);
10849 #if 0
10850 if (dyna_in_block()) {
10851 (yyvsp[(2) - (3)].val)->nd_value = NEW_DVAR(tid);
10852 }
10853 else {
10854 (yyvsp[(2) - (3)].val)->nd_value = NEW_LVAR(tid);
10855 }
10856 (yyval.val) = NEW_ARGS_AUX(tid, 1);
10857 (yyval.val)->nd_next = (yyvsp[(2) - (3)].val);
10858 #endif
10859 (yyval.val) = dispatch1(mlhs_paren, (yyvsp[(2) - (3)].val));
10860
10861 }
10862 break;
10863
10864 case 561:
10865
10866
10867 #line 4596 "ripper.y"
10868 {
10869 (yyval.val) = rb_ary_new3(1, (yyvsp[(1) - (1)].val));
10870 }
10871 break;
10872
10873 case 562:
10874
10875
10876 #line 4601 "ripper.y"
10877 {
10878 #if 0
10879 (yyval.val) = (yyvsp[(1) - (3)].val);
10880 (yyval.val)->nd_plen++;
10881 (yyval.val)->nd_next = block_append((yyval.val)->nd_next, (yyvsp[(3) - (3)].val)->nd_next);
10882 rb_gc_force_recycle((VALUE)(yyvsp[(3) - (3)].val));
10883 #endif
10884 (yyval.val) = rb_ary_push((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
10885
10886 }
10887 break;
10888
10889 case 563:
10890
10891
10892 #line 4615 "ripper.y"
10893 {
10894 arg_var(formal_argument(get_id((yyvsp[(1) - (1)].val))));
10895 (yyval.val) = (yyvsp[(1) - (1)].val);
10896 }
10897 break;
10898
10899 case 564:
10900
10901
10902 #line 4622 "ripper.y"
10903 {
10904 (yyval.val) = assignable((yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
10905 #if 0
10906 (yyval.val) = NEW_KW_ARG(0, (yyval.val));
10907 #endif
10908 (yyval.val) = rb_assoc_new((yyval.val), (yyvsp[(2) - (2)].val));
10909
10910 }
10911 break;
10912
10913 case 565:
10914
10915
10916 #line 4631 "ripper.y"
10917 {
10918 (yyval.val) = assignable((yyvsp[(1) - (1)].val), (NODE *)-1);
10919 #if 0
10920 (yyval.val) = NEW_KW_ARG(0, (yyval.val));
10921 #endif
10922 (yyval.val) = rb_assoc_new((yyval.val), 0);
10923
10924 }
10925 break;
10926
10927 case 566:
10928
10929
10930 #line 4642 "ripper.y"
10931 {
10932 (yyval.val) = assignable((yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
10933 #if 0
10934 (yyval.val) = NEW_KW_ARG(0, (yyval.val));
10935 #endif
10936 (yyval.val) = rb_assoc_new((yyval.val), (yyvsp[(2) - (2)].val));
10937
10938 }
10939 break;
10940
10941 case 567:
10942
10943
10944 #line 4651 "ripper.y"
10945 {
10946 (yyval.val) = assignable((yyvsp[(1) - (1)].val), (NODE *)-1);
10947 #if 0
10948 (yyval.val) = NEW_KW_ARG(0, (yyval.val));
10949 #endif
10950 (yyval.val) = rb_assoc_new((yyval.val), 0);
10951
10952 }
10953 break;
10954
10955 case 568:
10956
10957
10958 #line 4662 "ripper.y"
10959 {
10960 #if 0
10961 (yyval.val) = (yyvsp[(1) - (1)].val);
10962 #endif
10963 (yyval.val) = rb_ary_new3(1, (yyvsp[(1) - (1)].val));
10964
10965 }
10966 break;
10967
10968 case 569:
10969
10970
10971 #line 4670 "ripper.y"
10972 {
10973 #if 0
10974 NODE *kws = (yyvsp[(1) - (3)].val);
10975
10976 while (kws->nd_next) {
10977 kws = kws->nd_next;
10978 }
10979 kws->nd_next = (yyvsp[(3) - (3)].val);
10980 (yyval.val) = (yyvsp[(1) - (3)].val);
10981 #endif
10982 (yyval.val) = rb_ary_push((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
10983
10984 }
10985 break;
10986
10987 case 570:
10988
10989
10990 #line 4687 "ripper.y"
10991 {
10992 #if 0
10993 (yyval.val) = (yyvsp[(1) - (1)].val);
10994 #endif
10995 (yyval.val) = rb_ary_new3(1, (yyvsp[(1) - (1)].val));
10996
10997 }
10998 break;
10999
11000 case 571:
11001
11002
11003 #line 4695 "ripper.y"
11004 {
11005 #if 0
11006 NODE *kws = (yyvsp[(1) - (3)].val);
11007
11008 while (kws->nd_next) {
11009 kws = kws->nd_next;
11010 }
11011 kws->nd_next = (yyvsp[(3) - (3)].val);
11012 (yyval.val) = (yyvsp[(1) - (3)].val);
11013 #endif
11014 (yyval.val) = rb_ary_push((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
11015
11016 }
11017 break;
11018
11019 case 574:
11020
11021
11022 #line 4715 "ripper.y"
11023 {
11024 shadowing_lvar(get_id((yyvsp[(2) - (2)].val)));
11025 (yyval.val) = (yyvsp[(2) - (2)].val);
11026 }
11027 break;
11028
11029 case 575:
11030
11031
11032 #line 4720 "ripper.y"
11033 {
11034 (yyval.val) = internal_id();
11035 }
11036 break;
11037
11038 case 576:
11039
11040
11041 #line 4726 "ripper.y"
11042 {
11043 arg_var(get_id((yyvsp[(1) - (3)].val)));
11044 (yyval.val) = assignable((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
11045 #if 0
11046 (yyval.val) = NEW_OPT_ARG(0, (yyval.val));
11047 #endif
11048 (yyval.val) = rb_assoc_new((yyval.val), (yyvsp[(3) - (3)].val));
11049
11050 }
11051 break;
11052
11053 case 577:
11054
11055
11056 #line 4738 "ripper.y"
11057 {
11058 arg_var(get_id((yyvsp[(1) - (3)].val)));
11059 (yyval.val) = assignable((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
11060 #if 0
11061 (yyval.val) = NEW_OPT_ARG(0, (yyval.val));
11062 #endif
11063 (yyval.val) = rb_assoc_new((yyval.val), (yyvsp[(3) - (3)].val));
11064
11065 }
11066 break;
11067
11068 case 578:
11069
11070
11071 #line 4750 "ripper.y"
11072 {
11073 #if 0
11074 (yyval.val) = (yyvsp[(1) - (1)].val);
11075 #endif
11076 (yyval.val) = rb_ary_new3(1, (yyvsp[(1) - (1)].val));
11077
11078 }
11079 break;
11080
11081 case 579:
11082
11083
11084 #line 4758 "ripper.y"
11085 {
11086 #if 0
11087 NODE *opts = (yyvsp[(1) - (3)].val);
11088
11089 while (opts->nd_next) {
11090 opts = opts->nd_next;
11091 }
11092 opts->nd_next = (yyvsp[(3) - (3)].val);
11093 (yyval.val) = (yyvsp[(1) - (3)].val);
11094 #endif
11095 (yyval.val) = rb_ary_push((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
11096
11097 }
11098 break;
11099
11100 case 580:
11101
11102
11103 #line 4774 "ripper.y"
11104 {
11105 #if 0
11106 (yyval.val) = (yyvsp[(1) - (1)].val);
11107 #endif
11108 (yyval.val) = rb_ary_new3(1, (yyvsp[(1) - (1)].val));
11109
11110 }
11111 break;
11112
11113 case 581:
11114
11115
11116 #line 4782 "ripper.y"
11117 {
11118 #if 0
11119 NODE *opts = (yyvsp[(1) - (3)].val);
11120
11121 while (opts->nd_next) {
11122 opts = opts->nd_next;
11123 }
11124 opts->nd_next = (yyvsp[(3) - (3)].val);
11125 (yyval.val) = (yyvsp[(1) - (3)].val);
11126 #endif
11127 (yyval.val) = rb_ary_push((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
11128
11129 }
11130 break;
11131
11132 case 584:
11133
11134
11135 #line 4802 "ripper.y"
11136 {
11137 #if 0
11138 if (!is_local_id((yyvsp[(2) - (2)].val)))
11139 yyerror("rest argument must be local variable");
11140 #endif
11141 arg_var(shadowing_lvar(get_id((yyvsp[(2) - (2)].val))));
11142 #if 0
11143 (yyval.val) = (yyvsp[(2) - (2)].val);
11144 #endif
11145 (yyval.val) = dispatch1(rest_param, (yyvsp[(2) - (2)].val));
11146
11147 }
11148 break;
11149
11150 case 585:
11151
11152
11153 #line 4815 "ripper.y"
11154 {
11155 #if 0
11156 (yyval.val) = internal_id();
11157 arg_var((yyval.val));
11158 #endif
11159 (yyval.val) = dispatch1(rest_param, Qnil);
11160
11161 }
11162 break;
11163
11164 case 588:
11165
11166
11167 #line 4830 "ripper.y"
11168 {
11169 #if 0
11170 if (!is_local_id((yyvsp[(2) - (2)].val)))
11171 yyerror("block argument must be local variable");
11172 else if (!dyna_in_block() && local_id((yyvsp[(2) - (2)].val)))
11173 yyerror("duplicated block argument name");
11174 #endif
11175 arg_var(shadowing_lvar(get_id((yyvsp[(2) - (2)].val))));
11176 #if 0
11177 (yyval.val) = (yyvsp[(2) - (2)].val);
11178 #endif
11179 (yyval.val) = dispatch1(blockarg, (yyvsp[(2) - (2)].val));
11180
11181 }
11182 break;
11183
11184 case 589:
11185
11186
11187 #line 4847 "ripper.y"
11188 {
11189 (yyval.val) = (yyvsp[(2) - (2)].val);
11190 }
11191 break;
11192
11193 case 590:
11194
11195
11196 #line 4851 "ripper.y"
11197 {
11198 #if 0
11199 (yyval.val) = 0;
11200 #endif
11201 (yyval.val) = Qundef;
11202
11203 }
11204 break;
11205
11206 case 591:
11207
11208
11209 #line 4861 "ripper.y"
11210 {
11211 #if 0
11212 value_expr((yyvsp[(1) - (1)].val));
11213 (yyval.val) = (yyvsp[(1) - (1)].val);
11214 if (!(yyval.val)) (yyval.val) = NEW_NIL();
11215 #endif
11216 (yyval.val) = (yyvsp[(1) - (1)].val);
11217
11218 }
11219 break;
11220
11221 case 592:
11222
11223
11224 #line 4870 "ripper.y"
11225 {lex_state = EXPR_BEG;}
11226 break;
11227
11228 case 593:
11229
11230
11231 #line 4871 "ripper.y"
11232 {
11233 #if 0
11234 if ((yyvsp[(3) - (4)].val) == 0) {
11235 yyerror("can't define singleton method for ().");
11236 }
11237 else {
11238 switch (nd_type((yyvsp[(3) - (4)].val))) {
11239 case NODE_STR:
11240 case NODE_DSTR:
11241 case NODE_XSTR:
11242 case NODE_DXSTR:
11243 case NODE_DREGX:
11244 case NODE_LIT:
11245 case NODE_ARRAY:
11246 case NODE_ZARRAY:
11247 yyerror("can't define singleton method for literals");
11248 default:
11249 value_expr((yyvsp[(3) - (4)].val));
11250 break;
11251 }
11252 }
11253 (yyval.val) = (yyvsp[(3) - (4)].val);
11254 #endif
11255 (yyval.val) = dispatch1(paren, (yyvsp[(3) - (4)].val));
11256
11257 }
11258 break;
11259
11260 case 595:
11261
11262
11263 #line 4901 "ripper.y"
11264 {
11265 #if 0
11266 (yyval.val) = (yyvsp[(1) - (2)].val);
11267 #endif
11268 (yyval.val) = dispatch1(assoclist_from_args, (yyvsp[(1) - (2)].val));
11269
11270 }
11271 break;
11272
11273 case 596:
11274
11275
11276 #line 4913 "ripper.y"
11277 {
11278 (yyval.val) = rb_ary_new3(1, (yyvsp[(1) - (1)].val));
11279 }
11280 break;
11281
11282 case 597:
11283
11284
11285 #line 4918 "ripper.y"
11286 {
11287 #if 0
11288 (yyval.val) = list_concat((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
11289 #endif
11290 (yyval.val) = rb_ary_push((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
11291
11292 }
11293 break;
11294
11295 case 598:
11296
11297
11298 #line 4928 "ripper.y"
11299 {
11300 #if 0
11301 if (nd_type((yyvsp[(1) - (3)].val)) == NODE_STR) {
11302 nd_set_type((yyvsp[(1) - (3)].val), NODE_LIT);
11303 (yyvsp[(1) - (3)].val)->nd_lit = rb_fstring((yyvsp[(1) - (3)].val)->nd_lit);
11304 }
11305 (yyval.val) = list_append(NEW_LIST((yyvsp[(1) - (3)].val)), (yyvsp[(3) - (3)].val));
11306 #endif
11307 (yyval.val) = dispatch2(assoc_new, (yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
11308
11309 }
11310 break;
11311
11312 case 599:
11313
11314
11315 #line 4940 "ripper.y"
11316 {
11317 #if 0
11318 (yyval.val) = list_append(NEW_LIST(NEW_LIT(ID2SYM((yyvsp[(1) - (2)].val)))), (yyvsp[(2) - (2)].val));
11319 #endif
11320 (yyval.val) = dispatch2(assoc_new, (yyvsp[(1) - (2)].val), (yyvsp[(2) - (2)].val));
11321
11322 }
11323 break;
11324
11325 case 600:
11326
11327
11328 #line 4948 "ripper.y"
11329 {
11330 #if 0
11331 (yyval.val) = list_append(NEW_LIST(0), (yyvsp[(2) - (2)].val));
11332 #endif
11333 (yyval.val) = dispatch1(assoc_splat, (yyvsp[(2) - (2)].val));
11334
11335 }
11336 break;
11337
11338 case 611:
11339
11340
11341 #line 4978 "ripper.y"
11342 { (yyval.val) = (yyvsp[(1) - (1)].val); }
11343 break;
11344
11345 case 612:
11346
11347
11348 #line 4983 "ripper.y"
11349 { (yyval.val) = (yyvsp[(1) - (1)].val); }
11350 break;
11351
11352 case 622:
11353
11354
11355 #line 5006 "ripper.y"
11356 {yyerrok;}
11357 break;
11358
11359 case 625:
11360
11361
11362 #line 5011 "ripper.y"
11363 {yyerrok;}
11364 break;
11365
11366 case 626:
11367
11368
11369 #line 5015 "ripper.y"
11370 {
11371 #if 0
11372 (yyval.val) = 0;
11373 #endif
11374 (yyval.val) = Qundef;
11375
11376 }
11377 break;
11378
11379
11380
11381
11382 #line 11381 "parse.c"
11383 default: break;
11384 }
11385
11386
11387
11388
11389
11390
11391
11392
11393
11394
11395
11396 YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
11397
11398 YYPOPSTACK (yylen);
11399 yylen = 0;
11400 YY_STACK_PRINT (yyss, yyssp);
11401
11402 *++yyvsp = yyval;
11403
11404
11405
11406
11407
11408 yyn = yyr1[yyn];
11409
11410 yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
11411 if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
11412 yystate = yytable[yystate];
11413 else
11414 yystate = yydefgoto[yyn - YYNTOKENS];
11415
11416 goto yynewstate;
11417
11418
11419
11420
11421
11422 yyerrlab:
11423
11424
11425 yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar);
11426
11427
11428 if (!yyerrstatus)
11429 {
11430 ++yynerrs;
11431 #if ! YYERROR_VERBOSE
11432 parser_yyerror (parser, YY_("syntax error"));
11433 #else
11434 # define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \
11435 yyssp, yytoken)
11436 {
11437 char const *yymsgp = YY_("syntax error");
11438 int yysyntax_error_status;
11439 yysyntax_error_status = YYSYNTAX_ERROR;
11440 if (yysyntax_error_status == 0)
11441 yymsgp = yymsg;
11442 else if (yysyntax_error_status == 1)
11443 {
11444 if (yymsg != yymsgbuf)
11445 YYSTACK_FREE (yymsg);
11446 yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc);
11447 if (!yymsg)
11448 {
11449 yymsg = yymsgbuf;
11450 yymsg_alloc = sizeof yymsgbuf;
11451 yysyntax_error_status = 2;
11452 }
11453 else
11454 {
11455 yysyntax_error_status = YYSYNTAX_ERROR;
11456 yymsgp = yymsg;
11457 }
11458 }
11459 parser_yyerror (parser, yymsgp);
11460 if (yysyntax_error_status == 2)
11461 goto yyexhaustedlab;
11462 }
11463 # undef YYSYNTAX_ERROR
11464 #endif
11465 }
11466
11467
11468
11469 if (yyerrstatus == 3)
11470 {
11471
11472
11473
11474 if (yychar <= YYEOF)
11475 {
11476
11477 if (yychar == YYEOF)
11478 YYABORT;
11479 }
11480 else
11481 {
11482 yydestruct ("Error: discarding",
11483 yytoken, &yylval, parser);
11484 yychar = YYEMPTY;
11485 }
11486 }
11487
11488
11489
11490 goto yyerrlab1;
11491
11492
11493
11494
11495
11496 yyerrorlab:
11497
11498
11499
11500
11501 if ( 0)
11502 goto yyerrorlab;
11503
11504
11505
11506 YYPOPSTACK (yylen);
11507 yylen = 0;
11508 YY_STACK_PRINT (yyss, yyssp);
11509 yystate = *yyssp;
11510 goto yyerrlab1;
11511
11512
11513
11514
11515
11516 yyerrlab1:
11517 yyerrstatus = 3;
11518
11519 for (;;)
11520 {
11521 yyn = yypact[yystate];
11522 if (!yypact_value_is_default (yyn))
11523 {
11524 yyn += YYTERROR;
11525 if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
11526 {
11527 yyn = yytable[yyn];
11528 if (0 < yyn)
11529 break;
11530 }
11531 }
11532
11533
11534 if (yyssp == yyss)
11535 YYABORT;
11536
11537
11538 yydestruct ("Error: popping",
11539 yystos[yystate], yyvsp, parser);
11540 YYPOPSTACK (1);
11541 yystate = *yyssp;
11542 YY_STACK_PRINT (yyss, yyssp);
11543 }
11544
11545 *++yyvsp = yylval;
11546
11547
11548
11549 YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
11550
11551 yystate = yyn;
11552 goto yynewstate;
11553
11554
11555
11556
11557
11558 yyacceptlab:
11559 yyresult = 0;
11560 goto yyreturn;
11561
11562
11563
11564
11565 yyabortlab:
11566 yyresult = 1;
11567 goto yyreturn;
11568
11569 #if !defined(yyoverflow) || YYERROR_VERBOSE
11570
11571
11572
11573 yyexhaustedlab:
11574 parser_yyerror (parser, YY_("memory exhausted"));
11575 yyresult = 2;
11576
11577 #endif
11578
11579 yyreturn:
11580 if (yychar != YYEMPTY)
11581 {
11582
11583
11584 yytoken = YYTRANSLATE (yychar);
11585 yydestruct ("Cleanup: discarding lookahead",
11586 yytoken, &yylval, parser);
11587 }
11588
11589
11590 YYPOPSTACK (yylen);
11591 YY_STACK_PRINT (yyss, yyssp);
11592 while (yyssp != yyss)
11593 {
11594 yydestruct ("Cleanup: popping",
11595 yystos[*yyssp], yyvsp, parser);
11596 YYPOPSTACK (1);
11597 }
11598 #ifndef yyoverflow
11599 if (yyss != yyssa)
11600 YYSTACK_FREE (yyss);
11601 #endif
11602 #if YYERROR_VERBOSE
11603 if (yymsg != yymsgbuf)
11604 YYSTACK_FREE (yymsg);
11605 #endif
11606
11607 return YYID (yyresult);
11608 }
11609
11610
11611
11612
11613 #line 5023 "ripper.y"
11614
11615 # undef parser
11616 # undef yylex
11617 # undef yylval
11618 # define yylval (*((YYSTYPE*)(parser->parser_yylval)))
11619
11620 static int parser_regx_options(struct parser_params*);
11621 static int parser_tokadd_string(struct parser_params*,int,int,int,long*,rb_encoding**);
11622 static void parser_tokaddmbc(struct parser_params *parser, int c, rb_encoding *enc);
11623 static int parser_parse_string(struct parser_params*,NODE*);
11624 static int parser_here_document(struct parser_params*,NODE*);
11625
11626
11627 # define nextc() parser_nextc(parser)
11628 # define pushback(c) parser_pushback(parser, (c))
11629 # define newtok() parser_newtok(parser)
11630 # define tokspace(n) parser_tokspace(parser, (n))
11631 # define tokadd(c) parser_tokadd(parser, (c))
11632 # define tok_hex(numlen) parser_tok_hex(parser, (numlen))
11633 # define read_escape(flags,e) parser_read_escape(parser, (flags), (e))
11634 # define tokadd_escape(e) parser_tokadd_escape(parser, (e))
11635 # define regx_options() parser_regx_options(parser)
11636 # define tokadd_string(f,t,p,n,e) parser_tokadd_string(parser,(f),(t),(p),(n),(e))
11637 # define parse_string(n) parser_parse_string(parser,(n))
11638 # define tokaddmbc(c, enc) parser_tokaddmbc(parser, (c), (enc))
11639 # define here_document(n) parser_here_document(parser,(n))
11640 # define heredoc_identifier() parser_heredoc_identifier(parser)
11641 # define heredoc_restore(n) parser_heredoc_restore(parser,(n))
11642 # define whole_match_p(e,l,i) parser_whole_match_p(parser,(e),(l),(i))
11643 # define number_literal_suffix(f) parser_number_literal_suffix(parser, (f))
11644 # define set_number_literal(v, t, f) parser_set_number_literal(parser, (v), (t), (f))
11645 # define set_integer_literal(v, f) parser_set_integer_literal(parser, (v), (f))
11646
11647 #ifndef RIPPER
11648 # define set_yylval_str(x) (yylval.node = NEW_STR(x))
11649 # define set_yylval_num(x) (yylval.num = (x))
11650 # define set_yylval_id(x) (yylval.id = (x))
11651 # define set_yylval_name(x) (yylval.id = (x))
11652 # define set_yylval_literal(x) (yylval.node = NEW_LIT(x))
11653 # define set_yylval_node(x) (yylval.node = (x))
11654 # define yylval_id() (yylval.id)
11655 #else
11656 static inline VALUE
11657 ripper_yylval_id(ID x)
11658 {
11659 return (VALUE)NEW_LASGN(x, ID2SYM(x));
11660 }
11661 # define set_yylval_str(x) (void)(x)
11662 # define set_yylval_num(x) (void)(x)
11663 # define set_yylval_id(x) (void)(x)
11664 # define set_yylval_name(x) (void)(yylval.val = ripper_yylval_id(x))
11665 # define set_yylval_literal(x) (void)(x)
11666 # define set_yylval_node(x) (void)(x)
11667 # define yylval_id() yylval.id
11668 #endif
11669
11670 #ifndef RIPPER
11671 #define ripper_flush(p) (void)(p)
11672 #else
11673 #define ripper_flush(p) ((p)->tokp = (p)->parser_lex_p)
11674
11675 #define yylval_rval (*(RB_TYPE_P(yylval.val, T_NODE) ? &yylval.node->nd_rval : &yylval.val))
11676
11677 static int
11678 ripper_has_scan_event(struct parser_params *parser)
11679 {
11680
11681 if (lex_p < parser->tokp) rb_raise(rb_eRuntimeError, "lex_p < tokp");
11682 return lex_p > parser->tokp;
11683 }
11684
11685 static VALUE
11686 ripper_scan_event_val(struct parser_params *parser, int t)
11687 {
11688 VALUE str = STR_NEW(parser->tokp, lex_p - parser->tokp);
11689 VALUE rval = ripper_dispatch1(parser, ripper_token2eventid(t), str);
11690 ripper_flush(parser);
11691 return rval;
11692 }
11693
11694 static void
11695 ripper_dispatch_scan_event(struct parser_params *parser, int t)
11696 {
11697 if (!ripper_has_scan_event(parser)) return;
11698 yylval_rval = ripper_scan_event_val(parser, t);
11699 }
11700
11701 static void
11702 ripper_dispatch_ignored_scan_event(struct parser_params *parser, int t)
11703 {
11704 if (!ripper_has_scan_event(parser)) return;
11705 (void)ripper_scan_event_val(parser, t);
11706 }
11707
11708 static void
11709 ripper_dispatch_delayed_token(struct parser_params *parser, int t)
11710 {
11711 int saved_line = ruby_sourceline;
11712 const char *saved_tokp = parser->tokp;
11713
11714 ruby_sourceline = parser->delayed_line;
11715 parser->tokp = lex_pbeg + parser->delayed_col;
11716 yylval_rval = ripper_dispatch1(parser, ripper_token2eventid(t), parser->delayed);
11717 parser->delayed = Qnil;
11718 ruby_sourceline = saved_line;
11719 parser->tokp = saved_tokp;
11720 }
11721 #endif
11722
11723 #include "ruby/regex.h"
11724 #include "ruby/util.h"
11725
11726
11727
11728
11729
11730 #undef SIGN_EXTEND_CHAR
11731 #if __STDC__
11732 # define SIGN_EXTEND_CHAR(c) ((signed char)(c))
11733 #else
11734
11735 # define SIGN_EXTEND_CHAR(c) ((((unsigned char)(c)) ^ 128) - 128)
11736 #endif
11737
11738 #define parser_encoding_name() (current_enc->name)
11739 #define parser_mbclen() mbclen((lex_p-1),lex_pend,current_enc)
11740 #define parser_precise_mbclen() rb_enc_precise_mbclen((lex_p-1),lex_pend,current_enc)
11741 #define is_identchar(p,e,enc) (rb_enc_isalnum((unsigned char)(*(p)),(enc)) || (*(p)) == '_' || !ISASCII(*(p)))
11742 #define parser_is_identchar() (!parser->eofp && is_identchar((lex_p-1),lex_pend,current_enc))
11743
11744 #define parser_isascii() ISASCII(*(lex_p-1))
11745
11746 #ifndef RIPPER
11747 static int
11748 token_info_get_column(struct parser_params *parser, const char *token)
11749 {
11750 int column = 1;
11751 const char *p, *pend = lex_p - strlen(token);
11752 for (p = lex_pbeg; p < pend; p++) {
11753 if (*p == '\t') {
11754 column = (((column - 1) / 8) + 1) * 8;
11755 }
11756 column++;
11757 }
11758 return column;
11759 }
11760
11761 static int
11762 token_info_has_nonspaces(struct parser_params *parser, const char *token)
11763 {
11764 const char *p, *pend = lex_p - strlen(token);
11765 for (p = lex_pbeg; p < pend; p++) {
11766 if (*p != ' ' && *p != '\t') {
11767 return 1;
11768 }
11769 }
11770 return 0;
11771 }
11772
11773 #undef token_info_push
11774 static void
11775 token_info_push(struct parser_params *parser, const char *token)
11776 {
11777 token_info *ptinfo;
11778
11779 if (!parser->parser_token_info_enabled) return;
11780 ptinfo = ALLOC(token_info);
11781 ptinfo->token = token;
11782 ptinfo->linenum = ruby_sourceline;
11783 ptinfo->column = token_info_get_column(parser, token);
11784 ptinfo->nonspc = token_info_has_nonspaces(parser, token);
11785 ptinfo->next = parser->parser_token_info;
11786
11787 parser->parser_token_info = ptinfo;
11788 }
11789
11790 #undef token_info_pop
11791 static void
11792 token_info_pop(struct parser_params *parser, const char *token)
11793 {
11794 int linenum;
11795 token_info *ptinfo = parser->parser_token_info;
11796
11797 if (!ptinfo) return;
11798 parser->parser_token_info = ptinfo->next;
11799 if (token_info_get_column(parser, token) == ptinfo->column) {
11800 goto finish;
11801 }
11802 linenum = ruby_sourceline;
11803 if (linenum == ptinfo->linenum) {
11804 goto finish;
11805 }
11806 if (token_info_has_nonspaces(parser, token) || ptinfo->nonspc) {
11807 goto finish;
11808 }
11809 if (parser->parser_token_info_enabled) {
11810 rb_compile_warn(ruby_sourcefile, linenum,
11811 "mismatched indentations at '%s' with '%s' at %d",
11812 token, ptinfo->token, ptinfo->linenum);
11813 }
11814
11815 finish:
11816 xfree(ptinfo);
11817 }
11818 #endif
11819
11820 static int
11821 parser_yyerror(struct parser_params *parser, const char *msg)
11822 {
11823 #ifndef RIPPER
11824 const int max_line_margin = 30;
11825 const char *p, *pe;
11826 char *buf;
11827 long len;
11828 int i;
11829
11830 compile_error(PARSER_ARG "%s", msg);
11831 p = lex_p;
11832 while (lex_pbeg <= p) {
11833 if (*p == '\n') break;
11834 p--;
11835 }
11836 p++;
11837
11838 pe = lex_p;
11839 while (pe < lex_pend) {
11840 if (*pe == '\n') break;
11841 pe++;
11842 }
11843
11844 len = pe - p;
11845 if (len > 4) {
11846 char *p2;
11847 const char *pre = "", *post = "";
11848
11849 if (len > max_line_margin * 2 + 10) {
11850 if (lex_p - p > max_line_margin) {
11851 p = rb_enc_prev_char(p, lex_p - max_line_margin, pe, rb_enc_get(lex_lastline));
11852 pre = "...";
11853 }
11854 if (pe - lex_p > max_line_margin) {
11855 pe = rb_enc_prev_char(lex_p, lex_p + max_line_margin, pe, rb_enc_get(lex_lastline));
11856 post = "...";
11857 }
11858 len = pe - p;
11859 }
11860 buf = ALLOCA_N(char, len+2);
11861 MEMCPY(buf, p, char, len);
11862 buf[len] = '\0';
11863 rb_compile_error_with_enc(NULL, 0, (void *)current_enc, "%s%s%s", pre, buf, post);
11864
11865 i = (int)(lex_p - p);
11866 p2 = buf; pe = buf + len;
11867
11868 while (p2 < pe) {
11869 if (*p2 != '\t') *p2 = ' ';
11870 p2++;
11871 }
11872 buf[i] = '^';
11873 buf[i+1] = '\0';
11874 rb_compile_error_append("%s%s", pre, buf);
11875 }
11876 #else
11877 dispatch1(parse_error, STR_NEW2(msg));
11878 #endif
11879 return 0;
11880 }
11881
11882 static void parser_prepare(struct parser_params *parser);
11883
11884 #ifndef RIPPER
11885 static VALUE
11886 debug_lines(VALUE fname)
11887 {
11888 ID script_lines;
11889 CONST_ID(script_lines, "SCRIPT_LINES__");
11890 if (rb_const_defined_at(rb_cObject, script_lines)) {
11891 VALUE hash = rb_const_get_at(rb_cObject, script_lines);
11892 if (RB_TYPE_P(hash, T_HASH)) {
11893 VALUE lines = rb_ary_new();
11894 rb_hash_aset(hash, fname, lines);
11895 return lines;
11896 }
11897 }
11898 return 0;
11899 }
11900
11901 static VALUE
11902 coverage(VALUE fname, int n)
11903 {
11904 VALUE coverages = rb_get_coverages();
11905 if (RTEST(coverages) && RBASIC(coverages)->klass == 0) {
11906 VALUE lines = rb_ary_new2(n);
11907 int i;
11908 RBASIC_CLEAR_CLASS(lines);
11909 for (i = 0; i < n; i++) RARRAY_ASET(lines, i, Qnil);
11910 RARRAY(lines)->as.heap.len = n;
11911 rb_hash_aset(coverages, fname, lines);
11912 return lines;
11913 }
11914 return 0;
11915 }
11916
11917 static int
11918 e_option_supplied(struct parser_params *parser)
11919 {
11920 return strcmp(ruby_sourcefile, "-e") == 0;
11921 }
11922
11923 static VALUE
11924 yycompile0(VALUE arg)
11925 {
11926 int n;
11927 NODE *tree;
11928 struct parser_params *parser = (struct parser_params *)arg;
11929
11930 if (!compile_for_eval && rb_safe_level() == 0) {
11931 ruby_debug_lines = debug_lines(ruby_sourcefile_string);
11932 if (ruby_debug_lines && ruby_sourceline > 0) {
11933 VALUE str = STR_NEW0();
11934 n = ruby_sourceline;
11935 do {
11936 rb_ary_push(ruby_debug_lines, str);
11937 } while (--n);
11938 }
11939
11940 if (!e_option_supplied(parser)) {
11941 ruby_coverage = coverage(ruby_sourcefile_string, ruby_sourceline);
11942 }
11943 }
11944 parser->last_cr_line = ruby_sourceline - 1;
11945
11946 parser_prepare(parser);
11947 deferred_nodes = 0;
11948 #ifndef RIPPER
11949 parser->parser_token_info_enabled = !compile_for_eval && RTEST(ruby_verbose);
11950 #endif
11951 #ifndef RIPPER
11952 if (RUBY_DTRACE_PARSE_BEGIN_ENABLED()) {
11953 RUBY_DTRACE_PARSE_BEGIN(parser->parser_ruby_sourcefile,
11954 parser->parser_ruby_sourceline);
11955 }
11956 #endif
11957 n = yyparse((void*)parser);
11958 #ifndef RIPPER
11959 if (RUBY_DTRACE_PARSE_END_ENABLED()) {
11960 RUBY_DTRACE_PARSE_END(parser->parser_ruby_sourcefile,
11961 parser->parser_ruby_sourceline);
11962 }
11963 #endif
11964 ruby_debug_lines = 0;
11965 ruby_coverage = 0;
11966 compile_for_eval = 0;
11967
11968 lex_strterm = 0;
11969 lex_p = lex_pbeg = lex_pend = 0;
11970 lex_lastline = lex_nextline = 0;
11971 if (parser->nerr) {
11972 return 0;
11973 }
11974 tree = ruby_eval_tree;
11975 if (!tree) {
11976 tree = NEW_NIL();
11977 }
11978 else if (ruby_eval_tree_begin) {
11979 tree->nd_body = NEW_PRELUDE(ruby_eval_tree_begin, tree->nd_body);
11980 }
11981 return (VALUE)tree;
11982 }
11983
11984 static NODE*
11985 yycompile(struct parser_params *parser, VALUE fname, int line)
11986 {
11987 ruby_sourcefile_string = rb_str_new_frozen(fname);
11988 ruby_sourcefile = RSTRING_PTR(fname);
11989 ruby_sourceline = line - 1;
11990 return (NODE *)rb_suppress_tracing(yycompile0, (VALUE)parser);
11991 }
11992 #endif
11993
11994 static rb_encoding *
11995 must_be_ascii_compatible(VALUE s)
11996 {
11997 rb_encoding *enc = rb_enc_get(s);
11998 if (!rb_enc_asciicompat(enc)) {
11999 rb_raise(rb_eArgError, "invalid source encoding");
12000 }
12001 return enc;
12002 }
12003
12004 static VALUE
12005 lex_get_str(struct parser_params *parser, VALUE s)
12006 {
12007 char *beg, *end, *pend;
12008 rb_encoding *enc = must_be_ascii_compatible(s);
12009
12010 beg = RSTRING_PTR(s);
12011 if (lex_gets_ptr) {
12012 if (RSTRING_LEN(s) == lex_gets_ptr) return Qnil;
12013 beg += lex_gets_ptr;
12014 }
12015 pend = RSTRING_PTR(s) + RSTRING_LEN(s);
12016 end = beg;
12017 while (end < pend) {
12018 if (*end++ == '\n') break;
12019 }
12020 lex_gets_ptr = end - RSTRING_PTR(s);
12021 return rb_enc_str_new(beg, end - beg, enc);
12022 }
12023
12024 static VALUE
12025 lex_getline(struct parser_params *parser)
12026 {
12027 VALUE line = (*parser->parser_lex_gets)(parser, parser->parser_lex_input);
12028 if (NIL_P(line)) return line;
12029 must_be_ascii_compatible(line);
12030 #ifndef RIPPER
12031 if (ruby_debug_lines) {
12032 rb_enc_associate(line, current_enc);
12033 rb_ary_push(ruby_debug_lines, line);
12034 }
12035 if (ruby_coverage) {
12036 rb_ary_push(ruby_coverage, Qnil);
12037 }
12038 #endif
12039 return line;
12040 }
12041
12042 #ifdef RIPPER
12043 static rb_data_type_t parser_data_type;
12044 #else
12045 static const rb_data_type_t parser_data_type;
12046
12047 static NODE*
12048 parser_compile_string(volatile VALUE vparser, VALUE fname, VALUE s, int line)
12049 {
12050 struct parser_params *parser;
12051 NODE *node;
12052
12053 TypedData_Get_Struct(vparser, struct parser_params, &parser_data_type, parser);
12054 lex_gets = lex_get_str;
12055 lex_gets_ptr = 0;
12056 lex_input = s;
12057 lex_pbeg = lex_p = lex_pend = 0;
12058 compile_for_eval = rb_parse_in_eval();
12059
12060 node = yycompile(parser, fname, line);
12061 RB_GC_GUARD(vparser);
12062
12063 return node;
12064 }
12065
12066 NODE*
12067 rb_compile_string(const char *f, VALUE s, int line)
12068 {
12069 must_be_ascii_compatible(s);
12070 return parser_compile_string(rb_parser_new(), rb_filesystem_str_new_cstr(f), s, line);
12071 }
12072
12073 NODE*
12074 rb_parser_compile_string(volatile VALUE vparser, const char *f, VALUE s, int line)
12075 {
12076 return rb_parser_compile_string_path(vparser, rb_filesystem_str_new_cstr(f), s, line);
12077 }
12078
12079 NODE*
12080 rb_parser_compile_string_path(volatile VALUE vparser, VALUE f, VALUE s, int line)
12081 {
12082 must_be_ascii_compatible(s);
12083 return parser_compile_string(vparser, f, s, line);
12084 }
12085
12086 NODE*
12087 rb_compile_cstr(const char *f, const char *s, int len, int line)
12088 {
12089 VALUE str = rb_str_new(s, len);
12090 return parser_compile_string(rb_parser_new(), rb_filesystem_str_new_cstr(f), str, line);
12091 }
12092
12093 NODE*
12094 rb_parser_compile_cstr(volatile VALUE vparser, const char *f, const char *s, int len, int line)
12095 {
12096 VALUE str = rb_str_new(s, len);
12097 return parser_compile_string(vparser, rb_filesystem_str_new_cstr(f), str, line);
12098 }
12099
12100 static VALUE
12101 lex_io_gets(struct parser_params *parser, VALUE io)
12102 {
12103 return rb_io_gets(io);
12104 }
12105
12106 NODE*
12107 rb_compile_file(const char *f, VALUE file, int start)
12108 {
12109 VALUE volatile vparser = rb_parser_new();
12110
12111 return rb_parser_compile_file(vparser, f, file, start);
12112 }
12113
12114 NODE*
12115 rb_parser_compile_file(volatile VALUE vparser, const char *f, VALUE file, int start)
12116 {
12117 return rb_parser_compile_file_path(vparser, rb_filesystem_str_new_cstr(f), file, start);
12118 }
12119
12120 NODE*
12121 rb_parser_compile_file_path(volatile VALUE vparser, VALUE fname, VALUE file, int start)
12122 {
12123 struct parser_params *parser;
12124 NODE *node;
12125
12126 TypedData_Get_Struct(vparser, struct parser_params, &parser_data_type, parser);
12127 lex_gets = lex_io_gets;
12128 lex_input = file;
12129 lex_pbeg = lex_p = lex_pend = 0;
12130 compile_for_eval = rb_parse_in_eval();
12131
12132 node = yycompile(parser, fname, start);
12133 RB_GC_GUARD(vparser);
12134
12135 return node;
12136 }
12137 #endif
12138
12139 #define STR_FUNC_ESCAPE 0x01
12140 #define STR_FUNC_EXPAND 0x02
12141 #define STR_FUNC_REGEXP 0x04
12142 #define STR_FUNC_QWORDS 0x08
12143 #define STR_FUNC_SYMBOL 0x10
12144 #define STR_FUNC_INDENT 0x20
12145
12146 enum string_type {
12147 str_squote = (0),
12148 str_dquote = (STR_FUNC_EXPAND),
12149 str_xquote = (STR_FUNC_EXPAND),
12150 str_regexp = (STR_FUNC_REGEXP|STR_FUNC_ESCAPE|STR_FUNC_EXPAND),
12151 str_sword = (STR_FUNC_QWORDS),
12152 str_dword = (STR_FUNC_QWORDS|STR_FUNC_EXPAND),
12153 str_ssym = (STR_FUNC_SYMBOL),
12154 str_dsym = (STR_FUNC_SYMBOL|STR_FUNC_EXPAND)
12155 };
12156
12157 static VALUE
12158 parser_str_new(const char *p, long n, rb_encoding *enc, int func, rb_encoding *enc0)
12159 {
12160 VALUE str;
12161
12162 str = rb_enc_str_new(p, n, enc);
12163 if (!(func & STR_FUNC_REGEXP) && rb_enc_asciicompat(enc)) {
12164 if (rb_enc_str_coderange(str) == ENC_CODERANGE_7BIT) {
12165 }
12166 else if (enc0 == rb_usascii_encoding() && enc != rb_utf8_encoding()) {
12167 rb_enc_associate(str, rb_ascii8bit_encoding());
12168 }
12169 }
12170
12171 return str;
12172 }
12173
12174 #define lex_goto_eol(parser) ((parser)->parser_lex_p = (parser)->parser_lex_pend)
12175 #define lex_eol_p() (lex_p >= lex_pend)
12176 #define peek(c) peek_n((c), 0)
12177 #define peek_n(c,n) (lex_p+(n) < lex_pend && (c) == (unsigned char)lex_p[n])
12178
12179 static inline int
12180 parser_nextc(struct parser_params *parser)
12181 {
12182 int c;
12183
12184 if (lex_p == lex_pend) {
12185 VALUE v = lex_nextline;
12186 lex_nextline = 0;
12187 if (!v) {
12188 if (parser->eofp)
12189 return -1;
12190
12191 if (!lex_input || NIL_P(v = lex_getline(parser))) {
12192 parser->eofp = Qtrue;
12193 lex_goto_eol(parser);
12194 return -1;
12195 }
12196 }
12197 {
12198 #ifdef RIPPER
12199 if (parser->tokp < lex_pend) {
12200 if (NIL_P(parser->delayed)) {
12201 parser->delayed = rb_str_buf_new(1024);
12202 rb_enc_associate(parser->delayed, current_enc);
12203 rb_str_buf_cat(parser->delayed,
12204 parser->tokp, lex_pend - parser->tokp);
12205 parser->delayed_line = ruby_sourceline;
12206 parser->delayed_col = (int)(parser->tokp - lex_pbeg);
12207 }
12208 else {
12209 rb_str_buf_cat(parser->delayed,
12210 parser->tokp, lex_pend - parser->tokp);
12211 }
12212 }
12213 #endif
12214 if (heredoc_end > 0) {
12215 ruby_sourceline = heredoc_end;
12216 heredoc_end = 0;
12217 }
12218 ruby_sourceline++;
12219 parser->line_count++;
12220 lex_pbeg = lex_p = RSTRING_PTR(v);
12221 lex_pend = lex_p + RSTRING_LEN(v);
12222 ripper_flush(parser);
12223 lex_lastline = v;
12224 }
12225 }
12226 c = (unsigned char)*lex_p++;
12227 if (c == '\r') {
12228 if (peek('\n')) {
12229 lex_p++;
12230 c = '\n';
12231 }
12232 else if (ruby_sourceline > parser->last_cr_line) {
12233 parser->last_cr_line = ruby_sourceline;
12234 rb_compile_warn(ruby_sourcefile, ruby_sourceline, "encountered \\r in middle of line, treated as a mere space");
12235 }
12236 }
12237
12238 return c;
12239 }
12240
12241 static void
12242 parser_pushback(struct parser_params *parser, int c)
12243 {
12244 if (c == -1) return;
12245 lex_p--;
12246 if (lex_p > lex_pbeg && lex_p[0] == '\n' && lex_p[-1] == '\r') {
12247 lex_p--;
12248 }
12249 }
12250
12251 #define was_bol() (lex_p == lex_pbeg + 1)
12252
12253 #define tokfix() (tokenbuf[tokidx]='\0')
12254 #define tok() tokenbuf
12255 #define toklen() tokidx
12256 #define toklast() (tokidx>0?tokenbuf[tokidx-1]:0)
12257
12258 static char*
12259 parser_newtok(struct parser_params *parser)
12260 {
12261 tokidx = 0;
12262 tokline = ruby_sourceline;
12263 if (!tokenbuf) {
12264 toksiz = 60;
12265 tokenbuf = ALLOC_N(char, 60);
12266 }
12267 if (toksiz > 4096) {
12268 toksiz = 60;
12269 REALLOC_N(tokenbuf, char, 60);
12270 }
12271 return tokenbuf;
12272 }
12273
12274 static char *
12275 parser_tokspace(struct parser_params *parser, int n)
12276 {
12277 tokidx += n;
12278
12279 if (tokidx >= toksiz) {
12280 do {toksiz *= 2;} while (toksiz < tokidx);
12281 REALLOC_N(tokenbuf, char, toksiz);
12282 }
12283 return &tokenbuf[tokidx-n];
12284 }
12285
12286 static void
12287 parser_tokadd(struct parser_params *parser, int c)
12288 {
12289 tokenbuf[tokidx++] = (char)c;
12290 if (tokidx >= toksiz) {
12291 toksiz *= 2;
12292 REALLOC_N(tokenbuf, char, toksiz);
12293 }
12294 }
12295
12296 static int
12297 parser_tok_hex(struct parser_params *parser, size_t *numlen)
12298 {
12299 int c;
12300
12301 c = scan_hex(lex_p, 2, numlen);
12302 if (!*numlen) {
12303 yyerror("invalid hex escape");
12304 return 0;
12305 }
12306 lex_p += *numlen;
12307 return c;
12308 }
12309
12310 #define tokcopy(n) memcpy(tokspace(n), lex_p - (n), (n))
12311
12312
12313 static int
12314 parser_tokadd_utf8(struct parser_params *parser, rb_encoding **encp,
12315 int string_literal, int symbol_literal, int regexp_literal)
12316 {
12317
12318
12319
12320
12321
12322
12323
12324 int codepoint;
12325 size_t numlen;
12326
12327 if (regexp_literal) { tokadd('\\'); tokadd('u'); }
12328
12329 if (peek('{')) {
12330 do {
12331 if (regexp_literal) { tokadd(*lex_p); }
12332 nextc();
12333 codepoint = scan_hex(lex_p, 6, &numlen);
12334 if (numlen == 0) {
12335 yyerror("invalid Unicode escape");
12336 return 0;
12337 }
12338 if (codepoint > 0x10ffff) {
12339 yyerror("invalid Unicode codepoint (too large)");
12340 return 0;
12341 }
12342 lex_p += numlen;
12343 if (regexp_literal) {
12344 tokcopy((int)numlen);
12345 }
12346 else if (codepoint >= 0x80) {
12347 *encp = rb_utf8_encoding();
12348 if (string_literal) tokaddmbc(codepoint, *encp);
12349 }
12350 else if (string_literal) {
12351 tokadd(codepoint);
12352 }
12353 } while (string_literal && (peek(' ') || peek('\t')));
12354
12355 if (!peek('}')) {
12356 yyerror("unterminated Unicode escape");
12357 return 0;
12358 }
12359
12360 if (regexp_literal) { tokadd('}'); }
12361 nextc();
12362 }
12363 else {
12364 codepoint = scan_hex(lex_p, 4, &numlen);
12365 if (numlen < 4) {
12366 yyerror("invalid Unicode escape");
12367 return 0;
12368 }
12369 lex_p += 4;
12370 if (regexp_literal) {
12371 tokcopy(4);
12372 }
12373 else if (codepoint >= 0x80) {
12374 *encp = rb_utf8_encoding();
12375 if (string_literal) tokaddmbc(codepoint, *encp);
12376 }
12377 else if (string_literal) {
12378 tokadd(codepoint);
12379 }
12380 }
12381
12382 return codepoint;
12383 }
12384
12385 #define ESCAPE_CONTROL 1
12386 #define ESCAPE_META 2
12387
12388 static int
12389 parser_read_escape(struct parser_params *parser, int flags,
12390 rb_encoding **encp)
12391 {
12392 int c;
12393 size_t numlen;
12394
12395 switch (c = nextc()) {
12396 case '\\':
12397 return c;
12398
12399 case 'n':
12400 return '\n';
12401
12402 case 't':
12403 return '\t';
12404
12405 case 'r':
12406 return '\r';
12407
12408 case 'f':
12409 return '\f';
12410
12411 case 'v':
12412 return '\13';
12413
12414 case 'a':
12415 return '\007';
12416
12417 case 'e':
12418 return 033;
12419
12420 case '0': case '1': case '2': case '3':
12421 case '4': case '5': case '6': case '7':
12422 pushback(c);
12423 c = scan_oct(lex_p, 3, &numlen);
12424 lex_p += numlen;
12425 return c;
12426
12427 case 'x':
12428 c = tok_hex(&numlen);
12429 if (numlen == 0) return 0;
12430 return c;
12431
12432 case 'b':
12433 return '\010';
12434
12435 case 's':
12436 return ' ';
12437
12438 case 'M':
12439 if (flags & ESCAPE_META) goto eof;
12440 if ((c = nextc()) != '-') {
12441 pushback(c);
12442 goto eof;
12443 }
12444 if ((c = nextc()) == '\\') {
12445 if (peek('u')) goto eof;
12446 return read_escape(flags|ESCAPE_META, encp) | 0x80;
12447 }
12448 else if (c == -1 || !ISASCII(c)) goto eof;
12449 else {
12450 return ((c & 0xff) | 0x80);
12451 }
12452
12453 case 'C':
12454 if ((c = nextc()) != '-') {
12455 pushback(c);
12456 goto eof;
12457 }
12458 case 'c':
12459 if (flags & ESCAPE_CONTROL) goto eof;
12460 if ((c = nextc())== '\\') {
12461 if (peek('u')) goto eof;
12462 c = read_escape(flags|ESCAPE_CONTROL, encp);
12463 }
12464 else if (c == '?')
12465 return 0177;
12466 else if (c == -1 || !ISASCII(c)) goto eof;
12467 return c & 0x9f;
12468
12469 eof:
12470 case -1:
12471 yyerror("Invalid escape character syntax");
12472 return '\0';
12473
12474 default:
12475 return c;
12476 }
12477 }
12478
12479 static void
12480 parser_tokaddmbc(struct parser_params *parser, int c, rb_encoding *enc)
12481 {
12482 int len = rb_enc_codelen(c, enc);
12483 rb_enc_mbcput(c, tokspace(len), enc);
12484 }
12485
12486 static int
12487 parser_tokadd_escape(struct parser_params *parser, rb_encoding **encp)
12488 {
12489 int c;
12490 int flags = 0;
12491 size_t numlen;
12492
12493 first:
12494 switch (c = nextc()) {
12495 case '\n':
12496 return 0;
12497
12498 case '0': case '1': case '2': case '3':
12499 case '4': case '5': case '6': case '7':
12500 {
12501 ruby_scan_oct(--lex_p, 3, &numlen);
12502 if (numlen == 0) goto eof;
12503 lex_p += numlen;
12504 tokcopy((int)numlen + 1);
12505 }
12506 return 0;
12507
12508 case 'x':
12509 {
12510 tok_hex(&numlen);
12511 if (numlen == 0) return -1;
12512 tokcopy((int)numlen + 2);
12513 }
12514 return 0;
12515
12516 case 'M':
12517 if (flags & ESCAPE_META) goto eof;
12518 if ((c = nextc()) != '-') {
12519 pushback(c);
12520 goto eof;
12521 }
12522 tokcopy(3);
12523 flags |= ESCAPE_META;
12524 goto escaped;
12525
12526 case 'C':
12527 if (flags & ESCAPE_CONTROL) goto eof;
12528 if ((c = nextc()) != '-') {
12529 pushback(c);
12530 goto eof;
12531 }
12532 tokcopy(3);
12533 goto escaped;
12534
12535 case 'c':
12536 if (flags & ESCAPE_CONTROL) goto eof;
12537 tokcopy(2);
12538 flags |= ESCAPE_CONTROL;
12539 escaped:
12540 if ((c = nextc()) == '\\') {
12541 goto first;
12542 }
12543 else if (c == -1) goto eof;
12544 tokadd(c);
12545 return 0;
12546
12547 eof:
12548 case -1:
12549 yyerror("Invalid escape character syntax");
12550 return -1;
12551
12552 default:
12553 tokadd('\\');
12554 tokadd(c);
12555 }
12556 return 0;
12557 }
12558
12559 static int
12560 parser_regx_options(struct parser_params *parser)
12561 {
12562 int kcode = 0;
12563 int kopt = 0;
12564 int options = 0;
12565 int c, opt, kc;
12566
12567 newtok();
12568 while (c = nextc(), ISALPHA(c)) {
12569 if (c == 'o') {
12570 options |= RE_OPTION_ONCE;
12571 }
12572 else if (rb_char_to_option_kcode(c, &opt, &kc)) {
12573 if (kc >= 0) {
12574 if (kc != rb_ascii8bit_encindex()) kcode = c;
12575 kopt = opt;
12576 }
12577 else {
12578 options |= opt;
12579 }
12580 }
12581 else {
12582 tokadd(c);
12583 }
12584 }
12585 options |= kopt;
12586 pushback(c);
12587 if (toklen()) {
12588 tokfix();
12589 compile_error(PARSER_ARG "unknown regexp option%s - %s",
12590 toklen() > 1 ? "s" : "", tok());
12591 }
12592 return options | RE_OPTION_ENCODING(kcode);
12593 }
12594
12595 static void
12596 dispose_string(VALUE str)
12597 {
12598 rb_str_free(str);
12599 rb_gc_force_recycle(str);
12600 }
12601
12602 static int
12603 parser_tokadd_mbchar(struct parser_params *parser, int c)
12604 {
12605 int len = parser_precise_mbclen();
12606 if (!MBCLEN_CHARFOUND_P(len)) {
12607 compile_error(PARSER_ARG "invalid multibyte char (%s)", parser_encoding_name());
12608 return -1;
12609 }
12610 tokadd(c);
12611 lex_p += --len;
12612 if (len > 0) tokcopy(len);
12613 return c;
12614 }
12615
12616 #define tokadd_mbchar(c) parser_tokadd_mbchar(parser, (c))
12617
12618 static inline int
12619 simple_re_meta(int c)
12620 {
12621 switch (c) {
12622 case '$': case '*': case '+': case '.':
12623 case '?': case '^': case '|':
12624 case ')': case ']': case '}': case '>':
12625 return TRUE;
12626 default:
12627 return FALSE;
12628 }
12629 }
12630
12631 static int
12632 parser_tokadd_string(struct parser_params *parser,
12633 int func, int term, int paren, long *nest,
12634 rb_encoding **encp)
12635 {
12636 int c;
12637 int has_nonascii = 0;
12638 rb_encoding *enc = *encp;
12639 char *errbuf = 0;
12640 static const char mixed_msg[] = "%s mixed within %s source";
12641
12642 #define mixed_error(enc1, enc2) if (!errbuf) { \
12643 size_t len = sizeof(mixed_msg) - 4; \
12644 len += strlen(rb_enc_name(enc1)); \
12645 len += strlen(rb_enc_name(enc2)); \
12646 errbuf = ALLOCA_N(char, len); \
12647 snprintf(errbuf, len, mixed_msg, \
12648 rb_enc_name(enc1), \
12649 rb_enc_name(enc2)); \
12650 yyerror(errbuf); \
12651 }
12652 #define mixed_escape(beg, enc1, enc2) do { \
12653 const char *pos = lex_p; \
12654 lex_p = (beg); \
12655 mixed_error((enc1), (enc2)); \
12656 lex_p = pos; \
12657 } while (0)
12658
12659 while ((c = nextc()) != -1) {
12660 if (paren && c == paren) {
12661 ++*nest;
12662 }
12663 else if (c == term) {
12664 if (!nest || !*nest) {
12665 pushback(c);
12666 break;
12667 }
12668 --*nest;
12669 }
12670 else if ((func & STR_FUNC_EXPAND) && c == '#' && lex_p < lex_pend) {
12671 int c2 = *lex_p;
12672 if (c2 == '$' || c2 == '@' || c2 == '{') {
12673 pushback(c);
12674 break;
12675 }
12676 }
12677 else if (c == '\\') {
12678 const char *beg = lex_p - 1;
12679 c = nextc();
12680 switch (c) {
12681 case '\n':
12682 if (func & STR_FUNC_QWORDS) break;
12683 if (func & STR_FUNC_EXPAND) continue;
12684 tokadd('\\');
12685 break;
12686
12687 case '\\':
12688 if (func & STR_FUNC_ESCAPE) tokadd(c);
12689 break;
12690
12691 case 'u':
12692 if ((func & STR_FUNC_EXPAND) == 0) {
12693 tokadd('\\');
12694 break;
12695 }
12696 parser_tokadd_utf8(parser, &enc, 1,
12697 func & STR_FUNC_SYMBOL,
12698 func & STR_FUNC_REGEXP);
12699 if (has_nonascii && enc != *encp) {
12700 mixed_escape(beg, enc, *encp);
12701 }
12702 continue;
12703
12704 default:
12705 if (c == -1) return -1;
12706 if (!ISASCII(c)) {
12707 if ((func & STR_FUNC_EXPAND) == 0) tokadd('\\');
12708 goto non_ascii;
12709 }
12710 if (func & STR_FUNC_REGEXP) {
12711 if (c == term && !simple_re_meta(c)) {
12712 tokadd(c);
12713 continue;
12714 }
12715 pushback(c);
12716 if ((c = tokadd_escape(&enc)) < 0)
12717 return -1;
12718 if (has_nonascii && enc != *encp) {
12719 mixed_escape(beg, enc, *encp);
12720 }
12721 continue;
12722 }
12723 else if (func & STR_FUNC_EXPAND) {
12724 pushback(c);
12725 if (func & STR_FUNC_ESCAPE) tokadd('\\');
12726 c = read_escape(0, &enc);
12727 }
12728 else if ((func & STR_FUNC_QWORDS) && ISSPACE(c)) {
12729
12730 }
12731 else if (c != term && !(paren && c == paren)) {
12732 tokadd('\\');
12733 pushback(c);
12734 continue;
12735 }
12736 }
12737 }
12738 else if (!parser_isascii()) {
12739 non_ascii:
12740 has_nonascii = 1;
12741 if (enc != *encp) {
12742 mixed_error(enc, *encp);
12743 continue;
12744 }
12745 if (tokadd_mbchar(c) == -1) return -1;
12746 continue;
12747 }
12748 else if ((func & STR_FUNC_QWORDS) && ISSPACE(c)) {
12749 pushback(c);
12750 break;
12751 }
12752 if (c & 0x80) {
12753 has_nonascii = 1;
12754 if (enc != *encp) {
12755 mixed_error(enc, *encp);
12756 continue;
12757 }
12758 }
12759 tokadd(c);
12760 }
12761 *encp = enc;
12762 return c;
12763 }
12764
12765 #define NEW_STRTERM(func, term, paren) \
12766 rb_node_newnode(NODE_STRTERM, (func), (term) | ((paren) << (CHAR_BIT * 2)), 0)
12767
12768 #ifdef RIPPER
12769 static void
12770 ripper_flush_string_content(struct parser_params *parser, rb_encoding *enc)
12771 {
12772 if (!NIL_P(parser->delayed)) {
12773 ptrdiff_t len = lex_p - parser->tokp;
12774 if (len > 0) {
12775 rb_enc_str_buf_cat(parser->delayed, parser->tokp, len, enc);
12776 }
12777 ripper_dispatch_delayed_token(parser, tSTRING_CONTENT);
12778 parser->tokp = lex_p;
12779 }
12780 }
12781
12782 #define flush_string_content(enc) ripper_flush_string_content(parser, (enc))
12783 #else
12784 #define flush_string_content(enc) ((void)(enc))
12785 #endif
12786
12787 RUBY_FUNC_EXPORTED const unsigned int ruby_global_name_punct_bits[(0x7e - 0x20 + 31) / 32];
12788
12789
12790 #ifndef RIPPER
12791 #define BIT(c, idx) (((c) / 32 - 1 == idx) ? (1U << ((c) % 32)) : 0)
12792 #define SPECIAL_PUNCT(idx) ( \
12793 BIT('~', idx) | BIT('*', idx) | BIT('$', idx) | BIT('?', idx) | \
12794 BIT('!', idx) | BIT('@', idx) | BIT('/', idx) | BIT('\\', idx) | \
12795 BIT(';', idx) | BIT(',', idx) | BIT('.', idx) | BIT('=', idx) | \
12796 BIT(':', idx) | BIT('<', idx) | BIT('>', idx) | BIT('\"', idx) | \
12797 BIT('&', idx) | BIT('`', idx) | BIT('\'', idx) | BIT('+', idx) | \
12798 BIT('0', idx))
12799 const unsigned int ruby_global_name_punct_bits[] = {
12800 SPECIAL_PUNCT(0),
12801 SPECIAL_PUNCT(1),
12802 SPECIAL_PUNCT(2),
12803 };
12804 #undef BIT
12805 #undef SPECIAL_PUNCT
12806 #endif
12807
12808 static inline int
12809 is_global_name_punct(const int c)
12810 {
12811 if (c <= 0x20 || 0x7e < c) return 0;
12812 return (ruby_global_name_punct_bits[(c - 0x20) / 32] >> (c % 32)) & 1;
12813 }
12814
12815 static int
12816 parser_peek_variable_name(struct parser_params *parser)
12817 {
12818 int c;
12819 const char *p = lex_p;
12820
12821 if (p + 1 >= lex_pend) return 0;
12822 c = *p++;
12823 switch (c) {
12824 case '$':
12825 if ((c = *p) == '-') {
12826 if (++p >= lex_pend) return 0;
12827 c = *p;
12828 }
12829 else if (is_global_name_punct(c) || ISDIGIT(c)) {
12830 return tSTRING_DVAR;
12831 }
12832 break;
12833 case '@':
12834 if ((c = *p) == '@') {
12835 if (++p >= lex_pend) return 0;
12836 c = *p;
12837 }
12838 break;
12839 case '{':
12840 lex_p = p;
12841 command_start = TRUE;
12842 return tSTRING_DBEG;
12843 default:
12844 return 0;
12845 }
12846 if (!ISASCII(c) || c == '_' || ISALPHA(c))
12847 return tSTRING_DVAR;
12848 return 0;
12849 }
12850
12851 static int
12852 parser_parse_string(struct parser_params *parser, NODE *quote)
12853 {
12854 int func = (int)quote->nd_func;
12855 int term = nd_term(quote);
12856 int paren = nd_paren(quote);
12857 int c, space = 0;
12858 rb_encoding *enc = current_enc;
12859
12860 if (func == -1) return tSTRING_END;
12861 c = nextc();
12862 if ((func & STR_FUNC_QWORDS) && ISSPACE(c)) {
12863 do {c = nextc();} while (ISSPACE(c));
12864 space = 1;
12865 }
12866 if (c == term && !quote->nd_nest) {
12867 if (func & STR_FUNC_QWORDS) {
12868 quote->nd_func = -1;
12869 return ' ';
12870 }
12871 if (!(func & STR_FUNC_REGEXP)) return tSTRING_END;
12872 set_yylval_num(regx_options());
12873 return tREGEXP_END;
12874 }
12875 if (space) {
12876 pushback(c);
12877 return ' ';
12878 }
12879 newtok();
12880 if ((func & STR_FUNC_EXPAND) && c == '#') {
12881 int t = parser_peek_variable_name(parser);
12882 if (t) return t;
12883 tokadd('#');
12884 c = nextc();
12885 }
12886 pushback(c);
12887 if (tokadd_string(func, term, paren, "e->nd_nest,
12888 &enc) == -1) {
12889 ruby_sourceline = nd_line(quote);
12890 if (func & STR_FUNC_REGEXP) {
12891 if (parser->eofp)
12892 compile_error(PARSER_ARG "unterminated regexp meets end of file");
12893 return tREGEXP_END;
12894 }
12895 else {
12896 if (parser->eofp)
12897 compile_error(PARSER_ARG "unterminated string meets end of file");
12898 return tSTRING_END;
12899 }
12900 }
12901
12902 tokfix();
12903 set_yylval_str(STR_NEW3(tok(), toklen(), enc, func));
12904 flush_string_content(enc);
12905
12906 return tSTRING_CONTENT;
12907 }
12908
12909 static int
12910 parser_heredoc_identifier(struct parser_params *parser)
12911 {
12912 int c = nextc(), term, func = 0;
12913 long len;
12914
12915 if (c == '-') {
12916 c = nextc();
12917 func = STR_FUNC_INDENT;
12918 }
12919 switch (c) {
12920 case '\'':
12921 func |= str_squote; goto quoted;
12922 case '"':
12923 func |= str_dquote; goto quoted;
12924 case '`':
12925 func |= str_xquote;
12926 quoted:
12927 newtok();
12928 tokadd(func);
12929 term = c;
12930 while ((c = nextc()) != -1 && c != term) {
12931 if (tokadd_mbchar(c) == -1) return 0;
12932 }
12933 if (c == -1) {
12934 compile_error(PARSER_ARG "unterminated here document identifier");
12935 return 0;
12936 }
12937 break;
12938
12939 default:
12940 if (!parser_is_identchar()) {
12941 pushback(c);
12942 if (func & STR_FUNC_INDENT) {
12943 pushback('-');
12944 }
12945 return 0;
12946 }
12947 newtok();
12948 term = '"';
12949 tokadd(func |= str_dquote);
12950 do {
12951 if (tokadd_mbchar(c) == -1) return 0;
12952 } while ((c = nextc()) != -1 && parser_is_identchar());
12953 pushback(c);
12954 break;
12955 }
12956
12957 tokfix();
12958 #ifdef RIPPER
12959 ripper_dispatch_scan_event(parser, tHEREDOC_BEG);
12960 #endif
12961 len = lex_p - lex_pbeg;
12962 lex_goto_eol(parser);
12963 lex_strterm = rb_node_newnode(NODE_HEREDOC,
12964 STR_NEW(tok(), toklen()),
12965 len,
12966 lex_lastline);
12967 nd_set_line(lex_strterm, ruby_sourceline);
12968 ripper_flush(parser);
12969 return term == '`' ? tXSTRING_BEG : tSTRING_BEG;
12970 }
12971
12972 static void
12973 parser_heredoc_restore(struct parser_params *parser, NODE *here)
12974 {
12975 VALUE line;
12976
12977 lex_strterm = 0;
12978 line = here->nd_orig;
12979 lex_lastline = line;
12980 lex_pbeg = RSTRING_PTR(line);
12981 lex_pend = lex_pbeg + RSTRING_LEN(line);
12982 lex_p = lex_pbeg + here->nd_nth;
12983 heredoc_end = ruby_sourceline;
12984 ruby_sourceline = nd_line(here);
12985 dispose_string(here->nd_lit);
12986 rb_gc_force_recycle((VALUE)here);
12987 ripper_flush(parser);
12988 }
12989
12990 static int
12991 parser_whole_match_p(struct parser_params *parser,
12992 const char *eos, long len, int indent)
12993 {
12994 const char *p = lex_pbeg;
12995 long n;
12996
12997 if (indent) {
12998 while (*p && ISSPACE(*p)) p++;
12999 }
13000 n = lex_pend - (p + len);
13001 if (n < 0) return FALSE;
13002 if (n > 0 && p[len] != '\n') {
13003 if (p[len] != '\r') return FALSE;
13004 if (n <= 1 || p[len+1] != '\n') return FALSE;
13005 }
13006 return strncmp(eos, p, len) == 0;
13007 }
13008
13009 #define NUM_SUFFIX_R (1<<0)
13010 #define NUM_SUFFIX_I (1<<1)
13011 #define NUM_SUFFIX_ALL 3
13012
13013 static int
13014 parser_number_literal_suffix(struct parser_params *parser, int mask)
13015 {
13016 int c, result = 0;
13017 const char *lastp = lex_p;
13018
13019 while ((c = nextc()) != -1) {
13020 if ((mask & NUM_SUFFIX_I) && c == 'i') {
13021 result |= (mask & NUM_SUFFIX_I);
13022 mask &= ~NUM_SUFFIX_I;
13023
13024 mask &= ~NUM_SUFFIX_R;
13025 continue;
13026 }
13027 if ((mask & NUM_SUFFIX_R) && c == 'r') {
13028 result |= (mask & NUM_SUFFIX_R);
13029 mask &= ~NUM_SUFFIX_R;
13030 continue;
13031 }
13032 if (!ISASCII(c) || ISALPHA(c) || c == '_') {
13033 lex_p = lastp;
13034 return 0;
13035 }
13036 pushback(c);
13037 break;
13038 }
13039 return result;
13040 }
13041
13042 static int
13043 parser_set_number_literal(struct parser_params *parser, VALUE v, int type, int suffix)
13044 {
13045 if (suffix & NUM_SUFFIX_I) {
13046 v = rb_complex_raw(INT2FIX(0), v);
13047 type = tIMAGINARY;
13048 }
13049 set_yylval_literal(v);
13050 return type;
13051 }
13052
13053 static int
13054 parser_set_integer_literal(struct parser_params *parser, VALUE v, int suffix)
13055 {
13056 int type = tINTEGER;
13057 if (suffix & NUM_SUFFIX_R) {
13058 v = rb_rational_raw1(v);
13059 type = tRATIONAL;
13060 }
13061 return set_number_literal(v, type, suffix);
13062 }
13063
13064 #ifdef RIPPER
13065 static void
13066 ripper_dispatch_heredoc_end(struct parser_params *parser)
13067 {
13068 if (!NIL_P(parser->delayed))
13069 ripper_dispatch_delayed_token(parser, tSTRING_CONTENT);
13070 lex_goto_eol(parser);
13071 ripper_dispatch_ignored_scan_event(parser, tHEREDOC_END);
13072 }
13073
13074 #define dispatch_heredoc_end() ripper_dispatch_heredoc_end(parser)
13075 #else
13076 #define dispatch_heredoc_end() ((void)0)
13077 #endif
13078
13079 static int
13080 parser_here_document(struct parser_params *parser, NODE *here)
13081 {
13082 int c, func, indent = 0;
13083 const char *eos, *p, *pend;
13084 long len;
13085 VALUE str = 0;
13086 rb_encoding *enc = current_enc;
13087
13088 eos = RSTRING_PTR(here->nd_lit);
13089 len = RSTRING_LEN(here->nd_lit) - 1;
13090 indent = (func = *eos++) & STR_FUNC_INDENT;
13091
13092 if ((c = nextc()) == -1) {
13093 error:
13094 compile_error(PARSER_ARG "can't find string \"%s\" anywhere before EOF", eos);
13095 #ifdef RIPPER
13096 if (NIL_P(parser->delayed)) {
13097 ripper_dispatch_scan_event(parser, tSTRING_CONTENT);
13098 }
13099 else {
13100 if (str ||
13101 ((len = lex_p - parser->tokp) > 0 &&
13102 (str = STR_NEW3(parser->tokp, len, enc, func), 1))) {
13103 rb_str_append(parser->delayed, str);
13104 }
13105 ripper_dispatch_delayed_token(parser, tSTRING_CONTENT);
13106 }
13107 lex_goto_eol(parser);
13108 #endif
13109 restore:
13110 heredoc_restore(lex_strterm);
13111 return 0;
13112 }
13113 if (was_bol() && whole_match_p(eos, len, indent)) {
13114 dispatch_heredoc_end();
13115 heredoc_restore(lex_strterm);
13116 return tSTRING_END;
13117 }
13118
13119 if (!(func & STR_FUNC_EXPAND)) {
13120 do {
13121 p = RSTRING_PTR(lex_lastline);
13122 pend = lex_pend;
13123 if (pend > p) {
13124 switch (pend[-1]) {
13125 case '\n':
13126 if (--pend == p || pend[-1] != '\r') {
13127 pend++;
13128 break;
13129 }
13130 case '\r':
13131 --pend;
13132 }
13133 }
13134 if (str)
13135 rb_str_cat(str, p, pend - p);
13136 else
13137 str = STR_NEW(p, pend - p);
13138 if (pend < lex_pend) rb_str_cat(str, "\n", 1);
13139 lex_goto_eol(parser);
13140 if (nextc() == -1) {
13141 if (str) {
13142 dispose_string(str);
13143 str = 0;
13144 }
13145 goto error;
13146 }
13147 } while (!whole_match_p(eos, len, indent));
13148 }
13149 else {
13150
13151 newtok();
13152 if (c == '#') {
13153 int t = parser_peek_variable_name(parser);
13154 if (t) return t;
13155 tokadd('#');
13156 c = nextc();
13157 }
13158 do {
13159 pushback(c);
13160 if ((c = tokadd_string(func, '\n', 0, NULL, &enc)) == -1) {
13161 if (parser->eofp) goto error;
13162 goto restore;
13163 }
13164 if (c != '\n') {
13165 set_yylval_str(STR_NEW3(tok(), toklen(), enc, func));
13166 flush_string_content(enc);
13167 return tSTRING_CONTENT;
13168 }
13169 tokadd(nextc());
13170
13171 if ((c = nextc()) == -1) goto error;
13172 } while (!whole_match_p(eos, len, indent));
13173 str = STR_NEW3(tok(), toklen(), enc, func);
13174 }
13175 dispatch_heredoc_end();
13176 heredoc_restore(lex_strterm);
13177 lex_strterm = NEW_STRTERM(-1, 0, 0);
13178 set_yylval_str(str);
13179 return tSTRING_CONTENT;
13180 }
13181
13182 #include "lex.c"
13183
13184 static void
13185 arg_ambiguous_gen(struct parser_params *parser)
13186 {
13187 #ifndef RIPPER
13188 rb_warning0("ambiguous first argument; put parentheses or even spaces");
13189 #else
13190 dispatch0(arg_ambiguous);
13191 #endif
13192 }
13193 #define arg_ambiguous() (arg_ambiguous_gen(parser), 1)
13194
13195 static ID
13196 formal_argument_gen(struct parser_params *parser, ID lhs)
13197 {
13198 #ifndef RIPPER
13199 if (!is_local_id(lhs))
13200 yyerror("formal argument must be local variable");
13201 #endif
13202 shadowing_lvar(lhs);
13203 return lhs;
13204 }
13205
13206 static int
13207 lvar_defined_gen(struct parser_params *parser, ID id)
13208 {
13209 return (dyna_in_block() && dvar_defined_get(id)) || local_id(id);
13210 }
13211
13212
13213 static long
13214 parser_encode_length(struct parser_params *parser, const char *name, long len)
13215 {
13216 long nlen;
13217
13218 if (len > 5 && name[nlen = len - 5] == '-') {
13219 if (rb_memcicmp(name + nlen + 1, "unix", 4) == 0)
13220 return nlen;
13221 }
13222 if (len > 4 && name[nlen = len - 4] == '-') {
13223 if (rb_memcicmp(name + nlen + 1, "dos", 3) == 0)
13224 return nlen;
13225 if (rb_memcicmp(name + nlen + 1, "mac", 3) == 0 &&
13226 !(len == 8 && rb_memcicmp(name, "utf8-mac", len) == 0))
13227
13228 return nlen;
13229 }
13230 return len;
13231 }
13232
13233 static void
13234 parser_set_encode(struct parser_params *parser, const char *name)
13235 {
13236 int idx = rb_enc_find_index(name);
13237 rb_encoding *enc;
13238 VALUE excargs[3];
13239
13240 if (idx < 0) {
13241 excargs[1] = rb_sprintf("unknown encoding name: %s", name);
13242 error:
13243 excargs[0] = rb_eArgError;
13244 excargs[2] = rb_make_backtrace();
13245 rb_ary_unshift(excargs[2], rb_sprintf("%s:%d", ruby_sourcefile, ruby_sourceline));
13246 rb_exc_raise(rb_make_exception(3, excargs));
13247 }
13248 enc = rb_enc_from_index(idx);
13249 if (!rb_enc_asciicompat(enc)) {
13250 excargs[1] = rb_sprintf("%s is not ASCII compatible", rb_enc_name(enc));
13251 goto error;
13252 }
13253 parser->enc = enc;
13254 #ifndef RIPPER
13255 if (ruby_debug_lines) {
13256 VALUE lines = ruby_debug_lines;
13257 long i, n = RARRAY_LEN(lines);
13258 for (i = 0; i < n; ++i) {
13259 rb_enc_associate_index(RARRAY_AREF(lines, i), idx);
13260 }
13261 }
13262 #endif
13263 }
13264
13265 static int
13266 comment_at_top(struct parser_params *parser)
13267 {
13268 const char *p = lex_pbeg, *pend = lex_p - 1;
13269 if (parser->line_count != (parser->has_shebang ? 2 : 1)) return 0;
13270 while (p < pend) {
13271 if (!ISSPACE(*p)) return 0;
13272 p++;
13273 }
13274 return 1;
13275 }
13276
13277 #ifndef RIPPER
13278 typedef long (*rb_magic_comment_length_t)(struct parser_params *parser, const char *name, long len);
13279 typedef void (*rb_magic_comment_setter_t)(struct parser_params *parser, const char *name, const char *val);
13280
13281 static void
13282 magic_comment_encoding(struct parser_params *parser, const char *name, const char *val)
13283 {
13284 if (!comment_at_top(parser)) {
13285 return;
13286 }
13287 parser_set_encode(parser, val);
13288 }
13289
13290 static void
13291 parser_set_token_info(struct parser_params *parser, const char *name, const char *val)
13292 {
13293 int *p = &parser->parser_token_info_enabled;
13294
13295 switch (*val) {
13296 case 't': case 'T':
13297 if (strcasecmp(val, "true") == 0) {
13298 *p = TRUE;
13299 return;
13300 }
13301 break;
13302 case 'f': case 'F':
13303 if (strcasecmp(val, "false") == 0) {
13304 *p = FALSE;
13305 return;
13306 }
13307 break;
13308 }
13309 rb_compile_warning(ruby_sourcefile, ruby_sourceline, "invalid value for %s: %s", name, val);
13310 }
13311
13312 struct magic_comment {
13313 const char *name;
13314 rb_magic_comment_setter_t func;
13315 rb_magic_comment_length_t length;
13316 };
13317
13318 static const struct magic_comment magic_comments[] = {
13319 {"coding", magic_comment_encoding, parser_encode_length},
13320 {"encoding", magic_comment_encoding, parser_encode_length},
13321 {"warn_indent", parser_set_token_info},
13322 };
13323 #endif
13324
13325 static const char *
13326 magic_comment_marker(const char *str, long len)
13327 {
13328 long i = 2;
13329
13330 while (i < len) {
13331 switch (str[i]) {
13332 case '-':
13333 if (str[i-1] == '*' && str[i-2] == '-') {
13334 return str + i + 1;
13335 }
13336 i += 2;
13337 break;
13338 case '*':
13339 if (i + 1 >= len) return 0;
13340 if (str[i+1] != '-') {
13341 i += 4;
13342 }
13343 else if (str[i-1] != '-') {
13344 i += 2;
13345 }
13346 else {
13347 return str + i + 2;
13348 }
13349 break;
13350 default:
13351 i += 3;
13352 break;
13353 }
13354 }
13355 return 0;
13356 }
13357
13358 static int
13359 parser_magic_comment(struct parser_params *parser, const char *str, long len)
13360 {
13361 VALUE name = 0, val = 0;
13362 const char *beg, *end, *vbeg, *vend;
13363 #define str_copy(_s, _p, _n) ((_s) \
13364 ? (void)(rb_str_resize((_s), (_n)), \
13365 MEMCPY(RSTRING_PTR(_s), (_p), char, (_n)), (_s)) \
13366 : (void)((_s) = STR_NEW((_p), (_n))))
13367
13368 if (len <= 7) return FALSE;
13369 if (!(beg = magic_comment_marker(str, len))) return FALSE;
13370 if (!(end = magic_comment_marker(beg, str + len - beg))) return FALSE;
13371 str = beg;
13372 len = end - beg - 3;
13373
13374
13375 while (len > 0) {
13376 #ifndef RIPPER
13377 const struct magic_comment *p = magic_comments;
13378 #endif
13379 char *s;
13380 int i;
13381 long n = 0;
13382
13383 for (; len > 0 && *str; str++, --len) {
13384 switch (*str) {
13385 case '\'': case '"': case ':': case ';':
13386 continue;
13387 }
13388 if (!ISSPACE(*str)) break;
13389 }
13390 for (beg = str; len > 0; str++, --len) {
13391 switch (*str) {
13392 case '\'': case '"': case ':': case ';':
13393 break;
13394 default:
13395 if (ISSPACE(*str)) break;
13396 continue;
13397 }
13398 break;
13399 }
13400 for (end = str; len > 0 && ISSPACE(*str); str++, --len);
13401 if (!len) break;
13402 if (*str != ':') continue;
13403
13404 do str++; while (--len > 0 && ISSPACE(*str));
13405 if (!len) break;
13406 if (*str == '"') {
13407 for (vbeg = ++str; --len > 0 && *str != '"'; str++) {
13408 if (*str == '\\') {
13409 --len;
13410 ++str;
13411 }
13412 }
13413 vend = str;
13414 if (len) {
13415 --len;
13416 ++str;
13417 }
13418 }
13419 else {
13420 for (vbeg = str; len > 0 && *str != '"' && *str != ';' && !ISSPACE(*str); --len, str++);
13421 vend = str;
13422 }
13423 while (len > 0 && (*str == ';' || ISSPACE(*str))) --len, str++;
13424
13425 n = end - beg;
13426 str_copy(name, beg, n);
13427 s = RSTRING_PTR(name);
13428 for (i = 0; i < n; ++i) {
13429 if (s[i] == '-') s[i] = '_';
13430 }
13431 #ifndef RIPPER
13432 do {
13433 if (STRNCASECMP(p->name, s, n) == 0) {
13434 n = vend - vbeg;
13435 if (p->length) {
13436 n = (*p->length)(parser, vbeg, n);
13437 }
13438 str_copy(val, vbeg, n);
13439 (*p->func)(parser, s, RSTRING_PTR(val));
13440 break;
13441 }
13442 } while (++p < magic_comments + numberof(magic_comments));
13443 #else
13444 str_copy(val, vbeg, vend - vbeg);
13445 dispatch2(magic_comment, name, val);
13446 #endif
13447 }
13448
13449 return TRUE;
13450 }
13451
13452 static void
13453 set_file_encoding(struct parser_params *parser, const char *str, const char *send)
13454 {
13455 int sep = 0;
13456 const char *beg = str;
13457 VALUE s;
13458
13459 for (;;) {
13460 if (send - str <= 6) return;
13461 switch (str[6]) {
13462 case 'C': case 'c': str += 6; continue;
13463 case 'O': case 'o': str += 5; continue;
13464 case 'D': case 'd': str += 4; continue;
13465 case 'I': case 'i': str += 3; continue;
13466 case 'N': case 'n': str += 2; continue;
13467 case 'G': case 'g': str += 1; continue;
13468 case '=': case ':':
13469 sep = 1;
13470 str += 6;
13471 break;
13472 default:
13473 str += 6;
13474 if (ISSPACE(*str)) break;
13475 continue;
13476 }
13477 if (STRNCASECMP(str-6, "coding", 6) == 0) break;
13478 }
13479 for (;;) {
13480 do {
13481 if (++str >= send) return;
13482 } while (ISSPACE(*str));
13483 if (sep) break;
13484 if (*str != '=' && *str != ':') return;
13485 sep = 1;
13486 str++;
13487 }
13488 beg = str;
13489 while ((*str == '-' || *str == '_' || ISALNUM(*str)) && ++str < send);
13490 s = rb_str_new(beg, parser_encode_length(parser, beg, str - beg));
13491 parser_set_encode(parser, RSTRING_PTR(s));
13492 rb_str_resize(s, 0);
13493 }
13494
13495 static void
13496 parser_prepare(struct parser_params *parser)
13497 {
13498 int c = nextc();
13499 switch (c) {
13500 case '#':
13501 if (peek('!')) parser->has_shebang = 1;
13502 break;
13503 case 0xef:
13504 if (lex_pend - lex_p >= 2 &&
13505 (unsigned char)lex_p[0] == 0xbb &&
13506 (unsigned char)lex_p[1] == 0xbf) {
13507 parser->enc = rb_utf8_encoding();
13508 lex_p += 2;
13509 lex_pbeg = lex_p;
13510 return;
13511 }
13512 break;
13513 case EOF:
13514 return;
13515 }
13516 pushback(c);
13517 parser->enc = rb_enc_get(lex_lastline);
13518 }
13519
13520 #define IS_ARG() IS_lex_state(EXPR_ARG_ANY)
13521 #define IS_END() IS_lex_state(EXPR_END_ANY)
13522 #define IS_BEG() IS_lex_state(EXPR_BEG_ANY)
13523 #define IS_SPCARG(c) (IS_ARG() && space_seen && !ISSPACE(c))
13524 #define IS_LABEL_POSSIBLE() ((IS_lex_state(EXPR_BEG | EXPR_ENDFN) && !cmd_state) || IS_ARG())
13525 #define IS_LABEL_SUFFIX(n) (peek_n(':',(n)) && !peek_n(':', (n)+1))
13526 #define IS_AFTER_OPERATOR() IS_lex_state(EXPR_FNAME | EXPR_DOT)
13527
13528 #ifndef RIPPER
13529 #define ambiguous_operator(op, syn) ( \
13530 rb_warning0("`"op"' after local variable or literal is interpreted as binary operator"), \
13531 rb_warning0("even though it seems like "syn""))
13532 #else
13533 #define ambiguous_operator(op, syn) dispatch2(operator_ambiguous, ripper_intern(op), rb_str_new_cstr(syn))
13534 #endif
13535 #define warn_balanced(op, syn) ((void) \
13536 (!IS_lex_state_for(last_state, EXPR_CLASS|EXPR_DOT|EXPR_FNAME|EXPR_ENDFN|EXPR_ENDARG) && \
13537 space_seen && !ISSPACE(c) && \
13538 (ambiguous_operator(op, syn), 0)))
13539
13540 static int
13541 parser_yylex(struct parser_params *parser)
13542 {
13543 register int c;
13544 int space_seen = 0;
13545 int cmd_state;
13546 enum lex_state_e last_state;
13547 rb_encoding *enc;
13548 int mb;
13549 #ifdef RIPPER
13550 int fallthru = FALSE;
13551 #endif
13552
13553 if (lex_strterm) {
13554 int token;
13555 if (nd_type(lex_strterm) == NODE_HEREDOC) {
13556 token = here_document(lex_strterm);
13557 if (token == tSTRING_END) {
13558 lex_strterm = 0;
13559 lex_state = EXPR_END;
13560 }
13561 }
13562 else {
13563 token = parse_string(lex_strterm);
13564 if (token == tSTRING_END || token == tREGEXP_END) {
13565 rb_gc_force_recycle((VALUE)lex_strterm);
13566 lex_strterm = 0;
13567 lex_state = EXPR_END;
13568 }
13569 }
13570 return token;
13571 }
13572 cmd_state = command_start;
13573 command_start = FALSE;
13574 retry:
13575 last_state = lex_state;
13576 switch (c = nextc()) {
13577 case '\0':
13578 case '\004':
13579 case '\032':
13580 case -1:
13581 return 0;
13582
13583
13584 case ' ': case '\t': case '\f': case '\r':
13585 case '\13':
13586 space_seen = 1;
13587 #ifdef RIPPER
13588 while ((c = nextc())) {
13589 switch (c) {
13590 case ' ': case '\t': case '\f': case '\r':
13591 case '\13':
13592 break;
13593 default:
13594 goto outofloop;
13595 }
13596 }
13597 outofloop:
13598 pushback(c);
13599 ripper_dispatch_scan_event(parser, tSP);
13600 #endif
13601 goto retry;
13602
13603 case '#':
13604
13605 if (!parser_magic_comment(parser, lex_p, lex_pend - lex_p)) {
13606 if (comment_at_top(parser)) {
13607 set_file_encoding(parser, lex_p, lex_pend);
13608 }
13609 }
13610 lex_p = lex_pend;
13611 #ifdef RIPPER
13612 ripper_dispatch_scan_event(parser, tCOMMENT);
13613 fallthru = TRUE;
13614 #endif
13615
13616 case '\n':
13617 if (IS_lex_state(EXPR_BEG | EXPR_VALUE | EXPR_CLASS | EXPR_FNAME | EXPR_DOT | EXPR_LABELARG)) {
13618 #ifdef RIPPER
13619 if (!fallthru) {
13620 ripper_dispatch_scan_event(parser, tIGNORED_NL);
13621 }
13622 fallthru = FALSE;
13623 #endif
13624 if (IS_lex_state(EXPR_LABELARG) && parser->parser_in_kwarg) {
13625 goto normal_newline;
13626 }
13627 goto retry;
13628 }
13629 while ((c = nextc())) {
13630 switch (c) {
13631 case ' ': case '\t': case '\f': case '\r':
13632 case '\13':
13633 space_seen = 1;
13634 break;
13635 case '.': {
13636 if ((c = nextc()) != '.') {
13637 pushback(c);
13638 pushback('.');
13639 goto retry;
13640 }
13641 }
13642 default:
13643 --ruby_sourceline;
13644 lex_nextline = lex_lastline;
13645 case -1:
13646 lex_goto_eol(parser);
13647 #ifdef RIPPER
13648 if (c != -1) {
13649 parser->tokp = lex_p;
13650 }
13651 #endif
13652 goto normal_newline;
13653 }
13654 }
13655 normal_newline:
13656 command_start = TRUE;
13657 lex_state = EXPR_BEG;
13658 return '\n';
13659
13660 case '*':
13661 if ((c = nextc()) == '*') {
13662 if ((c = nextc()) == '=') {
13663 set_yylval_id(tPOW);
13664 lex_state = EXPR_BEG;
13665 return tOP_ASGN;
13666 }
13667 pushback(c);
13668 if (IS_SPCARG(c)) {
13669 rb_warning0("`**' interpreted as argument prefix");
13670 c = tDSTAR;
13671 }
13672 else if (IS_BEG()) {
13673 c = tDSTAR;
13674 }
13675 else {
13676 warn_balanced("**", "argument prefix");
13677 c = tPOW;
13678 }
13679 }
13680 else {
13681 if (c == '=') {
13682 set_yylval_id('*');
13683 lex_state = EXPR_BEG;
13684 return tOP_ASGN;
13685 }
13686 pushback(c);
13687 if (IS_SPCARG(c)) {
13688 rb_warning0("`*' interpreted as argument prefix");
13689 c = tSTAR;
13690 }
13691 else if (IS_BEG()) {
13692 c = tSTAR;
13693 }
13694 else {
13695 warn_balanced("*", "argument prefix");
13696 c = '*';
13697 }
13698 }
13699 lex_state = IS_AFTER_OPERATOR() ? EXPR_ARG : EXPR_BEG;
13700 return c;
13701
13702 case '!':
13703 c = nextc();
13704 if (IS_AFTER_OPERATOR()) {
13705 lex_state = EXPR_ARG;
13706 if (c == '@') {
13707 return '!';
13708 }
13709 }
13710 else {
13711 lex_state = EXPR_BEG;
13712 }
13713 if (c == '=') {
13714 return tNEQ;
13715 }
13716 if (c == '~') {
13717 return tNMATCH;
13718 }
13719 pushback(c);
13720 return '!';
13721
13722 case '=':
13723 if (was_bol()) {
13724
13725 if (strncmp(lex_p, "begin", 5) == 0 && ISSPACE(lex_p[5])) {
13726 #ifdef RIPPER
13727 int first_p = TRUE;
13728
13729 lex_goto_eol(parser);
13730 ripper_dispatch_scan_event(parser, tEMBDOC_BEG);
13731 #endif
13732 for (;;) {
13733 lex_goto_eol(parser);
13734 #ifdef RIPPER
13735 if (!first_p) {
13736 ripper_dispatch_scan_event(parser, tEMBDOC);
13737 }
13738 first_p = FALSE;
13739 #endif
13740 c = nextc();
13741 if (c == -1) {
13742 compile_error(PARSER_ARG "embedded document meets end of file");
13743 return 0;
13744 }
13745 if (c != '=') continue;
13746 if (strncmp(lex_p, "end", 3) == 0 &&
13747 (lex_p + 3 == lex_pend || ISSPACE(lex_p[3]))) {
13748 break;
13749 }
13750 }
13751 lex_goto_eol(parser);
13752 #ifdef RIPPER
13753 ripper_dispatch_scan_event(parser, tEMBDOC_END);
13754 #endif
13755 goto retry;
13756 }
13757 }
13758
13759 lex_state = IS_AFTER_OPERATOR() ? EXPR_ARG : EXPR_BEG;
13760 if ((c = nextc()) == '=') {
13761 if ((c = nextc()) == '=') {
13762 return tEQQ;
13763 }
13764 pushback(c);
13765 return tEQ;
13766 }
13767 if (c == '~') {
13768 return tMATCH;
13769 }
13770 else if (c == '>') {
13771 return tASSOC;
13772 }
13773 pushback(c);
13774 return '=';
13775
13776 case '<':
13777 last_state = lex_state;
13778 c = nextc();
13779 if (c == '<' &&
13780 !IS_lex_state(EXPR_DOT | EXPR_CLASS) &&
13781 !IS_END() &&
13782 (!IS_ARG() || space_seen)) {
13783 int token = heredoc_identifier();
13784 if (token) return token;
13785 }
13786 if (IS_AFTER_OPERATOR()) {
13787 lex_state = EXPR_ARG;
13788 }
13789 else {
13790 if (IS_lex_state(EXPR_CLASS))
13791 command_start = TRUE;
13792 lex_state = EXPR_BEG;
13793 }
13794 if (c == '=') {
13795 if ((c = nextc()) == '>') {
13796 return tCMP;
13797 }
13798 pushback(c);
13799 return tLEQ;
13800 }
13801 if (c == '<') {
13802 if ((c = nextc()) == '=') {
13803 set_yylval_id(tLSHFT);
13804 lex_state = EXPR_BEG;
13805 return tOP_ASGN;
13806 }
13807 pushback(c);
13808 warn_balanced("<<", "here document");
13809 return tLSHFT;
13810 }
13811 pushback(c);
13812 return '<';
13813
13814 case '>':
13815 lex_state = IS_AFTER_OPERATOR() ? EXPR_ARG : EXPR_BEG;
13816 if ((c = nextc()) == '=') {
13817 return tGEQ;
13818 }
13819 if (c == '>') {
13820 if ((c = nextc()) == '=') {
13821 set_yylval_id(tRSHFT);
13822 lex_state = EXPR_BEG;
13823 return tOP_ASGN;
13824 }
13825 pushback(c);
13826 return tRSHFT;
13827 }
13828 pushback(c);
13829 return '>';
13830
13831 case '"':
13832 lex_strterm = NEW_STRTERM(str_dquote, '"', 0);
13833 return tSTRING_BEG;
13834
13835 case '`':
13836 if (IS_lex_state(EXPR_FNAME)) {
13837 lex_state = EXPR_ENDFN;
13838 return c;
13839 }
13840 if (IS_lex_state(EXPR_DOT)) {
13841 if (cmd_state)
13842 lex_state = EXPR_CMDARG;
13843 else
13844 lex_state = EXPR_ARG;
13845 return c;
13846 }
13847 lex_strterm = NEW_STRTERM(str_xquote, '`', 0);
13848 return tXSTRING_BEG;
13849
13850 case '\'':
13851 lex_strterm = NEW_STRTERM(str_squote, '\'', 0);
13852 return tSTRING_BEG;
13853
13854 case '?':
13855 if (IS_END()) {
13856 lex_state = EXPR_VALUE;
13857 return '?';
13858 }
13859 c = nextc();
13860 if (c == -1) {
13861 compile_error(PARSER_ARG "incomplete character syntax");
13862 return 0;
13863 }
13864 if (rb_enc_isspace(c, current_enc)) {
13865 if (!IS_ARG()) {
13866 int c2 = 0;
13867 switch (c) {
13868 case ' ':
13869 c2 = 's';
13870 break;
13871 case '\n':
13872 c2 = 'n';
13873 break;
13874 case '\t':
13875 c2 = 't';
13876 break;
13877 case '\v':
13878 c2 = 'v';
13879 break;
13880 case '\r':
13881 c2 = 'r';
13882 break;
13883 case '\f':
13884 c2 = 'f';
13885 break;
13886 }
13887 if (c2) {
13888 rb_warnI("invalid character syntax; use ?\\%c", c2);
13889 }
13890 }
13891 ternary:
13892 pushback(c);
13893 lex_state = EXPR_VALUE;
13894 return '?';
13895 }
13896 newtok();
13897 enc = current_enc;
13898 if (!parser_isascii()) {
13899 if (tokadd_mbchar(c) == -1) return 0;
13900 }
13901 else if ((rb_enc_isalnum(c, current_enc) || c == '_') &&
13902 lex_p < lex_pend && is_identchar(lex_p, lex_pend, current_enc)) {
13903 goto ternary;
13904 }
13905 else if (c == '\\') {
13906 if (peek('u')) {
13907 nextc();
13908 c = parser_tokadd_utf8(parser, &enc, 0, 0, 0);
13909 if (0x80 <= c) {
13910 tokaddmbc(c, enc);
13911 }
13912 else {
13913 tokadd(c);
13914 }
13915 }
13916 else if (!lex_eol_p() && !(c = *lex_p, ISASCII(c))) {
13917 nextc();
13918 if (tokadd_mbchar(c) == -1) return 0;
13919 }
13920 else {
13921 c = read_escape(0, &enc);
13922 tokadd(c);
13923 }
13924 }
13925 else {
13926 tokadd(c);
13927 }
13928 tokfix();
13929 set_yylval_str(STR_NEW3(tok(), toklen(), enc, 0));
13930 lex_state = EXPR_END;
13931 return tCHAR;
13932
13933 case '&':
13934 if ((c = nextc()) == '&') {
13935 lex_state = EXPR_BEG;
13936 if ((c = nextc()) == '=') {
13937 set_yylval_id(tANDOP);
13938 lex_state = EXPR_BEG;
13939 return tOP_ASGN;
13940 }
13941 pushback(c);
13942 return tANDOP;
13943 }
13944 else if (c == '=') {
13945 set_yylval_id('&');
13946 lex_state = EXPR_BEG;
13947 return tOP_ASGN;
13948 }
13949 pushback(c);
13950 if (IS_SPCARG(c)) {
13951 rb_warning0("`&' interpreted as argument prefix");
13952 c = tAMPER;
13953 }
13954 else if (IS_BEG()) {
13955 c = tAMPER;
13956 }
13957 else {
13958 warn_balanced("&", "argument prefix");
13959 c = '&';
13960 }
13961 lex_state = IS_AFTER_OPERATOR() ? EXPR_ARG : EXPR_BEG;
13962 return c;
13963
13964 case '|':
13965 if ((c = nextc()) == '|') {
13966 lex_state = EXPR_BEG;
13967 if ((c = nextc()) == '=') {
13968 set_yylval_id(tOROP);
13969 lex_state = EXPR_BEG;
13970 return tOP_ASGN;
13971 }
13972 pushback(c);
13973 return tOROP;
13974 }
13975 if (c == '=') {
13976 set_yylval_id('|');
13977 lex_state = EXPR_BEG;
13978 return tOP_ASGN;
13979 }
13980 lex_state = IS_AFTER_OPERATOR() ? EXPR_ARG : EXPR_BEG;
13981 pushback(c);
13982 return '|';
13983
13984 case '+':
13985 c = nextc();
13986 if (IS_AFTER_OPERATOR()) {
13987 lex_state = EXPR_ARG;
13988 if (c == '@') {
13989 return tUPLUS;
13990 }
13991 pushback(c);
13992 return '+';
13993 }
13994 if (c == '=') {
13995 set_yylval_id('+');
13996 lex_state = EXPR_BEG;
13997 return tOP_ASGN;
13998 }
13999 if (IS_BEG() || (IS_SPCARG(c) && arg_ambiguous())) {
14000 lex_state = EXPR_BEG;
14001 pushback(c);
14002 if (c != -1 && ISDIGIT(c)) {
14003 c = '+';
14004 goto start_num;
14005 }
14006 return tUPLUS;
14007 }
14008 lex_state = EXPR_BEG;
14009 pushback(c);
14010 warn_balanced("+", "unary operator");
14011 return '+';
14012
14013 case '-':
14014 c = nextc();
14015 if (IS_AFTER_OPERATOR()) {
14016 lex_state = EXPR_ARG;
14017 if (c == '@') {
14018 return tUMINUS;
14019 }
14020 pushback(c);
14021 return '-';
14022 }
14023 if (c == '=') {
14024 set_yylval_id('-');
14025 lex_state = EXPR_BEG;
14026 return tOP_ASGN;
14027 }
14028 if (c == '>') {
14029 lex_state = EXPR_ENDFN;
14030 return tLAMBDA;
14031 }
14032 if (IS_BEG() || (IS_SPCARG(c) && arg_ambiguous())) {
14033 lex_state = EXPR_BEG;
14034 pushback(c);
14035 if (c != -1 && ISDIGIT(c)) {
14036 return tUMINUS_NUM;
14037 }
14038 return tUMINUS;
14039 }
14040 lex_state = EXPR_BEG;
14041 pushback(c);
14042 warn_balanced("-", "unary operator");
14043 return '-';
14044
14045 case '.':
14046 lex_state = EXPR_BEG;
14047 if ((c = nextc()) == '.') {
14048 if ((c = nextc()) == '.') {
14049 return tDOT3;
14050 }
14051 pushback(c);
14052 return tDOT2;
14053 }
14054 pushback(c);
14055 if (c != -1 && ISDIGIT(c)) {
14056 yyerror("no .<digit> floating literal anymore; put 0 before dot");
14057 }
14058 lex_state = EXPR_DOT;
14059 return '.';
14060
14061 start_num:
14062 case '0': case '1': case '2': case '3': case '4':
14063 case '5': case '6': case '7': case '8': case '9':
14064 {
14065 int is_float, seen_point, seen_e, nondigit;
14066 int suffix;
14067
14068 is_float = seen_point = seen_e = nondigit = 0;
14069 lex_state = EXPR_END;
14070 newtok();
14071 if (c == '-' || c == '+') {
14072 tokadd(c);
14073 c = nextc();
14074 }
14075 if (c == '0') {
14076 #define no_digits() do {yyerror("numeric literal without digits"); return 0;} while (0)
14077 int start = toklen();
14078 c = nextc();
14079 if (c == 'x' || c == 'X') {
14080
14081 c = nextc();
14082 if (c != -1 && ISXDIGIT(c)) {
14083 do {
14084 if (c == '_') {
14085 if (nondigit) break;
14086 nondigit = c;
14087 continue;
14088 }
14089 if (!ISXDIGIT(c)) break;
14090 nondigit = 0;
14091 tokadd(c);
14092 } while ((c = nextc()) != -1);
14093 }
14094 pushback(c);
14095 tokfix();
14096 if (toklen() == start) {
14097 no_digits();
14098 }
14099 else if (nondigit) goto trailing_uc;
14100 suffix = number_literal_suffix(NUM_SUFFIX_ALL);
14101 return set_integer_literal(rb_cstr_to_inum(tok(), 16, FALSE), suffix);
14102 }
14103 if (c == 'b' || c == 'B') {
14104
14105 c = nextc();
14106 if (c == '0' || c == '1') {
14107 do {
14108 if (c == '_') {
14109 if (nondigit) break;
14110 nondigit = c;
14111 continue;
14112 }
14113 if (c != '0' && c != '1') break;
14114 nondigit = 0;
14115 tokadd(c);
14116 } while ((c = nextc()) != -1);
14117 }
14118 pushback(c);
14119 tokfix();
14120 if (toklen() == start) {
14121 no_digits();
14122 }
14123 else if (nondigit) goto trailing_uc;
14124 suffix = number_literal_suffix(NUM_SUFFIX_ALL);
14125 return set_integer_literal(rb_cstr_to_inum(tok(), 2, FALSE), suffix);
14126 }
14127 if (c == 'd' || c == 'D') {
14128
14129 c = nextc();
14130 if (c != -1 && ISDIGIT(c)) {
14131 do {
14132 if (c == '_') {
14133 if (nondigit) break;
14134 nondigit = c;
14135 continue;
14136 }
14137 if (!ISDIGIT(c)) break;
14138 nondigit = 0;
14139 tokadd(c);
14140 } while ((c = nextc()) != -1);
14141 }
14142 pushback(c);
14143 tokfix();
14144 if (toklen() == start) {
14145 no_digits();
14146 }
14147 else if (nondigit) goto trailing_uc;
14148 suffix = number_literal_suffix(NUM_SUFFIX_ALL);
14149 return set_integer_literal(rb_cstr_to_inum(tok(), 10, FALSE), suffix);
14150 }
14151 if (c == '_') {
14152
14153 goto octal_number;
14154 }
14155 if (c == 'o' || c == 'O') {
14156
14157 c = nextc();
14158 if (c == -1 || c == '_' || !ISDIGIT(c)) {
14159 no_digits();
14160 }
14161 }
14162 if (c >= '0' && c <= '7') {
14163
14164 octal_number:
14165 do {
14166 if (c == '_') {
14167 if (nondigit) break;
14168 nondigit = c;
14169 continue;
14170 }
14171 if (c < '0' || c > '9') break;
14172 if (c > '7') goto invalid_octal;
14173 nondigit = 0;
14174 tokadd(c);
14175 } while ((c = nextc()) != -1);
14176 if (toklen() > start) {
14177 pushback(c);
14178 tokfix();
14179 if (nondigit) goto trailing_uc;
14180 suffix = number_literal_suffix(NUM_SUFFIX_ALL);
14181 return set_integer_literal(rb_cstr_to_inum(tok(), 8, FALSE), suffix);
14182 }
14183 if (nondigit) {
14184 pushback(c);
14185 goto trailing_uc;
14186 }
14187 }
14188 if (c > '7' && c <= '9') {
14189 invalid_octal:
14190 yyerror("Invalid octal digit");
14191 }
14192 else if (c == '.' || c == 'e' || c == 'E') {
14193 tokadd('0');
14194 }
14195 else {
14196 pushback(c);
14197 suffix = number_literal_suffix(NUM_SUFFIX_ALL);
14198 return set_integer_literal(INT2FIX(0), suffix);
14199 }
14200 }
14201
14202 for (;;) {
14203 switch (c) {
14204 case '0': case '1': case '2': case '3': case '4':
14205 case '5': case '6': case '7': case '8': case '9':
14206 nondigit = 0;
14207 tokadd(c);
14208 break;
14209
14210 case '.':
14211 if (nondigit) goto trailing_uc;
14212 if (seen_point || seen_e) {
14213 goto decode_num;
14214 }
14215 else {
14216 int c0 = nextc();
14217 if (c0 == -1 || !ISDIGIT(c0)) {
14218 pushback(c0);
14219 goto decode_num;
14220 }
14221 c = c0;
14222 }
14223 seen_point = toklen();
14224 tokadd('.');
14225 tokadd(c);
14226 is_float++;
14227 nondigit = 0;
14228 break;
14229
14230 case 'e':
14231 case 'E':
14232 if (nondigit) {
14233 pushback(c);
14234 c = nondigit;
14235 goto decode_num;
14236 }
14237 if (seen_e) {
14238 goto decode_num;
14239 }
14240 nondigit = c;
14241 c = nextc();
14242 if (c != '-' && c != '+' && !ISDIGIT(c)) {
14243 pushback(c);
14244 nondigit = 0;
14245 goto decode_num;
14246 }
14247 tokadd(nondigit);
14248 seen_e++;
14249 is_float++;
14250 tokadd(c);
14251 nondigit = (c == '-' || c == '+') ? c : 0;
14252 break;
14253
14254 case '_':
14255 if (nondigit) goto decode_num;
14256 nondigit = c;
14257 break;
14258
14259 default:
14260 goto decode_num;
14261 }
14262 c = nextc();
14263 }
14264
14265 decode_num:
14266 pushback(c);
14267 if (nondigit) {
14268 char tmp[30];
14269 trailing_uc:
14270 snprintf(tmp, sizeof(tmp), "trailing `%c' in number", nondigit);
14271 yyerror(tmp);
14272 }
14273 tokfix();
14274 if (is_float) {
14275 int type = tFLOAT;
14276 VALUE v;
14277
14278 suffix = number_literal_suffix(seen_e ? NUM_SUFFIX_I : NUM_SUFFIX_ALL);
14279 if (suffix & NUM_SUFFIX_R) {
14280 char *point = &tok()[seen_point];
14281 size_t fraclen = toklen()-seen_point-1;
14282 type = tRATIONAL;
14283 memmove(point, point+1, fraclen+1);
14284 v = rb_cstr_to_inum(tok(), 10, FALSE);
14285 v = rb_rational_new(v, rb_int_positive_pow(10, fraclen));
14286 }
14287 else {
14288 double d = strtod(tok(), 0);
14289 if (errno == ERANGE) {
14290 rb_warningS("Float %s out of range", tok());
14291 errno = 0;
14292 }
14293 v = DBL2NUM(d);
14294 }
14295 return set_number_literal(v, type, suffix);
14296 }
14297 suffix = number_literal_suffix(NUM_SUFFIX_ALL);
14298 return set_integer_literal(rb_cstr_to_inum(tok(), 10, FALSE), suffix);
14299 }
14300
14301 case ')':
14302 case ']':
14303 paren_nest--;
14304 case '}':
14305 COND_LEXPOP();
14306 CMDARG_LEXPOP();
14307 if (c == ')')
14308 lex_state = EXPR_ENDFN;
14309 else
14310 lex_state = EXPR_ENDARG;
14311 if (c == '}') {
14312 if (!brace_nest--) c = tSTRING_DEND;
14313 }
14314 return c;
14315
14316 case ':':
14317 c = nextc();
14318 if (c == ':') {
14319 if (IS_BEG() || IS_lex_state(EXPR_CLASS) || IS_SPCARG(-1)) {
14320 lex_state = EXPR_BEG;
14321 return tCOLON3;
14322 }
14323 lex_state = EXPR_DOT;
14324 return tCOLON2;
14325 }
14326 if (IS_END() || ISSPACE(c)) {
14327 pushback(c);
14328 warn_balanced(":", "symbol literal");
14329 lex_state = EXPR_BEG;
14330 return ':';
14331 }
14332 switch (c) {
14333 case '\'':
14334 lex_strterm = NEW_STRTERM(str_ssym, c, 0);
14335 break;
14336 case '"':
14337 lex_strterm = NEW_STRTERM(str_dsym, c, 0);
14338 break;
14339 default:
14340 pushback(c);
14341 break;
14342 }
14343 lex_state = EXPR_FNAME;
14344 return tSYMBEG;
14345
14346 case '/':
14347 if (IS_lex_state(EXPR_BEG_ANY)) {
14348 lex_strterm = NEW_STRTERM(str_regexp, '/', 0);
14349 return tREGEXP_BEG;
14350 }
14351 if ((c = nextc()) == '=') {
14352 set_yylval_id('/');
14353 lex_state = EXPR_BEG;
14354 return tOP_ASGN;
14355 }
14356 pushback(c);
14357 if (IS_SPCARG(c)) {
14358 (void)arg_ambiguous();
14359 lex_strterm = NEW_STRTERM(str_regexp, '/', 0);
14360 return tREGEXP_BEG;
14361 }
14362 lex_state = IS_AFTER_OPERATOR() ? EXPR_ARG : EXPR_BEG;
14363 warn_balanced("/", "regexp literal");
14364 return '/';
14365
14366 case '^':
14367 if ((c = nextc()) == '=') {
14368 set_yylval_id('^');
14369 lex_state = EXPR_BEG;
14370 return tOP_ASGN;
14371 }
14372 lex_state = IS_AFTER_OPERATOR() ? EXPR_ARG : EXPR_BEG;
14373 pushback(c);
14374 return '^';
14375
14376 case ';':
14377 lex_state = EXPR_BEG;
14378 command_start = TRUE;
14379 return ';';
14380
14381 case ',':
14382 lex_state = EXPR_BEG;
14383 return ',';
14384
14385 case '~':
14386 if (IS_AFTER_OPERATOR()) {
14387 if ((c = nextc()) != '@') {
14388 pushback(c);
14389 }
14390 lex_state = EXPR_ARG;
14391 }
14392 else {
14393 lex_state = EXPR_BEG;
14394 }
14395 return '~';
14396
14397 case '(':
14398 if (IS_BEG()) {
14399 c = tLPAREN;
14400 }
14401 else if (IS_SPCARG(-1)) {
14402 c = tLPAREN_ARG;
14403 }
14404 paren_nest++;
14405 COND_PUSH(0);
14406 CMDARG_PUSH(0);
14407 lex_state = EXPR_BEG;
14408 return c;
14409
14410 case '[':
14411 paren_nest++;
14412 if (IS_AFTER_OPERATOR()) {
14413 lex_state = EXPR_ARG;
14414 if ((c = nextc()) == ']') {
14415 if ((c = nextc()) == '=') {
14416 return tASET;
14417 }
14418 pushback(c);
14419 return tAREF;
14420 }
14421 pushback(c);
14422 return '[';
14423 }
14424 else if (IS_BEG()) {
14425 c = tLBRACK;
14426 }
14427 else if (IS_ARG() && space_seen) {
14428 c = tLBRACK;
14429 }
14430 lex_state = EXPR_BEG;
14431 COND_PUSH(0);
14432 CMDARG_PUSH(0);
14433 return c;
14434
14435 case '{':
14436 ++brace_nest;
14437 if (lpar_beg && lpar_beg == paren_nest) {
14438 lex_state = EXPR_BEG;
14439 lpar_beg = 0;
14440 --paren_nest;
14441 COND_PUSH(0);
14442 CMDARG_PUSH(0);
14443 return tLAMBEG;
14444 }
14445 if (IS_ARG() || IS_lex_state(EXPR_END | EXPR_ENDFN))
14446 c = '{';
14447 else if (IS_lex_state(EXPR_ENDARG))
14448 c = tLBRACE_ARG;
14449 else
14450 c = tLBRACE;
14451 COND_PUSH(0);
14452 CMDARG_PUSH(0);
14453 lex_state = EXPR_BEG;
14454 if (c != tLBRACE) command_start = TRUE;
14455 return c;
14456
14457 case '\\':
14458 c = nextc();
14459 if (c == '\n') {
14460 space_seen = 1;
14461 #ifdef RIPPER
14462 ripper_dispatch_scan_event(parser, tSP);
14463 #endif
14464 goto retry;
14465 }
14466 pushback(c);
14467 return '\\';
14468
14469 case '%':
14470 if (IS_lex_state(EXPR_BEG_ANY)) {
14471 int term;
14472 int paren;
14473
14474 c = nextc();
14475 quotation:
14476 if (c == -1 || !ISALNUM(c)) {
14477 term = c;
14478 c = 'Q';
14479 }
14480 else {
14481 term = nextc();
14482 if (rb_enc_isalnum(term, current_enc) || !parser_isascii()) {
14483 yyerror("unknown type of %string");
14484 return 0;
14485 }
14486 }
14487 if (c == -1 || term == -1) {
14488 compile_error(PARSER_ARG "unterminated quoted string meets end of file");
14489 return 0;
14490 }
14491 paren = term;
14492 if (term == '(') term = ')';
14493 else if (term == '[') term = ']';
14494 else if (term == '{') term = '}';
14495 else if (term == '<') term = '>';
14496 else paren = 0;
14497
14498 switch (c) {
14499 case 'Q':
14500 lex_strterm = NEW_STRTERM(str_dquote, term, paren);
14501 return tSTRING_BEG;
14502
14503 case 'q':
14504 lex_strterm = NEW_STRTERM(str_squote, term, paren);
14505 return tSTRING_BEG;
14506
14507 case 'W':
14508 lex_strterm = NEW_STRTERM(str_dword, term, paren);
14509 do {c = nextc();} while (ISSPACE(c));
14510 pushback(c);
14511 return tWORDS_BEG;
14512
14513 case 'w':
14514 lex_strterm = NEW_STRTERM(str_sword, term, paren);
14515 do {c = nextc();} while (ISSPACE(c));
14516 pushback(c);
14517 return tQWORDS_BEG;
14518
14519 case 'I':
14520 lex_strterm = NEW_STRTERM(str_dword, term, paren);
14521 do {c = nextc();} while (ISSPACE(c));
14522 pushback(c);
14523 return tSYMBOLS_BEG;
14524
14525 case 'i':
14526 lex_strterm = NEW_STRTERM(str_sword, term, paren);
14527 do {c = nextc();} while (ISSPACE(c));
14528 pushback(c);
14529 return tQSYMBOLS_BEG;
14530
14531 case 'x':
14532 lex_strterm = NEW_STRTERM(str_xquote, term, paren);
14533 return tXSTRING_BEG;
14534
14535 case 'r':
14536 lex_strterm = NEW_STRTERM(str_regexp, term, paren);
14537 return tREGEXP_BEG;
14538
14539 case 's':
14540 lex_strterm = NEW_STRTERM(str_ssym, term, paren);
14541 lex_state = EXPR_FNAME;
14542 return tSYMBEG;
14543
14544 default:
14545 yyerror("unknown type of %string");
14546 return 0;
14547 }
14548 }
14549 if ((c = nextc()) == '=') {
14550 set_yylval_id('%');
14551 lex_state = EXPR_BEG;
14552 return tOP_ASGN;
14553 }
14554 if (IS_SPCARG(c)) {
14555 goto quotation;
14556 }
14557 lex_state = IS_AFTER_OPERATOR() ? EXPR_ARG : EXPR_BEG;
14558 pushback(c);
14559 warn_balanced("%%", "string literal");
14560 return '%';
14561
14562 case '$':
14563 lex_state = EXPR_END;
14564 newtok();
14565 c = nextc();
14566 switch (c) {
14567 case '_':
14568 c = nextc();
14569 if (parser_is_identchar()) {
14570 tokadd('$');
14571 tokadd('_');
14572 break;
14573 }
14574 pushback(c);
14575 c = '_';
14576
14577 case '~':
14578 case '*':
14579 case '$':
14580 case '?':
14581 case '!':
14582 case '@':
14583 case '/':
14584 case '\\':
14585 case ';':
14586 case ',':
14587 case '.':
14588 case '=':
14589 case ':':
14590 case '<':
14591 case '>':
14592 case '\"':
14593 tokadd('$');
14594 tokadd(c);
14595 goto gvar;
14596
14597 case '-':
14598 tokadd('$');
14599 tokadd(c);
14600 c = nextc();
14601 if (parser_is_identchar()) {
14602 if (tokadd_mbchar(c) == -1) return 0;
14603 }
14604 else {
14605 pushback(c);
14606 pushback('-');
14607 return '$';
14608 }
14609 gvar:
14610 set_yylval_name(rb_intern3(tok(), tokidx, current_enc));
14611 return tGVAR;
14612
14613 case '&':
14614 case '`':
14615 case '\'':
14616 case '+':
14617 if (IS_lex_state_for(last_state, EXPR_FNAME)) {
14618 tokadd('$');
14619 tokadd(c);
14620 goto gvar;
14621 }
14622 set_yylval_node(NEW_BACK_REF(c));
14623 return tBACK_REF;
14624
14625 case '1': case '2': case '3':
14626 case '4': case '5': case '6':
14627 case '7': case '8': case '9':
14628 tokadd('$');
14629 do {
14630 tokadd(c);
14631 c = nextc();
14632 } while (c != -1 && ISDIGIT(c));
14633 pushback(c);
14634 if (IS_lex_state_for(last_state, EXPR_FNAME)) goto gvar;
14635 tokfix();
14636 set_yylval_node(NEW_NTH_REF(atoi(tok()+1)));
14637 return tNTH_REF;
14638
14639 default:
14640 if (!parser_is_identchar()) {
14641 pushback(c);
14642 compile_error(PARSER_ARG "`$%c' is not allowed as a global variable name", c);
14643 return 0;
14644 }
14645 case '0':
14646 tokadd('$');
14647 }
14648 break;
14649
14650 case '@':
14651 c = nextc();
14652 newtok();
14653 tokadd('@');
14654 if (c == '@') {
14655 tokadd('@');
14656 c = nextc();
14657 }
14658 if (c != -1 && (ISDIGIT(c) || !parser_is_identchar())) {
14659 pushback(c);
14660 if (tokidx == 1) {
14661 compile_error(PARSER_ARG "`@%c' is not allowed as an instance variable name", c);
14662 }
14663 else {
14664 compile_error(PARSER_ARG "`@@%c' is not allowed as a class variable name", c);
14665 }
14666 return 0;
14667 }
14668 break;
14669
14670 case '_':
14671 if (was_bol() && whole_match_p("__END__", 7, 0)) {
14672 ruby__end__seen = 1;
14673 parser->eofp = Qtrue;
14674 #ifndef RIPPER
14675 return -1;
14676 #else
14677 lex_goto_eol(parser);
14678 ripper_dispatch_scan_event(parser, k__END__);
14679 return 0;
14680 #endif
14681 }
14682 newtok();
14683 break;
14684
14685 default:
14686 if (!parser_is_identchar()) {
14687 compile_error(PARSER_ARG "Invalid char `\\x%02X' in expression", c);
14688 goto retry;
14689 }
14690
14691 newtok();
14692 break;
14693 }
14694
14695 mb = ENC_CODERANGE_7BIT;
14696 do {
14697 if (!ISASCII(c)) mb = ENC_CODERANGE_UNKNOWN;
14698 if (tokadd_mbchar(c) == -1) return 0;
14699 c = nextc();
14700 } while (parser_is_identchar());
14701 switch (tok()[0]) {
14702 case '@': case '$':
14703 pushback(c);
14704 break;
14705 default:
14706 if ((c == '!' || c == '?') && !peek('=')) {
14707 tokadd(c);
14708 }
14709 else {
14710 pushback(c);
14711 }
14712 }
14713 tokfix();
14714
14715 {
14716 int result = 0;
14717
14718 last_state = lex_state;
14719 switch (tok()[0]) {
14720 case '$':
14721 lex_state = EXPR_END;
14722 result = tGVAR;
14723 break;
14724 case '@':
14725 lex_state = EXPR_END;
14726 if (tok()[1] == '@')
14727 result = tCVAR;
14728 else
14729 result = tIVAR;
14730 break;
14731
14732 default:
14733 if (toklast() == '!' || toklast() == '?') {
14734 result = tFID;
14735 }
14736 else {
14737 if (IS_lex_state(EXPR_FNAME)) {
14738 if ((c = nextc()) == '=' && !peek('~') && !peek('>') &&
14739 (!peek('=') || (peek_n('>', 1)))) {
14740 result = tIDENTIFIER;
14741 tokadd(c);
14742 tokfix();
14743 }
14744 else {
14745 pushback(c);
14746 }
14747 }
14748 if (result == 0 && ISUPPER(tok()[0])) {
14749 result = tCONSTANT;
14750 }
14751 else {
14752 result = tIDENTIFIER;
14753 }
14754 }
14755
14756 if (IS_LABEL_POSSIBLE()) {
14757 if (IS_LABEL_SUFFIX(0)) {
14758 lex_state = EXPR_LABELARG;
14759 nextc();
14760 set_yylval_name(TOK_INTERN(!ENC_SINGLE(mb)));
14761 return tLABEL;
14762 }
14763 }
14764 if (mb == ENC_CODERANGE_7BIT && !IS_lex_state(EXPR_DOT)) {
14765 const struct kwtable *kw;
14766
14767
14768 kw = rb_reserved_word(tok(), toklen());
14769 if (kw) {
14770 enum lex_state_e state = lex_state;
14771 lex_state = kw->state;
14772 if (IS_lex_state_for(state, EXPR_FNAME)) {
14773 set_yylval_name(rb_intern(kw->name));
14774 return kw->id[0];
14775 }
14776 if (IS_lex_state(EXPR_BEG)) {
14777 command_start = TRUE;
14778 }
14779 if (kw->id[0] == keyword_do) {
14780 if (lpar_beg && lpar_beg == paren_nest) {
14781 lpar_beg = 0;
14782 --paren_nest;
14783 return keyword_do_LAMBDA;
14784 }
14785 if (COND_P()) return keyword_do_cond;
14786 if (CMDARG_P() && !IS_lex_state_for(state, EXPR_CMDARG))
14787 return keyword_do_block;
14788 if (IS_lex_state_for(state, (EXPR_BEG | EXPR_ENDARG)))
14789 return keyword_do_block;
14790 return keyword_do;
14791 }
14792 if (IS_lex_state_for(state, (EXPR_BEG | EXPR_VALUE | EXPR_LABELARG)))
14793 return kw->id[0];
14794 else {
14795 if (kw->id[0] != kw->id[1])
14796 lex_state = EXPR_BEG;
14797 return kw->id[1];
14798 }
14799 }
14800 }
14801
14802 if (IS_lex_state(EXPR_BEG_ANY | EXPR_ARG_ANY | EXPR_DOT)) {
14803 if (cmd_state) {
14804 lex_state = EXPR_CMDARG;
14805 }
14806 else {
14807 lex_state = EXPR_ARG;
14808 }
14809 }
14810 else if (lex_state == EXPR_FNAME) {
14811 lex_state = EXPR_ENDFN;
14812 }
14813 else {
14814 lex_state = EXPR_END;
14815 }
14816 }
14817 {
14818 ID ident = TOK_INTERN(!ENC_SINGLE(mb));
14819
14820 set_yylval_name(ident);
14821 if (!IS_lex_state_for(last_state, EXPR_DOT|EXPR_FNAME) &&
14822 is_local_id(ident) && lvar_defined(ident)) {
14823 lex_state = EXPR_END;
14824 }
14825 }
14826 return result;
14827 }
14828 }
14829
14830 #if YYPURE
14831 static int
14832 yylex(void *lval, void *p)
14833 #else
14834 yylex(void *p)
14835 #endif
14836 {
14837 struct parser_params *parser = (struct parser_params*)p;
14838 int t;
14839
14840 #if YYPURE
14841 parser->parser_yylval = lval;
14842 parser->parser_yylval->val = Qundef;
14843 #endif
14844 t = parser_yylex(parser);
14845 #ifdef RIPPER
14846 if (!NIL_P(parser->delayed)) {
14847 ripper_dispatch_delayed_token(parser, t);
14848 return t;
14849 }
14850 if (t != 0)
14851 ripper_dispatch_scan_event(parser, t);
14852 #endif
14853
14854 return t;
14855 }
14856
14857 #ifndef RIPPER
14858 static NODE*
14859 node_newnode(struct parser_params *parser, enum node_type type, VALUE a0, VALUE a1, VALUE a2)
14860 {
14861 NODE *n = (rb_node_newnode)(type, a0, a1, a2);
14862 nd_set_line(n, ruby_sourceline);
14863 return n;
14864 }
14865
14866 static enum node_type
14867 nodetype(NODE *node)
14868 {
14869 return (enum node_type)nd_type(node);
14870 }
14871
14872 static int
14873 nodeline(NODE *node)
14874 {
14875 return nd_line(node);
14876 }
14877
14878 static NODE*
14879 newline_node(NODE *node)
14880 {
14881 if (node) {
14882 node = remove_begin(node);
14883 node->flags |= NODE_FL_NEWLINE;
14884 }
14885 return node;
14886 }
14887
14888 static void
14889 fixpos(NODE *node, NODE *orig)
14890 {
14891 if (!node) return;
14892 if (!orig) return;
14893 if (orig == (NODE*)1) return;
14894 nd_set_line(node, nd_line(orig));
14895 }
14896
14897 static void
14898 parser_warning(struct parser_params *parser, NODE *node, const char *mesg)
14899 {
14900 rb_compile_warning(ruby_sourcefile, nd_line(node), "%s", mesg);
14901 }
14902 #define parser_warning(node, mesg) parser_warning(parser, (node), (mesg))
14903
14904 static void
14905 parser_warn(struct parser_params *parser, NODE *node, const char *mesg)
14906 {
14907 rb_compile_warn(ruby_sourcefile, nd_line(node), "%s", mesg);
14908 }
14909 #define parser_warn(node, mesg) parser_warn(parser, (node), (mesg))
14910
14911 static NODE*
14912 block_append_gen(struct parser_params *parser, NODE *head, NODE *tail)
14913 {
14914 NODE *end, *h = head, *nd;
14915
14916 if (tail == 0) return head;
14917
14918 if (h == 0) return tail;
14919 switch (nd_type(h)) {
14920 case NODE_LIT:
14921 case NODE_STR:
14922 case NODE_SELF:
14923 case NODE_TRUE:
14924 case NODE_FALSE:
14925 case NODE_NIL:
14926 parser_warning(h, "unused literal ignored");
14927 return tail;
14928 default:
14929 h = end = NEW_BLOCK(head);
14930 end->nd_end = end;
14931 fixpos(end, head);
14932 head = end;
14933 break;
14934 case NODE_BLOCK:
14935 end = h->nd_end;
14936 break;
14937 }
14938
14939 nd = end->nd_head;
14940 switch (nd_type(nd)) {
14941 case NODE_RETURN:
14942 case NODE_BREAK:
14943 case NODE_NEXT:
14944 case NODE_REDO:
14945 case NODE_RETRY:
14946 if (RTEST(ruby_verbose)) {
14947 parser_warning(tail, "statement not reached");
14948 }
14949 break;
14950
14951 default:
14952 break;
14953 }
14954
14955 if (nd_type(tail) != NODE_BLOCK) {
14956 tail = NEW_BLOCK(tail);
14957 tail->nd_end = tail;
14958 }
14959 end->nd_next = tail;
14960 h->nd_end = tail->nd_end;
14961 return head;
14962 }
14963
14964
14965 static NODE*
14966 list_append_gen(struct parser_params *parser, NODE *list, NODE *item)
14967 {
14968 NODE *last;
14969
14970 if (list == 0) return NEW_LIST(item);
14971 if (list->nd_next) {
14972 last = list->nd_next->nd_end;
14973 }
14974 else {
14975 last = list;
14976 }
14977
14978 list->nd_alen += 1;
14979 last->nd_next = NEW_LIST(item);
14980 list->nd_next->nd_end = last->nd_next;
14981 return list;
14982 }
14983
14984
14985 static NODE*
14986 list_concat_gen(struct parser_params *parser, NODE *head, NODE *tail)
14987 {
14988 NODE *last;
14989
14990 if (head->nd_next) {
14991 last = head->nd_next->nd_end;
14992 }
14993 else {
14994 last = head;
14995 }
14996
14997 head->nd_alen += tail->nd_alen;
14998 last->nd_next = tail;
14999 if (tail->nd_next) {
15000 head->nd_next->nd_end = tail->nd_next->nd_end;
15001 }
15002 else {
15003 head->nd_next->nd_end = tail;
15004 }
15005
15006 return head;
15007 }
15008
15009 static int
15010 literal_concat0(struct parser_params *parser, VALUE head, VALUE tail)
15011 {
15012 if (NIL_P(tail)) return 1;
15013 if (!rb_enc_compatible(head, tail)) {
15014 compile_error(PARSER_ARG "string literal encodings differ (%s / %s)",
15015 rb_enc_name(rb_enc_get(head)),
15016 rb_enc_name(rb_enc_get(tail)));
15017 rb_str_resize(head, 0);
15018 rb_str_resize(tail, 0);
15019 return 0;
15020 }
15021 rb_str_buf_append(head, tail);
15022 return 1;
15023 }
15024
15025
15026 static NODE *
15027 literal_concat_gen(struct parser_params *parser, NODE *head, NODE *tail)
15028 {
15029 enum node_type htype;
15030 NODE *headlast;
15031 VALUE lit;
15032
15033 if (!head) return tail;
15034 if (!tail) return head;
15035
15036 htype = nd_type(head);
15037 if (htype == NODE_EVSTR) {
15038 NODE *node = NEW_DSTR(Qnil);
15039 head = list_append(node, head);
15040 htype = NODE_DSTR;
15041 }
15042 switch (nd_type(tail)) {
15043 case NODE_STR:
15044 if (htype == NODE_DSTR && (headlast = head->nd_next->nd_end->nd_head) &&
15045 nd_type(headlast) == NODE_STR) {
15046 htype = NODE_STR;
15047 lit = headlast->nd_lit;
15048 }
15049 else {
15050 lit = head->nd_lit;
15051 }
15052 if (htype == NODE_STR) {
15053 if (!literal_concat0(parser, lit, tail->nd_lit)) {
15054 error:
15055 rb_gc_force_recycle((VALUE)head);
15056 rb_gc_force_recycle((VALUE)tail);
15057 return 0;
15058 }
15059 rb_gc_force_recycle((VALUE)tail);
15060 }
15061 else {
15062 list_append(head, tail);
15063 }
15064 break;
15065
15066 case NODE_DSTR:
15067 if (htype == NODE_STR) {
15068 if (!literal_concat0(parser, head->nd_lit, tail->nd_lit))
15069 goto error;
15070 tail->nd_lit = head->nd_lit;
15071 rb_gc_force_recycle((VALUE)head);
15072 head = tail;
15073 }
15074 else if (NIL_P(tail->nd_lit)) {
15075 append:
15076 head->nd_alen += tail->nd_alen - 1;
15077 head->nd_next->nd_end->nd_next = tail->nd_next;
15078 head->nd_next->nd_end = tail->nd_next->nd_end;
15079 rb_gc_force_recycle((VALUE)tail);
15080 }
15081 else if (htype == NODE_DSTR && (headlast = head->nd_next->nd_end->nd_head) &&
15082 nd_type(headlast) == NODE_STR) {
15083 lit = headlast->nd_lit;
15084 if (!literal_concat0(parser, lit, tail->nd_lit))
15085 goto error;
15086 tail->nd_lit = Qnil;
15087 goto append;
15088 }
15089 else {
15090 nd_set_type(tail, NODE_ARRAY);
15091 tail->nd_head = NEW_STR(tail->nd_lit);
15092 list_concat(head, tail);
15093 }
15094 break;
15095
15096 case NODE_EVSTR:
15097 if (htype == NODE_STR) {
15098 nd_set_type(head, NODE_DSTR);
15099 head->nd_alen = 1;
15100 }
15101 list_append(head, tail);
15102 break;
15103 }
15104 return head;
15105 }
15106
15107 static NODE *
15108 evstr2dstr_gen(struct parser_params *parser, NODE *node)
15109 {
15110 if (nd_type(node) == NODE_EVSTR) {
15111 node = list_append(NEW_DSTR(Qnil), node);
15112 }
15113 return node;
15114 }
15115
15116 static NODE *
15117 new_evstr_gen(struct parser_params *parser, NODE *node)
15118 {
15119 NODE *head = node;
15120
15121 if (node) {
15122 switch (nd_type(node)) {
15123 case NODE_STR: case NODE_DSTR: case NODE_EVSTR:
15124 return node;
15125 }
15126 }
15127 return NEW_EVSTR(head);
15128 }
15129
15130 static NODE *
15131 call_bin_op_gen(struct parser_params *parser, NODE *recv, ID id, NODE *arg1)
15132 {
15133 value_expr(recv);
15134 value_expr(arg1);
15135 return NEW_CALL(recv, id, NEW_LIST(arg1));
15136 }
15137
15138 static NODE *
15139 call_uni_op_gen(struct parser_params *parser, NODE *recv, ID id)
15140 {
15141 value_expr(recv);
15142 return NEW_CALL(recv, id, 0);
15143 }
15144
15145 static NODE*
15146 match_op_gen(struct parser_params *parser, NODE *node1, NODE *node2)
15147 {
15148 value_expr(node1);
15149 value_expr(node2);
15150 if (node1) {
15151 switch (nd_type(node1)) {
15152 case NODE_DREGX:
15153 case NODE_DREGX_ONCE:
15154 return NEW_MATCH2(node1, node2);
15155
15156 case NODE_LIT:
15157 if (RB_TYPE_P(node1->nd_lit, T_REGEXP)) {
15158 return NEW_MATCH2(node1, node2);
15159 }
15160 }
15161 }
15162
15163 if (node2) {
15164 switch (nd_type(node2)) {
15165 case NODE_DREGX:
15166 case NODE_DREGX_ONCE:
15167 return NEW_MATCH3(node2, node1);
15168
15169 case NODE_LIT:
15170 if (RB_TYPE_P(node2->nd_lit, T_REGEXP)) {
15171 return NEW_MATCH3(node2, node1);
15172 }
15173 }
15174 }
15175
15176 return NEW_CALL(node1, tMATCH, NEW_LIST(node2));
15177 }
15178
15179 static NODE*
15180 gettable_gen(struct parser_params *parser, ID id)
15181 {
15182 switch (id) {
15183 case keyword_self:
15184 return NEW_SELF();
15185 case keyword_nil:
15186 return NEW_NIL();
15187 case keyword_true:
15188 return NEW_TRUE();
15189 case keyword_false:
15190 return NEW_FALSE();
15191 case keyword__FILE__:
15192 return NEW_STR(rb_str_dup(ruby_sourcefile_string));
15193 case keyword__LINE__:
15194 return NEW_LIT(INT2FIX(tokline));
15195 case keyword__ENCODING__:
15196 return NEW_LIT(rb_enc_from_encoding(current_enc));
15197 }
15198 switch (id_type(id)) {
15199 case ID_LOCAL:
15200 if (dyna_in_block() && dvar_defined(id)) return NEW_DVAR(id);
15201 if (local_id(id)) return NEW_LVAR(id);
15202
15203 return NEW_VCALL(id);
15204 case ID_GLOBAL:
15205 return NEW_GVAR(id);
15206 case ID_INSTANCE:
15207 return NEW_IVAR(id);
15208 case ID_CONST:
15209 return NEW_CONST(id);
15210 case ID_CLASS:
15211 return NEW_CVAR(id);
15212 }
15213 compile_error(PARSER_ARG "identifier %s is not valid to get", rb_id2name(id));
15214 return 0;
15215 }
15216 #else
15217 static int
15218 id_is_var_gen(struct parser_params *parser, ID id)
15219 {
15220 if (is_notop_id(id)) {
15221 switch (id & ID_SCOPE_MASK) {
15222 case ID_GLOBAL: case ID_INSTANCE: case ID_CONST: case ID_CLASS:
15223 return 1;
15224 case ID_LOCAL:
15225 if (dyna_in_block() && dvar_defined(id)) return 1;
15226 if (local_id(id)) return 1;
15227
15228 return 0;
15229 }
15230 }
15231 compile_error(PARSER_ARG "identifier %s is not valid to get", rb_id2name(id));
15232 return 0;
15233 }
15234 #endif
15235
15236 #if PARSER_DEBUG
15237 static const char *
15238 lex_state_name(enum lex_state_e state)
15239 {
15240 static const char names[][12] = {
15241 "EXPR_BEG", "EXPR_END", "EXPR_ENDARG", "EXPR_ENDFN", "EXPR_ARG",
15242 "EXPR_CMDARG", "EXPR_MID", "EXPR_FNAME", "EXPR_DOT", "EXPR_CLASS",
15243 "EXPR_VALUE",
15244 };
15245
15246 if ((unsigned)state & ~(~0u << EXPR_MAX_STATE))
15247 return names[ffs(state)];
15248 return NULL;
15249 }
15250 #endif
15251
15252 #ifdef RIPPER
15253 static VALUE
15254 assignable_gen(struct parser_params *parser, VALUE lhs)
15255 #else
15256 static NODE*
15257 assignable_gen(struct parser_params *parser, ID id, NODE *val)
15258 #endif
15259 {
15260 #ifdef RIPPER
15261 ID id = get_id(lhs);
15262 # define assignable_result(x) get_value(lhs)
15263 # define parser_yyerror(parser, x) dispatch1(assign_error, lhs)
15264 #else
15265 # define assignable_result(x) (x)
15266 #endif
15267 if (!id) return assignable_result(0);
15268 switch (id) {
15269 case keyword_self:
15270 yyerror("Can't change the value of self");
15271 goto error;
15272 case keyword_nil:
15273 yyerror("Can't assign to nil");
15274 goto error;
15275 case keyword_true:
15276 yyerror("Can't assign to true");
15277 goto error;
15278 case keyword_false:
15279 yyerror("Can't assign to false");
15280 goto error;
15281 case keyword__FILE__:
15282 yyerror("Can't assign to __FILE__");
15283 goto error;
15284 case keyword__LINE__:
15285 yyerror("Can't assign to __LINE__");
15286 goto error;
15287 case keyword__ENCODING__:
15288 yyerror("Can't assign to __ENCODING__");
15289 goto error;
15290 }
15291 switch (id_type(id)) {
15292 case ID_LOCAL:
15293 if (dyna_in_block()) {
15294 if (dvar_curr(id)) {
15295 return assignable_result(NEW_DASGN_CURR(id, val));
15296 }
15297 else if (dvar_defined(id)) {
15298 return assignable_result(NEW_DASGN(id, val));
15299 }
15300 else if (local_id(id)) {
15301 return assignable_result(NEW_LASGN(id, val));
15302 }
15303 else {
15304 dyna_var(id);
15305 return assignable_result(NEW_DASGN_CURR(id, val));
15306 }
15307 }
15308 else {
15309 if (!local_id(id)) {
15310 local_var(id);
15311 }
15312 return assignable_result(NEW_LASGN(id, val));
15313 }
15314 break;
15315 case ID_GLOBAL:
15316 return assignable_result(NEW_GASGN(id, val));
15317 case ID_INSTANCE:
15318 return assignable_result(NEW_IASGN(id, val));
15319 case ID_CONST:
15320 if (!in_def && !in_single)
15321 return assignable_result(NEW_CDECL(id, val, 0));
15322 yyerror("dynamic constant assignment");
15323 break;
15324 case ID_CLASS:
15325 return assignable_result(NEW_CVASGN(id, val));
15326 default:
15327 compile_error(PARSER_ARG "identifier %s is not valid to set", rb_id2name(id));
15328 }
15329 error:
15330 return assignable_result(0);
15331 #undef assignable_result
15332 #undef parser_yyerror
15333 }
15334
15335 static int
15336 is_private_local_id(ID name)
15337 {
15338 VALUE s;
15339 if (name == idUScore) return 1;
15340 if (!is_local_id(name)) return 0;
15341 s = rb_id2str(name);
15342 if (!s) return 0;
15343 return RSTRING_PTR(s)[0] == '_';
15344 }
15345
15346 #define LVAR_USED ((ID)1 << (sizeof(ID) * CHAR_BIT - 1))
15347
15348 static int
15349 shadowing_lvar_0(struct parser_params *parser, ID name)
15350 {
15351 if (is_private_local_id(name)) return 1;
15352 if (dyna_in_block()) {
15353 if (dvar_curr(name)) {
15354 yyerror("duplicated argument name");
15355 }
15356 else if (dvar_defined_get(name) || local_id(name)) {
15357 rb_warningS("shadowing outer local variable - %s", rb_id2name(name));
15358 vtable_add(lvtbl->vars, name);
15359 if (lvtbl->used) {
15360 vtable_add(lvtbl->used, (ID)ruby_sourceline | LVAR_USED);
15361 }
15362 return 0;
15363 }
15364 }
15365 else {
15366 if (local_id(name)) {
15367 yyerror("duplicated argument name");
15368 }
15369 }
15370 return 1;
15371 }
15372
15373 static ID
15374 shadowing_lvar_gen(struct parser_params *parser, ID name)
15375 {
15376 shadowing_lvar_0(parser, name);
15377 return name;
15378 }
15379
15380 static void
15381 new_bv_gen(struct parser_params *parser, ID name)
15382 {
15383 if (!name) return;
15384 if (!is_local_id(name)) {
15385 compile_error(PARSER_ARG "invalid local variable - %s",
15386 rb_id2name(name));
15387 return;
15388 }
15389 if (!shadowing_lvar_0(parser, name)) return;
15390 dyna_var(name);
15391 }
15392
15393 #ifndef RIPPER
15394 static NODE *
15395 aryset_gen(struct parser_params *parser, NODE *recv, NODE *idx)
15396 {
15397 if (recv && nd_type(recv) == NODE_SELF)
15398 recv = (NODE *)1;
15399 return NEW_ATTRASGN(recv, tASET, idx);
15400 }
15401
15402 static void
15403 block_dup_check_gen(struct parser_params *parser, NODE *node1, NODE *node2)
15404 {
15405 if (node2 && node1 && nd_type(node1) == NODE_BLOCK_PASS) {
15406 compile_error(PARSER_ARG "both block arg and actual block given");
15407 }
15408 }
15409
15410 static const char id_type_names[][9] = {
15411 "LOCAL",
15412 "INSTANCE",
15413 "",
15414 "GLOBAL",
15415 "ATTRSET",
15416 "CONST",
15417 "CLASS",
15418 "JUNK",
15419 };
15420
15421 ID
15422 rb_id_attrset(ID id)
15423 {
15424 if (!is_notop_id(id)) {
15425 switch (id) {
15426 case tAREF: case tASET:
15427 return tASET;
15428 }
15429 rb_name_error(id, "cannot make operator ID :%s attrset", rb_id2name(id));
15430 }
15431 else {
15432 int scope = (int)(id & ID_SCOPE_MASK);
15433 switch (scope) {
15434 case ID_LOCAL: case ID_INSTANCE: case ID_GLOBAL:
15435 case ID_CONST: case ID_CLASS: case ID_JUNK:
15436 break;
15437 case ID_ATTRSET:
15438 return id;
15439 default:
15440 rb_name_error(id, "cannot make %s ID %+"PRIsVALUE" attrset",
15441 id_type_names[scope], ID2SYM(id));
15442
15443 }
15444 }
15445 id &= ~ID_SCOPE_MASK;
15446 id |= ID_ATTRSET;
15447 return id;
15448 }
15449
15450 static NODE *
15451 attrset_gen(struct parser_params *parser, NODE *recv, ID id)
15452 {
15453 if (recv && nd_type(recv) == NODE_SELF)
15454 recv = (NODE *)1;
15455 return NEW_ATTRASGN(recv, rb_id_attrset(id), 0);
15456 }
15457
15458 static void
15459 rb_backref_error_gen(struct parser_params *parser, NODE *node)
15460 {
15461 switch (nd_type(node)) {
15462 case NODE_NTH_REF:
15463 compile_error(PARSER_ARG "Can't set variable $%ld", node->nd_nth);
15464 break;
15465 case NODE_BACK_REF:
15466 compile_error(PARSER_ARG "Can't set variable $%c", (int)node->nd_nth);
15467 break;
15468 }
15469 }
15470
15471 static NODE *
15472 arg_concat_gen(struct parser_params *parser, NODE *node1, NODE *node2)
15473 {
15474 if (!node2) return node1;
15475 switch (nd_type(node1)) {
15476 case NODE_BLOCK_PASS:
15477 if (node1->nd_head)
15478 node1->nd_head = arg_concat(node1->nd_head, node2);
15479 else
15480 node1->nd_head = NEW_LIST(node2);
15481 return node1;
15482 case NODE_ARGSPUSH:
15483 if (nd_type(node2) != NODE_ARRAY) break;
15484 node1->nd_body = list_concat(NEW_LIST(node1->nd_body), node2);
15485 nd_set_type(node1, NODE_ARGSCAT);
15486 return node1;
15487 case NODE_ARGSCAT:
15488 if (nd_type(node2) != NODE_ARRAY ||
15489 nd_type(node1->nd_body) != NODE_ARRAY) break;
15490 node1->nd_body = list_concat(node1->nd_body, node2);
15491 return node1;
15492 }
15493 return NEW_ARGSCAT(node1, node2);
15494 }
15495
15496 static NODE *
15497 arg_append_gen(struct parser_params *parser, NODE *node1, NODE *node2)
15498 {
15499 if (!node1) return NEW_LIST(node2);
15500 switch (nd_type(node1)) {
15501 case NODE_ARRAY:
15502 return list_append(node1, node2);
15503 case NODE_BLOCK_PASS:
15504 node1->nd_head = arg_append(node1->nd_head, node2);
15505 return node1;
15506 case NODE_ARGSPUSH:
15507 node1->nd_body = list_append(NEW_LIST(node1->nd_body), node2);
15508 nd_set_type(node1, NODE_ARGSCAT);
15509 return node1;
15510 }
15511 return NEW_ARGSPUSH(node1, node2);
15512 }
15513
15514 static NODE *
15515 splat_array(NODE* node)
15516 {
15517 if (nd_type(node) == NODE_SPLAT) node = node->nd_head;
15518 if (nd_type(node) == NODE_ARRAY) return node;
15519 return 0;
15520 }
15521
15522 static NODE *
15523 node_assign_gen(struct parser_params *parser, NODE *lhs, NODE *rhs)
15524 {
15525 if (!lhs) return 0;
15526
15527 switch (nd_type(lhs)) {
15528 case NODE_GASGN:
15529 case NODE_IASGN:
15530 case NODE_IASGN2:
15531 case NODE_LASGN:
15532 case NODE_DASGN:
15533 case NODE_DASGN_CURR:
15534 case NODE_MASGN:
15535 case NODE_CDECL:
15536 case NODE_CVASGN:
15537 lhs->nd_value = rhs;
15538 break;
15539
15540 case NODE_ATTRASGN:
15541 case NODE_CALL:
15542 lhs->nd_args = arg_append(lhs->nd_args, rhs);
15543 break;
15544
15545 default:
15546
15547 break;
15548 }
15549
15550 return lhs;
15551 }
15552
15553 static int
15554 value_expr_gen(struct parser_params *parser, NODE *node)
15555 {
15556 int cond = 0;
15557
15558 if (!node) {
15559 rb_warning0("empty expression");
15560 }
15561 while (node) {
15562 switch (nd_type(node)) {
15563 case NODE_RETURN:
15564 case NODE_BREAK:
15565 case NODE_NEXT:
15566 case NODE_REDO:
15567 case NODE_RETRY:
15568 if (!cond) yyerror("void value expression");
15569
15570 return FALSE;
15571
15572 case NODE_BLOCK:
15573 while (node->nd_next) {
15574 node = node->nd_next;
15575 }
15576 node = node->nd_head;
15577 break;
15578
15579 case NODE_BEGIN:
15580 node = node->nd_body;
15581 break;
15582
15583 case NODE_IF:
15584 if (!node->nd_body) {
15585 node = node->nd_else;
15586 break;
15587 }
15588 else if (!node->nd_else) {
15589 node = node->nd_body;
15590 break;
15591 }
15592 if (!value_expr(node->nd_body)) return FALSE;
15593 node = node->nd_else;
15594 break;
15595
15596 case NODE_AND:
15597 case NODE_OR:
15598 cond = 1;
15599 node = node->nd_2nd;
15600 break;
15601
15602 default:
15603 return TRUE;
15604 }
15605 }
15606
15607 return TRUE;
15608 }
15609
15610 static void
15611 void_expr_gen(struct parser_params *parser, NODE *node)
15612 {
15613 const char *useless = 0;
15614
15615 if (!RTEST(ruby_verbose)) return;
15616
15617 if (!node) return;
15618 switch (nd_type(node)) {
15619 case NODE_CALL:
15620 switch (node->nd_mid) {
15621 case '+':
15622 case '-':
15623 case '*':
15624 case '/':
15625 case '%':
15626 case tPOW:
15627 case tUPLUS:
15628 case tUMINUS:
15629 case '|':
15630 case '^':
15631 case '&':
15632 case tCMP:
15633 case '>':
15634 case tGEQ:
15635 case '<':
15636 case tLEQ:
15637 case tEQ:
15638 case tNEQ:
15639 useless = rb_id2name(node->nd_mid);
15640 break;
15641 }
15642 break;
15643
15644 case NODE_LVAR:
15645 case NODE_DVAR:
15646 case NODE_GVAR:
15647 case NODE_IVAR:
15648 case NODE_CVAR:
15649 case NODE_NTH_REF:
15650 case NODE_BACK_REF:
15651 useless = "a variable";
15652 break;
15653 case NODE_CONST:
15654 useless = "a constant";
15655 break;
15656 case NODE_LIT:
15657 case NODE_STR:
15658 case NODE_DSTR:
15659 case NODE_DREGX:
15660 case NODE_DREGX_ONCE:
15661 useless = "a literal";
15662 break;
15663 case NODE_COLON2:
15664 case NODE_COLON3:
15665 useless = "::";
15666 break;
15667 case NODE_DOT2:
15668 useless = "..";
15669 break;
15670 case NODE_DOT3:
15671 useless = "...";
15672 break;
15673 case NODE_SELF:
15674 useless = "self";
15675 break;
15676 case NODE_NIL:
15677 useless = "nil";
15678 break;
15679 case NODE_TRUE:
15680 useless = "true";
15681 break;
15682 case NODE_FALSE:
15683 useless = "false";
15684 break;
15685 case NODE_DEFINED:
15686 useless = "defined?";
15687 break;
15688 }
15689
15690 if (useless) {
15691 int line = ruby_sourceline;
15692
15693 ruby_sourceline = nd_line(node);
15694 rb_warnS("possibly useless use of %s in void context", useless);
15695 ruby_sourceline = line;
15696 }
15697 }
15698
15699 static void
15700 void_stmts_gen(struct parser_params *parser, NODE *node)
15701 {
15702 if (!RTEST(ruby_verbose)) return;
15703 if (!node) return;
15704 if (nd_type(node) != NODE_BLOCK) return;
15705
15706 for (;;) {
15707 if (!node->nd_next) return;
15708 void_expr0(node->nd_head);
15709 node = node->nd_next;
15710 }
15711 }
15712
15713 static NODE *
15714 remove_begin(NODE *node)
15715 {
15716 NODE **n = &node, *n1 = node;
15717 while (n1 && nd_type(n1) == NODE_BEGIN && n1->nd_body) {
15718 *n = n1 = n1->nd_body;
15719 }
15720 return node;
15721 }
15722
15723 static NODE *
15724 remove_begin_all(NODE *node)
15725 {
15726 NODE **n = &node, *n1 = node;
15727 while (n1 && nd_type(n1) == NODE_BEGIN) {
15728 *n = n1 = n1->nd_body;
15729 }
15730 return node;
15731 }
15732
15733 static void
15734 reduce_nodes_gen(struct parser_params *parser, NODE **body)
15735 {
15736 NODE *node = *body;
15737
15738 if (!node) {
15739 *body = NEW_NIL();
15740 return;
15741 }
15742 #define subnodes(n1, n2) \
15743 ((!node->n1) ? (node->n2 ? (body = &node->n2, 1) : 0) : \
15744 (!node->n2) ? (body = &node->n1, 1) : \
15745 (reduce_nodes(&node->n1), body = &node->n2, 1))
15746
15747 while (node) {
15748 int newline = (int)(node->flags & NODE_FL_NEWLINE);
15749 switch (nd_type(node)) {
15750 end:
15751 case NODE_NIL:
15752 *body = 0;
15753 return;
15754 case NODE_RETURN:
15755 *body = node = node->nd_stts;
15756 if (newline && node) node->flags |= NODE_FL_NEWLINE;
15757 continue;
15758 case NODE_BEGIN:
15759 *body = node = node->nd_body;
15760 if (newline && node) node->flags |= NODE_FL_NEWLINE;
15761 continue;
15762 case NODE_BLOCK:
15763 body = &node->nd_end->nd_head;
15764 break;
15765 case NODE_IF:
15766 if (subnodes(nd_body, nd_else)) break;
15767 return;
15768 case NODE_CASE:
15769 body = &node->nd_body;
15770 break;
15771 case NODE_WHEN:
15772 if (!subnodes(nd_body, nd_next)) goto end;
15773 break;
15774 case NODE_ENSURE:
15775 if (!subnodes(nd_head, nd_resq)) goto end;
15776 break;
15777 case NODE_RESCUE:
15778 if (node->nd_else) {
15779 body = &node->nd_resq;
15780 break;
15781 }
15782 if (!subnodes(nd_head, nd_resq)) goto end;
15783 break;
15784 default:
15785 return;
15786 }
15787 node = *body;
15788 if (newline && node) node->flags |= NODE_FL_NEWLINE;
15789 }
15790
15791 #undef subnodes
15792 }
15793
15794 static int
15795 is_static_content(NODE *node)
15796 {
15797 if (!node) return 1;
15798 switch (nd_type(node)) {
15799 case NODE_HASH:
15800 if (!(node = node->nd_head)) break;
15801 case NODE_ARRAY:
15802 do {
15803 if (!is_static_content(node->nd_head)) return 0;
15804 } while ((node = node->nd_next) != 0);
15805 case NODE_LIT:
15806 case NODE_STR:
15807 case NODE_NIL:
15808 case NODE_TRUE:
15809 case NODE_FALSE:
15810 case NODE_ZARRAY:
15811 break;
15812 default:
15813 return 0;
15814 }
15815 return 1;
15816 }
15817
15818 static int
15819 assign_in_cond(struct parser_params *parser, NODE *node)
15820 {
15821 switch (nd_type(node)) {
15822 case NODE_MASGN:
15823 yyerror("multiple assignment in conditional");
15824 return 1;
15825
15826 case NODE_LASGN:
15827 case NODE_DASGN:
15828 case NODE_DASGN_CURR:
15829 case NODE_GASGN:
15830 case NODE_IASGN:
15831 break;
15832
15833 default:
15834 return 0;
15835 }
15836
15837 if (!node->nd_value) return 1;
15838 if (is_static_content(node->nd_value)) {
15839
15840 parser_warn(node->nd_value, "found = in conditional, should be ==");
15841 }
15842 return 1;
15843 }
15844
15845 static void
15846 warn_unless_e_option(struct parser_params *parser, NODE *node, const char *str)
15847 {
15848 if (!e_option_supplied(parser)) parser_warn(node, str);
15849 }
15850
15851 static void
15852 warning_unless_e_option(struct parser_params *parser, NODE *node, const char *str)
15853 {
15854 if (!e_option_supplied(parser)) parser_warning(node, str);
15855 }
15856
15857 static void
15858 fixup_nodes(NODE **rootnode)
15859 {
15860 NODE *node, *next, *head;
15861
15862 for (node = *rootnode; node; node = next) {
15863 enum node_type type;
15864 VALUE val;
15865
15866 next = node->nd_next;
15867 head = node->nd_head;
15868 rb_gc_force_recycle((VALUE)node);
15869 *rootnode = next;
15870 switch (type = nd_type(head)) {
15871 case NODE_DOT2:
15872 case NODE_DOT3:
15873 val = rb_range_new(head->nd_beg->nd_lit, head->nd_end->nd_lit,
15874 type == NODE_DOT3);
15875 rb_gc_force_recycle((VALUE)head->nd_beg);
15876 rb_gc_force_recycle((VALUE)head->nd_end);
15877 nd_set_type(head, NODE_LIT);
15878 head->nd_lit = val;
15879 break;
15880 default:
15881 break;
15882 }
15883 }
15884 }
15885
15886 static NODE *cond0(struct parser_params*,NODE*);
15887
15888 static NODE*
15889 range_op(struct parser_params *parser, NODE *node)
15890 {
15891 enum node_type type;
15892
15893 if (node == 0) return 0;
15894
15895 type = nd_type(node);
15896 value_expr(node);
15897 if (type == NODE_LIT && FIXNUM_P(node->nd_lit)) {
15898 warn_unless_e_option(parser, node, "integer literal in conditional range");
15899 return NEW_CALL(node, tEQ, NEW_LIST(NEW_GVAR(rb_intern("$."))));
15900 }
15901 return cond0(parser, node);
15902 }
15903
15904 static int
15905 literal_node(NODE *node)
15906 {
15907 if (!node) return 1;
15908 switch (nd_type(node)) {
15909 case NODE_LIT:
15910 case NODE_STR:
15911 case NODE_DSTR:
15912 case NODE_EVSTR:
15913 case NODE_DREGX:
15914 case NODE_DREGX_ONCE:
15915 case NODE_DSYM:
15916 return 2;
15917 case NODE_TRUE:
15918 case NODE_FALSE:
15919 case NODE_NIL:
15920 return 1;
15921 }
15922 return 0;
15923 }
15924
15925 static NODE*
15926 cond0(struct parser_params *parser, NODE *node)
15927 {
15928 if (node == 0) return 0;
15929 assign_in_cond(parser, node);
15930
15931 switch (nd_type(node)) {
15932 case NODE_DSTR:
15933 case NODE_EVSTR:
15934 case NODE_STR:
15935 rb_warn0("string literal in condition");
15936 break;
15937
15938 case NODE_DREGX:
15939 case NODE_DREGX_ONCE:
15940 warning_unless_e_option(parser, node, "regex literal in condition");
15941 return NEW_MATCH2(node, NEW_GVAR(rb_intern("$_")));
15942
15943 case NODE_AND:
15944 case NODE_OR:
15945 node->nd_1st = cond0(parser, node->nd_1st);
15946 node->nd_2nd = cond0(parser, node->nd_2nd);
15947 break;
15948
15949 case NODE_DOT2:
15950 case NODE_DOT3:
15951 node->nd_beg = range_op(parser, node->nd_beg);
15952 node->nd_end = range_op(parser, node->nd_end);
15953 if (nd_type(node) == NODE_DOT2) nd_set_type(node,NODE_FLIP2);
15954 else if (nd_type(node) == NODE_DOT3) nd_set_type(node, NODE_FLIP3);
15955 if (!e_option_supplied(parser)) {
15956 int b = literal_node(node->nd_beg);
15957 int e = literal_node(node->nd_end);
15958 if ((b == 1 && e == 1) || (b + e >= 2 && RTEST(ruby_verbose))) {
15959 parser_warn(node, "range literal in condition");
15960 }
15961 }
15962 break;
15963
15964 case NODE_DSYM:
15965 parser_warning(node, "literal in condition");
15966 break;
15967
15968 case NODE_LIT:
15969 if (RB_TYPE_P(node->nd_lit, T_REGEXP)) {
15970 warn_unless_e_option(parser, node, "regex literal in condition");
15971 nd_set_type(node, NODE_MATCH);
15972 }
15973 else {
15974 parser_warning(node, "literal in condition");
15975 }
15976 default:
15977 break;
15978 }
15979 return node;
15980 }
15981
15982 static NODE*
15983 cond_gen(struct parser_params *parser, NODE *node)
15984 {
15985 if (node == 0) return 0;
15986 return cond0(parser, node);
15987 }
15988
15989 static NODE*
15990 logop_gen(struct parser_params *parser, enum node_type type, NODE *left, NODE *right)
15991 {
15992 value_expr(left);
15993 if (left && (enum node_type)nd_type(left) == type) {
15994 NODE *node = left, *second;
15995 while ((second = node->nd_2nd) != 0 && (enum node_type)nd_type(second) == type) {
15996 node = second;
15997 }
15998 node->nd_2nd = NEW_NODE(type, second, right, 0);
15999 return left;
16000 }
16001 return NEW_NODE(type, left, right, 0);
16002 }
16003
16004 static void
16005 no_blockarg(struct parser_params *parser, NODE *node)
16006 {
16007 if (node && nd_type(node) == NODE_BLOCK_PASS) {
16008 compile_error(PARSER_ARG "block argument should not be given");
16009 }
16010 }
16011
16012 static NODE *
16013 ret_args_gen(struct parser_params *parser, NODE *node)
16014 {
16015 if (node) {
16016 no_blockarg(parser, node);
16017 if (nd_type(node) == NODE_ARRAY) {
16018 if (node->nd_next == 0) {
16019 node = node->nd_head;
16020 }
16021 else {
16022 nd_set_type(node, NODE_VALUES);
16023 }
16024 }
16025 }
16026 return node;
16027 }
16028
16029 static NODE *
16030 new_yield_gen(struct parser_params *parser, NODE *node)
16031 {
16032 if (node) no_blockarg(parser, node);
16033
16034 return NEW_YIELD(node);
16035 }
16036
16037 static NODE*
16038 negate_lit(NODE *node)
16039 {
16040 switch (TYPE(node->nd_lit)) {
16041 case T_FIXNUM:
16042 node->nd_lit = LONG2FIX(-FIX2LONG(node->nd_lit));
16043 break;
16044 case T_BIGNUM:
16045 case T_RATIONAL:
16046 case T_COMPLEX:
16047 node->nd_lit = rb_funcall(node->nd_lit,tUMINUS,0,0);
16048 break;
16049 case T_FLOAT:
16050 #if USE_FLONUM
16051 if (FLONUM_P(node->nd_lit)) {
16052 node->nd_lit = DBL2NUM(-RFLOAT_VALUE(node->nd_lit));
16053 }
16054 else {
16055 RFLOAT(node->nd_lit)->float_value = -RFLOAT_VALUE(node->nd_lit);
16056 }
16057 #else
16058 RFLOAT(node->nd_lit)->float_value = -RFLOAT_VALUE(node->nd_lit);
16059 #endif
16060 break;
16061 default:
16062 rb_bug("unknown literal type passed to negate_lit");
16063 break;
16064 }
16065 return node;
16066 }
16067
16068 static NODE *
16069 arg_blk_pass(NODE *node1, NODE *node2)
16070 {
16071 if (node2) {
16072 node2->nd_head = node1;
16073 return node2;
16074 }
16075 return node1;
16076 }
16077
16078
16079 static NODE*
16080 new_args_gen(struct parser_params *parser, NODE *m, NODE *o, ID r, NODE *p, NODE *tail)
16081 {
16082 int saved_line = ruby_sourceline;
16083 struct rb_args_info *args = tail->nd_ainfo;
16084
16085 args->pre_args_num = m ? rb_long2int(m->nd_plen) : 0;
16086 args->pre_init = m ? m->nd_next : 0;
16087
16088 args->post_args_num = p ? rb_long2int(p->nd_plen) : 0;
16089 args->post_init = p ? p->nd_next : 0;
16090 args->first_post_arg = p ? p->nd_pid : 0;
16091
16092 args->rest_arg = r;
16093
16094 args->opt_args = o;
16095
16096 ruby_sourceline = saved_line;
16097
16098 return tail;
16099 }
16100
16101 static NODE*
16102 new_args_tail_gen(struct parser_params *parser, NODE *k, ID kr, ID b)
16103 {
16104 int saved_line = ruby_sourceline;
16105 struct rb_args_info *args;
16106 NODE *kw_rest_arg = 0;
16107 NODE *node;
16108 int check = 0;
16109
16110 args = ALLOC(struct rb_args_info);
16111 MEMZERO(args, struct rb_args_info, 1);
16112 node = NEW_NODE(NODE_ARGS, 0, 0, args);
16113
16114 args->block_arg = b;
16115 args->kw_args = k;
16116 if (k && !kr) {
16117 check = 1;
16118 kr = internal_id();
16119 }
16120 if (kr) {
16121 arg_var(kr);
16122 kw_rest_arg = NEW_DVAR(kr);
16123 kw_rest_arg->nd_cflag = check;
16124 }
16125 args->kw_rest_arg = kw_rest_arg;
16126
16127 ruby_sourceline = saved_line;
16128 return node;
16129 }
16130
16131 static NODE*
16132 dsym_node_gen(struct parser_params *parser, NODE *node)
16133 {
16134 VALUE lit;
16135
16136 if (!node) {
16137 return NEW_LIT(ID2SYM(idNULL));
16138 }
16139
16140 switch (nd_type(node)) {
16141 case NODE_DSTR:
16142 nd_set_type(node, NODE_DSYM);
16143 break;
16144 case NODE_STR:
16145 lit = node->nd_lit;
16146 node->nd_lit = ID2SYM(rb_intern_str(lit));
16147 nd_set_type(node, NODE_LIT);
16148 break;
16149 default:
16150 node = NEW_NODE(NODE_DSYM, Qnil, 1, NEW_LIST(node));
16151 break;
16152 }
16153 return node;
16154 }
16155 #endif
16156
16157 #ifndef RIPPER
16158 static NODE *
16159 new_op_assign_gen(struct parser_params *parser, NODE *lhs, ID op, NODE *rhs)
16160 {
16161 NODE *asgn;
16162
16163 if (lhs) {
16164 ID vid = lhs->nd_vid;
16165 if (op == tOROP) {
16166 lhs->nd_value = rhs;
16167 asgn = NEW_OP_ASGN_OR(gettable(vid), lhs);
16168 if (is_asgn_or_id(vid)) {
16169 asgn->nd_aid = vid;
16170 }
16171 }
16172 else if (op == tANDOP) {
16173 lhs->nd_value = rhs;
16174 asgn = NEW_OP_ASGN_AND(gettable(vid), lhs);
16175 }
16176 else {
16177 asgn = lhs;
16178 asgn->nd_value = NEW_CALL(gettable(vid), op, NEW_LIST(rhs));
16179 }
16180 }
16181 else {
16182 asgn = NEW_BEGIN(0);
16183 }
16184 return asgn;
16185 }
16186
16187 static NODE *
16188 new_attr_op_assign_gen(struct parser_params *parser, NODE *lhs, ID attr, ID op, NODE *rhs)
16189 {
16190 NODE *asgn;
16191
16192 if (op == tOROP) {
16193 op = 0;
16194 }
16195 else if (op == tANDOP) {
16196 op = 1;
16197 }
16198 asgn = NEW_OP_ASGN2(lhs, attr, op, rhs);
16199 fixpos(asgn, lhs);
16200 return asgn;
16201 }
16202
16203 static NODE *
16204 new_const_op_assign_gen(struct parser_params *parser, NODE *lhs, ID op, NODE *rhs)
16205 {
16206 NODE *asgn;
16207
16208 if (op == tOROP) {
16209 op = 0;
16210 }
16211 else if (op == tANDOP) {
16212 op = 1;
16213 }
16214 if (lhs) {
16215 asgn = NEW_OP_CDECL(lhs, op, rhs);
16216 }
16217 else {
16218 asgn = NEW_BEGIN(0);
16219 }
16220 fixpos(asgn, lhs);
16221 return asgn;
16222 }
16223 #else
16224 static VALUE
16225 new_op_assign_gen(struct parser_params *parser, VALUE lhs, VALUE op, VALUE rhs)
16226 {
16227 return dispatch3(opassign, lhs, op, rhs);
16228 }
16229
16230 static VALUE
16231 new_attr_op_assign_gen(struct parser_params *parser, VALUE lhs, VALUE type, VALUE attr, VALUE op, VALUE rhs)
16232 {
16233 VALUE recv = dispatch3(field, lhs, type, attr);
16234 return dispatch3(opassign, recv, op, rhs);
16235 }
16236 #endif
16237
16238 static void
16239 warn_unused_var(struct parser_params *parser, struct local_vars *local)
16240 {
16241 int i, cnt;
16242 ID *v, *u;
16243
16244 if (!local->used) return;
16245 v = local->vars->tbl;
16246 u = local->used->tbl;
16247 cnt = local->used->pos;
16248 if (cnt != local->vars->pos) {
16249 rb_bug("local->used->pos != local->vars->pos");
16250 }
16251 for (i = 0; i < cnt; ++i) {
16252 if (!v[i] || (u[i] & LVAR_USED)) continue;
16253 if (is_private_local_id(v[i])) continue;
16254 rb_warn4S(ruby_sourcefile, (int)u[i], "assigned but unused variable - %s", rb_id2name(v[i]));
16255 }
16256 }
16257
16258 static void
16259 local_push_gen(struct parser_params *parser, int inherit_dvars)
16260 {
16261 struct local_vars *local;
16262
16263 local = ALLOC(struct local_vars);
16264 local->prev = lvtbl;
16265 local->args = vtable_alloc(0);
16266 local->vars = vtable_alloc(inherit_dvars ? DVARS_INHERIT : DVARS_TOPSCOPE);
16267 local->used = !(inherit_dvars &&
16268 (ifndef_ripper(compile_for_eval || e_option_supplied(parser))+0)) &&
16269 RTEST(ruby_verbose) ? vtable_alloc(0) : 0;
16270 local->cmdargs = cmdarg_stack;
16271 cmdarg_stack = 0;
16272 lvtbl = local;
16273 }
16274
16275 static void
16276 local_pop_gen(struct parser_params *parser)
16277 {
16278 struct local_vars *local = lvtbl->prev;
16279 if (lvtbl->used) {
16280 warn_unused_var(parser, lvtbl);
16281 vtable_free(lvtbl->used);
16282 }
16283 vtable_free(lvtbl->args);
16284 vtable_free(lvtbl->vars);
16285 cmdarg_stack = lvtbl->cmdargs;
16286 xfree(lvtbl);
16287 lvtbl = local;
16288 }
16289
16290 #ifndef RIPPER
16291 static ID*
16292 local_tbl_gen(struct parser_params *parser)
16293 {
16294 int cnt_args = vtable_size(lvtbl->args);
16295 int cnt_vars = vtable_size(lvtbl->vars);
16296 int cnt = cnt_args + cnt_vars;
16297 int i, j;
16298 ID *buf;
16299
16300 if (cnt <= 0) return 0;
16301 buf = ALLOC_N(ID, cnt + 1);
16302 MEMCPY(buf+1, lvtbl->args->tbl, ID, cnt_args);
16303
16304 for (i = 0, j = cnt_args+1; i < cnt_vars; ++i) {
16305 ID id = lvtbl->vars->tbl[i];
16306 if (!vtable_included(lvtbl->args, id)) {
16307 buf[j++] = id;
16308 }
16309 }
16310 if (--j < cnt) REALLOC_N(buf, ID, (cnt = j) + 1);
16311 buf[0] = cnt;
16312 return buf;
16313 }
16314 #endif
16315
16316 static int
16317 arg_var_gen(struct parser_params *parser, ID id)
16318 {
16319 vtable_add(lvtbl->args, id);
16320 return vtable_size(lvtbl->args) - 1;
16321 }
16322
16323 static int
16324 local_var_gen(struct parser_params *parser, ID id)
16325 {
16326 vtable_add(lvtbl->vars, id);
16327 if (lvtbl->used) {
16328 vtable_add(lvtbl->used, (ID)ruby_sourceline);
16329 }
16330 return vtable_size(lvtbl->vars) - 1;
16331 }
16332
16333 static int
16334 local_id_gen(struct parser_params *parser, ID id)
16335 {
16336 struct vtable *vars, *args, *used;
16337
16338 vars = lvtbl->vars;
16339 args = lvtbl->args;
16340 used = lvtbl->used;
16341
16342 while (vars && POINTER_P(vars->prev)) {
16343 vars = vars->prev;
16344 args = args->prev;
16345 if (used) used = used->prev;
16346 }
16347
16348 if (vars && vars->prev == DVARS_INHERIT) {
16349 return rb_local_defined(id);
16350 }
16351 else if (vtable_included(args, id)) {
16352 return 1;
16353 }
16354 else {
16355 int i = vtable_included(vars, id);
16356 if (i && used) used->tbl[i-1] |= LVAR_USED;
16357 return i != 0;
16358 }
16359 }
16360
16361 static const struct vtable *
16362 dyna_push_gen(struct parser_params *parser)
16363 {
16364 lvtbl->args = vtable_alloc(lvtbl->args);
16365 lvtbl->vars = vtable_alloc(lvtbl->vars);
16366 if (lvtbl->used) {
16367 lvtbl->used = vtable_alloc(lvtbl->used);
16368 }
16369 return lvtbl->args;
16370 }
16371
16372 static void
16373 dyna_pop_1(struct parser_params *parser)
16374 {
16375 struct vtable *tmp;
16376
16377 if ((tmp = lvtbl->used) != 0) {
16378 warn_unused_var(parser, lvtbl);
16379 lvtbl->used = lvtbl->used->prev;
16380 vtable_free(tmp);
16381 }
16382 tmp = lvtbl->args;
16383 lvtbl->args = lvtbl->args->prev;
16384 vtable_free(tmp);
16385 tmp = lvtbl->vars;
16386 lvtbl->vars = lvtbl->vars->prev;
16387 vtable_free(tmp);
16388 }
16389
16390 static void
16391 dyna_pop_gen(struct parser_params *parser, const struct vtable *lvargs)
16392 {
16393 while (lvtbl->args != lvargs) {
16394 dyna_pop_1(parser);
16395 if (!lvtbl->args) {
16396 struct local_vars *local = lvtbl->prev;
16397 xfree(lvtbl);
16398 lvtbl = local;
16399 }
16400 }
16401 dyna_pop_1(parser);
16402 }
16403
16404 static int
16405 dyna_in_block_gen(struct parser_params *parser)
16406 {
16407 return POINTER_P(lvtbl->vars) && lvtbl->vars->prev != DVARS_TOPSCOPE;
16408 }
16409
16410 static int
16411 dvar_defined_gen(struct parser_params *parser, ID id, int get)
16412 {
16413 struct vtable *vars, *args, *used;
16414 int i;
16415
16416 args = lvtbl->args;
16417 vars = lvtbl->vars;
16418 used = lvtbl->used;
16419
16420 while (POINTER_P(vars)) {
16421 if (vtable_included(args, id)) {
16422 return 1;
16423 }
16424 if ((i = vtable_included(vars, id)) != 0) {
16425 if (used) used->tbl[i-1] |= LVAR_USED;
16426 return 1;
16427 }
16428 args = args->prev;
16429 vars = vars->prev;
16430 if (get) used = 0;
16431 if (used) used = used->prev;
16432 }
16433
16434 if (vars == DVARS_INHERIT) {
16435 return rb_dvar_defined(id);
16436 }
16437
16438 return 0;
16439 }
16440
16441 static int
16442 dvar_curr_gen(struct parser_params *parser, ID id)
16443 {
16444 return (vtable_included(lvtbl->args, id) ||
16445 vtable_included(lvtbl->vars, id));
16446 }
16447
16448 #ifndef RIPPER
16449 static void
16450 reg_fragment_setenc_gen(struct parser_params* parser, VALUE str, int options)
16451 {
16452 int c = RE_OPTION_ENCODING_IDX(options);
16453
16454 if (c) {
16455 int opt, idx;
16456 rb_char_to_option_kcode(c, &opt, &idx);
16457 if (idx != ENCODING_GET(str) &&
16458 rb_enc_str_coderange(str) != ENC_CODERANGE_7BIT) {
16459 goto error;
16460 }
16461 ENCODING_SET(str, idx);
16462 }
16463 else if (RE_OPTION_ENCODING_NONE(options)) {
16464 if (!ENCODING_IS_ASCII8BIT(str) &&
16465 rb_enc_str_coderange(str) != ENC_CODERANGE_7BIT) {
16466 c = 'n';
16467 goto error;
16468 }
16469 rb_enc_associate(str, rb_ascii8bit_encoding());
16470 }
16471 else if (current_enc == rb_usascii_encoding()) {
16472 if (rb_enc_str_coderange(str) != ENC_CODERANGE_7BIT) {
16473
16474 rb_enc_associate(str, rb_usascii_encoding());
16475 }
16476 else {
16477 rb_enc_associate(str, rb_ascii8bit_encoding());
16478 }
16479 }
16480 return;
16481
16482 error:
16483 compile_error(PARSER_ARG
16484 "regexp encoding option '%c' differs from source encoding '%s'",
16485 c, rb_enc_name(rb_enc_get(str)));
16486 }
16487
16488 static int
16489 reg_fragment_check_gen(struct parser_params* parser, VALUE str, int options)
16490 {
16491 VALUE err;
16492 reg_fragment_setenc(str, options);
16493 err = rb_reg_check_preprocess(str);
16494 if (err != Qnil) {
16495 err = rb_obj_as_string(err);
16496 compile_error(PARSER_ARG "%"PRIsVALUE, err);
16497 return 0;
16498 }
16499 return 1;
16500 }
16501
16502 typedef struct {
16503 struct parser_params* parser;
16504 rb_encoding *enc;
16505 NODE *succ_block;
16506 NODE *fail_block;
16507 int num;
16508 } reg_named_capture_assign_t;
16509
16510 static int
16511 reg_named_capture_assign_iter(const OnigUChar *name, const OnigUChar *name_end,
16512 int back_num, int *back_refs, OnigRegex regex, void *arg0)
16513 {
16514 reg_named_capture_assign_t *arg = (reg_named_capture_assign_t*)arg0;
16515 struct parser_params* parser = arg->parser;
16516 rb_encoding *enc = arg->enc;
16517 long len = name_end - name;
16518 const char *s = (const char *)name;
16519 ID var;
16520
16521 arg->num++;
16522
16523 if (arg->succ_block == 0) {
16524 arg->succ_block = NEW_BEGIN(0);
16525 arg->fail_block = NEW_BEGIN(0);
16526 }
16527
16528 if (!len || (*name != '_' && ISASCII(*name) && !rb_enc_islower(*name, enc)) ||
16529 (len < MAX_WORD_LENGTH && rb_reserved_word(s, (int)len)) ||
16530 !rb_enc_symname2_p(s, len, enc)) {
16531 return ST_CONTINUE;
16532 }
16533 var = rb_intern3(s, len, enc);
16534 if (dvar_defined(var) || local_id(var)) {
16535 rb_warningS("named capture conflicts a local variable - %s",
16536 rb_id2name(var));
16537 }
16538 arg->succ_block = block_append(arg->succ_block,
16539 newline_node(node_assign(assignable(var,0),
16540 NEW_CALL(
16541 gettable(rb_intern("$~")),
16542 idAREF,
16543 NEW_LIST(NEW_LIT(ID2SYM(var))))
16544 )));
16545 arg->fail_block = block_append(arg->fail_block,
16546 newline_node(node_assign(assignable(var,0), NEW_LIT(Qnil))));
16547 return ST_CONTINUE;
16548 }
16549
16550 static NODE *
16551 reg_named_capture_assign_gen(struct parser_params* parser, VALUE regexp, NODE *match)
16552 {
16553 reg_named_capture_assign_t arg;
16554
16555 arg.parser = parser;
16556 arg.enc = rb_enc_get(regexp);
16557 arg.succ_block = 0;
16558 arg.fail_block = 0;
16559 arg.num = 0;
16560 onig_foreach_name(RREGEXP(regexp)->ptr, reg_named_capture_assign_iter, (void*)&arg);
16561
16562 if (arg.num == 0)
16563 return match;
16564
16565 return
16566 block_append(
16567 newline_node(match),
16568 NEW_IF(gettable(rb_intern("$~")),
16569 block_append(
16570 newline_node(arg.succ_block),
16571 newline_node(
16572 NEW_CALL(
16573 gettable(rb_intern("$~")),
16574 rb_intern("begin"),
16575 NEW_LIST(NEW_LIT(INT2FIX(0)))))),
16576 block_append(
16577 newline_node(arg.fail_block),
16578 newline_node(
16579 NEW_LIT(Qnil)))));
16580 }
16581
16582 static VALUE
16583 reg_compile_gen(struct parser_params* parser, VALUE str, int options)
16584 {
16585 VALUE re;
16586 VALUE err;
16587
16588 reg_fragment_setenc(str, options);
16589 err = rb_errinfo();
16590 re = rb_reg_compile(str, options & RE_OPTION_MASK, ruby_sourcefile, ruby_sourceline);
16591 if (NIL_P(re)) {
16592 ID mesg = rb_intern("mesg");
16593 VALUE m = rb_attr_get(rb_errinfo(), mesg);
16594 rb_set_errinfo(err);
16595 if (!NIL_P(err)) {
16596 rb_str_append(rb_str_cat(rb_attr_get(err, mesg), "\n", 1), m);
16597 }
16598 else {
16599 compile_error(PARSER_ARG "%"PRIsVALUE, m);
16600 }
16601 return Qnil;
16602 }
16603 return re;
16604 }
16605
16606 void
16607 rb_gc_mark_parser(void)
16608 {
16609 }
16610
16611 NODE*
16612 rb_parser_append_print(VALUE vparser, NODE *node)
16613 {
16614 NODE *prelude = 0;
16615 NODE *scope = node;
16616 struct parser_params *parser;
16617
16618 if (!node) return node;
16619
16620 TypedData_Get_Struct(vparser, struct parser_params, &parser_data_type, parser);
16621
16622 node = node->nd_body;
16623
16624 if (nd_type(node) == NODE_PRELUDE) {
16625 prelude = node;
16626 node = node->nd_body;
16627 }
16628
16629 node = block_append(node,
16630 NEW_FCALL(rb_intern("print"),
16631 NEW_ARRAY(NEW_GVAR(rb_intern("$_")))));
16632 if (prelude) {
16633 prelude->nd_body = node;
16634 scope->nd_body = prelude;
16635 }
16636 else {
16637 scope->nd_body = node;
16638 }
16639
16640 return scope;
16641 }
16642
16643 NODE *
16644 rb_parser_while_loop(VALUE vparser, NODE *node, int chop, int split)
16645 {
16646 NODE *prelude = 0;
16647 NODE *scope = node;
16648 struct parser_params *parser;
16649
16650 if (!node) return node;
16651
16652 TypedData_Get_Struct(vparser, struct parser_params, &parser_data_type, parser);
16653
16654 node = node->nd_body;
16655
16656 if (nd_type(node) == NODE_PRELUDE) {
16657 prelude = node;
16658 node = node->nd_body;
16659 }
16660 if (split) {
16661 node = block_append(NEW_GASGN(rb_intern("$F"),
16662 NEW_CALL(NEW_GVAR(rb_intern("$_")),
16663 rb_intern("split"), 0)),
16664 node);
16665 }
16666 if (chop) {
16667 node = block_append(NEW_CALL(NEW_GVAR(rb_intern("$_")),
16668 rb_intern("chop!"), 0), node);
16669 }
16670
16671 node = NEW_OPT_N(node);
16672
16673 if (prelude) {
16674 prelude->nd_body = node;
16675 scope->nd_body = prelude;
16676 }
16677 else {
16678 scope->nd_body = node;
16679 }
16680
16681 return scope;
16682 }
16683
16684 static const struct {
16685 ID token;
16686 const char *name;
16687 } op_tbl[] = {
16688 {tDOT2, ".."},
16689 {tDOT3, "..."},
16690 {tPOW, "**"},
16691 {tDSTAR, "**"},
16692 {tUPLUS, "+@"},
16693 {tUMINUS, "-@"},
16694 {tCMP, "<=>"},
16695 {tGEQ, ">="},
16696 {tLEQ, "<="},
16697 {tEQ, "=="},
16698 {tEQQ, "==="},
16699 {tNEQ, "!="},
16700 {tMATCH, "=~"},
16701 {tNMATCH, "!~"},
16702 {tAREF, "[]"},
16703 {tASET, "[]="},
16704 {tLSHFT, "<<"},
16705 {tRSHFT, ">>"},
16706 {tCOLON2, "::"},
16707 };
16708
16709 #define op_tbl_count numberof(op_tbl)
16710
16711 #ifndef ENABLE_SELECTOR_NAMESPACE
16712 #define ENABLE_SELECTOR_NAMESPACE 0
16713 #endif
16714
16715 static struct symbols {
16716 ID last_id;
16717 st_table *sym_id;
16718 st_table *id_str;
16719 #if ENABLE_SELECTOR_NAMESPACE
16720 st_table *ivar2_id;
16721 st_table *id_ivar2;
16722 #endif
16723 VALUE op_sym[tLAST_OP_ID];
16724 int minor_marked;
16725 } global_symbols = {tLAST_TOKEN};
16726
16727 static const struct st_hash_type symhash = {
16728 rb_str_hash_cmp,
16729 rb_str_hash,
16730 };
16731
16732 #if ENABLE_SELECTOR_NAMESPACE
16733 struct ivar2_key {
16734 ID id;
16735 VALUE klass;
16736 };
16737
16738 static int
16739 ivar2_cmp(struct ivar2_key *key1, struct ivar2_key *key2)
16740 {
16741 if (key1->id == key2->id && key1->klass == key2->klass) {
16742 return 0;
16743 }
16744 return 1;
16745 }
16746
16747 static int
16748 ivar2_hash(struct ivar2_key *key)
16749 {
16750 return (key->id << 8) ^ (key->klass >> 2);
16751 }
16752
16753 static const struct st_hash_type ivar2_hash_type = {
16754 ivar2_cmp,
16755 ivar2_hash,
16756 };
16757 #endif
16758
16759 void
16760 Init_sym(void)
16761 {
16762 global_symbols.sym_id = st_init_table_with_size(&symhash, 1000);
16763 global_symbols.id_str = st_init_numtable_with_size(1000);
16764 #if ENABLE_SELECTOR_NAMESPACE
16765 global_symbols.ivar2_id = st_init_table_with_size(&ivar2_hash_type, 1000);
16766 global_symbols.id_ivar2 = st_init_numtable_with_size(1000);
16767 #endif
16768
16769 (void)nodetype;
16770 (void)nodeline;
16771 #if PARSER_DEBUG
16772 (void)lex_state_name(-1);
16773 #endif
16774
16775 Init_id();
16776 }
16777
16778 void
16779 rb_gc_mark_symbols(int full_mark)
16780 {
16781 if (full_mark || global_symbols.minor_marked == 0) {
16782 rb_mark_tbl(global_symbols.id_str);
16783 rb_gc_mark_locations(global_symbols.op_sym,
16784 global_symbols.op_sym + numberof(global_symbols.op_sym));
16785
16786 if (!full_mark) global_symbols.minor_marked = 1;
16787 }
16788 }
16789 #endif
16790
16791 static ID
16792 internal_id_gen(struct parser_params *parser)
16793 {
16794 ID id = (ID)vtable_size(lvtbl->args) + (ID)vtable_size(lvtbl->vars);
16795 id += ((tLAST_TOKEN - ID_INTERNAL) >> ID_SCOPE_SHIFT) + 1;
16796 return ID_INTERNAL | (id << ID_SCOPE_SHIFT);
16797 }
16798
16799 #ifndef RIPPER
16800 static int
16801 is_special_global_name(const char *m, const char *e, rb_encoding *enc)
16802 {
16803 int mb = 0;
16804
16805 if (m >= e) return 0;
16806 if (is_global_name_punct(*m)) {
16807 ++m;
16808 }
16809 else if (*m == '-') {
16810 if (++m >= e) return 0;
16811 if (is_identchar(m, e, enc)) {
16812 if (!ISASCII(*m)) mb = 1;
16813 m += rb_enc_mbclen(m, e, enc);
16814 }
16815 }
16816 else {
16817 if (!rb_enc_isdigit(*m, enc)) return 0;
16818 do {
16819 if (!ISASCII(*m)) mb = 1;
16820 ++m;
16821 } while (m < e && rb_enc_isdigit(*m, enc));
16822 }
16823 return m == e ? mb + 1 : 0;
16824 }
16825
16826 int
16827 rb_symname_p(const char *name)
16828 {
16829 return rb_enc_symname_p(name, rb_ascii8bit_encoding());
16830 }
16831
16832 int
16833 rb_enc_symname_p(const char *name, rb_encoding *enc)
16834 {
16835 return rb_enc_symname2_p(name, strlen(name), enc);
16836 }
16837
16838 #define IDSET_ATTRSET_FOR_SYNTAX ((1U<<ID_LOCAL)|(1U<<ID_CONST))
16839 #define IDSET_ATTRSET_FOR_INTERN (~(~0U<<ID_SCOPE_MASK) & ~(1U<<ID_ATTRSET))
16840
16841 static int
16842 rb_enc_symname_type(const char *name, long len, rb_encoding *enc, unsigned int allowed_attrset)
16843 {
16844 const char *m = name;
16845 const char *e = m + len;
16846 int type = ID_JUNK;
16847
16848 if (!m || len <= 0) return -1;
16849 switch (*m) {
16850 case '\0':
16851 return -1;
16852
16853 case '$':
16854 type = ID_GLOBAL;
16855 if (is_special_global_name(++m, e, enc)) return type;
16856 goto id;
16857
16858 case '@':
16859 type = ID_INSTANCE;
16860 if (*++m == '@') {
16861 ++m;
16862 type = ID_CLASS;
16863 }
16864 goto id;
16865
16866 case '<':
16867 switch (*++m) {
16868 case '<': ++m; break;
16869 case '=': if (*++m == '>') ++m; break;
16870 default: break;
16871 }
16872 break;
16873
16874 case '>':
16875 switch (*++m) {
16876 case '>': case '=': ++m; break;
16877 }
16878 break;
16879
16880 case '=':
16881 switch (*++m) {
16882 case '~': ++m; break;
16883 case '=': if (*++m == '=') ++m; break;
16884 default: return -1;
16885 }
16886 break;
16887
16888 case '*':
16889 if (*++m == '*') ++m;
16890 break;
16891
16892 case '+': case '-':
16893 if (*++m == '@') ++m;
16894 break;
16895
16896 case '|': case '^': case '&': case '/': case '%': case '~': case '`':
16897 ++m;
16898 break;
16899
16900 case '[':
16901 if (*++m != ']') return -1;
16902 if (*++m == '=') ++m;
16903 break;
16904
16905 case '!':
16906 if (len == 1) return ID_JUNK;
16907 switch (*++m) {
16908 case '=': case '~': ++m; break;
16909 default: return -1;
16910 }
16911 break;
16912
16913 default:
16914 type = rb_enc_isupper(*m, enc) ? ID_CONST : ID_LOCAL;
16915 id:
16916 if (m >= e || (*m != '_' && !rb_enc_isalpha(*m, enc) && ISASCII(*m)))
16917 return -1;
16918 while (m < e && is_identchar(m, e, enc)) m += rb_enc_mbclen(m, e, enc);
16919 if (m >= e) break;
16920 switch (*m) {
16921 case '!': case '?':
16922 if (type == ID_GLOBAL || type == ID_CLASS || type == ID_INSTANCE) return -1;
16923 type = ID_JUNK;
16924 ++m;
16925 break;
16926 case '=':
16927 if (!(allowed_attrset & (1U << type))) return -1;
16928 type = ID_ATTRSET;
16929 ++m;
16930 break;
16931 }
16932 break;
16933 }
16934 return m == e ? type : -1;
16935 }
16936
16937 int
16938 rb_enc_symname2_p(const char *name, long len, rb_encoding *enc)
16939 {
16940 return rb_enc_symname_type(name, len, enc, IDSET_ATTRSET_FOR_SYNTAX) != -1;
16941 }
16942
16943 static int
16944 rb_str_symname_type(VALUE name, unsigned int allowed_attrset)
16945 {
16946 const char *ptr = StringValuePtr(name);
16947 long len = RSTRING_LEN(name);
16948 int type = rb_enc_symname_type(ptr, len, rb_enc_get(name), allowed_attrset);
16949 RB_GC_GUARD(name);
16950 return type;
16951 }
16952
16953 static ID
16954 register_symid(ID id, const char *name, long len, rb_encoding *enc)
16955 {
16956 VALUE str = rb_enc_str_new(name, len, enc);
16957 return register_symid_str(id, str);
16958 }
16959
16960 static ID
16961 register_symid_str(ID id, VALUE str)
16962 {
16963 OBJ_FREEZE(str);
16964 str = rb_fstring(str);
16965
16966 if (RUBY_DTRACE_SYMBOL_CREATE_ENABLED()) {
16967 RUBY_DTRACE_SYMBOL_CREATE(RSTRING_PTR(str), rb_sourcefile(), rb_sourceline());
16968 }
16969
16970 st_add_direct(global_symbols.sym_id, (st_data_t)str, id);
16971 st_add_direct(global_symbols.id_str, id, (st_data_t)str);
16972 global_symbols.minor_marked = 0;
16973 return id;
16974 }
16975
16976 static int
16977 sym_check_asciionly(VALUE str)
16978 {
16979 if (!rb_enc_asciicompat(rb_enc_get(str))) return FALSE;
16980 switch (rb_enc_str_coderange(str)) {
16981 case ENC_CODERANGE_BROKEN:
16982 rb_raise(rb_eEncodingError, "invalid encoding symbol");
16983 case ENC_CODERANGE_7BIT:
16984 return TRUE;
16985 }
16986 return FALSE;
16987 }
16988
16989
16990
16991
16992
16993
16994 static ID intern_str(VALUE str);
16995
16996 static VALUE
16997 setup_fake_str(struct RString *fake_str, const char *name, long len)
16998 {
16999 fake_str->basic.flags = T_STRING|RSTRING_NOEMBED;
17000 RBASIC_SET_CLASS_RAW((VALUE)fake_str, rb_cString);
17001 fake_str->as.heap.len = len;
17002 fake_str->as.heap.ptr = (char *)name;
17003 fake_str->as.heap.aux.capa = len;
17004 return (VALUE)fake_str;
17005 }
17006
17007 ID
17008 rb_intern3(const char *name, long len, rb_encoding *enc)
17009 {
17010 st_data_t data;
17011 struct RString fake_str;
17012 VALUE str = setup_fake_str(&fake_str, name, len);
17013 rb_enc_associate(str, enc);
17014 OBJ_FREEZE(str);
17015
17016 if (st_lookup(global_symbols.sym_id, str, &data))
17017 return (ID)data;
17018
17019 str = rb_enc_str_new(name, len, enc);
17020 return intern_str(str);
17021 }
17022
17023 static ID
17024 intern_str(VALUE str)
17025 {
17026 const char *name, *m, *e;
17027 long len, last;
17028 rb_encoding *enc, *symenc;
17029 unsigned char c;
17030 ID id;
17031 int mb;
17032
17033 RSTRING_GETMEM(str, name, len);
17034 m = name;
17035 e = m + len;
17036 enc = rb_enc_get(str);
17037 symenc = enc;
17038
17039 if (!len || (rb_cString && !rb_enc_asciicompat(enc))) {
17040 junk:
17041 id = ID_JUNK;
17042 goto new_id;
17043 }
17044 last = len-1;
17045 id = 0;
17046 switch (*m) {
17047 case '$':
17048 if (len < 2) goto junk;
17049 id |= ID_GLOBAL;
17050 if ((mb = is_special_global_name(++m, e, enc)) != 0) {
17051 if (!--mb) symenc = rb_usascii_encoding();
17052 goto new_id;
17053 }
17054 break;
17055 case '@':
17056 if (m[1] == '@') {
17057 if (len < 3) goto junk;
17058 m++;
17059 id |= ID_CLASS;
17060 }
17061 else {
17062 if (len < 2) goto junk;
17063 id |= ID_INSTANCE;
17064 }
17065 m++;
17066 break;
17067 default:
17068 c = m[0];
17069 if (c != '_' && rb_enc_isascii(c, enc) && rb_enc_ispunct(c, enc)) {
17070
17071 int i;
17072
17073 if (len == 1) {
17074 id = c;
17075 goto id_register;
17076 }
17077 for (i = 0; i < op_tbl_count; i++) {
17078 if (*op_tbl[i].name == *m &&
17079 strcmp(op_tbl[i].name, m) == 0) {
17080 id = op_tbl[i].token;
17081 goto id_register;
17082 }
17083 }
17084 }
17085 break;
17086 }
17087 if (name[last] == '=') {
17088
17089 if (last > 1 && name[last-1] == '=')
17090 goto junk;
17091 id = rb_intern3(name, last, enc);
17092 if (id > tLAST_OP_ID && !is_attrset_id(id)) {
17093 enc = rb_enc_get(rb_id2str(id));
17094 id = rb_id_attrset(id);
17095 goto id_register;
17096 }
17097 id = ID_ATTRSET;
17098 }
17099 else if (id == 0) {
17100 if (rb_enc_isupper(m[0], enc)) {
17101 id = ID_CONST;
17102 }
17103 else {
17104 id = ID_LOCAL;
17105 }
17106 }
17107 if (!rb_enc_isdigit(*m, enc)) {
17108 while (m <= name + last && is_identchar(m, e, enc)) {
17109 if (ISASCII(*m)) {
17110 m++;
17111 }
17112 else {
17113 m += rb_enc_mbclen(m, e, enc);
17114 }
17115 }
17116 }
17117 if (id != ID_ATTRSET && m - name < len) id = ID_JUNK;
17118 if (sym_check_asciionly(str)) symenc = rb_usascii_encoding();
17119 new_id:
17120 if (symenc != enc) rb_enc_associate(str, symenc);
17121 if (global_symbols.last_id >= ~(ID)0 >> (ID_SCOPE_SHIFT+RUBY_SPECIAL_SHIFT)) {
17122 if (len > 20) {
17123 rb_raise(rb_eRuntimeError, "symbol table overflow (symbol %.20s...)",
17124 name);
17125 }
17126 else {
17127 rb_raise(rb_eRuntimeError, "symbol table overflow (symbol %.*s)",
17128 (int)len, name);
17129 }
17130 }
17131 id |= ++global_symbols.last_id << ID_SCOPE_SHIFT;
17132 id_register:
17133 return register_symid_str(id, str);
17134 }
17135
17136 ID
17137 rb_intern2(const char *name, long len)
17138 {
17139 return rb_intern3(name, len, rb_usascii_encoding());
17140 }
17141
17142 #undef rb_intern
17143 ID
17144 rb_intern(const char *name)
17145 {
17146 return rb_intern2(name, strlen(name));
17147 }
17148
17149 ID
17150 rb_intern_str(VALUE str)
17151 {
17152 st_data_t id;
17153
17154 if (st_lookup(global_symbols.sym_id, str, &id))
17155 return (ID)id;
17156 return intern_str(rb_str_dup(str));
17157 }
17158
17159 VALUE
17160 rb_id2str(ID id)
17161 {
17162 st_data_t data;
17163
17164 if (id < tLAST_TOKEN) {
17165 int i = 0;
17166
17167 if (id < INT_MAX && rb_ispunct((int)id)) {
17168 VALUE str = global_symbols.op_sym[i = (int)id];
17169 if (!str) {
17170 char name[2];
17171 name[0] = (char)id;
17172 name[1] = 0;
17173 str = rb_usascii_str_new(name, 1);
17174 OBJ_FREEZE(str);
17175 str = rb_fstring(str);
17176 global_symbols.op_sym[i] = str;
17177 global_symbols.minor_marked = 0;
17178 }
17179 return str;
17180 }
17181 for (i = 0; i < op_tbl_count; i++) {
17182 if (op_tbl[i].token == id) {
17183 VALUE str = global_symbols.op_sym[i];
17184 if (!str) {
17185 str = rb_usascii_str_new2(op_tbl[i].name);
17186 OBJ_FREEZE(str);
17187 str = rb_fstring(str);
17188 global_symbols.op_sym[i] = str;
17189 global_symbols.minor_marked = 0;
17190 }
17191 return str;
17192 }
17193 }
17194 }
17195
17196 if (st_lookup(global_symbols.id_str, id, &data)) {
17197 VALUE str = (VALUE)data;
17198 if (RBASIC(str)->klass == 0)
17199 RBASIC_SET_CLASS_RAW(str, rb_cString);
17200 return str;
17201 }
17202
17203 if (is_attrset_id(id)) {
17204 ID id_stem = (id & ~ID_SCOPE_MASK);
17205 VALUE str;
17206
17207 do {
17208 if (!!(str = rb_id2str(id_stem | ID_LOCAL))) break;
17209 if (!!(str = rb_id2str(id_stem | ID_CONST))) break;
17210 if (!!(str = rb_id2str(id_stem | ID_INSTANCE))) break;
17211 if (!!(str = rb_id2str(id_stem | ID_GLOBAL))) break;
17212 if (!!(str = rb_id2str(id_stem | ID_CLASS))) break;
17213 if (!!(str = rb_id2str(id_stem | ID_JUNK))) break;
17214 return 0;
17215 } while (0);
17216 str = rb_str_dup(str);
17217 rb_str_cat(str, "=", 1);
17218 register_symid_str(id, str);
17219 if (st_lookup(global_symbols.id_str, id, &data)) {
17220 VALUE str = (VALUE)data;
17221 if (RBASIC(str)->klass == 0)
17222 RBASIC_SET_CLASS_RAW(str, rb_cString);
17223 return str;
17224 }
17225 }
17226 return 0;
17227 }
17228
17229 const char *
17230 rb_id2name(ID id)
17231 {
17232 VALUE str = rb_id2str(id);
17233
17234 if (!str) return 0;
17235 return RSTRING_PTR(str);
17236 }
17237
17238 static int
17239 symbols_i(VALUE sym, ID value, VALUE ary)
17240 {
17241 rb_ary_push(ary, ID2SYM(value));
17242 return ST_CONTINUE;
17243 }
17244
17245
17246
17247
17248
17249
17250
17251
17252
17253
17254
17255
17256
17257
17258
17259
17260
17261 VALUE
17262 rb_sym_all_symbols(void)
17263 {
17264 VALUE ary = rb_ary_new2(global_symbols.sym_id->num_entries);
17265
17266 st_foreach(global_symbols.sym_id, symbols_i, ary);
17267 return ary;
17268 }
17269
17270 int
17271 rb_is_const_id(ID id)
17272 {
17273 return is_const_id(id);
17274 }
17275
17276 int
17277 rb_is_class_id(ID id)
17278 {
17279 return is_class_id(id);
17280 }
17281
17282 int
17283 rb_is_global_id(ID id)
17284 {
17285 return is_global_id(id);
17286 }
17287
17288 int
17289 rb_is_instance_id(ID id)
17290 {
17291 return is_instance_id(id);
17292 }
17293
17294 int
17295 rb_is_attrset_id(ID id)
17296 {
17297 return is_attrset_id(id);
17298 }
17299
17300 int
17301 rb_is_local_id(ID id)
17302 {
17303 return is_local_id(id);
17304 }
17305
17306 int
17307 rb_is_junk_id(ID id)
17308 {
17309 return is_junk_id(id);
17310 }
17311
17323 ID
17324 rb_check_id(volatile VALUE *namep)
17325 {
17326 st_data_t id;
17327 VALUE tmp;
17328 VALUE name = *namep;
17329
17330 if (SYMBOL_P(name)) {
17331 return SYM2ID(name);
17332 }
17333 else if (!RB_TYPE_P(name, T_STRING)) {
17334 tmp = rb_check_string_type(name);
17335 if (NIL_P(tmp)) {
17336 tmp = rb_inspect(name);
17337 rb_raise(rb_eTypeError, "%s is not a symbol",
17338 RSTRING_PTR(tmp));
17339 }
17340 name = tmp;
17341 *namep = name;
17342 }
17343
17344 sym_check_asciionly(name);
17345
17346 if (st_lookup(global_symbols.sym_id, (st_data_t)name, &id))
17347 return (ID)id;
17348
17349 if (rb_is_attrset_name(name)) {
17350 struct RString fake_str;
17351
17352 const VALUE localname = setup_fake_str(&fake_str, RSTRING_PTR(name), RSTRING_LEN(name) - 1);
17353 rb_enc_copy(localname, name);
17354 OBJ_FREEZE(localname);
17355
17356 if (st_lookup(global_symbols.sym_id, (st_data_t)localname, &id)) {
17357 return rb_id_attrset((ID)id);
17358 }
17359 RB_GC_GUARD(name);
17360 }
17361
17362 return (ID)0;
17363 }
17364
17365 ID
17366 rb_check_id_cstr(const char *ptr, long len, rb_encoding *enc)
17367 {
17368 st_data_t id;
17369 struct RString fake_str;
17370 const VALUE name = setup_fake_str(&fake_str, ptr, len);
17371 rb_enc_associate(name, enc);
17372
17373 sym_check_asciionly(name);
17374
17375 if (st_lookup(global_symbols.sym_id, (st_data_t)name, &id))
17376 return (ID)id;
17377
17378 if (rb_is_attrset_name(name)) {
17379 fake_str.as.heap.len = len - 1;
17380 if (st_lookup(global_symbols.sym_id, (st_data_t)name, &id)) {
17381 return rb_id_attrset((ID)id);
17382 }
17383 }
17384
17385 return (ID)0;
17386 }
17387
17388 int
17389 rb_is_const_name(VALUE name)
17390 {
17391 return rb_str_symname_type(name, 0) == ID_CONST;
17392 }
17393
17394 int
17395 rb_is_class_name(VALUE name)
17396 {
17397 return rb_str_symname_type(name, 0) == ID_CLASS;
17398 }
17399
17400 int
17401 rb_is_global_name(VALUE name)
17402 {
17403 return rb_str_symname_type(name, 0) == ID_GLOBAL;
17404 }
17405
17406 int
17407 rb_is_instance_name(VALUE name)
17408 {
17409 return rb_str_symname_type(name, 0) == ID_INSTANCE;
17410 }
17411
17412 int
17413 rb_is_attrset_name(VALUE name)
17414 {
17415 return rb_str_symname_type(name, IDSET_ATTRSET_FOR_INTERN) == ID_ATTRSET;
17416 }
17417
17418 int
17419 rb_is_local_name(VALUE name)
17420 {
17421 return rb_str_symname_type(name, 0) == ID_LOCAL;
17422 }
17423
17424 int
17425 rb_is_method_name(VALUE name)
17426 {
17427 switch (rb_str_symname_type(name, 0)) {
17428 case ID_LOCAL: case ID_ATTRSET: case ID_JUNK:
17429 return TRUE;
17430 }
17431 return FALSE;
17432 }
17433
17434 int
17435 rb_is_junk_name(VALUE name)
17436 {
17437 return rb_str_symname_type(name, IDSET_ATTRSET_FOR_SYNTAX) == -1;
17438 }
17439
17440 #endif
17441
17442 static void
17443 parser_initialize(struct parser_params *parser)
17444 {
17445 parser->eofp = Qfalse;
17446
17447 parser->parser_lex_strterm = 0;
17448 parser->parser_cond_stack = 0;
17449 parser->parser_cmdarg_stack = 0;
17450 parser->parser_class_nest = 0;
17451 parser->parser_paren_nest = 0;
17452 parser->parser_lpar_beg = 0;
17453 parser->parser_brace_nest = 0;
17454 parser->parser_in_single = 0;
17455 parser->parser_in_def = 0;
17456 parser->parser_in_defined = 0;
17457 parser->parser_in_kwarg = 0;
17458 parser->parser_compile_for_eval = 0;
17459 parser->parser_cur_mid = 0;
17460 parser->parser_tokenbuf = NULL;
17461 parser->parser_tokidx = 0;
17462 parser->parser_toksiz = 0;
17463 parser->parser_heredoc_end = 0;
17464 parser->parser_command_start = TRUE;
17465 parser->parser_deferred_nodes = 0;
17466 parser->parser_lex_pbeg = 0;
17467 parser->parser_lex_p = 0;
17468 parser->parser_lex_pend = 0;
17469 parser->parser_lvtbl = 0;
17470 parser->parser_ruby__end__seen = 0;
17471 parser->parser_ruby_sourcefile = 0;
17472 parser->parser_ruby_sourcefile_string = Qnil;
17473 #ifndef RIPPER
17474 parser->is_ripper = 0;
17475 parser->parser_eval_tree_begin = 0;
17476 parser->parser_eval_tree = 0;
17477 #else
17478 parser->is_ripper = 1;
17479 parser->delayed = Qnil;
17480
17481 parser->result = Qnil;
17482 parser->parsing_thread = Qnil;
17483 parser->toplevel_p = TRUE;
17484 #endif
17485 #ifdef YYMALLOC
17486 parser->heap = NULL;
17487 #endif
17488 parser->enc = rb_utf8_encoding();
17489 }
17490
17491 #ifdef RIPPER
17492 #define parser_mark ripper_parser_mark
17493 #define parser_free ripper_parser_free
17494 #endif
17495
17496 static void
17497 parser_mark(void *ptr)
17498 {
17499 struct parser_params *p = (struct parser_params*)ptr;
17500
17501 rb_gc_mark((VALUE)p->parser_lex_strterm);
17502 rb_gc_mark((VALUE)p->parser_deferred_nodes);
17503 rb_gc_mark(p->parser_lex_input);
17504 rb_gc_mark(p->parser_lex_lastline);
17505 rb_gc_mark(p->parser_lex_nextline);
17506 rb_gc_mark(p->parser_ruby_sourcefile_string);
17507 #ifndef RIPPER
17508 rb_gc_mark((VALUE)p->parser_eval_tree_begin) ;
17509 rb_gc_mark((VALUE)p->parser_eval_tree) ;
17510 rb_gc_mark(p->debug_lines);
17511 #else
17512 rb_gc_mark(p->delayed);
17513 rb_gc_mark(p->value);
17514 rb_gc_mark(p->result);
17515 rb_gc_mark(p->parsing_thread);
17516 #endif
17517 #ifdef YYMALLOC
17518 rb_gc_mark((VALUE)p->heap);
17519 #endif
17520 }
17521
17522 static void
17523 parser_free(void *ptr)
17524 {
17525 struct parser_params *p = (struct parser_params*)ptr;
17526 struct local_vars *local, *prev;
17527
17528 if (p->parser_tokenbuf) {
17529 xfree(p->parser_tokenbuf);
17530 }
17531 for (local = p->parser_lvtbl; local; local = prev) {
17532 if (local->vars) xfree(local->vars);
17533 prev = local->prev;
17534 xfree(local);
17535 }
17536 xfree(p);
17537 }
17538
17539 static size_t
17540 parser_memsize(const void *ptr)
17541 {
17542 struct parser_params *p = (struct parser_params*)ptr;
17543 struct local_vars *local;
17544 size_t size = sizeof(*p);
17545
17546 if (!ptr) return 0;
17547 size += p->parser_toksiz;
17548 for (local = p->parser_lvtbl; local; local = local->prev) {
17549 size += sizeof(*local);
17550 if (local->vars) size += local->vars->capa * sizeof(ID);
17551 }
17552 return size;
17553 }
17554
17555 static
17556 #ifndef RIPPER
17557 const
17558 #endif
17559 rb_data_type_t parser_data_type = {
17560 "parser",
17561 {
17562 parser_mark,
17563 parser_free,
17564 parser_memsize,
17565 },
17566 NULL, NULL, RUBY_TYPED_FREE_IMMEDIATELY
17567 };
17568
17569 #ifndef RIPPER
17570 #undef rb_reserved_word
17571
17572 const struct kwtable *
17573 rb_reserved_word(const char *str, unsigned int len)
17574 {
17575 return reserved_word(str, len);
17576 }
17577
17578 static struct parser_params *
17579 parser_new(void)
17580 {
17581 struct parser_params *p;
17582
17583 p = ALLOC_N(struct parser_params, 1);
17584 MEMZERO(p, struct parser_params, 1);
17585 parser_initialize(p);
17586 return p;
17587 }
17588
17589 VALUE
17590 rb_parser_new(void)
17591 {
17592 struct parser_params *p = parser_new();
17593
17594 return TypedData_Wrap_Struct(0, &parser_data_type, p);
17595 }
17596
17597
17598
17599
17600
17601
17602
17603 VALUE
17604 rb_parser_end_seen_p(VALUE vparser)
17605 {
17606 struct parser_params *parser;
17607
17608 TypedData_Get_Struct(vparser, struct parser_params, &parser_data_type, parser);
17609 return ruby__end__seen ? Qtrue : Qfalse;
17610 }
17611
17612
17613
17614
17615
17616
17617
17618 VALUE
17619 rb_parser_encoding(VALUE vparser)
17620 {
17621 struct parser_params *parser;
17622
17623 TypedData_Get_Struct(vparser, struct parser_params, &parser_data_type, parser);
17624 return rb_enc_from_encoding(current_enc);
17625 }
17626
17627
17628
17629
17630
17631
17632
17633 VALUE
17634 rb_parser_get_yydebug(VALUE self)
17635 {
17636 struct parser_params *parser;
17637
17638 TypedData_Get_Struct(self, struct parser_params, &parser_data_type, parser);
17639 return yydebug ? Qtrue : Qfalse;
17640 }
17641
17642
17643
17644
17645
17646
17647
17648 VALUE
17649 rb_parser_set_yydebug(VALUE self, VALUE flag)
17650 {
17651 struct parser_params *parser;
17652
17653 TypedData_Get_Struct(self, struct parser_params, &parser_data_type, parser);
17654 yydebug = RTEST(flag);
17655 return flag;
17656 }
17657
17658 #ifdef YYMALLOC
17659 #define HEAPCNT(n, size) ((n) * (size) / sizeof(YYSTYPE))
17660 #define NEWHEAP() rb_node_newnode(NODE_ALLOCA, 0, (VALUE)parser->heap, 0)
17661 #define ADD2HEAP(n, c, p) ((parser->heap = (n))->u1.node = (p), \
17662 (n)->u3.cnt = (c), (p))
17663
17664 void *
17665 rb_parser_malloc(struct parser_params *parser, size_t size)
17666 {
17667 size_t cnt = HEAPCNT(1, size);
17668 NODE *n = NEWHEAP();
17669 void *ptr = xmalloc(size);
17670
17671 return ADD2HEAP(n, cnt, ptr);
17672 }
17673
17674 void *
17675 rb_parser_calloc(struct parser_params *parser, size_t nelem, size_t size)
17676 {
17677 size_t cnt = HEAPCNT(nelem, size);
17678 NODE *n = NEWHEAP();
17679 void *ptr = xcalloc(nelem, size);
17680
17681 return ADD2HEAP(n, cnt, ptr);
17682 }
17683
17684 void *
17685 rb_parser_realloc(struct parser_params *parser, void *ptr, size_t size)
17686 {
17687 NODE *n;
17688 size_t cnt = HEAPCNT(1, size);
17689
17690 if (ptr && (n = parser->heap) != NULL) {
17691 do {
17692 if (n->u1.node == ptr) {
17693 n->u1.node = ptr = xrealloc(ptr, size);
17694 if (n->u3.cnt) n->u3.cnt = cnt;
17695 return ptr;
17696 }
17697 } while ((n = n->u2.node) != NULL);
17698 }
17699 n = NEWHEAP();
17700 ptr = xrealloc(ptr, size);
17701 return ADD2HEAP(n, cnt, ptr);
17702 }
17703
17704 void
17705 rb_parser_free(struct parser_params *parser, void *ptr)
17706 {
17707 NODE **prev = &parser->heap, *n;
17708
17709 while ((n = *prev) != NULL) {
17710 if (n->u1.node == ptr) {
17711 *prev = n->u2.node;
17712 rb_gc_force_recycle((VALUE)n);
17713 break;
17714 }
17715 prev = &n->u2.node;
17716 }
17717 xfree(ptr);
17718 }
17719 #endif
17720 #endif
17721
17722 #ifdef RIPPER
17723 #ifdef RIPPER_DEBUG
17724 extern int rb_is_pointer_to_heap(VALUE);
17725
17726
17727 static VALUE
17728 ripper_validate_object(VALUE self, VALUE x)
17729 {
17730 if (x == Qfalse) return x;
17731 if (x == Qtrue) return x;
17732 if (x == Qnil) return x;
17733 if (x == Qundef)
17734 rb_raise(rb_eArgError, "Qundef given");
17735 if (FIXNUM_P(x)) return x;
17736 if (SYMBOL_P(x)) return x;
17737 if (!rb_is_pointer_to_heap(x))
17738 rb_raise(rb_eArgError, "invalid pointer: %p", x);
17739 switch (BUILTIN_TYPE(x)) {
17740 case T_STRING:
17741 case T_OBJECT:
17742 case T_ARRAY:
17743 case T_BIGNUM:
17744 case T_FLOAT:
17745 case T_COMPLEX:
17746 case T_RATIONAL:
17747 return x;
17748 case T_NODE:
17749 if (nd_type(x) != NODE_LASGN) {
17750 rb_raise(rb_eArgError, "NODE given: %p", x);
17751 }
17752 return ((NODE *)x)->nd_rval;
17753 default:
17754 rb_raise(rb_eArgError, "wrong type of ruby object: %p (%s)",
17755 x, rb_obj_classname(x));
17756 }
17757 return x;
17758 }
17759 #endif
17760
17761 #define validate(x) ((x) = get_value(x))
17762
17763 static VALUE
17764 ripper_dispatch0(struct parser_params *parser, ID mid)
17765 {
17766 return rb_funcall(parser->value, mid, 0);
17767 }
17768
17769 static VALUE
17770 ripper_dispatch1(struct parser_params *parser, ID mid, VALUE a)
17771 {
17772 validate(a);
17773 return rb_funcall(parser->value, mid, 1, a);
17774 }
17775
17776 static VALUE
17777 ripper_dispatch2(struct parser_params *parser, ID mid, VALUE a, VALUE b)
17778 {
17779 validate(a);
17780 validate(b);
17781 return rb_funcall(parser->value, mid, 2, a, b);
17782 }
17783
17784 static VALUE
17785 ripper_dispatch3(struct parser_params *parser, ID mid, VALUE a, VALUE b, VALUE c)
17786 {
17787 validate(a);
17788 validate(b);
17789 validate(c);
17790 return rb_funcall(parser->value, mid, 3, a, b, c);
17791 }
17792
17793 static VALUE
17794 ripper_dispatch4(struct parser_params *parser, ID mid, VALUE a, VALUE b, VALUE c, VALUE d)
17795 {
17796 validate(a);
17797 validate(b);
17798 validate(c);
17799 validate(d);
17800 return rb_funcall(parser->value, mid, 4, a, b, c, d);
17801 }
17802
17803 static VALUE
17804 ripper_dispatch5(struct parser_params *parser, ID mid, VALUE a, VALUE b, VALUE c, VALUE d, VALUE e)
17805 {
17806 validate(a);
17807 validate(b);
17808 validate(c);
17809 validate(d);
17810 validate(e);
17811 return rb_funcall(parser->value, mid, 5, a, b, c, d, e);
17812 }
17813
17814 static VALUE
17815 ripper_dispatch7(struct parser_params *parser, ID mid, VALUE a, VALUE b, VALUE c, VALUE d, VALUE e, VALUE f, VALUE g)
17816 {
17817 validate(a);
17818 validate(b);
17819 validate(c);
17820 validate(d);
17821 validate(e);
17822 validate(f);
17823 validate(g);
17824 return rb_funcall(parser->value, mid, 7, a, b, c, d, e, f, g);
17825 }
17826
17827 static const struct kw_assoc {
17828 ID id;
17829 const char *name;
17830 } keyword_to_name[] = {
17831 {keyword_class, "class"},
17832 {keyword_module, "module"},
17833 {keyword_def, "def"},
17834 {keyword_undef, "undef"},
17835 {keyword_begin, "begin"},
17836 {keyword_rescue, "rescue"},
17837 {keyword_ensure, "ensure"},
17838 {keyword_end, "end"},
17839 {keyword_if, "if"},
17840 {keyword_unless, "unless"},
17841 {keyword_then, "then"},
17842 {keyword_elsif, "elsif"},
17843 {keyword_else, "else"},
17844 {keyword_case, "case"},
17845 {keyword_when, "when"},
17846 {keyword_while, "while"},
17847 {keyword_until, "until"},
17848 {keyword_for, "for"},
17849 {keyword_break, "break"},
17850 {keyword_next, "next"},
17851 {keyword_redo, "redo"},
17852 {keyword_retry, "retry"},
17853 {keyword_in, "in"},
17854 {keyword_do, "do"},
17855 {keyword_do_cond, "do"},
17856 {keyword_do_block, "do"},
17857 {keyword_return, "return"},
17858 {keyword_yield, "yield"},
17859 {keyword_super, "super"},
17860 {keyword_self, "self"},
17861 {keyword_nil, "nil"},
17862 {keyword_true, "true"},
17863 {keyword_false, "false"},
17864 {keyword_and, "and"},
17865 {keyword_or, "or"},
17866 {keyword_not, "not"},
17867 {modifier_if, "if"},
17868 {modifier_unless, "unless"},
17869 {modifier_while, "while"},
17870 {modifier_until, "until"},
17871 {modifier_rescue, "rescue"},
17872 {keyword_alias, "alias"},
17873 {keyword_defined, "defined?"},
17874 {keyword_BEGIN, "BEGIN"},
17875 {keyword_END, "END"},
17876 {keyword__LINE__, "__LINE__"},
17877 {keyword__FILE__, "__FILE__"},
17878 {keyword__ENCODING__, "__ENCODING__"},
17879 {0, NULL}
17880 };
17881
17882 static const char*
17883 keyword_id_to_str(ID id)
17884 {
17885 const struct kw_assoc *a;
17886
17887 for (a = keyword_to_name; a->id; a++) {
17888 if (a->id == id)
17889 return a->name;
17890 }
17891 return NULL;
17892 }
17893
17894 #undef ripper_id2sym
17895 static VALUE
17896 ripper_id2sym(ID id)
17897 {
17898 const char *name;
17899 char buf[8];
17900
17901 if (id <= 256) {
17902 buf[0] = (char)id;
17903 buf[1] = '\0';
17904 return ID2SYM(rb_intern2(buf, 1));
17905 }
17906 if ((name = keyword_id_to_str(id))) {
17907 return ID2SYM(rb_intern(name));
17908 }
17909 switch (id) {
17910 case tOROP:
17911 name = "||";
17912 break;
17913 case tANDOP:
17914 name = "&&";
17915 break;
17916 default:
17917 name = rb_id2name(id);
17918 if (!name) {
17919 rb_bug("cannot convert ID to string: %ld", (unsigned long)id);
17920 }
17921 return ID2SYM(id);
17922 }
17923 return ID2SYM(rb_intern(name));
17924 }
17925
17926 static ID
17927 ripper_get_id(VALUE v)
17928 {
17929 NODE *nd;
17930 if (!RB_TYPE_P(v, T_NODE)) return 0;
17931 nd = (NODE *)v;
17932 if (nd_type(nd) != NODE_LASGN) return 0;
17933 return nd->nd_vid;
17934 }
17935
17936 static VALUE
17937 ripper_get_value(VALUE v)
17938 {
17939 NODE *nd;
17940 if (v == Qundef) return Qnil;
17941 if (!RB_TYPE_P(v, T_NODE)) return v;
17942 nd = (NODE *)v;
17943 if (nd_type(nd) != NODE_LASGN) return Qnil;
17944 return nd->nd_rval;
17945 }
17946
17947 static void
17948 ripper_compile_error(struct parser_params *parser, const char *fmt, ...)
17949 {
17950 VALUE str;
17951 va_list args;
17952
17953 va_start(args, fmt);
17954 str = rb_vsprintf(fmt, args);
17955 va_end(args);
17956 rb_funcall(parser->value, rb_intern("compile_error"), 1, str);
17957 }
17958
17959 static void
17960 ripper_warn0(struct parser_params *parser, const char *fmt)
17961 {
17962 rb_funcall(parser->value, rb_intern("warn"), 1, STR_NEW2(fmt));
17963 }
17964
17965 static void
17966 ripper_warnI(struct parser_params *parser, const char *fmt, int a)
17967 {
17968 rb_funcall(parser->value, rb_intern("warn"), 2,
17969 STR_NEW2(fmt), INT2NUM(a));
17970 }
17971
17972 static void
17973 ripper_warnS(struct parser_params *parser, const char *fmt, const char *str)
17974 {
17975 rb_funcall(parser->value, rb_intern("warn"), 2,
17976 STR_NEW2(fmt), STR_NEW2(str));
17977 }
17978
17979 static void
17980 ripper_warning0(struct parser_params *parser, const char *fmt)
17981 {
17982 rb_funcall(parser->value, rb_intern("warning"), 1, STR_NEW2(fmt));
17983 }
17984
17985 static void
17986 ripper_warningS(struct parser_params *parser, const char *fmt, const char *str)
17987 {
17988 rb_funcall(parser->value, rb_intern("warning"), 2,
17989 STR_NEW2(fmt), STR_NEW2(str));
17990 }
17991
17992 static VALUE
17993 ripper_lex_get_generic(struct parser_params *parser, VALUE src)
17994 {
17995 return rb_io_gets(src);
17996 }
17997
17998 static VALUE
17999 ripper_s_allocate(VALUE klass)
18000 {
18001 struct parser_params *p;
18002 VALUE self;
18003
18004 p = ALLOC_N(struct parser_params, 1);
18005 MEMZERO(p, struct parser_params, 1);
18006 self = TypedData_Wrap_Struct(klass, &parser_data_type, p);
18007 p->value = self;
18008 return self;
18009 }
18010
18011 #define ripper_initialized_p(r) ((r)->parser_lex_input != 0)
18012
18013
18014
18015
18016
18017
18018
18019
18020
18021
18022
18023 static VALUE
18024 ripper_initialize(int argc, VALUE *argv, VALUE self)
18025 {
18026 struct parser_params *parser;
18027 VALUE src, fname, lineno;
18028
18029 TypedData_Get_Struct(self, struct parser_params, &parser_data_type, parser);
18030 rb_scan_args(argc, argv, "12", &src, &fname, &lineno);
18031 if (RB_TYPE_P(src, T_FILE)) {
18032 parser->parser_lex_gets = ripper_lex_get_generic;
18033 }
18034 else {
18035 StringValue(src);
18036 parser->parser_lex_gets = lex_get_str;
18037 }
18038 parser->parser_lex_input = src;
18039 parser->eofp = Qfalse;
18040 if (NIL_P(fname)) {
18041 fname = STR_NEW2("(ripper)");
18042 }
18043 else {
18044 StringValue(fname);
18045 }
18046 parser_initialize(parser);
18047
18048 parser->parser_ruby_sourcefile_string = fname;
18049 parser->parser_ruby_sourcefile = RSTRING_PTR(fname);
18050 parser->parser_ruby_sourceline = NIL_P(lineno) ? 0 : NUM2INT(lineno) - 1;
18051
18052 return Qnil;
18053 }
18054
18055 struct ripper_args {
18056 struct parser_params *parser;
18057 int argc;
18058 VALUE *argv;
18059 };
18060
18061 static VALUE
18062 ripper_parse0(VALUE parser_v)
18063 {
18064 struct parser_params *parser;
18065
18066 TypedData_Get_Struct(parser_v, struct parser_params, &parser_data_type, parser);
18067 parser_prepare(parser);
18068 ripper_yyparse((void*)parser);
18069 return parser->result;
18070 }
18071
18072 static VALUE
18073 ripper_ensure(VALUE parser_v)
18074 {
18075 struct parser_params *parser;
18076
18077 TypedData_Get_Struct(parser_v, struct parser_params, &parser_data_type, parser);
18078 parser->parsing_thread = Qnil;
18079 return Qnil;
18080 }
18081
18082
18083
18084
18085
18086
18087
18088 static VALUE
18089 ripper_parse(VALUE self)
18090 {
18091 struct parser_params *parser;
18092
18093 TypedData_Get_Struct(self, struct parser_params, &parser_data_type, parser);
18094 if (!ripper_initialized_p(parser)) {
18095 rb_raise(rb_eArgError, "method called for uninitialized object");
18096 }
18097 if (!NIL_P(parser->parsing_thread)) {
18098 if (parser->parsing_thread == rb_thread_current())
18099 rb_raise(rb_eArgError, "Ripper#parse is not reentrant");
18100 else
18101 rb_raise(rb_eArgError, "Ripper#parse is not multithread-safe");
18102 }
18103 parser->parsing_thread = rb_thread_current();
18104 rb_ensure(ripper_parse0, self, ripper_ensure, self);
18105
18106 return parser->result;
18107 }
18108
18109
18110
18111
18112
18113
18114
18115
18116 static VALUE
18117 ripper_column(VALUE self)
18118 {
18119 struct parser_params *parser;
18120 long col;
18121
18122 TypedData_Get_Struct(self, struct parser_params, &parser_data_type, parser);
18123 if (!ripper_initialized_p(parser)) {
18124 rb_raise(rb_eArgError, "method called for uninitialized object");
18125 }
18126 if (NIL_P(parser->parsing_thread)) return Qnil;
18127 col = parser->tokp - parser->parser_lex_pbeg;
18128 return LONG2NUM(col);
18129 }
18130
18131
18132
18133
18134
18135
18136
18137 static VALUE
18138 ripper_filename(VALUE self)
18139 {
18140 struct parser_params *parser;
18141
18142 TypedData_Get_Struct(self, struct parser_params, &parser_data_type, parser);
18143 if (!ripper_initialized_p(parser)) {
18144 rb_raise(rb_eArgError, "method called for uninitialized object");
18145 }
18146 return parser->parser_ruby_sourcefile_string;
18147 }
18148
18149
18150
18151
18152
18153
18154
18155
18156 static VALUE
18157 ripper_lineno(VALUE self)
18158 {
18159 struct parser_params *parser;
18160
18161 TypedData_Get_Struct(self, struct parser_params, &parser_data_type, parser);
18162 if (!ripper_initialized_p(parser)) {
18163 rb_raise(rb_eArgError, "method called for uninitialized object");
18164 }
18165 if (NIL_P(parser->parsing_thread)) return Qnil;
18166 return INT2NUM(parser->parser_ruby_sourceline);
18167 }
18168
18169 #ifdef RIPPER_DEBUG
18170
18171 static VALUE
18172 ripper_assert_Qundef(VALUE self, VALUE obj, VALUE msg)
18173 {
18174 StringValue(msg);
18175 if (obj == Qundef) {
18176 rb_raise(rb_eArgError, "%"PRIsVALUE, msg);
18177 }
18178 return Qnil;
18179 }
18180
18181
18182 static VALUE
18183 ripper_value(VALUE self, VALUE obj)
18184 {
18185 return ULONG2NUM(obj);
18186 }
18187 #endif
18188
18189
18190 void
18191 Init_ripper(void)
18192 {
18193 parser_data_type.parent = RTYPEDDATA_TYPE(rb_parser_new());
18194
18195 ripper_init_eventids1();
18196 ripper_init_eventids2();
18197
18198 (void)rb_intern("||");
18199 (void)rb_intern("&&");
18200
18201 InitVM(ripper);
18202 }
18203
18204 void
18205 InitVM_ripper(void)
18206 {
18207 VALUE Ripper;
18208
18209 Ripper = rb_define_class("Ripper", rb_cObject);
18210
18211 rb_define_const(Ripper, "Version", rb_usascii_str_new2(RIPPER_VERSION));
18212 rb_define_alloc_func(Ripper, ripper_s_allocate);
18213 rb_define_method(Ripper, "initialize", ripper_initialize, -1);
18214 rb_define_method(Ripper, "parse", ripper_parse, 0);
18215 rb_define_method(Ripper, "column", ripper_column, 0);
18216 rb_define_method(Ripper, "filename", ripper_filename, 0);
18217 rb_define_method(Ripper, "lineno", ripper_lineno, 0);
18218 rb_define_method(Ripper, "end_seen?", rb_parser_end_seen_p, 0);
18219 rb_define_method(Ripper, "encoding", rb_parser_encoding, 0);
18220 rb_define_method(Ripper, "yydebug", rb_parser_get_yydebug, 0);
18221 rb_define_method(Ripper, "yydebug=", rb_parser_set_yydebug, 1);
18222 #ifdef RIPPER_DEBUG
18223 rb_define_method(rb_mKernel, "assert_Qundef", ripper_assert_Qundef, 2);
18224 rb_define_method(rb_mKernel, "rawVALUE", ripper_value, 1);
18225 rb_define_method(rb_mKernel, "validate_object", ripper_validate_object, 1);
18226 #endif
18227
18228 ripper_init_eventids1_table(Ripper);
18229 ripper_init_eventids2_table(Ripper);
18230
18231 # if 0
18232
18233
18234
18235
18236
18237
18238
18239 rb_define_global_const("SCRIPT_LINES__", Qnil);
18240 #endif
18241
18242 }
18243 #endif
18244
18245