Ruby
2.4.2p198(2017-09-14revision59899)
|
#include "ruby/ruby.h"
#include "ruby/st.h"
#include "ruby/encoding.h"
#include "internal.h"
#include "node.h"
#include "parse.h"
#include "symbol.h"
#include "regenc.h"
#include <stdio.h>
#include <errno.h>
#include <ctype.h>
#include "probes.h"
#include "ruby/regex.h"
#include "ruby/util.h"
#include "lex.c"
Go to the source code of this file.
Data Structures | |
struct | vtable |
struct | local_vars |
struct | token_info |
struct | parser_params |
union | yyalloc |
struct | magic_comment |
struct | reg_named_capture_assign_t |
Macros | |
#define | YYBISON 1 |
#define | YYBISON_VERSION "2.5" |
#define | YYSKELETON_NAME "yacc.c" |
#define | YYPURE 1 |
#define | YYPUSH 0 |
#define | YYPULL 1 |
#define | YYLSP_NEEDED 0 |
#define | PARSER_DEBUG 0 |
#define | YYDEBUG 1 |
#define | YYERROR_VERBOSE 1 |
#define | YYSTACK_USE_ALLOCA 0 |
#define | WARN_PAST_SCOPE 0 |
#define | TAB_WIDTH 8 |
#define | YYMALLOC(size) rb_parser_malloc(parser, (size)) |
#define | YYREALLOC(ptr, size) rb_parser_realloc(parser, (ptr), (size)) |
#define | YYCALLOC(nelem, size) rb_parser_calloc(parser, (nelem), (size)) |
#define | YYFREE(ptr) rb_parser_free(parser, (ptr)) |
#define | YYFPRINTF rb_parser_printf |
#define | malloc YYMALLOC |
#define | realloc YYREALLOC |
#define | calloc YYCALLOC |
#define | free YYFREE |
#define | DEF_EXPR(n) EXPR_##n = (1 << EXPR_##n##_bit) |
#define | IS_lex_state_for(x, ls) ((x) & (ls)) |
#define | IS_lex_state_all_for(x, ls) (((x) & (ls)) == (ls)) |
#define | IS_lex_state(ls) IS_lex_state_for(lex_state, (ls)) |
#define | IS_lex_state_all(ls) IS_lex_state_all_for(lex_state, (ls)) |
#define | SET_LEX_STATE(ls) |
#define | SHOW_BITSTACK(stack, name) (yydebug ? show_bitstack(stack, name, __LINE__) : (void)0) |
#define | BITSTACK_PUSH(stack, n) (((stack) = ((stack)<<1)|((n)&1)), SHOW_BITSTACK(stack, #stack"(push)")) |
#define | BITSTACK_POP(stack) (((stack) = (stack) >> 1), SHOW_BITSTACK(stack, #stack"(pop)")) |
#define | BITSTACK_LEXPOP(stack) (((stack) = ((stack) >> 1) | ((stack) & 1)), SHOW_BITSTACK(stack, #stack"(lexpop)")) |
#define | BITSTACK_SET_P(stack) (SHOW_BITSTACK(stack, #stack), (stack)&1) |
#define | BITSTACK_SET(stack, n) ((stack)=(n), SHOW_BITSTACK(stack, #stack"(set)")) |
#define | COND_PUSH(n) BITSTACK_PUSH(cond_stack, (n)) |
#define | COND_POP() BITSTACK_POP(cond_stack) |
#define | COND_LEXPOP() BITSTACK_LEXPOP(cond_stack) |
#define | COND_P() BITSTACK_SET_P(cond_stack) |
#define | COND_SET(n) BITSTACK_SET(cond_stack, (n)) |
#define | CMDARG_PUSH(n) BITSTACK_PUSH(cmdarg_stack, (n)) |
#define | CMDARG_POP() BITSTACK_POP(cmdarg_stack) |
#define | CMDARG_LEXPOP() BITSTACK_LEXPOP(cmdarg_stack) |
#define | CMDARG_P() BITSTACK_SET_P(cmdarg_stack) |
#define | CMDARG_SET(n) BITSTACK_SET(cmdarg_stack, (n)) |
#define | DVARS_INHERIT ((void*)1) |
#define | DVARS_TOPSCOPE NULL |
#define | DVARS_SPECIAL_P(tbl) (!POINTER_P(tbl)) |
#define | POINTER_P(val) ((VALUE)(val) & ~(VALUE)3) |
#define | VTBL_DEBUG 0 |
#define | intern_cstr(n, l, en) rb_intern3(n,l,en) |
#define | STR_NEW(p, n) rb_enc_str_new((p),(n),current_enc) |
#define | STR_NEW0() rb_enc_str_new(0,0,current_enc) |
#define | STR_NEW2(p) rb_enc_str_new((p),strlen(p),current_enc) |
#define | STR_NEW3(p, n, e, func) parser_str_new((p),(n),(e),(func),current_enc) |
#define | TOK_INTERN() intern_cstr(tok(), toklen(), current_enc) |
#define | yyerror(msg) parser_yyerror(parser, (msg)) |
#define | lex_strterm (parser->lex.strterm) |
#define | lex_state (parser->lex.state) |
#define | cond_stack (parser->cond_stack) |
#define | cmdarg_stack (parser->cmdarg_stack) |
#define | paren_nest (parser->lex.paren_nest) |
#define | lpar_beg (parser->lex.lpar_beg) |
#define | brace_nest (parser->lex.brace_nest) |
#define | in_single (parser->in_single) |
#define | in_def (parser->in_def) |
#define | in_main (parser->in_main) |
#define | in_defined (parser->in_defined) |
#define | tokenbuf (parser->tokenbuf) |
#define | tokidx (parser->tokidx) |
#define | toksiz (parser->toksiz) |
#define | tokline (parser->tokline) |
#define | lex_input (parser->lex.input) |
#define | lex_lastline (parser->lex.lastline) |
#define | lex_nextline (parser->lex.nextline) |
#define | lex_pbeg (parser->lex.pbeg) |
#define | lex_p (parser->lex.pcur) |
#define | lex_pend (parser->lex.pend) |
#define | heredoc_end (parser->heredoc_end) |
#define | heredoc_indent (parser->heredoc_indent) |
#define | heredoc_line_indent (parser->heredoc_line_indent) |
#define | command_start (parser->command_start) |
#define | lex_gets_ptr (parser->lex.gets_ptr) |
#define | lex_gets (parser->lex.gets) |
#define | lvtbl (parser->lvtbl) |
#define | ruby__end__seen (parser->ruby__end__seen) |
#define | ruby_sourceline (parser->ruby_sourceline) |
#define | ruby_sourcefile (parser->ruby_sourcefile) |
#define | ruby_sourcefile_string (parser->ruby_sourcefile_string) |
#define | current_enc (parser->enc) |
#define | current_arg (parser->cur_arg) |
#define | yydebug (parser->yydebug) |
#define | compile_for_eval (parser->base_block != 0 && !in_main) |
#define | ruby_eval_tree (parser->eval_tree) |
#define | ruby_eval_tree_begin (parser->eval_tree_begin) |
#define | ruby_debug_lines (parser->debug_lines) |
#define | ruby_coverage (parser->coverage) |
#define | CALL_Q_P(q) ((q) == tANDDOT) |
#define | NODE_CALL_Q(q) (CALL_Q_P(q) ? NODE_QCALL : NODE_CALL) |
#define | NEW_QCALL(q, r, m, a) NEW_NODE(NODE_CALL_Q(q),r,m,a) |
#define | lambda_beginning_p() (lpar_beg && lpar_beg == paren_nest) |
#define | yyparse ruby_yyparse |
#define | rb_node_newnode(type, a1, a2, a3) node_newnode(parser, (type), (a1), (a2), (a3)) |
#define | cond(node) cond_gen(parser, (node), FALSE) |
#define | method_cond(node) cond_gen(parser, (node), TRUE) |
#define | new_if(cc, left, right) new_if_gen(parser, (cc), (left), (right)) |
#define | new_unless(cc, left, right) new_if_gen(parser, (cc), (right), (left)) |
#define | logop(type, node1, node2) logop_gen(parser, (type), (node1), (node2)) |
#define | value_expr(node) value_expr_gen(parser, (node) = remove_begin(node)) |
#define | void_expr0(node) void_expr_gen(parser, (node)) |
#define | void_expr(node) void_expr0((node) = remove_begin(node)) |
#define | void_stmts(node) void_stmts_gen(parser, (node)) |
#define | reduce_nodes(n) reduce_nodes_gen(parser,(n)) |
#define | block_dup_check(n1, n2) block_dup_check_gen(parser,(n1),(n2)) |
#define | block_append(h, t) block_append_gen(parser,(h),(t)) |
#define | list_append(l, i) list_append_gen(parser,(l),(i)) |
#define | arg_append(h, t) arg_append_gen(parser,(h),(t)) |
#define | arg_concat(h, t) arg_concat_gen(parser,(h),(t)) |
#define | literal_concat(h, t) literal_concat_gen(parser,(h),(t)) |
#define | new_evstr(n) new_evstr_gen(parser,(n)) |
#define | evstr2dstr(n) evstr2dstr_gen(parser,(n)) |
#define | call_bin_op(recv, id, arg1) call_bin_op_gen(parser, (recv),(id),(arg1)) |
#define | call_uni_op(recv, id) call_uni_op_gen(parser, (recv),(id)) |
#define | new_args(f, o, r, p, t) new_args_gen(parser, (f),(o),(r),(p),(t)) |
#define | new_args_tail(k, kr, b) new_args_tail_gen(parser, (k),(kr),(b)) |
#define | new_kw_arg(k) ((k) ? NEW_KW_ARG(0, (k)) : 0) |
#define | ret_args(node) ret_args_gen(parser, (node)) |
#define | new_yield(node) new_yield_gen(parser, (node)) |
#define | dsym_node(node) dsym_node_gen(parser, (node)) |
#define | gettable(id) gettable_gen(parser,(id)) |
#define | assignable(id, node) assignable_gen(parser, (id), (node)) |
#define | aryset(node1, node2) aryset_gen(parser, (node1), (node2)) |
#define | attrset(node, q, id) attrset_gen(parser, (node), (q), (id)) |
#define | rb_backref_error(n) rb_backref_error_gen(parser,(n)) |
#define | node_assign(node1, node2) node_assign_gen(parser, (node1), (node2)) |
#define | new_attr_op_assign(lhs, type, attr, op, rhs) new_attr_op_assign_gen(parser, (lhs), (type), (attr), (op), (rhs)) |
#define | new_const_op_assign(lhs, op, rhs) new_const_op_assign_gen(parser, (lhs), (op), (rhs)) |
#define | const_path_field(w, n) NEW_COLON2(w, n) |
#define | top_const_field(n) NEW_COLON3(n) |
#define | const_decl(path) const_decl_gen(parser, path) |
#define | var_field(n) (n) |
#define | backref_assign_error(n, a) (rb_backref_error(n), NEW_BEGIN(0)) |
#define | new_hash(hash) new_hash_gen(parser, (hash)) |
#define | new_defined(expr) NEW_DEFINED(remove_begin_all(expr)) |
#define | new_regexp(node, opt) new_regexp_gen(parser, node, opt) |
#define | new_xstring(node) new_xstring_gen(parser, node) |
#define | new_string1(str) (str) |
#define | new_brace_body(param, stmt) NEW_ITER(param, stmt) |
#define | new_do_body(param, stmt) NEW_ITER(param, stmt) |
#define | match_op(node1, node2) match_op_gen(parser, (node1), (node2)) |
#define | local_tbl() local_tbl_gen(parser) |
#define | reg_compile(str, options) reg_compile_gen(parser, (str), (options)) |
#define | reg_fragment_setenc(str, options) reg_fragment_setenc_gen(parser, (str), (options)) |
#define | reg_fragment_check(str, options) reg_fragment_check_gen(parser, (str), (options)) |
#define | reg_named_capture_assign(regexp) reg_named_capture_assign_gen(parser,(regexp)) |
#define | heredoc_dedent(str) parser_heredoc_dedent(parser, (str)) |
#define | get_id(id) (id) |
#define | get_value(val) (val) |
#define | new_op_assign(lhs, op, rhs) new_op_assign_gen(parser, (lhs), (op), (rhs)) |
#define | formal_argument(id) formal_argument_gen(parser, (id)) |
#define | shadowing_lvar(name) shadowing_lvar_gen(parser, (name)) |
#define | new_bv(id) new_bv_gen(parser, (id)) |
#define | local_push(top) local_push_gen(parser,(top)) |
#define | local_pop() local_pop_gen(parser) |
#define | local_var(id) local_var_gen(parser, (id)) |
#define | arg_var(id) arg_var_gen(parser, (id)) |
#define | local_id(id) local_id_gen(parser, (id)) |
#define | internal_id() internal_id_gen(parser) |
#define | dyna_push() dyna_push_gen(parser) |
#define | dyna_pop(node) dyna_pop_gen(parser, (node)) |
#define | dyna_in_block() dyna_in_block_gen(parser) |
#define | dyna_var(id) local_var(id) |
#define | dvar_defined(id) dvar_defined_gen(parser, (id), 0) |
#define | dvar_defined_get(id) dvar_defined_gen(parser, (id), 1) |
#define | dvar_curr(id) dvar_curr_gen(parser, (id)) |
#define | lvar_defined(id) lvar_defined_gen(parser, (id)) |
#define | RE_OPTION_ONCE (1<<16) |
#define | RE_OPTION_ENCODING_SHIFT 8 |
#define | RE_OPTION_ENCODING(e) (((e)&0xff)<<RE_OPTION_ENCODING_SHIFT) |
#define | RE_OPTION_ENCODING_IDX(o) (((o)>>RE_OPTION_ENCODING_SHIFT)&0xff) |
#define | RE_OPTION_ENCODING_NONE(o) ((o)&RE_OPTION_ARG_ENCODING_NONE) |
#define | RE_OPTION_MASK 0xff |
#define | RE_OPTION_ARG_ENCODING_NONE 32 |
#define | NODE_STRTERM NODE_ZARRAY /* nothing to gc */ |
#define | NODE_HEREDOC NODE_ARRAY /* 1, 3 to gc */ |
#define | SIGN_EXTEND(x, n) (((1<<(n)-1)^((x)&~(~0<<(n))))-(1<<(n)-1)) |
#define | nd_func u1.id |
#define | nd_term(node) SIGN_EXTEND((node)->u2.id, CHAR_BIT*2) |
#define | nd_paren(node) (char)((node)->u2.id >> CHAR_BIT*2) |
#define | nd_nest u3.cnt |
#define | ripper_id2sym(id) id |
#define | Qnone 0 |
#define | ifndef_ripper(x) (x) |
#define | rb_warn0(fmt) WARN_CALL(WARN_ARGS(fmt, 1)) |
#define | rb_warn1(fmt, a) WARN_CALL(WARN_ARGS(fmt, 2), (a)) |
#define | rb_warn2(fmt, a, b) WARN_CALL(WARN_ARGS(fmt, 3), (a), (b)) |
#define | rb_warn3(fmt, a, b, c) WARN_CALL(WARN_ARGS(fmt, 4), (a), (b), (c)) |
#define | rb_warn4(fmt, a, b, c, d) WARN_CALL(WARN_ARGS(fmt, 5), (a), (b), (c), (d)) |
#define | rb_warning0(fmt) WARNING_CALL(WARNING_ARGS(fmt, 1)) |
#define | rb_warning1(fmt, a) WARNING_CALL(WARNING_ARGS(fmt, 2), (a)) |
#define | rb_warning2(fmt, a, b) WARNING_CALL(WARNING_ARGS(fmt, 3), (a), (b)) |
#define | rb_warning3(fmt, a, b, c) WARNING_CALL(WARNING_ARGS(fmt, 4), (a), (b), (c)) |
#define | rb_warning4(fmt, a, b, c, d) WARNING_CALL(WARNING_ARGS(fmt, 5), (a), (b), (c), (d)) |
#define | rb_warn0L(l, fmt) WARN_CALL(WARN_ARGS_L(l, fmt, 1)) |
#define | rb_warn1L(l, fmt, a) WARN_CALL(WARN_ARGS_L(l, fmt, 2), (a)) |
#define | rb_warn2L(l, fmt, a, b) WARN_CALL(WARN_ARGS_L(l, fmt, 3), (a), (b)) |
#define | rb_warn3L(l, fmt, a, b, c) WARN_CALL(WARN_ARGS_L(l, fmt, 4), (a), (b), (c)) |
#define | rb_warn4L(l, fmt, a, b, c, d) WARN_CALL(WARN_ARGS_L(l, fmt, 5), (a), (b), (c), (d)) |
#define | rb_warning0L(l, fmt) WARNING_CALL(WARNING_ARGS_L(l, fmt, 1)) |
#define | rb_warning1L(l, fmt, a) WARNING_CALL(WARNING_ARGS_L(l, fmt, 2), (a)) |
#define | rb_warning2L(l, fmt, a, b) WARNING_CALL(WARNING_ARGS_L(l, fmt, 3), (a), (b)) |
#define | rb_warning3L(l, fmt, a, b, c) WARNING_CALL(WARNING_ARGS_L(l, fmt, 4), (a), (b), (c)) |
#define | rb_warning4L(l, fmt, a, b, c, d) WARNING_CALL(WARNING_ARGS_L(l, fmt, 5), (a), (b), (c), (d)) |
#define | WARN_S_L(s, l) s |
#define | WARN_S(s) s |
#define | WARN_I(i) i |
#define | PRIsWARN PRIsVALUE |
#define | WARN_ARGS(fmt, n) WARN_ARGS_L(ruby_sourceline,fmt,n) |
#define | WARN_ARGS_L(l, fmt, n) ruby_sourcefile, (l), (fmt) |
#define | WARN_CALL rb_compile_warn |
#define | WARNING_ARGS(fmt, n) WARN_ARGS(fmt,n) |
#define | WARNING_ARGS_L(l, fmt, n) WARN_ARGS_L(l,fmt,n) |
#define | WARNING_CALL rb_compile_warning |
#define | compile_error parser_compile_error |
#define | PARSER_ARG parser, |
#define | token_info_push(token) token_info_push_gen(parser, (token), rb_strlen_lit(token)) |
#define | token_info_pop(token) token_info_pop_gen(parser, (token), rb_strlen_lit(token)) |
#define | YYERROR_VERBOSE 1 |
#define | YYTOKEN_TABLE 0 |
#define | YYSIZE_T unsigned int |
#define | YYSIZE_MAXIMUM ((YYSIZE_T) -1) |
#define | YY_(msgid) msgid |
#define | YYUSE(e) ((void) (e)) |
#define | YYID(n) (n) |
#define | YYSTACK_ALLOC YYMALLOC |
#define | YYSTACK_FREE YYFREE |
#define | YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM |
#define | YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) |
#define | YYSTACK_BYTES(N) |
#define | YYCOPY_NEEDED 1 |
#define | YYSTACK_RELOCATE(Stack_alloc, Stack) |
#define | YYCOPY(To, From, Count) |
#define | YYFINAL 3 |
#define | YYLAST 11794 |
#define | YYNTOKENS 146 |
#define | YYNNTS 217 |
#define | YYNRULES 642 |
#define | YYNSTATES 1085 |
#define | YYUNDEFTOK 2 |
#define | YYMAXUTOK 353 |
#define | YYTRANSLATE(YYX) ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) |
#define | YYPACT_NINF -876 |
#define | YYTABLE_NINF -643 |
#define | yypact_value_is_default(yystate) ((yystate) == (-876)) |
#define | yytable_value_is_error(yytable_value) ((yytable_value) == (-643)) |
#define | yyerrok (yyerrstatus = 0) |
#define | yyclearin (yychar = YYEMPTY) |
#define | YYEMPTY (-2) |
#define | YYEOF 0 |
#define | YYACCEPT goto yyacceptlab |
#define | YYABORT goto yyabortlab |
#define | YYERROR goto yyerrorlab |
#define | YYFAIL goto yyerrlab |
#define | YYRECOVERING() (!!yyerrstatus) |
#define | YYBACKUP(Token, Value) |
#define | YYTERROR 1 |
#define | YYERRCODE 256 |
#define | YYRHSLOC(Rhs, K) ((Rhs)[K]) |
#define | YYLLOC_DEFAULT(Current, Rhs, N) |
#define | YY_LOCATION_PRINT(File, Loc) ((void) 0) |
#define | YYLEX yylex (&yylval, parser) |
#define | YYDPRINTF(Args) |
#define | YY_SYMBOL_PRINT(Title, Type, Value, Location) |
#define | YY_STACK_PRINT(Bottom, Top) |
#define | YY_REDUCE_PRINT(Rule) |
#define | YYINITDEPTH 200 |
#define | YYMAXDEPTH 10000 |
#define | YYCASE_(N, S) |
#define | YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) |
#define | YYSYNTAX_ERROR |
#define | yylval (*parser->lval) |
#define | nextc() parser_nextc(parser) |
#define | pushback(c) parser_pushback(parser, (c)) |
#define | newtok() parser_newtok(parser) |
#define | tokspace(n) parser_tokspace(parser, (n)) |
#define | tokadd(c) parser_tokadd(parser, (c)) |
#define | tok_hex(numlen) parser_tok_hex(parser, (numlen)) |
#define | read_escape(flags, e) parser_read_escape(parser, (flags), (e)) |
#define | tokadd_escape(e) parser_tokadd_escape(parser, (e)) |
#define | regx_options() parser_regx_options(parser) |
#define | tokadd_string(f, t, p, n, e) parser_tokadd_string(parser,(f),(t),(p),(n),(e)) |
#define | parse_string(n) parser_parse_string(parser,(n)) |
#define | tokaddmbc(c, enc) parser_tokaddmbc(parser, (c), (enc)) |
#define | here_document(n) parser_here_document(parser,(n)) |
#define | heredoc_identifier() parser_heredoc_identifier(parser) |
#define | heredoc_restore(n) parser_heredoc_restore(parser,(n)) |
#define | whole_match_p(e, l, i) parser_whole_match_p(parser,(e),(l),(i)) |
#define | number_literal_suffix(f) parser_number_literal_suffix(parser, (f)) |
#define | set_number_literal(v, t, f) parser_set_number_literal(parser, (v), (t), (f)) |
#define | set_integer_literal(v, f) parser_set_integer_literal(parser, (v), (f)) |
#define | set_yylval_str(x) (yylval.node = NEW_STR(x)) |
#define | set_yylval_num(x) (yylval.num = (x)) |
#define | set_yylval_id(x) (yylval.id = (x)) |
#define | set_yylval_name(x) (yylval.id = (x)) |
#define | set_yylval_literal(x) (yylval.node = NEW_LIT(x)) |
#define | set_yylval_node(x) (yylval.node = (x)) |
#define | yylval_id() (yylval.id) |
#define | ripper_flush(p) (void)(p) |
#define | dispatch_scan_event(t) ((void)0) |
#define | dispatch_delayed_token(t) ((void)0) |
#define | has_delayed_token() (0) |
#define | parser_encoding_name() (current_enc->name) |
#define | parser_mbclen() mbclen((lex_p-1),lex_pend,current_enc) |
#define | is_identchar(p, e, enc) (rb_enc_isalnum((unsigned char)(*(p)),(enc)) || (*(p)) == '_' || !ISASCII(*(p))) |
#define | parser_is_identchar() (!parser->eofp && is_identchar((lex_p-1),lex_pend,current_enc)) |
#define | parser_isascii() ISASCII(*(lex_p-1)) |
#define | RUBY_DTRACE_PARSE_HOOK(name) |
#define | STR_FUNC_ESCAPE 0x01 |
#define | STR_FUNC_EXPAND 0x02 |
#define | STR_FUNC_REGEXP 0x04 |
#define | STR_FUNC_QWORDS 0x08 |
#define | STR_FUNC_SYMBOL 0x10 |
#define | STR_FUNC_INDENT 0x20 |
#define | STR_FUNC_LABEL 0x40 |
#define | STR_TERM_END -1 |
#define | lex_goto_eol(parser) ((parser)->lex.pcur = (parser)->lex.pend) |
#define | lex_eol_p() (lex_p >= lex_pend) |
#define | peek(c) peek_n((c), 0) |
#define | peek_n(c, n) (lex_p+(n) < lex_pend && (c) == (unsigned char)lex_p[n]) |
#define | peekc() peekc_n(0) |
#define | peekc_n(n) (lex_p+(n) < lex_pend ? (unsigned char)lex_p[n] : -1) |
#define | was_bol() (lex_p == lex_pbeg + 1) |
#define | tokfix() (tokenbuf[tokidx]='\0') |
#define | tok() tokenbuf |
#define | toklen() tokidx |
#define | toklast() (tokidx>0?tokenbuf[tokidx-1]:0) |
#define | tokcopy(n) memcpy(tokspace(n), lex_p - (n), (n)) |
#define | ESCAPE_CONTROL 1 |
#define | ESCAPE_META 2 |
#define | tokadd_mbchar(c) parser_tokadd_mbchar(parser, (c)) |
#define | mixed_error(enc1, enc2) |
#define | mixed_escape(beg, enc1, enc2) |
#define | NEW_STRTERM(func, term, paren) rb_node_newnode(NODE_STRTERM, (func), (term) | ((paren) << (CHAR_BIT * 2)), 0) |
#define | flush_string_content(enc) ((void)(enc)) |
#define | BIT(c, idx) (((c) / 32 - 1 == idx) ? (1U << ((c) % 32)) : 0) |
#define | SPECIAL_PUNCT(idx) |
#define | NUM_SUFFIX_R (1<<0) |
#define | NUM_SUFFIX_I (1<<1) |
#define | NUM_SUFFIX_ALL 3 |
#define | dispatch_heredoc_end() ((void)0) |
#define | arg_ambiguous(c) (arg_ambiguous_gen(parser, (c)), 1) |
#define | str_copy(_s, _p, _n) |
#define | IS_ARG() IS_lex_state(EXPR_ARG_ANY) |
#define | IS_END() IS_lex_state(EXPR_END_ANY) |
#define | IS_BEG() (IS_lex_state(EXPR_BEG_ANY) || IS_lex_state_all(EXPR_ARG|EXPR_LABELED)) |
#define | IS_SPCARG(c) (IS_ARG() && space_seen && !ISSPACE(c)) |
#define | IS_LABEL_POSSIBLE() |
#define | IS_LABEL_SUFFIX(n) (peek_n(':',(n)) && !peek_n(':', (n)+1)) |
#define | IS_AFTER_OPERATOR() IS_lex_state(EXPR_FNAME | EXPR_DOT) |
#define | ambiguous_operator(op, syn) |
#define | warn_balanced(op, syn) |
#define | no_digits() do {yyerror("numeric literal without digits"); return 0;} while (0) |
#define | parser_warning(node, mesg) parser_warning(parser, (node), (mesg)) |
#define | parser_warn(node, mesg) parser_warn(parser, (node), (mesg)) |
#define | assignable_result(x) (x) |
#define | LVAR_USED ((ID)1 << (sizeof(ID) * CHAR_BIT - 1)) |
#define | subnodes(n1, n2) |
#define | HEAPCNT(n, size) ((n) * (size) / sizeof(YYSTYPE)) |
#define | NEWHEAP() rb_node_newnode(NODE_ALLOCA, 0, (VALUE)parser->heap, 0) |
#define | ADD2HEAP(n, c, p) |
Typedefs | |
typedef VALUE | stack_type |
typedef struct token_info | token_info |
typedef unsigned char | yytype_uint8 |
typedef short int | yytype_int8 |
typedef unsigned short int | yytype_uint16 |
typedef short int | yytype_int16 |
typedef long(* | rb_magic_comment_length_t) (struct parser_params *parser, const char *name, long len) |
typedef void(* | rb_magic_comment_setter_t) (struct parser_params *parser, const char *name, const char *val) |
Enumerations | |
enum | lex_state_bits { EXPR_BEG_bit, EXPR_END_bit, EXPR_ENDARG_bit, EXPR_ENDFN_bit, EXPR_ARG_bit, EXPR_CMDARG_bit, EXPR_MID_bit, EXPR_FNAME_bit, EXPR_DOT_bit, EXPR_CLASS_bit, EXPR_LABEL_bit, EXPR_LABELED_bit, EXPR_FITEM_bit, EXPR_MAX_STATE, EXPR_BEG_bit, EXPR_END_bit, EXPR_ENDARG_bit, EXPR_ENDFN_bit, EXPR_ARG_bit, EXPR_CMDARG_bit, EXPR_MID_bit, EXPR_FNAME_bit, EXPR_DOT_bit, EXPR_CLASS_bit, EXPR_LABEL_bit, EXPR_LABELED_bit, EXPR_FITEM_bit, EXPR_MAX_STATE } |
enum | lex_state_e { DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), EXPR_VALUE = EXPR_BEG, EXPR_BEG_ANY = (EXPR_BEG | EXPR_MID | EXPR_CLASS), EXPR_ARG_ANY = (EXPR_ARG | EXPR_CMDARG), EXPR_END_ANY = (EXPR_END | EXPR_ENDARG | EXPR_ENDFN), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), DEF_EXPR =(BEG), EXPR_VALUE = EXPR_BEG, EXPR_BEG_ANY = (EXPR_BEG | EXPR_MID | EXPR_CLASS), EXPR_ARG_ANY = (EXPR_ARG | EXPR_CMDARG), EXPR_END_ANY = (EXPR_END | EXPR_ENDARG | EXPR_ENDFN) } |
enum | string_type { str_label = STR_FUNC_LABEL, str_squote = (0), str_dquote = (STR_FUNC_EXPAND), str_xquote = (STR_FUNC_EXPAND), str_regexp = (STR_FUNC_REGEXP|STR_FUNC_ESCAPE|STR_FUNC_EXPAND), str_sword = (STR_FUNC_QWORDS), str_dword = (STR_FUNC_QWORDS|STR_FUNC_EXPAND), str_ssym = (STR_FUNC_SYMBOL), str_dsym = (STR_FUNC_SYMBOL|STR_FUNC_EXPAND), str_label = STR_FUNC_LABEL, str_squote = (0), str_dquote = (STR_FUNC_EXPAND), str_xquote = (STR_FUNC_EXPAND), str_regexp = (STR_FUNC_REGEXP|STR_FUNC_ESCAPE|STR_FUNC_EXPAND), str_sword = (STR_FUNC_QWORDS), str_dword = (STR_FUNC_QWORDS|STR_FUNC_EXPAND), str_ssym = (STR_FUNC_SYMBOL), str_dsym = (STR_FUNC_SYMBOL|STR_FUNC_EXPAND) } |
Functions | |
static enum lex_state_e | trace_lex_state (enum lex_state_e from, enum lex_state_e to, int line) |
static void | show_bitstack (stack_type, const char *, int) |
static int | vtable_size (const struct vtable *tbl) |
static struct vtable * | vtable_alloc (struct vtable *prev) |
static void | vtable_free (struct vtable *tbl) |
static void | vtable_add (struct vtable *tbl, ID id) |
static void | vtable_pop (struct vtable *tbl, int n) |
static int | vtable_included (const struct vtable *tbl, ID id) |
static int | parser_yyerror (struct parser_params *, const char *) |
static int | yylex (YYSTYPE *, struct parser_params *) |
static NODE * | node_newnode (struct parser_params *, enum node_type, VALUE, VALUE, VALUE) |
static NODE * | cond_gen (struct parser_params *, NODE *, int) |
static NODE * | new_if_gen (struct parser_params *, NODE *, NODE *, NODE *) |
static NODE * | logop_gen (struct parser_params *, enum node_type, NODE *, NODE *) |
static NODE * | newline_node (NODE *) |
static void | fixpos (NODE *, NODE *) |
static int | value_expr_gen (struct parser_params *, NODE *) |
static void | void_expr_gen (struct parser_params *, NODE *) |
static NODE * | remove_begin (NODE *) |
static NODE * | remove_begin_all (NODE *) |
static void | void_stmts_gen (struct parser_params *, NODE *) |
static void | reduce_nodes_gen (struct parser_params *, NODE **) |
static void | block_dup_check_gen (struct parser_params *, NODE *, NODE *) |
static NODE * | block_append_gen (struct parser_params *, NODE *, NODE *) |
static NODE * | list_append_gen (struct parser_params *, NODE *, NODE *) |
static NODE * | list_concat (NODE *, NODE *) |
static NODE * | arg_append_gen (struct parser_params *, NODE *, NODE *) |
static NODE * | arg_concat_gen (struct parser_params *, NODE *, NODE *) |
static NODE * | literal_concat_gen (struct parser_params *, NODE *, NODE *) |
static int | literal_concat0 (struct parser_params *, VALUE, VALUE) |
static NODE * | new_evstr_gen (struct parser_params *, NODE *) |
static NODE * | evstr2dstr_gen (struct parser_params *, NODE *) |
static NODE * | splat_array (NODE *) |
static NODE * | call_bin_op_gen (struct parser_params *, NODE *, ID, NODE *) |
static NODE * | call_uni_op_gen (struct parser_params *, NODE *, ID) |
static NODE * | new_args_gen (struct parser_params *, NODE *, NODE *, ID, NODE *, NODE *) |
static NODE * | new_args_tail_gen (struct parser_params *, NODE *, ID, ID) |
static VALUE | negate_lit (VALUE) |
static NODE * | ret_args_gen (struct parser_params *, NODE *) |
static NODE * | arg_blk_pass (NODE *, NODE *) |
static NODE * | new_yield_gen (struct parser_params *, NODE *) |
static NODE * | dsym_node_gen (struct parser_params *, NODE *) |
static NODE * | gettable_gen (struct parser_params *, ID) |
static NODE * | assignable_gen (struct parser_params *, ID, NODE *) |
static NODE * | aryset_gen (struct parser_params *, NODE *, NODE *) |
static NODE * | attrset_gen (struct parser_params *, NODE *, ID, ID) |
static void | rb_backref_error_gen (struct parser_params *, NODE *) |
static NODE * | node_assign_gen (struct parser_params *, NODE *, NODE *) |
static NODE * | new_op_assign_gen (struct parser_params *parser, NODE *lhs, ID op, NODE *rhs) |
static NODE * | new_attr_op_assign_gen (struct parser_params *parser, NODE *lhs, ID atype, ID attr, ID op, NODE *rhs) |
static NODE * | new_const_op_assign_gen (struct parser_params *parser, NODE *lhs, ID op, NODE *rhs) |
static NODE * | const_decl_gen (struct parser_params *parser, NODE *path) |
static NODE * | kwd_append (NODE *, NODE *) |
static NODE * | new_hash_gen (struct parser_params *parser, NODE *hash) |
static NODE * | new_regexp_gen (struct parser_params *, NODE *, int) |
static NODE * | new_xstring_gen (struct parser_params *, NODE *) |
static NODE * | match_op_gen (struct parser_params *, NODE *, NODE *) |
static ID * | local_tbl_gen (struct parser_params *) |
static VALUE | reg_compile_gen (struct parser_params *, VALUE, int) |
static void | reg_fragment_setenc_gen (struct parser_params *, VALUE, int) |
static int | reg_fragment_check_gen (struct parser_params *, VALUE, int) |
static NODE * | reg_named_capture_assign_gen (struct parser_params *parser, VALUE regexp) |
static NODE * | parser_heredoc_dedent (struct parser_params *, NODE *) |
RUBY_FUNC_EXPORTED VALUE | rb_parser_reg_compile (struct parser_params *parser, VALUE str, int options) |
RUBY_FUNC_EXPORTED int | rb_reg_fragment_setenc (struct parser_params *, VALUE, int) |
static ID | formal_argument_gen (struct parser_params *, ID) |
static ID | shadowing_lvar_gen (struct parser_params *, ID) |
static void | new_bv_gen (struct parser_params *, ID) |
static void | local_push_gen (struct parser_params *, int) |
static void | local_pop_gen (struct parser_params *) |
static void | local_var_gen (struct parser_params *, ID) |
static void | arg_var_gen (struct parser_params *, ID) |
static int | local_id_gen (struct parser_params *, ID) |
static ID | internal_id_gen (struct parser_params *) |
static const struct vtable * | dyna_push_gen (struct parser_params *) |
static void | dyna_pop_gen (struct parser_params *, const struct vtable *) |
static int | dyna_in_block_gen (struct parser_params *) |
static int | dvar_defined_gen (struct parser_params *, ID, int) |
static int | dvar_curr_gen (struct parser_params *, ID) |
static int | lvar_defined_gen (struct parser_params *, ID) |
static void | parser_compile_error (struct parser_params *, const char *fmt,...) |
static void | token_info_push_gen (struct parser_params *, const char *token, size_t len) |
static void | token_info_pop_gen (struct parser_params *, const char *token, size_t len) |
static void | yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const *const yyvaluep, struct parser_params *parser) |
static void | yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const *const yyvaluep, struct parser_params *parser) |
static void | yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop, parser) |
static void | yy_reduce_print (YYSTYPE *yyvsp, int yyrule, struct parser_params *parser) |
static YYSIZE_T | yystrlen (char *yystr) const |
static char * | yystpcpy (char *yydest, const char *yysrc) |
static YYSIZE_T | yytnamerr (char *yyres, const char *yystr) |
static int | yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, yytype_int16 *yyssp, int yytoken) |
static void | yydestruct (char *yymsg, int yytype, YYSTYPE *yyvaluep, struct parser_params *parser) const |
int | yyparse () |
int | yyparse (struct parser_params *parser) |
static int | parser_regx_options (struct parser_params *) |
static int | parser_tokadd_string (struct parser_params *, int, int, int, long *, rb_encoding **) |
static void | parser_tokaddmbc (struct parser_params *parser, int c, rb_encoding *enc) |
static int | parser_parse_string (struct parser_params *, NODE *) |
static int | parser_here_document (struct parser_params *, NODE *) |
static int | token_info_get_column (struct parser_params *parser, const char *pend) |
static int | token_info_has_nonspaces (struct parser_params *parser, const char *pend) |
static int | parser_precise_mbclen (struct parser_params *parser, const char *p) |
static void | parser_prepare (struct parser_params *parser) |
static VALUE | debug_lines (VALUE fname) |
static VALUE | coverage (VALUE fname, int n) |
static int | e_option_supplied (struct parser_params *parser) |
static VALUE | yycompile0 (VALUE arg) |
static NODE * | yycompile (struct parser_params *parser, VALUE fname, int line) |
static rb_encoding * | must_be_ascii_compatible (VALUE s) |
static VALUE | lex_get_str (struct parser_params *parser, VALUE s) |
static VALUE | lex_getline (struct parser_params *parser) |
static NODE * | parser_compile_string (VALUE vparser, VALUE fname, VALUE s, int line) |
NODE * | rb_compile_string (const char *f, VALUE s, int line) |
NODE * | rb_parser_compile_string (VALUE vparser, const char *f, VALUE s, int line) |
NODE * | rb_parser_compile_string_path (VALUE vparser, VALUE f, VALUE s, int line) |
NODE * | rb_compile_cstr (const char *f, const char *s, int len, int line) |
NODE * | rb_parser_compile_cstr (VALUE vparser, const char *f, const char *s, int len, int line) |
VALUE | rb_io_gets_internal (VALUE io) |
static VALUE | lex_io_gets (struct parser_params *parser, VALUE io) |
NODE * | rb_compile_file (const char *f, VALUE file, int start) |
NODE * | rb_parser_compile_file (VALUE vparser, const char *f, VALUE file, int start) |
NODE * | rb_parser_compile_file_path (VALUE vparser, VALUE fname, VALUE file, int start) |
static VALUE | parser_str_new (const char *p, long n, rb_encoding *enc, int func, rb_encoding *enc0) |
static int | parser_nextline (struct parser_params *parser) |
static int | parser_cr (struct parser_params *parser, int c) |
static int | parser_nextc (struct parser_params *parser) |
static void | parser_pushback (struct parser_params *parser, int c) |
static char * | parser_newtok (struct parser_params *parser) |
static char * | parser_tokspace (struct parser_params *parser, int n) |
static void | parser_tokadd (struct parser_params *parser, int c) |
static int | parser_tok_hex (struct parser_params *parser, size_t *numlen) |
static int | parser_tokadd_codepoint (struct parser_params *parser, rb_encoding **encp, int regexp_literal, int wide) |
static int | parser_tokadd_utf8 (struct parser_params *parser, rb_encoding **encp, int string_literal, int symbol_literal, int regexp_literal) |
static int | parser_read_escape (struct parser_params *parser, int flags, rb_encoding **encp) |
static int | parser_tokadd_escape (struct parser_params *parser, rb_encoding **encp) |
static void | dispose_string (VALUE str) |
static int | parser_tokadd_mbchar (struct parser_params *parser, int c) |
static int | simple_re_meta (int c) |
static int | parser_update_heredoc_indent (struct parser_params *parser, int c) |
static int | parser_peek_variable_name (struct parser_params *parser) |
static int | parser_string_term (struct parser_params *parser, int func) |
static int | parser_heredoc_identifier (struct parser_params *parser) |
static void | parser_heredoc_restore (struct parser_params *parser, NODE *here) |
static int | dedent_string (VALUE string, int width) |
static int | parser_whole_match_p (struct parser_params *parser, const char *eos, long len, int indent) |
static int | parser_number_literal_suffix (struct parser_params *parser, int mask) |
static int | parser_set_number_literal (struct parser_params *parser, VALUE v, int type, int suffix) |
static int | parser_set_integer_literal (struct parser_params *parser, VALUE v, int suffix) |
static void | arg_ambiguous_gen (struct parser_params *parser, char c) |
static long | parser_encode_length (struct parser_params *parser, const char *name, long len) |
static void | parser_set_encode (struct parser_params *parser, const char *name) |
static int | comment_at_top (struct parser_params *parser) |
static void | magic_comment_encoding (struct parser_params *parser, const char *name, const char *val) |
static int | parser_get_bool (struct parser_params *parser, const char *name, const char *val) |
static void | parser_set_token_info (struct parser_params *parser, const char *name, const char *val) |
static void | parser_set_compile_option_flag (struct parser_params *parser, const char *name, const char *val) |
static const char * | magic_comment_marker (const char *str, long len) |
static int | parser_magic_comment (struct parser_params *parser, const char *str, long len) |
static void | set_file_encoding (struct parser_params *parser, const char *str, const char *send) |
static VALUE | parse_rational (struct parser_params *parser, char *str, int len, int seen_point) |
static int | parse_numeric (struct parser_params *parser, int c) |
static int | parse_qmark (struct parser_params *parser, int space_seen) |
static int | parse_percent (struct parser_params *parser, const int space_seen, const enum lex_state_e last_state) |
static int | tokadd_ident (struct parser_params *parser, int c) |
static ID | tokenize_ident (struct parser_params *parser, const enum lex_state_e last_state) |
static int | parse_numvar (struct parser_params *parser) |
static int | parse_gvar (struct parser_params *parser, const enum lex_state_e last_state) |
static int | parse_atmark (struct parser_params *parser, const enum lex_state_e last_state) |
static int | parse_ident (struct parser_params *parser, int c, int cmd_state) |
static int | parser_yylex (struct parser_params *parser) |
static enum node_type | nodetype (NODE *node) |
static int | nodeline (NODE *node) |
static void | parser_warning (struct parser_params *parser, NODE *node, const char *mesg) |
static void | parser_warn (struct parser_params *parser, NODE *node, const char *mesg) |
static VALUE | append_lex_state_name (enum lex_state_e state, VALUE buf) |
static int | is_private_local_id (ID name) |
static int | shadowing_lvar_0 (struct parser_params *parser, ID name) |
static int | is_static_content (NODE *node) |
static int | assign_in_cond (struct parser_params *parser, NODE *node) |
static void | warn_unless_e_option (struct parser_params *parser, NODE *node, const char *str) |
static void | warning_unless_e_option (struct parser_params *parser, NODE *node, const char *str) |
static NODE * | cond0 (struct parser_params *, NODE *, int) |
static NODE * | range_op (struct parser_params *parser, NODE *node) |
static int | literal_node (NODE *node) |
static void | no_blockarg (struct parser_params *parser, NODE *node) |
static int | append_literal_keys (st_data_t k, st_data_t v, st_data_t h) |
static NODE * | remove_duplicate_keys (struct parser_params *parser, NODE *hash) |
static void | warn_unused_var (struct parser_params *parser, struct local_vars *local) |
static void | dyna_pop_vtable (struct parser_params *parser, struct vtable **vtblp) |
static void | dyna_pop_1 (struct parser_params *parser) |
static void | reg_fragment_enc_error (struct parser_params *parser, VALUE str, int c) |
static int | reg_named_capture_assign_iter (const OnigUChar *name, const OnigUChar *name_end, int back_num, int *back_refs, OnigRegex regex, void *arg0) |
static VALUE | parser_reg_compile (struct parser_params *parser, VALUE str, int options) |
NODE * | rb_parser_append_print (VALUE vparser, NODE *node) |
NODE * | rb_parser_while_loop (VALUE vparser, NODE *node, int chop, int split) |
void | rb_init_parse (void) |
static void | parser_initialize (struct parser_params *parser) |
static void | parser_mark (void *ptr) |
static void | parser_free (void *ptr) |
static size_t | parser_memsize (const void *ptr) |
const struct kwtable * | rb_reserved_word (const char *str, unsigned int len) |
VALUE | rb_parser_new (void) |
VALUE | rb_parser_set_context (VALUE vparser, const struct rb_block *base, int main) |
VALUE | rb_parser_end_seen_p (VALUE vparser) |
VALUE | rb_parser_encoding (VALUE vparser) |
VALUE | rb_parser_get_yydebug (VALUE self) |
VALUE | rb_parser_set_yydebug (VALUE self, VALUE flag) |
void * | rb_parser_malloc (struct parser_params *parser, size_t size) |
void * | rb_parser_calloc (struct parser_params *parser, size_t nelem, size_t size) |
void * | rb_parser_realloc (struct parser_params *parser, void *ptr, size_t size) |
void | rb_parser_free (struct parser_params *parser, void *ptr) |
void | rb_parser_printf (struct parser_params *parser, const char *fmt,...) |
Variables | |
static const yytype_uint8 | yytranslate [] |
static const yytype_uint16 | yyprhs [] |
static const yytype_int16 | yyrhs [] |
static const yytype_uint16 | yyrline [] |
static const char *const | yytname [] |
static const yytype_uint16 | yyr1 [] |
static const yytype_uint8 | yyr2 [] |
static const yytype_uint16 | yydefact [] |
static const yytype_int16 | yydefgoto [] |
static const yytype_int16 | yypact [] |
static const yytype_int16 | yypgoto [] |
static const yytype_int16 | yytable [] |
static const yytype_int16 | yycheck [] |
static const yytype_uint16 | yystos [] |
static const rb_data_type_t | parser_data_type |
RUBY_FUNC_EXPORTED const unsigned int | ruby_global_name_punct_bits [(0x7e - 0x20+31)/32] |
static const struct magic_comment | magic_comments [] |
static const char | lex_state_names [][13] |
#define ADD2HEAP | ( | n, | |
c, | |||
p | |||
) |
Definition at line 17852 of file ripper.c.
Referenced by rb_parser_calloc(), rb_parser_malloc(), and rb_parser_realloc().
#define ambiguous_operator | ( | op, | |
syn | |||
) |
#define arg_ambiguous | ( | c | ) | (arg_ambiguous_gen(parser, (c)), 1) |
Definition at line 13674 of file ripper.c.
Referenced by arg_ambiguous_gen(), parser_yylex(), and ripper_init_eventids1().
#define arg_append | ( | h, | |
t | |||
) | arg_append_gen(parser,(h),(t)) |
Definition at line 495 of file ripper.c.
Referenced by arg_append_gen(), node_assign_gen(), and yyparse().
#define arg_concat | ( | h, | |
t | |||
) | arg_concat_gen(parser,(h),(t)) |
Definition at line 497 of file ripper.c.
Referenced by arg_concat_gen(), and yyparse().
#define arg_var | ( | id | ) | arg_var_gen(parser, (id)) |
Definition at line 672 of file ripper.c.
Referenced by new_args_tail_gen(), and yyparse().
#define aryset | ( | node1, | |
node2 | |||
) | aryset_gen(parser, (node1), (node2)) |
#define assignable | ( | id, | |
node | |||
) | assignable_gen(parser, (id), (node)) |
Definition at line 530 of file ripper.c.
Referenced by reg_named_capture_assign_iter(), and yyparse().
#define assignable_result | ( | x | ) | (x) |
Referenced by assignable_gen().
#define attrset | ( | node, | |
q, | |||
id | |||
) | attrset_gen(parser, (node), (q), (id)) |
#define backref_assign_error | ( | n, | |
a | |||
) | (rb_backref_error(n), NEW_BEGIN(0)) |
#define BIT | ( | c, | |
idx | |||
) | (((c) / 32 - 1 == idx) ? (1U << ((c) % 32)) : 0) |
#define BITSTACK_LEXPOP | ( | stack | ) | (((stack) = ((stack) >> 1) | ((stack) & 1)), SHOW_BITSTACK(stack, #stack"(lexpop)")) |
#define BITSTACK_POP | ( | stack | ) | (((stack) = (stack) >> 1), SHOW_BITSTACK(stack, #stack"(pop)")) |
#define BITSTACK_PUSH | ( | stack, | |
n | |||
) | (((stack) = ((stack)<<1)|((n)&1)), SHOW_BITSTACK(stack, #stack"(push)")) |
#define BITSTACK_SET | ( | stack, | |
n | |||
) | ((stack)=(n), SHOW_BITSTACK(stack, #stack"(set)")) |
#define BITSTACK_SET_P | ( | stack | ) | (SHOW_BITSTACK(stack, #stack), (stack)&1) |
#define block_append | ( | h, | |
t | |||
) | block_append_gen(parser,(h),(t)) |
Definition at line 490 of file ripper.c.
Referenced by rb_parser_append_print(), rb_parser_while_loop(), reg_named_capture_assign_iter(), remove_duplicate_keys(), and yyparse().
#define block_dup_check | ( | n1, | |
n2 | |||
) | block_dup_check_gen(parser,(n1),(n2)) |
#define brace_nest (parser->lex.brace_nest) |
Definition at line 410 of file ripper.c.
Referenced by parser_yylex(), and yyparse().
#define call_bin_op | ( | recv, | |
id, | |||
arg1 | |||
) | call_bin_op_gen(parser, (recv),(id),(arg1)) |
#define CALL_Q_P | ( | q | ) | ((q) == tANDDOT) |
Definition at line 449 of file ripper.c.
Referenced by attrset_gen(), and new_attr_op_assign_gen().
#define call_uni_op | ( | recv, | |
id | |||
) | call_uni_op_gen(parser, (recv),(id)) |
#define calloc YYCALLOC |
Definition at line 118 of file ripper.c.
Referenced by compat_init_setproctitle(), ffi_prep_incoming_args_VFP(), heap_page_allocate(), Init_Method(), objspace_xcalloc(), rb_objspace_alloc(), w32_cmdvector(), and w32_wopendir().
#define CMDARG_LEXPOP | ( | ) | BITSTACK_LEXPOP(cmdarg_stack) |
Definition at line 186 of file ripper.c.
Referenced by parser_yylex(), and yyparse().
#define CMDARG_P | ( | ) | BITSTACK_SET_P(cmdarg_stack) |
Definition at line 187 of file ripper.c.
Referenced by parse_ident().
#define CMDARG_POP | ( | ) | BITSTACK_POP(cmdarg_stack) |
#define CMDARG_PUSH | ( | n | ) | BITSTACK_PUSH(cmdarg_stack, (n)) |
Definition at line 184 of file ripper.c.
Referenced by parser_yylex(), and yyparse().
#define CMDARG_SET | ( | n | ) | BITSTACK_SET(cmdarg_stack, (n)) |
Definition at line 188 of file ripper.c.
Referenced by local_pop_gen(), local_push_gen(), and yyparse().
#define cmdarg_stack (parser->cmdarg_stack) |
Definition at line 407 of file ripper.c.
Referenced by local_push_gen(), and yyparse().
#define command_start (parser->command_start) |
Definition at line 428 of file ripper.c.
Referenced by parse_ident(), parser_initialize(), parser_peek_variable_name(), parser_yylex(), and yyparse().
#define compile_error parser_compile_error |
Definition at line 863 of file ripper.c.
Referenced by assignable_gen(), block_dup_check_gen(), gettable_gen(), literal_concat0(), new_bv_gen(), new_xstring_gen(), no_blockarg(), parse_atmark(), parse_gvar(), parse_percent(), parse_qmark(), parser_here_document(), parser_heredoc_identifier(), parser_parse_string(), parser_precise_mbclen(), parser_regx_options(), parser_yyerror(), parser_yylex(), rb_backref_error_gen(), reg_compile_gen(), reg_fragment_check_gen(), reg_fragment_enc_error(), and yyparse().
#define compile_for_eval (parser->base_block != 0 && !in_main) |
Definition at line 442 of file ripper.c.
Referenced by local_push_gen(), parser_prepare(), yycompile0(), and yyparse().
Definition at line 464 of file ripper.c.
Referenced by iseq_peephole_optimize(), value_expr_gen(), and yyparse().
#define COND_LEXPOP | ( | ) | BITSTACK_LEXPOP(cond_stack) |
Definition at line 180 of file ripper.c.
Referenced by parser_yylex().
#define COND_P | ( | ) | BITSTACK_SET_P(cond_stack) |
Definition at line 181 of file ripper.c.
Referenced by parse_ident(), and parser_yylex().
#define COND_POP | ( | ) | BITSTACK_POP(cond_stack) |
#define COND_PUSH | ( | n | ) | BITSTACK_PUSH(cond_stack, (n)) |
Definition at line 178 of file ripper.c.
Referenced by parser_yylex(), and yyparse().
#define COND_SET | ( | n | ) | BITSTACK_SET(cond_stack, (n)) |
#define cond_stack (parser->cond_stack) |
#define const_decl | ( | path | ) | const_decl_gen(parser, path) |
#define const_path_field | ( | w, | |
n | |||
) | NEW_COLON2(w, n) |
Definition at line 548 of file ripper.c.
Referenced by ripper_init_eventids1(), and yyparse().
#define current_arg (parser->cur_arg) |
Definition at line 437 of file ripper.c.
Referenced by gettable_gen(), and yyparse().
#define current_enc (parser->enc) |
Definition at line 436 of file ripper.c.
Referenced by gettable_gen(), lex_getline(), parse_percent(), parse_qmark(), parser_compile_error(), parser_here_document(), parser_nextline(), parser_parse_string(), parser_precise_mbclen(), rb_parser_encoding(), and rb_reg_fragment_setenc().
#define dispatch_delayed_token | ( | t | ) | ((void)0) |
Definition at line 11947 of file ripper.c.
Referenced by parser_here_document(), parser_set_integer_literal(), parser_yylex(), and yylex().
#define dispatch_heredoc_end | ( | ) | ((void)0) |
Definition at line 13525 of file ripper.c.
Referenced by parser_here_document().
#define dispatch_scan_event | ( | t | ) | ((void)0) |
Definition at line 11946 of file ripper.c.
Referenced by parser_here_document(), parser_heredoc_identifier(), parser_string_term(), parser_yylex(), and yylex().
#define dsym_node | ( | node | ) | dsym_node_gen(parser, (node)) |
#define dvar_curr | ( | id | ) | dvar_curr_gen(parser, (id)) |
Definition at line 689 of file ripper.c.
Referenced by assignable_gen(), and shadowing_lvar_0().
#define dvar_defined | ( | id | ) | dvar_defined_gen(parser, (id), 0) |
Definition at line 686 of file ripper.c.
Referenced by assignable_gen(), gettable_gen(), and new_xstring_gen().
#define dvar_defined_get | ( | id | ) | dvar_defined_gen(parser, (id), 1) |
Definition at line 687 of file ripper.c.
Referenced by lvar_defined_gen(), and shadowing_lvar_0().
#define DVARS_INHERIT ((void*)1) |
Definition at line 208 of file ripper.c.
Referenced by dvar_defined_gen(), local_id_gen(), and local_push_gen().
#define DVARS_TOPSCOPE NULL |
Definition at line 209 of file ripper.c.
Referenced by dyna_in_block_gen(), and local_push_gen().
#define dyna_in_block | ( | ) | dyna_in_block_gen(parser) |
Definition at line 683 of file ripper.c.
Referenced by assignable_gen(), gettable_gen(), lvar_defined_gen(), new_xstring_gen(), shadowing_lvar_0(), and yyparse().
#define dyna_pop | ( | node | ) | dyna_pop_gen(parser, (node)) |
#define dyna_push | ( | ) | dyna_push_gen(parser) |
Definition at line 684 of file ripper.c.
Referenced by assignable_gen(), and new_bv_gen().
#define ESCAPE_CONTROL 1 |
Definition at line 12680 of file ripper.c.
Referenced by parser_read_escape(), and parser_tokadd_escape().
#define ESCAPE_META 2 |
Definition at line 12681 of file ripper.c.
Referenced by parser_read_escape(), and parser_tokadd_escape().
#define evstr2dstr | ( | n | ) | evstr2dstr_gen(parser,(n)) |
#define flush_string_content | ( | enc | ) | ((void)(enc)) |
Definition at line 13114 of file ripper.c.
Referenced by parser_here_document(), and parser_parse_string().
#define formal_argument | ( | id | ) | formal_argument_gen(parser, (id)) |
Definition at line 591 of file ripper.c.
Referenced by assignable_gen(), and yyparse().
#define gettable | ( | id | ) | gettable_gen(parser,(id)) |
Definition at line 528 of file ripper.c.
Referenced by new_op_assign_gen(), and yyparse().
#define has_delayed_token | ( | ) | (0) |
Definition at line 11948 of file ripper.c.
Referenced by parser_here_document(), parser_nextline(), parser_set_integer_literal(), and yylex().
Definition at line 17850 of file ripper.c.
Referenced by rb_parser_calloc(), rb_parser_malloc(), and rb_parser_realloc().
#define here_document | ( | n | ) | parser_here_document(parser,(n)) |
Definition at line 11913 of file ripper.c.
Referenced by parser_yylex().
#define heredoc_dedent | ( | str | ) | parser_heredoc_dedent(parser, (str)) |
Definition at line 589 of file ripper.c.
Referenced by parser_heredoc_dedent(), ripper_init_eventids1(), and yyparse().
#define heredoc_end (parser->heredoc_end) |
Definition at line 425 of file ripper.c.
Referenced by parser_heredoc_restore(), parser_nextline(), and ripper_init_eventids2().
#define heredoc_identifier | ( | ) | parser_heredoc_identifier(parser) |
Definition at line 11914 of file ripper.c.
Referenced by parser_yylex().
#define heredoc_indent (parser->heredoc_indent) |
Definition at line 426 of file ripper.c.
Referenced by literal_concat_gen(), parser_here_document(), parser_heredoc_dedent(), parser_heredoc_identifier(), parser_tokadd_string(), parser_update_heredoc_indent(), and yyparse().
#define heredoc_line_indent (parser->heredoc_line_indent) |
Definition at line 427 of file ripper.c.
Referenced by parser_here_document(), parser_heredoc_identifier(), parser_update_heredoc_indent(), and yyparse().
#define heredoc_restore | ( | n | ) | parser_heredoc_restore(parser,(n)) |
Definition at line 11915 of file ripper.c.
Referenced by parser_here_document().
#define ifndef_ripper | ( | x | ) | (x) |
Definition at line 810 of file ripper.c.
Referenced by local_push_gen(), and yyparse().
#define in_def (parser->in_def) |
Definition at line 412 of file ripper.c.
Referenced by assignable_gen(), const_decl_gen(), and yyparse().
#define in_defined (parser->in_defined) |
Definition at line 414 of file ripper.c.
Referenced by gettable_gen(), and yyparse().
#define in_main (parser->in_main) |
Definition at line 413 of file ripper.c.
Referenced by rb_parser_set_context(), and yyparse().
#define in_single (parser->in_single) |
Definition at line 411 of file ripper.c.
Referenced by assignable_gen(), const_decl_gen(), and yyparse().
#define intern_cstr | ( | n, | |
l, | |||
en | |||
) | rb_intern3(n,l,en) |
Definition at line 392 of file ripper.c.
Referenced by reg_named_capture_assign_iter().
#define internal_id | ( | ) | internal_id_gen(parser) |
Definition at line 676 of file ripper.c.
Referenced by new_args_tail_gen(), and yyparse().
#define IS_AFTER_OPERATOR | ( | ) | IS_lex_state(EXPR_FNAME | EXPR_DOT) |
Definition at line 14076 of file ripper.c.
Referenced by parse_percent(), and parser_yylex().
#define IS_ARG | ( | ) | IS_lex_state(EXPR_ARG_ANY) |
Definition at line 14068 of file ripper.c.
Referenced by parse_qmark(), and parser_yylex().
#define IS_BEG | ( | ) | (IS_lex_state(EXPR_BEG_ANY) || IS_lex_state_all(EXPR_ARG|EXPR_LABELED)) |
Definition at line 14070 of file ripper.c.
Referenced by parse_percent(), and parser_yylex().
#define IS_END | ( | ) | IS_lex_state(EXPR_END_ANY) |
Definition at line 14069 of file ripper.c.
Referenced by parse_qmark(), and parser_yylex().
#define is_identchar | ( | p, | |
e, | |||
enc | |||
) | (rb_enc_isalnum((unsigned char)(*(p)),(enc)) || (*(p)) == '_' || !ISASCII(*(p))) |
Definition at line 12008 of file ripper.c.
Referenced by parse_qmark().
#define IS_LABEL_POSSIBLE | ( | ) |
Definition at line 14072 of file ripper.c.
Referenced by parse_ident(), and parser_yylex().
Definition at line 14075 of file ripper.c.
Referenced by parse_ident(), and parser_yylex().
#define IS_lex_state | ( | ls | ) | IS_lex_state_for(lex_state, (ls)) |
Definition at line 160 of file ripper.c.
Referenced by parse_ident(), parse_percent(), and parser_yylex().
#define IS_lex_state_all | ( | ls | ) | IS_lex_state_all_for(lex_state, (ls)) |
Definition at line 161 of file ripper.c.
Referenced by parser_yylex().
#define IS_lex_state_all_for | ( | x, | |
ls | |||
) | (((x) & (ls)) == (ls)) |
#define IS_lex_state_for | ( | x, | |
ls | |||
) | ((x) & (ls)) |
Definition at line 158 of file ripper.c.
Referenced by parse_gvar(), and parse_ident().
Definition at line 14071 of file ripper.c.
Referenced by parse_percent(), and parser_yylex().
#define lambda_beginning_p | ( | ) | (lpar_beg && lpar_beg == paren_nest) |
Definition at line 453 of file ripper.c.
Referenced by parse_ident(), and parser_yylex().
Definition at line 12448 of file ripper.c.
Referenced by parse_qmark().
#define lex_gets (parser->lex.gets) |
Definition at line 430 of file ripper.c.
Referenced by parser_compile_error(), parser_compile_string(), and rb_parser_compile_file_path().
#define lex_gets_ptr (parser->lex.gets_ptr) |
Definition at line 429 of file ripper.c.
Referenced by lex_get_str(), and parser_compile_string().
#define lex_goto_eol | ( | parser | ) | ((parser)->lex.pcur = (parser)->lex.pend) |
Definition at line 12447 of file ripper.c.
Referenced by parser_here_document(), parser_heredoc_identifier(), parser_nextline(), parser_set_integer_literal(), and parser_yylex().
#define lex_input (parser->lex.input) |
Definition at line 419 of file ripper.c.
Referenced by lex_getline(), parser_compile_error(), parser_compile_string(), parser_mark(), parser_nextline(), and rb_parser_compile_file_path().
#define lex_lastline (parser->lex.lastline) |
Definition at line 420 of file ripper.c.
Referenced by parser_here_document(), parser_heredoc_identifier(), parser_heredoc_restore(), parser_mark(), parser_nextline(), parser_prepare(), parser_yyerror(), parser_yylex(), and yycompile0().
#define lex_nextline (parser->lex.nextline) |
Definition at line 421 of file ripper.c.
Referenced by parser_mark(), parser_nextline(), parser_yylex(), and yycompile0().
#define lex_p (parser->lex.pcur) |
Definition at line 423 of file ripper.c.
Referenced by comment_at_top(), parse_qmark(), parser_compile_error(), parser_compile_string(), parser_cr(), parser_here_document(), parser_heredoc_identifier(), parser_heredoc_restore(), parser_nextc(), parser_nextline(), parser_number_literal_suffix(), parser_peek_variable_name(), parser_prepare(), parser_pushback(), parser_read_escape(), parser_tok_hex(), parser_tokadd_codepoint(), parser_tokadd_escape(), parser_tokadd_mbchar(), parser_tokadd_string(), parser_yyerror(), parser_yylex(), rb_parser_compile_file_path(), token_info_pop_gen(), token_info_push_gen(), and yycompile0().
#define lex_pbeg (parser->lex.pbeg) |
Definition at line 422 of file ripper.c.
Referenced by comment_at_top(), parser_compile_error(), parser_compile_string(), parser_heredoc_identifier(), parser_heredoc_restore(), parser_nextline(), parser_prepare(), parser_pushback(), parser_whole_match_p(), parser_yyerror(), rb_parser_compile_file_path(), token_info_get_column(), token_info_has_nonspaces(), and yycompile0().
#define lex_pend (parser->lex.pend) |
Definition at line 424 of file ripper.c.
Referenced by parse_qmark(), parser_compile_string(), parser_here_document(), parser_heredoc_restore(), parser_nextc(), parser_nextline(), parser_peek_variable_name(), parser_precise_mbclen(), parser_prepare(), parser_set_integer_literal(), parser_tokadd_string(), parser_whole_match_p(), parser_yyerror(), parser_yylex(), rb_parser_compile_file_path(), and yycompile0().
#define lex_state (parser->lex.state) |
Definition at line 405 of file ripper.c.
Referenced by parse_ident(), parser_yylex(), and yyparse().
#define lex_strterm (parser->lex.strterm) |
Definition at line 404 of file ripper.c.
Referenced by parse_percent(), parser_here_document(), parser_heredoc_identifier(), parser_heredoc_restore(), parser_mark(), parser_yylex(), yycompile0(), and yyparse().
#define list_append | ( | l, | |
i | |||
) | list_append_gen(parser,(l),(i)) |
Definition at line 492 of file ripper.c.
Referenced by arg_append_gen(), evstr2dstr_gen(), literal_concat_gen(), and yyparse().
#define literal_concat | ( | h, | |
t | |||
) | literal_concat_gen(parser,(h),(t)) |
#define local_id | ( | id | ) | local_id_gen(parser, (id)) |
Definition at line 674 of file ripper.c.
Referenced by assignable_gen(), gettable_gen(), lvar_defined_gen(), new_xstring_gen(), shadowing_lvar_0(), and yyparse().
#define local_pop | ( | ) | local_pop_gen(parser) |
#define local_push | ( | top | ) | local_push_gen(parser,(top)) |
#define local_tbl | ( | ) | local_tbl_gen(parser) |
#define local_var | ( | id | ) | local_var_gen(parser, (id)) |
Definition at line 670 of file ripper.c.
Referenced by assignable_gen().
#define logop | ( | type, | |
node1, | |||
node2 | |||
) | logop_gen(parser, (type), (node1), (node2)) |
#define lpar_beg (parser->lex.lpar_beg) |
Definition at line 409 of file ripper.c.
Referenced by parse_ident(), parser_yylex(), and yyparse().
#define lvar_defined | ( | id | ) | lvar_defined_gen(parser, (id)) |
Definition at line 692 of file ripper.c.
Referenced by parse_ident().
Definition at line 16195 of file ripper.c.
Referenced by dvar_defined_gen(), local_id_gen(), shadowing_lvar_0(), and warn_unused_var().
#define lvtbl (parser->lvtbl) |
Definition at line 431 of file ripper.c.
Referenced by arg_var_gen(), dvar_curr_gen(), dvar_defined_gen(), dyna_in_block_gen(), dyna_pop_1(), dyna_pop_gen(), dyna_pop_vtable(), dyna_push_gen(), internal_id_gen(), local_id_gen(), local_pop_gen(), local_push_gen(), local_tbl_gen(), local_var_gen(), match_op_gen(), new_args_tail_gen(), parser_free(), parser_memsize(), and shadowing_lvar_0().
#define malloc YYMALLOC |
Definition at line 116 of file ripper.c.
Referenced by aligned_malloc(), cmdglob(), ffi_prep_incoming_args_VFP(), gc_info_decode(), gc_prof_setup_new_record(), heap_pages_expand_sorted_to(), Init_heap(), insert(), main(), nkf_xmalloc(), objspace_xmalloc0(), onig_new_with_source(), open_ifs_socket(), pruby_var_to_cstr(), rb_gc_unprotect_logging(), rb_w32_conv_from_wstr(), rb_w32_get_environ(), rb_w32_getcwd(), rb_w32_mbstr_to_wstr(), rb_w32_wstr_to_mbstr(), readline_attempted_completion_function(), ruby_mimmalloc(), ruby_setenv(), sdbm_open(), sdbm_prep(), sip_hash_final(), sip_hash_new(), stack_chunk_alloc(), th_init(), w32_cmdvector(), w32_wopendir(), yaml_malloc(), and yaml_realloc().
#define match_op | ( | node1, | |
node2 | |||
) | match_op_gen(parser, (node1), (node2)) |
#define mixed_error | ( | enc1, | |
enc2 | |||
) |
Referenced by parser_tokadd_string().
#define mixed_escape | ( | beg, | |
enc1, | |||
enc2 | |||
) |
Referenced by parser_tokadd_string().
Definition at line 711 of file ripper.c.
Referenced by parser_parse_string().
#define nd_term | ( | node | ) | SIGN_EXTEND((node)->u2.id, CHAR_BIT*2) |
Definition at line 709 of file ripper.c.
Referenced by parser_parse_string().
#define new_args | ( | f, | |
o, | |||
r, | |||
p, | |||
t | |||
) | new_args_gen(parser, (f),(o),(r),(p),(t)) |
Definition at line 513 of file ripper.c.
Referenced by check_funcall_missing(), and yyparse().
#define new_args_tail | ( | k, | |
kr, | |||
b | |||
) | new_args_tail_gen(parser, (k),(kr),(b)) |
#define new_attr_op_assign | ( | lhs, | |
type, | |||
attr, | |||
op, | |||
rhs | |||
) | new_attr_op_assign_gen(parser, (lhs), (type), (attr), (op), (rhs)) |
#define new_brace_body | ( | param, | |
stmt | |||
) | NEW_ITER(param, stmt) |
#define new_bv | ( | id | ) | new_bv_gen(parser, (id)) |
#define new_const_op_assign | ( | lhs, | |
op, | |||
rhs | |||
) | new_const_op_assign_gen(parser, (lhs), (op), (rhs)) |
#define new_defined | ( | expr | ) | NEW_DEFINED(remove_begin_all(expr)) |
#define new_do_body | ( | param, | |
stmt | |||
) | NEW_ITER(param, stmt) |
#define new_evstr | ( | n | ) | new_evstr_gen(parser,(n)) |
#define new_hash | ( | hash | ) | new_hash_gen(parser, (hash)) |
#define new_if | ( | cc, | |
left, | |||
right | |||
) | new_if_gen(parser, (cc), (left), (right)) |
#define new_kw_arg | ( | k | ) | ((k) ? NEW_KW_ARG(0, (k)) : 0) |
#define new_op_assign | ( | lhs, | |
op, | |||
rhs | |||
) | new_op_assign_gen(parser, (lhs), (op), (rhs)) |
#define NEW_QCALL | ( | q, | |
r, | |||
m, | |||
a | |||
) | NEW_NODE(NODE_CALL_Q(q),r,m,a) |
#define new_regexp | ( | node, | |
opt | |||
) | new_regexp_gen(parser, node, opt) |
#define NEW_STRTERM | ( | func, | |
term, | |||
paren | |||
) | rb_node_newnode(NODE_STRTERM, (func), (term) | ((paren) << (CHAR_BIT * 2)), 0) |
Definition at line 13087 of file ripper.c.
Referenced by parse_percent(), parser_here_document(), and parser_yylex().
#define new_unless | ( | cc, | |
left, | |||
right | |||
) | new_if_gen(parser, (cc), (right), (left)) |
#define new_xstring | ( | node | ) | new_xstring_gen(parser, node) |
#define new_yield | ( | node | ) | new_yield_gen(parser, (node)) |
#define NEWHEAP | ( | ) | rb_node_newnode(NODE_ALLOCA, 0, (VALUE)parser->heap, 0) |
Definition at line 17851 of file ripper.c.
Referenced by rb_parser_calloc(), rb_parser_malloc(), and rb_parser_realloc().
#define newtok | ( | ) | parser_newtok(parser) |
Definition at line 11903 of file ripper.c.
Referenced by parse_atmark(), parse_gvar(), parse_numeric(), parse_qmark(), parser_here_document(), parser_heredoc_identifier(), parser_parse_string(), parser_regx_options(), and parser_yylex().
#define nextc | ( | ) | parser_nextc(parser) |
Definition at line 11901 of file ripper.c.
Referenced by parse_atmark(), parse_gvar(), parse_ident(), parse_numeric(), parse_percent(), parse_qmark(), parser_here_document(), parser_heredoc_identifier(), parser_number_literal_suffix(), parser_parse_string(), parser_prepare(), parser_read_escape(), parser_regx_options(), parser_tokadd_escape(), parser_tokadd_string(), parser_tokadd_utf8(), parser_yylex(), and tokadd_ident().
#define no_digits | ( | ) | do {yyerror("numeric literal without digits"); return 0;} while (0) |
Referenced by parse_numeric(), and ruby_dtoa().
#define node_assign | ( | node1, | |
node2 | |||
) | node_assign_gen(parser, (node1), (node2)) |
Definition at line 540 of file ripper.c.
Referenced by reg_named_capture_assign_iter(), and yyparse().
#define NODE_CALL_Q | ( | q | ) | (CALL_Q_P(q) ? NODE_QCALL : NODE_CALL) |
#define NODE_HEREDOC NODE_ARRAY /* 1, 3 to gc */ |
Definition at line 703 of file ripper.c.
Referenced by parser_heredoc_identifier(), and parser_yylex().
#define NODE_STRTERM NODE_ZARRAY /* nothing to gc */ |
#define NUM_SUFFIX_ALL 3 |
Definition at line 13448 of file ripper.c.
Referenced by parse_numeric().
#define NUM_SUFFIX_I (1<<1) |
Definition at line 13447 of file ripper.c.
Referenced by parse_numeric(), parser_number_literal_suffix(), and parser_set_number_literal().
#define NUM_SUFFIX_R (1<<0) |
Definition at line 13446 of file ripper.c.
Referenced by parse_numeric(), parser_number_literal_suffix(), and parser_set_integer_literal().
#define number_literal_suffix | ( | f | ) | parser_number_literal_suffix(parser, (f)) |
Definition at line 11917 of file ripper.c.
Referenced by parse_numeric().
#define paren_nest (parser->lex.paren_nest) |
Definition at line 408 of file ripper.c.
Referenced by parse_ident(), parser_yylex(), and yyparse().
#define parse_string | ( | n | ) | parser_parse_string(parser,(n)) |
Definition at line 11911 of file ripper.c.
Referenced by parser_yylex().
#define PARSER_ARG parser, |
Definition at line 864 of file ripper.c.
Referenced by assignable_gen(), block_dup_check_gen(), gettable_gen(), literal_concat0(), new_bv_gen(), new_xstring_gen(), no_blockarg(), parse_atmark(), parse_gvar(), parse_percent(), parse_qmark(), parser_here_document(), parser_heredoc_identifier(), parser_parse_string(), parser_precise_mbclen(), parser_regx_options(), parser_yyerror(), parser_yylex(), rb_backref_error_gen(), reg_compile_gen(), reg_fragment_check_gen(), reg_fragment_enc_error(), and yyparse().
#define parser_encoding_name | ( | ) | (current_enc->name) |
Definition at line 12006 of file ripper.c.
Referenced by parser_precise_mbclen().
#define parser_is_identchar | ( | ) | (!parser->eofp && is_identchar((lex_p-1),lex_pend,current_enc)) |
Definition at line 12009 of file ripper.c.
Referenced by parse_atmark(), parse_gvar(), parse_ident(), parser_heredoc_identifier(), parser_number_literal_suffix(), parser_yylex(), and tokadd_ident().
Definition at line 12011 of file ripper.c.
Referenced by parse_percent(), parse_qmark(), and parser_tokadd_string().
#define parser_mbclen | ( | ) | mbclen((lex_p-1),lex_pend,current_enc) |
#define parser_warn | ( | node, | |
mesg | |||
) | parser_warn(parser, (node), (mesg)) |
Definition at line 15561 of file ripper.c.
Referenced by assign_in_cond(), cond0(), and warn_unless_e_option().
#define parser_warning | ( | node, | |
mesg | |||
) | parser_warning(parser, (node), (mesg)) |
Definition at line 15554 of file ripper.c.
Referenced by block_append_gen(), cond0(), and warning_unless_e_option().
#define peek | ( | c | ) | peek_n((c), 0) |
Definition at line 12449 of file ripper.c.
Referenced by parse_ident(), parse_qmark(), parser_cr(), parser_prepare(), parser_read_escape(), parser_tokadd_utf8(), and parser_yylex().
Definition at line 12450 of file ripper.c.
Referenced by parse_ident().
Definition at line 12452 of file ripper.c.
Referenced by parser_number_literal_suffix().
Definition at line 211 of file ripper.c.
Referenced by dvar_defined_gen(), dyna_in_block_gen(), local_id_gen(), vtable_add(), vtable_free(), vtable_included(), and vtable_size().
#define PRIsWARN PRIsVALUE |
Definition at line 855 of file ripper.c.
Referenced by gettable_gen(), shadowing_lvar_0(), and warn_unused_var().
#define pushback | ( | c | ) | parser_pushback(parser, (c)) |
Definition at line 11902 of file ripper.c.
Referenced by parse_atmark(), parse_gvar(), parse_ident(), parse_numeric(), parse_percent(), parse_qmark(), parser_here_document(), parser_heredoc_identifier(), parser_number_literal_suffix(), parser_parse_string(), parser_prepare(), parser_read_escape(), parser_regx_options(), parser_tokadd_escape(), parser_tokadd_string(), parser_tokadd_utf8(), parser_yylex(), and tokadd_ident().
#define rb_backref_error | ( | n | ) | rb_backref_error_gen(parser,(n)) |
#define rb_node_newnode | ( | type, | |
a1, | |||
a2, | |||
a3 | |||
) | node_newnode(parser, (type), (a1), (a2), (a3)) |
Definition at line 461 of file ripper.c.
Referenced by node_newnode(), and parser_heredoc_identifier().
Definition at line 816 of file ripper.c.
Referenced by cond0(), parser_cr(), parser_heredoc_identifier(), and yyparse().
#define rb_warn0L | ( | l, | |
fmt | |||
) | WARN_CALL(WARN_ARGS_L(l, fmt, 1)) |
Definition at line 817 of file ripper.c.
Referenced by gettable_gen(), parse_numvar(), and parse_qmark().
#define rb_warn1L | ( | l, | |
fmt, | |||
a | |||
) | WARN_CALL(WARN_ARGS_L(l, fmt, 2), (a)) |
Definition at line 827 of file ripper.c.
Referenced by void_expr_gen(), and warn_unused_var().
Definition at line 818 of file ripper.c.
Referenced by parse_qmark().
#define rb_warn2L | ( | l, | |
fmt, | |||
a, | |||
b | |||
) | WARN_CALL(WARN_ARGS_L(l, fmt, 3), (a), (b)) |
#define rb_warn3L | ( | l, | |
fmt, | |||
a, | |||
b, | |||
c | |||
) | WARN_CALL(WARN_ARGS_L(l, fmt, 4), (a), (b), (c)) |
Definition at line 829 of file ripper.c.
Referenced by token_info_pop_gen().
#define rb_warn4L | ( | l, | |
fmt, | |||
a, | |||
b, | |||
c, | |||
d | |||
) | WARN_CALL(WARN_ARGS_L(l, fmt, 5), (a), (b), (c), (d)) |
#define rb_warning0 | ( | fmt | ) | WARNING_CALL(WARNING_ARGS(fmt, 1)) |
Definition at line 821 of file ripper.c.
Referenced by parser_yylex(), and value_expr_gen().
#define rb_warning0L | ( | l, | |
fmt | |||
) | WARNING_CALL(WARNING_ARGS_L(l, fmt, 1)) |
#define rb_warning1 | ( | fmt, | |
a | |||
) | WARNING_CALL(WARNING_ARGS(fmt, 2), (a)) |
Definition at line 822 of file ripper.c.
Referenced by arg_ambiguous_gen(), gettable_gen(), parse_numeric(), parser_set_compile_option_flag(), and shadowing_lvar_0().
#define rb_warning1L | ( | l, | |
fmt, | |||
a | |||
) | WARNING_CALL(WARNING_ARGS_L(l, fmt, 2), (a)) |
#define rb_warning2 | ( | fmt, | |
a, | |||
b | |||
) | WARNING_CALL(WARNING_ARGS(fmt, 3), (a), (b)) |
#define rb_warning2L | ( | l, | |
fmt, | |||
a, | |||
b | |||
) | WARNING_CALL(WARNING_ARGS_L(l, fmt, 3), (a), (b)) |
#define rb_warning3 | ( | fmt, | |
a, | |||
b, | |||
c | |||
) | WARNING_CALL(WARNING_ARGS(fmt, 4), (a), (b), (c)) |
#define rb_warning3L | ( | l, | |
fmt, | |||
a, | |||
b, | |||
c | |||
) | WARNING_CALL(WARNING_ARGS_L(l, fmt, 4), (a), (b), (c)) |
#define rb_warning4 | ( | fmt, | |
a, | |||
b, | |||
c, | |||
d | |||
) | WARNING_CALL(WARNING_ARGS(fmt, 5), (a), (b), (c), (d)) |
#define rb_warning4L | ( | l, | |
fmt, | |||
a, | |||
b, | |||
c, | |||
d | |||
) | WARNING_CALL(WARNING_ARGS_L(l, fmt, 5), (a), (b), (c), (d)) |
#define RE_OPTION_ENCODING | ( | e | ) | (((e)&0xff)<<RE_OPTION_ENCODING_SHIFT) |
Definition at line 696 of file ripper.c.
Referenced by parser_regx_options().
#define RE_OPTION_ENCODING_IDX | ( | o | ) | (((o)>>RE_OPTION_ENCODING_SHIFT)&0xff) |
Definition at line 697 of file ripper.c.
Referenced by rb_reg_fragment_setenc().
#define RE_OPTION_ENCODING_NONE | ( | o | ) | ((o)&RE_OPTION_ARG_ENCODING_NONE) |
Definition at line 698 of file ripper.c.
Referenced by rb_reg_fragment_setenc().
#define RE_OPTION_MASK 0xff |
Definition at line 699 of file ripper.c.
Referenced by new_regexp_gen(), and rb_parser_reg_compile().
#define RE_OPTION_ONCE (1<<16) |
Definition at line 694 of file ripper.c.
Referenced by new_regexp_gen(), and parser_regx_options().
#define read_escape | ( | flags, | |
e | |||
) | parser_read_escape(parser, (flags), (e)) |
Definition at line 11907 of file ripper.c.
Referenced by parse_qmark(), parser_read_escape(), and parser_tokadd_string().
#define realloc YYREALLOC |
Definition at line 117 of file ripper.c.
Referenced by base64_conv(), code_page_i(), enc_table_expand(), gc_prof_setup_new_record(), gc_profile_clear(), heap_pages_expand_sorted_to(), nkf_xrealloc(), objspace_xrealloc(), w32_wopendir(), and yaml_realloc().
#define reduce_nodes | ( | n | ) | reduce_nodes_gen(parser,(n)) |
#define reg_compile | ( | str, | |
options | |||
) | reg_compile_gen(parser, (str), (options)) |
Definition at line 580 of file ripper.c.
Referenced by new_regexp_gen().
#define reg_fragment_check | ( | str, | |
options | |||
) | reg_fragment_check_gen(parser, (str), (options)) |
Definition at line 584 of file ripper.c.
Referenced by new_regexp_gen().
#define reg_fragment_setenc | ( | str, | |
options | |||
) | reg_fragment_setenc_gen(parser, (str), (options)) |
Definition at line 582 of file ripper.c.
Referenced by parser_reg_compile(), and reg_fragment_check_gen().
#define reg_named_capture_assign | ( | regexp | ) | reg_named_capture_assign_gen(parser,(regexp)) |
#define regx_options | ( | ) | parser_regx_options(parser) |
Definition at line 11909 of file ripper.c.
Referenced by parser_string_term().
#define ret_args | ( | node | ) | ret_args_gen(parser, (node)) |
#define ripper_flush | ( | p | ) | (void)(p) |
Definition at line 11945 of file ripper.c.
Referenced by parser_heredoc_identifier(), parser_heredoc_restore(), parser_nextline(), and parser_set_integer_literal().
Definition at line 805 of file ripper.c.
Referenced by parser_compile_error(), and yyparse().
#define ruby__end__seen (parser->ruby__end__seen) |
Definition at line 432 of file ripper.c.
Referenced by parser_yylex(), and rb_parser_end_seen_p().
#define ruby_coverage (parser->coverage) |
Definition at line 446 of file ripper.c.
Referenced by lex_getline(), and yycompile0().
#define ruby_debug_lines (parser->debug_lines) |
Definition at line 445 of file ripper.c.
Referenced by lex_getline(), parser_mark(), parser_set_encode(), and yycompile0().
#define RUBY_DTRACE_PARSE_HOOK | ( | name | ) |
Referenced by yycompile0().
#define ruby_eval_tree (parser->eval_tree) |
Definition at line 443 of file ripper.c.
Referenced by parser_mark(), yycompile0(), and yyparse().
#define ruby_eval_tree_begin (parser->eval_tree_begin) |
Definition at line 444 of file ripper.c.
Referenced by parser_mark(), yycompile0(), and yyparse().
#define ruby_sourcefile (parser->ruby_sourcefile) |
Definition at line 434 of file ripper.c.
Referenced by e_option_supplied(), parser_compile_error(), parser_get_bool(), parser_warn(), parser_warning(), rb_parser_reg_compile(), remove_duplicate_keys(), and yycompile().
#define ruby_sourcefile_string (parser->ruby_sourcefile_string) |
Definition at line 435 of file ripper.c.
Referenced by gettable_gen(), parser_compile_error(), parser_initialize(), parser_mark(), parser_set_encode(), yycompile(), and yycompile0().
#define ruby_sourceline (parser->ruby_sourceline) |
Definition at line 433 of file ripper.c.
Referenced by local_var_gen(), new_args_gen(), new_args_tail_gen(), node_newnode(), parser_compile_error(), parser_get_bool(), parser_heredoc_identifier(), parser_heredoc_restore(), parser_newtok(), parser_nextline(), parser_parse_string(), parser_set_encode(), parser_yylex(), rb_parser_reg_compile(), shadowing_lvar_0(), token_info_pop_gen(), token_info_push_gen(), yycompile(), yycompile0(), and yyparse().
#define set_integer_literal | ( | v, | |
f | |||
) | parser_set_integer_literal(parser, (v), (f)) |
Definition at line 11919 of file ripper.c.
Referenced by parse_numeric().
#define SET_LEX_STATE | ( | ls | ) |
Definition at line 163 of file ripper.c.
Referenced by parse_atmark(), parse_gvar(), parse_ident(), parse_numeric(), parse_percent(), parse_qmark(), parser_set_number_literal(), parser_yylex(), and yyparse().
#define set_number_literal | ( | v, | |
t, | |||
f | |||
) | parser_set_number_literal(parser, (v), (t), (f)) |
Definition at line 11918 of file ripper.c.
Referenced by parse_numeric(), and parser_set_integer_literal().
#define set_yylval_id | ( | x | ) | (yylval.id = (x)) |
Definition at line 11924 of file ripper.c.
Referenced by parse_percent(), and parser_yylex().
#define set_yylval_literal | ( | x | ) | (yylval.node = NEW_LIT(x)) |
Definition at line 11926 of file ripper.c.
Referenced by parser_set_number_literal().
#define set_yylval_name | ( | x | ) | (yylval.id = (x)) |
Definition at line 11925 of file ripper.c.
Referenced by parse_gvar(), parse_ident(), and tokenize_ident().
#define set_yylval_node | ( | x | ) | (yylval.node = (x)) |
Definition at line 11927 of file ripper.c.
Referenced by parse_gvar().
#define set_yylval_num | ( | x | ) | (yylval.num = (x)) |
Definition at line 11923 of file ripper.c.
Referenced by parser_string_term().
#define set_yylval_str | ( | x | ) | (yylval.node = NEW_STR(x)) |
Definition at line 11922 of file ripper.c.
Referenced by parse_qmark(), parser_here_document(), and parser_parse_string().
#define shadowing_lvar | ( | name | ) | shadowing_lvar_gen(parser, (name)) |
Definition at line 661 of file ripper.c.
Referenced by formal_argument_gen(), and yyparse().
#define SHOW_BITSTACK | ( | stack, | |
name | |||
) | (yydebug ? show_bitstack(stack, name, __LINE__) : (void)0) |
#define SIGN_EXTEND | ( | x, | |
n | |||
) | (((1<<(n)-1)^((x)&~(~0<<(n))))-(1<<(n)-1)) |
#define SPECIAL_PUNCT | ( | idx | ) |
#define str_copy | ( | _s, | |
_p, | |||
_n | |||
) |
Referenced by parser_magic_comment().
#define STR_FUNC_ESCAPE 0x01 |
Definition at line 12409 of file ripper.c.
Referenced by parser_tokadd_string().
#define STR_FUNC_EXPAND 0x02 |
Definition at line 12410 of file ripper.c.
Referenced by parser_here_document(), parser_parse_string(), and parser_tokadd_string().
#define STR_FUNC_INDENT 0x20 |
Definition at line 12414 of file ripper.c.
Referenced by parser_here_document(), and parser_heredoc_identifier().
#define STR_FUNC_LABEL 0x40 |
Definition at line 12415 of file ripper.c.
Referenced by parser_yylex().
#define STR_FUNC_QWORDS 0x08 |
Definition at line 12412 of file ripper.c.
Referenced by parser_parse_string(), and parser_tokadd_string().
#define STR_FUNC_REGEXP 0x04 |
Definition at line 12411 of file ripper.c.
Referenced by parser_here_document(), parser_parse_string(), parser_str_new(), parser_string_term(), and parser_tokadd_string().
#define STR_FUNC_SYMBOL 0x10 |
Definition at line 12413 of file ripper.c.
Referenced by parser_tokadd_string().
#define STR_NEW | ( | p, | |
n | |||
) | rb_enc_str_new((p),(n),current_enc) |
Definition at line 395 of file ripper.c.
Referenced by parser_here_document(), parser_heredoc_identifier(), and parser_set_integer_literal().
#define STR_NEW0 | ( | ) | rb_enc_str_new(0,0,current_enc) |
Definition at line 396 of file ripper.c.
Referenced by evstr2dstr_gen(), literal_concat_gen(), new_regexp_gen(), new_xstring_gen(), yycompile0(), and yyparse().
#define STR_NEW2 | ( | p | ) | rb_enc_str_new((p),strlen(p),current_enc) |
Definition at line 397 of file ripper.c.
Referenced by parser_compile_error(), and parser_yyerror().
#define STR_NEW3 | ( | p, | |
n, | |||
e, | |||
func | |||
) | parser_str_new((p),(n),(e),(func),current_enc) |
Definition at line 398 of file ripper.c.
Referenced by parse_qmark(), parser_here_document(), and parser_parse_string().
#define STR_TERM_END -1 |
Definition at line 12416 of file ripper.c.
Referenced by parser_here_document(), and parser_parse_string().
#define subnodes | ( | n1, | |
n2 | |||
) |
Referenced by reduce_nodes_gen().
#define TAB_WIDTH 8 |
Definition at line 99 of file ripper.c.
Referenced by dedent_string(), parser_update_heredoc_indent(), and token_info_get_column().
#define tok | ( | ) | tokenbuf |
Definition at line 12543 of file ripper.c.
Referenced by fetch_escaped_value(), lexer_i(), parse_ident(), parse_numeric(), parse_numvar(), parse_qmark(), parse_regexp(), parser_here_document(), parser_heredoc_identifier(), parser_parse_string(), and parser_regx_options().
#define tok_hex | ( | numlen | ) | parser_tok_hex(parser, (numlen)) |
Definition at line 11906 of file ripper.c.
Referenced by parser_read_escape(), and parser_tokadd_escape().
#define TOK_INTERN | ( | ) | intern_cstr(tok(), toklen(), current_enc) |
Definition at line 399 of file ripper.c.
Referenced by parse_gvar(), parse_ident(), and tokenize_ident().
#define tokadd | ( | c | ) | parser_tokadd(parser, (c)) |
Definition at line 11905 of file ripper.c.
Referenced by parse_atmark(), parse_gvar(), parse_ident(), parse_numeric(), parse_qmark(), parser_here_document(), parser_heredoc_identifier(), parser_parse_string(), parser_regx_options(), parser_tokadd_codepoint(), parser_tokadd_escape(), parser_tokadd_mbchar(), parser_tokadd_string(), and parser_tokadd_utf8().
#define tokadd_escape | ( | e | ) | parser_tokadd_escape(parser, (e)) |
Definition at line 11908 of file ripper.c.
Referenced by parser_tokadd_string().
#define tokadd_mbchar | ( | c | ) | parser_tokadd_mbchar(parser, (c)) |
Definition at line 12908 of file ripper.c.
Referenced by parse_gvar(), parse_ident(), parse_qmark(), parser_heredoc_identifier(), parser_tokadd_string(), and tokadd_ident().
#define tokadd_string | ( | f, | |
t, | |||
p, | |||
n, | |||
e | |||
) | parser_tokadd_string(parser,(f),(t),(p),(n),(e)) |
Definition at line 11910 of file ripper.c.
Referenced by parser_here_document(), and parser_parse_string().
#define tokaddmbc | ( | c, | |
enc | |||
) | parser_tokaddmbc(parser, (c), (enc)) |
Definition at line 11912 of file ripper.c.
Referenced by parser_tokadd_codepoint().
Definition at line 12599 of file ripper.c.
Referenced by parser_tokadd_codepoint(), parser_tokadd_escape(), and parser_tokadd_mbchar().
#define token_info_pop | ( | token | ) | token_info_pop_gen(parser, (token), rb_strlen_lit(token)) |
#define token_info_push | ( | token | ) | token_info_push_gen(parser, (token), rb_strlen_lit(token)) |
Definition at line 878 of file ripper.c.
Referenced by parser_yylex(), and yyparse().
#define tokenbuf (parser->tokenbuf) |
Definition at line 415 of file ripper.c.
Referenced by parser_free(), parser_heredoc_identifier(), parser_newtok(), parser_tokadd(), and parser_tokspace().
Definition at line 12542 of file ripper.c.
Referenced by parse_gvar(), parse_ident(), parse_numeric(), parse_qmark(), parser_heredoc_identifier(), parser_parse_string(), and parser_regx_options().
#define tokidx (parser->tokidx) |
Definition at line 416 of file ripper.c.
Referenced by parser_heredoc_identifier(), parser_newtok(), parser_tokadd(), and parser_tokspace().
Definition at line 12545 of file ripper.c.
Referenced by parse_ident().
#define toklen | ( | ) | tokidx |
Definition at line 12544 of file ripper.c.
Referenced by parse_ident(), parse_numeric(), parse_numvar(), parse_qmark(), parser_here_document(), parser_heredoc_identifier(), parser_parse_string(), and parser_regx_options().
#define tokline (parser->tokline) |
Definition at line 418 of file ripper.c.
Referenced by gettable_gen(), parser_newtok(), and yyparse().
#define toksiz (parser->toksiz) |
Definition at line 417 of file ripper.c.
Referenced by parser_memsize(), parser_newtok(), parser_tokadd(), and parser_tokspace().
#define tokspace | ( | n | ) | parser_tokspace(parser, (n)) |
Definition at line 11904 of file ripper.c.
Referenced by parser_tokaddmbc().
#define top_const_field | ( | n | ) | NEW_COLON3(n) |
Definition at line 549 of file ripper.c.
Referenced by ripper_init_eventids1(), and yyparse().
#define value_expr | ( | node | ) | value_expr_gen(parser, (node) = remove_begin(node)) |
Definition at line 479 of file ripper.c.
Referenced by call_bin_op_gen(), call_uni_op_gen(), logop_gen(), match_op_gen(), range_op(), value_expr_gen(), and yyparse().
#define var_field | ( | n | ) | (n) |
Definition at line 553 of file ripper.c.
Referenced by ripper_init_eventids1(), and yyparse().
#define void_expr | ( | node | ) | void_expr0((node) = remove_begin(node)) |
#define void_expr0 | ( | node | ) | void_expr_gen(parser, (node)) |
Definition at line 480 of file ripper.c.
Referenced by void_stmts_gen().
#define void_stmts | ( | node | ) | void_stmts_gen(parser, (node)) |
#define VTBL_DEBUG 0 |
Definition at line 224 of file ripper.c.
Referenced by vtable_add(), vtable_alloc(), and vtable_free().
#define WARN_ARGS | ( | fmt, | |
n | |||
) | WARN_ARGS_L(ruby_sourceline,fmt,n) |
#define WARN_ARGS_L | ( | l, | |
fmt, | |||
n | |||
) | ruby_sourcefile, (l), (fmt) |
#define warn_balanced | ( | op, | |
syn | |||
) |
Definition at line 14085 of file ripper.c.
Referenced by parse_percent(), and parser_yylex().
#define WARN_CALL rb_compile_warn |
#define WARN_I | ( | i | ) | i |
Definition at line 854 of file ripper.c.
Referenced by arg_ambiguous_gen(), parse_qmark(), and token_info_pop_gen().
#define WARN_S | ( | s | ) | s |
Definition at line 853 of file ripper.c.
Referenced by parse_numeric(), parse_numvar(), parser_set_compile_option_flag(), token_info_pop_gen(), and void_expr_gen().
#define WARN_S_L | ( | s, | |
l | |||
) | s |
Definition at line 852 of file ripper.c.
Referenced by parse_qmark().
#define WARNING_ARGS_L | ( | l, | |
fmt, | |||
n | |||
) | WARN_ARGS_L(l,fmt,n) |
#define WARNING_CALL rb_compile_warning |
Definition at line 12540 of file ripper.c.
Referenced by parser_here_document(), and parser_yylex().
#define whole_match_p | ( | e, | |
l, | |||
i | |||
) | parser_whole_match_p(parser,(e),(l),(i)) |
Definition at line 11916 of file ripper.c.
Referenced by parser_here_document(), and parser_yylex().
#define YY_ | ( | msgid | ) | msgid |
Definition at line 1117 of file ripper.c.
Referenced by yyparse(), and yysyntax_error().
#define YY_REDUCE_PRINT | ( | Rule | ) |
#define YY_STACK_PRINT | ( | Bottom, | |
Top | |||
) |
#define YY_SYMBOL_PRINT | ( | Title, | |
Type, | |||
Value, | |||
Location | |||
) |
#define YYACCEPT goto yyacceptlab |
#define YYBACKUP | ( | Token, | |
Value | |||
) |
#define YYCALLOC | ( | nelem, | |
size | |||
) | rb_parser_calloc(parser, (nelem), (size)) |
Referenced by yysyntax_error().
#define YYCOPY | ( | To, | |
From, | |||
Count | |||
) |
#define yydebug (parser->yydebug) |
Definition at line 438 of file ripper.c.
Referenced by proc_options(), and process_options().
#define YYDPRINTF | ( | Args | ) |
#define YYEMPTY (-2) |
Definition at line 4696 of file ripper.c.
Referenced by yyparse(), and yysyntax_error().
#define yyerrok (yyerrstatus = 0) |
#define yyerror | ( | msg | ) | parser_yyerror(parser, (msg)) |
Definition at line 402 of file ripper.c.
Referenced by assignable_gen(), const_decl_gen(), formal_argument_gen(), parse_numeric(), parse_percent(), parser_number_literal_suffix(), parser_read_escape(), parser_tok_hex(), parser_tokadd_codepoint(), parser_tokadd_escape(), parser_tokadd_utf8(), parser_yylex(), shadowing_lvar_0(), value_expr_gen(), and yyparse().
#define YYFPRINTF rb_parser_printf |
Definition at line 105 of file ripper.c.
Referenced by yy_reduce_print(), yy_stack_print(), and yy_symbol_print().
#define YYFREE | ( | ptr | ) | rb_parser_free(parser, (ptr)) |
#define YYLAST 11794 |
Definition at line 1279 of file ripper.c.
Referenced by yyparse(), and yysyntax_error().
#define YYLLOC_DEFAULT | ( | Current, | |
Rhs, | |||
N | |||
) |
#define yylval (*parser->lval) |
Definition at line 11892 of file ripper.c.
Referenced by parser_here_document(), and yyparse().
#define YYMALLOC | ( | size | ) | rb_parser_malloc(parser, (size)) |
#define YYNTOKENS 146 |
Definition at line 1282 of file ripper.c.
Referenced by yy_symbol_print(), yy_symbol_value_print(), yyparse(), and yysyntax_error().
#define yypact_value_is_default | ( | yystate | ) | ((yystate) == (-876)) |
Definition at line 3389 of file ripper.c.
Referenced by yyparse(), and yysyntax_error().
#define yyparse ruby_yyparse |
Definition at line 458 of file ripper.c.
Referenced by yycompile0(), and yydestruct().
#define YYREALLOC | ( | ptr, | |
size | |||
) | rb_parser_realloc(parser, (ptr), (size)) |
#define YYSIZE_T unsigned int |
Definition at line 1103 of file ripper.c.
Referenced by yyparse(), yystpcpy(), yystrlen(), yysyntax_error(), and yytnamerr().
#define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM |
Definition at line 1188 of file ripper.c.
Referenced by yysyntax_error().
#define YYSTACK_BYTES | ( | N | ) |
#define YYSTACK_RELOCATE | ( | Stack_alloc, | |
Stack | |||
) |
Definition at line 1243 of file ripper.c.
Referenced by yyparse().
#define YYSYNTAX_ERROR |
Referenced by yyparse().
#define yytable_value_is_error | ( | yytable_value | ) | ((yytable_value) == (-643)) |
Definition at line 3392 of file ripper.c.
Referenced by yyparse(), and yysyntax_error().
#define YYTERROR 1 |
Definition at line 4738 of file ripper.c.
Referenced by yyparse(), and yysyntax_error().
#define YYTRANSLATE | ( | YYX | ) | ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) |
#define YYUSE | ( | e | ) | ((void) (e)) |
Definition at line 1123 of file ripper.c.
Referenced by yy_symbol_value_print(), and yydestruct().
typedef long(* rb_magic_comment_length_t) (struct parser_params *parser, const char *name, long len) |
typedef void(* rb_magic_comment_setter_t) (struct parser_params *parser, const char *name, const char *val) |
typedef VALUE stack_type |
typedef struct token_info token_info |
typedef short int yytype_int16 |
typedef short int yytype_int8 |
typedef unsigned short int yytype_uint16 |
typedef unsigned char yytype_uint8 |
enum lex_state_bits |
enum lex_state_e |
enum string_type |
|
static |
Definition at line 16051 of file ripper.c.
References buf, EXPR_MAX_STATE, rb_str_cat(), and rb_str_cat_cstr().
Referenced by trace_lex_state().
Definition at line 16979 of file ripper.c.
References list_concat(), result, and ST_CONTINUE.
Referenced by remove_duplicate_keys().
|
static |
Definition at line 13666 of file ripper.c.
References arg_ambiguous, rb_usascii_str_new(), rb_warning1, and WARN_I.
|
static |
Definition at line 16303 of file ripper.c.
References arg_append, list_append, nd_set_type, nd_type, NEW_ARGSPUSH, NEW_LIST, NODE_ARGSCAT, NODE_ARGSPUSH, NODE_ARRAY, and NODE_BLOCK_PASS.
|
static |
Definition at line 16278 of file ripper.c.
References arg_concat, list_concat(), nd_set_type, nd_type, NEW_ARGSCAT, NEW_LIST, NODE_ARGSCAT, NODE_ARGSPUSH, NODE_ARRAY, and NODE_BLOCK_PASS.
|
static |
Definition at line 17236 of file ripper.c.
References lvtbl, and vtable_add().
|
static |
Definition at line 16244 of file ripper.c.
References NEW_ATTRASGN, and tASET.
|
static |
Definition at line 16621 of file ripper.c.
References is_static_content(), nd_type, NODE_DASGN, NODE_DASGN_CURR, NODE_GASGN, NODE_IASGN, NODE_LASGN, NODE_MASGN, and parser_warn.
Referenced by cond0().
|
static |
Definition at line 16106 of file ripper.c.
References assignable_result, compile_error, dvar_curr, dvar_defined, dyna_in_block, dyna_var, get_id, ID_CLASS, ID_CONST, ID_GLOBAL, ID_INSTANCE, ID_LOCAL, id_type(), in_def, in_single, keyword__ENCODING__, keyword__FILE__, keyword__LINE__, keyword_false, keyword_nil, keyword_self, keyword_true, local_id, local_var, NEW_CDECL, NEW_CVASGN, NEW_DASGN, NEW_DASGN_CURR, NEW_GASGN, NEW_IASGN, NEW_LASGN, PARSER_ARG, PRIsVALUE, rb_id2str, and yyerror.
Referenced by show_bitstack().
|
static |
Definition at line 16258 of file ripper.c.
References CALL_Q_P, NEW_ATTRASGN, and rb_id_attrset().
|
static |
Definition at line 15564 of file ripper.c.
References fixpos(), nd_type, NEW_BLOCK, NODE_BLOCK, NODE_BREAK, NODE_FALSE, NODE_LIT, NODE_NEXT, NODE_NIL, NODE_REDO, NODE_RETRY, NODE_RETURN, NODE_SELF, NODE_STR, NODE_TRUE, parser_warning, RTEST, and ruby_verbose.
|
static |
Definition at line 16250 of file ripper.c.
References compile_error, nd_type, NODE_BLOCK_PASS, and PARSER_ARG.
|
static |
Definition at line 15793 of file ripper.c.
References NEW_CALL, NEW_LIST, and value_expr.
|
static |
Definition at line 15801 of file ripper.c.
References NEW_CALL, and value_expr.
|
static |
Definition at line 13769 of file ripper.c.
References parser_params::has_shebang, ISSPACE, lex_p, lex_pbeg, parser_params::line_count, and parser_params::pend.
Referenced by magic_comment_encoding(), and parser_yylex().
|
static |
Definition at line 16696 of file ripper.c.
References assign_in_cond(), e_option_supplied(), FALSE, literal_node(), nd_set_type, nd_type, NEW_GVAR, NEW_MATCH2, NODE_AND, NODE_DOT2, NODE_DOT3, NODE_DREGX, NODE_DREGX_ONCE, NODE_DSTR, NODE_DSYM, NODE_EVSTR, NODE_FLIP2, NODE_FLIP3, NODE_LIT, NODE_MATCH, NODE_OR, NODE_STR, parser_warn, parser_warning, range_op(), RB_TYPE_P, rb_warn0, RTEST, ruby_verbose, T_REGEXP, warn_unless_e_option(), and warning_unless_e_option().
Referenced by cond_gen(), new_if_gen(), range_op(), and warning_unless_e_option().
|
static |
|
static |
Definition at line 17108 of file ripper.c.
References in_def, in_single, new_attr_op_assign_gen(), NEW_CDECL, new_op_assign_gen(), and yyerror.
Definition at line 12176 of file ripper.c.
References rb_ary_tmp_new(), rb_ary_tmp_new_fill(), rb_get_coverages(), rb_hash_aset(), RBASIC, and RTEST.
Referenced by coverage_peek_result_i(), prepare_iseq_build(), reset_coverage_i(), update_coverage(), and yycompile0().
Definition at line 12160 of file ripper.c.
References CONST_ID, hash(), rb_ary_new(), rb_cObject, rb_const_defined_at(), rb_const_get_at(), rb_hash_aset(), RB_TYPE_P, and T_HASH.
Referenced by yycompile0().
|
static |
Definition at line 13341 of file ripper.c.
References len, MEMMOVE, PRIsVALUE, rb_fatal(), rb_str_modify(), rb_str_set_len(), RSTRING_GETMEM, RSTRING_LEN, RSTRING_PTR, and TAB_WIDTH.
Referenced by parser_heredoc_dedent().
|
static |
Definition at line 12891 of file ripper.c.
References rb_gc_force_recycle(), and rb_str_free().
Referenced by parser_here_document(), and parser_heredoc_restore().
|
static |
|
static |
Definition at line 17370 of file ripper.c.
References lvtbl, and vtable_included().
|
static |
Definition at line 17339 of file ripper.c.
References parser_params::base_block, DVARS_INHERIT, LVAR_USED, lvtbl, POINTER_P, vtable::prev, rb_dvar_defined(), vtable::tbl, and vtable_included().
|
static |
Definition at line 17333 of file ripper.c.
References DVARS_TOPSCOPE, lvtbl, and POINTER_P.
|
static |
Definition at line 17305 of file ripper.c.
References dyna_pop_vtable(), lvtbl, vtable_free(), and warn_unused_var().
Referenced by dyna_pop_gen().
|
static |
Definition at line 17319 of file ripper.c.
References dyna_pop_1(), lvtbl, and xfree().
|
static |
Definition at line 17290 of file ripper.c.
References lvtbl, vtable::prev, and vtable_free().
Referenced by dyna_pop_1().
|
static |
Definition at line 17279 of file ripper.c.
References lvtbl, and vtable_alloc().
|
static |
Definition at line 12188 of file ripper.c.
References ruby_sourcefile.
Referenced by cond0(), local_push_gen(), warn_unless_e_option(), warning_unless_e_option(), and yycompile0().
|
static |
Definition at line 15770 of file ripper.c.
References list_append, nd_type, NEW_DSTR, NODE_EVSTR, and STR_NEW0.
Definition at line 15541 of file ripper.c.
References nd_line, and nd_set_line.
Referenced by block_append_gen(), new_attr_op_assign_gen(), new_const_op_assign_gen(), and yyparse().
|
static |
Definition at line 13677 of file ripper.c.
References ID_CLASS, ID_CONST, ID_GLOBAL, ID_INSTANCE, ID_LOCAL, id_type(), shadowing_lvar, and yyerror.
|
static |
Definition at line 15855 of file ripper.c.
References compile_error, current_arg, current_enc, dvar_defined, dyna_in_block, ID_CLASS, ID_CONST, ID_GLOBAL, ID_INSTANCE, ID_LOCAL, id_type(), in_defined, INT2FIX, keyword__ENCODING__, keyword__FILE__, keyword__LINE__, keyword_false, keyword_nil, keyword_self, keyword_true, local_id, NEW_CONST, NEW_CVAR, NEW_DVAR, NEW_FALSE, NEW_GVAR, NEW_IVAR, NEW_LIT, NEW_LVAR, NEW_NIL, NEW_SELF, NEW_STR, NEW_TRUE, NEW_VCALL, PARSER_ARG, PRIsVALUE, PRIsWARN, rb_enc_from_encoding(), rb_id2str, rb_str_dup(), rb_warn1, rb_warning1, RTEST, ruby_sourcefile_string, ruby_verbose, and tokline.
|
static |
Definition at line 17619 of file ripper.c.
References ID_INTERNAL, ID_SCOPE_SHIFT, ID_STATIC_SYM, lvtbl, tLAST_TOKEN, and vtable_size().
|
static |
Definition at line 16185 of file ripper.c.
References is_local_id, rb_id2str, and RSTRING_PTR.
Referenced by shadowing_lvar_0(), and warn_unused_var().
|
static |
Definition at line 16597 of file ripper.c.
References nd_type, NODE_ARRAY, NODE_FALSE, NODE_HASH, NODE_LIT, NODE_NIL, NODE_STR, NODE_TRUE, and NODE_ZARRAY.
Referenced by assign_in_cond().
|
static |
Definition at line 12277 of file ripper.c.
References len, lex_gets_ptr, Qnil, rb_str_subseq(), RSTRING_LEN, and RSTRING_PTR.
Referenced by parser_compile_error(), and parser_compile_string().
|
static |
Definition at line 12297 of file ripper.c.
References current_enc, lex_input, must_be_ascii_compatible(), NIL_P, Qnil, rb_ary_push(), rb_enc_associate(), ruby_coverage, and ruby_debug_lines.
Referenced by parser_nextline().
|
static |
Definition at line 12372 of file ripper.c.
References rb_io_gets_internal().
Referenced by rb_parser_compile_file_path().
|
static |
Definition at line 15638 of file ripper.c.
References last.
Referenced by append_literal_keys(), arg_concat_gen(), literal_concat_gen(), remove_duplicate_keys(), and yyparse().
|
static |
Definition at line 15662 of file ripper.c.
References compile_error, NIL_P, PARSER_ARG, rb_enc_compatible(), rb_enc_get(), rb_enc_name, rb_str_buf_append(), and rb_str_resize().
Referenced by literal_concat_gen(), and new_regexp_gen().
|
static |
Definition at line 15679 of file ripper.c.
References heredoc_indent, list_append, list_concat(), literal_concat0(), nd_set_type, nd_type, NEW_DSTR, NEW_STR, NIL_P, NODE_ARRAY, NODE_DSTR, NODE_EVSTR, NODE_STR, Qnil, rb_gc_force_recycle(), and STR_NEW0.
|
static |
Definition at line 16675 of file ripper.c.
References nd_type, NODE_DREGX, NODE_DREGX_ONCE, NODE_DSTR, NODE_DSYM, NODE_EVSTR, NODE_FALSE, NODE_LIT, NODE_NIL, NODE_STR, and NODE_TRUE.
Referenced by cond0().
|
static |
Definition at line 17251 of file ripper.c.
References parser_params::base_block, DVARS_INHERIT, LVAR_USED, lvtbl, POINTER_P, vtable::prev, rb_local_defined(), vtable::tbl, and vtable_included().
|
static |
Definition at line 17188 of file ripper.c.
References CMDARG_SET, lvtbl, vtable::prev, vtable_free(), warn_unused_var(), and xfree().
|
static |
Definition at line 17168 of file ripper.c.
References ALLOC, local_vars::args, CMDARG_SET, cmdarg_stack, local_vars::cmdargs, compile_for_eval, DVARS_INHERIT, DVARS_TOPSCOPE, e_option_supplied(), ifndef_ripper, lvtbl, local_vars::prev, RTEST, ruby_verbose, local_vars::used, local_vars::vars, and vtable_alloc().
|
static |
|
static |
Definition at line 17242 of file ripper.c.
References lvtbl, ruby_sourceline, and vtable_add().
|
static |
Definition at line 16771 of file ripper.c.
References nd_type, NEW_NODE, and value_expr.
|
static |
Definition at line 13710 of file ripper.c.
References dvar_defined_get, dyna_in_block, and local_id.
|
static |
Definition at line 13784 of file ripper.c.
References comment_at_top(), and parser_set_encode().
Definition at line 13863 of file ripper.c.
Referenced by parser_magic_comment().
|
static |
Definition at line 15808 of file ripper.c.
References lvtbl, nd_type, NEW_CALL, NEW_LIST, NEW_MATCH2, NEW_MATCH3, NODE_DREGX, NODE_DREGX_ONCE, NODE_LIT, vtable::prev, RB_TYPE_P, T_REGEXP, tMATCH, value_expr, and vtable_included().
|
static |
Definition at line 12267 of file ripper.c.
References parser_params::enc, rb_eArgError, rb_enc_asciicompat, rb_enc_get(), and rb_raise().
Referenced by lex_getline(), rb_compile_string(), and rb_parser_compile_string_path().
Definition at line 16819 of file ripper.c.
References BIGNUM_NEGATE, DBL2NUM, FIX2LONG, FLONUM_P, LONG2FIX, rb_big_norm(), rb_bug(), RCOMPLEX, RCOMPLEX_SET_IMAG, RCOMPLEX_SET_REAL, RFLOAT, RFLOAT_VALUE, RRATIONAL, RRATIONAL_SET_NUM, T_BIGNUM, T_COMPLEX, T_FIXNUM, T_FLOAT, T_RATIONAL, and TYPE.
Referenced by yyparse().
|
static |
Definition at line 16865 of file ripper.c.
References rb_args_info::first_post_arg, rb_args_info::opt_args, rb_args_info::post_args_num, rb_args_info::post_init, rb_args_info::pre_args_num, rb_args_info::pre_init, rb_long2int, rb_args_info::rest_arg, and ruby_sourceline.
|
static |
Definition at line 16887 of file ripper.c.
References arg_var, rb_args_info::block_arg, internal_id, is_junk_id, rb_args_info::kw_args, rb_args_info::kw_rest_arg, lvtbl, NEW_DVAR, NEW_NODE, NODE_ARGS, NULL, ruby_sourceline, vtable::tbl, vtable_add(), vtable_alloc(), vtable_free(), vtable_pop(), vtable_size(), and ZALLOC.
|
static |
Definition at line 17070 of file ripper.c.
References CALL_Q_P, fixpos(), NEW_OP_ASGN2, tANDOP, and tOROP.
Referenced by const_decl_gen().
|
static |
Definition at line 16230 of file ripper.c.
References compile_error, dyna_var, is_local_id, PARSER_ARG, PRIsVALUE, rb_id2str, and shadowing_lvar_0().
|
static |
|
static |
|
static |
Definition at line 17027 of file ripper.c.
References NEW_HASH, and remove_duplicate_keys().
|
static |
|
static |
Definition at line 17036 of file ripper.c.
References gettable, ID_CLASS, ID_GLOBAL, ID_INSTANCE, id_type(), is_notop_id, NEW_BEGIN, NEW_CALL, NEW_LIST, NEW_OP_ASGN_AND, NEW_OP_ASGN_OR, tANDOP, and tOROP.
Referenced by const_decl_gen().
|
static |
Definition at line 15921 of file ripper.c.
References list, literal_concat0(), nd_next, nd_set_type, nd_type, NEW_LIST, NEW_LIT, NEW_NODE, NIL_P, NODE_DREGX, NODE_DREGX_ONCE, NODE_DSTR, NODE_LIT, NODE_STR, vtable::prev, rb_gc_force_recycle(), rb_str_resize(), RE_OPTION_MASK, RE_OPTION_ONCE, reg_compile, reg_fragment_check, and STR_NEW0.
Referenced by new_xstring_gen().
|
static |
Definition at line 15981 of file ripper.c.
References compile_error, dvar_defined, dyna_in_block, err, ID_CLASS, ID_CONST, ID_GLOBAL, ID_INSTANCE, ID_LOCAL, ID_SCOPE_MASK, is_notop_id, local_id, nd_set_type, nd_type, NEW_LIST, NEW_NODE, new_regexp_gen(), NEW_XSTR, NIL_P, NODE_DSTR, NODE_DXSTR, NODE_STR, NODE_XSTR, options(), PARSER_ARG, parser_reg_compile(), PRIsVALUE, Qnil, rb_id2str, RNODE, and STR_NEW0.
|
static |
Definition at line 16811 of file ripper.c.
References NEW_YIELD, and no_blockarg().
Definition at line 15531 of file ripper.c.
References RNode::flags, NODE_FL_NEWLINE, and remove_begin().
Referenced by new_if_gen(), and yyparse().
|
static |
Definition at line 16786 of file ripper.c.
References compile_error, nd_type, NODE_BLOCK_PASS, and PARSER_ARG.
Referenced by new_yield_gen(), and ret_args_gen().
|
static |
Definition at line 16329 of file ripper.c.
References arg_append, nd_type, NODE_ATTRASGN, NODE_CALL, NODE_CDECL, NODE_CVASGN, NODE_DASGN, NODE_DASGN_CURR, NODE_GASGN, NODE_IASGN, NODE_IASGN2, NODE_LASGN, and NODE_MASGN.
|
static |
Definition at line 15511 of file ripper.c.
References nd_set_line, rb_node_newnode, and ruby_sourceline.
|
static |
|
static |
Definition at line 14670 of file ripper.c.
References compile_error, ISDIGIT, ISSPACE, newtok, nextc, PARSER_ARG, parser_is_identchar, pushback, result, SET_LEX_STATE, tCVAR, tIVAR, tokadd, tokadd_ident(), and tokenize_ident().
Referenced by parser_yylex().
|
static |
Definition at line 14568 of file ripper.c.
References compile_error, IS_lex_state_for, ISDIGIT, ISSPACE, NEW_BACK_REF, NEW_NTH_REF, newtok, nextc, parse_numvar(), PARSER_ARG, parser_is_identchar, pushback, SET_LEX_STATE, set_yylval_name, set_yylval_node, tBACK_REF, tGVAR, tNTH_REF, TOK_INTERN, tokadd, tokadd_ident(), tokadd_mbchar, tokenize_ident(), and tokfix.
Referenced by parser_yylex().
|
static |
Definition at line 14709 of file ripper.c.
References CMDARG_P, command_start, COND_P, ENC_CODERANGE_7BIT, ENC_CODERANGE_UNKNOWN, EXPR_ARG_ANY, EXPR_BEG_ANY, kwtable::id, IS_LABEL_POSSIBLE, IS_LABEL_SUFFIX, IS_lex_state, IS_lex_state_for, ISASCII, ISUPPER, keyword_do, keyword_do_block, keyword_do_cond, keyword_do_LAMBDA, lambda_beginning_p, lex_state, lpar_beg, lvar_defined, nextc, paren_nest, parser_is_identchar, peek, peek_n, pushback, rb_intern2(), rb_reserved_word(), result, SET_LEX_STATE, set_yylval_name, kwtable::state, tCONSTANT, tFID, tIDENTIFIER, tLABEL, tok, TOK_INTERN, tokadd, tokadd_mbchar, tokenize_ident(), tokfix, toklast, toklen, and TRUE.
Referenced by parser_yylex().
|
static |
Definition at line 14102 of file ripper.c.
References DBL2NUM, errno, FALSE, INT2FIX, ISDIGIT, ISXDIGIT, newtok, nextc, no_digits, NUM_SUFFIX_ALL, NUM_SUFFIX_I, NUM_SUFFIX_R, number_literal_suffix, parse_rational(), pushback, rb_cstr_to_inum(), rb_warning1, set_integer_literal, SET_LEX_STATE, set_number_literal, snprintf, strtod, tFLOAT, tok, tokadd, tokfix, toklen, tRATIONAL, WARN_S, and yyerror.
Referenced by parser_yylex().
|
static |
Definition at line 14547 of file ripper.c.
References len, rb_warn1, ruby_scan_digits(), tok, toklen, and WARN_S.
Referenced by parse_gvar().
|
static |
Definition at line 14428 of file ripper.c.
References compile_error, current_enc, IS_AFTER_OPERATOR, IS_BEG, IS_lex_state, IS_SPCARG, ISALNUM, ISSPACE, lex_strterm, NEW_STRTERM, nextc, PARSER_ARG, parser_isascii, pushback, rb_enc_isalnum, SET_LEX_STATE, set_yylval_id, str_dquote, str_dword, str_regexp, str_squote, str_ssym, str_sword, str_xquote, term, tOP_ASGN, tQSYMBOLS_BEG, tQWORDS_BEG, tREGEXP_BEG, tSTRING_BEG, tSYMBEG, tSYMBOLS_BEG, tWORDS_BEG, tXSTRING_BEG, warn_balanced, and yyerror.
Referenced by parser_yylex().
|
static |
Definition at line 14337 of file ripper.c.
References compile_error, current_enc, EXPR_VALUE, IS_ARG, IS_END, is_identchar, ISASCII, lex_eol_p, lex_p, lex_pend, newtok, nextc, PARSER_ARG, parser_isascii, parser_precise_mbclen(), parser_tokadd_utf8(), peek, pushback, rb_enc_isalnum, rb_enc_isspace, rb_warn1, rb_warn2, read_escape, SET_LEX_STATE, set_yylval_str, STR_NEW3, tCHAR, tok, tokadd, tokadd_mbchar, tokfix, toklen, WARN_I, and WARN_S_L.
Referenced by parser_yylex().
|
static |
Definition at line 14091 of file ripper.c.
References FALSE, memmove(), rb_cstr_to_inum(), rb_int_positive_pow(), and rb_rational_new().
Referenced by parse_numeric().
|
static |
Definition at line 17929 of file ripper.c.
References argc, argv, buf, BUILTIN_TYPE, current_enc, parser_params::eofp, parser_params::error_buffer, parser_params::error_p, FIXNUM_P, id, ID2SYM, InitVM, INT2NUM, keyword__ENCODING__, keyword__FILE__, keyword__LINE__, keyword_alias, keyword_and, keyword_begin, keyword_BEGIN, keyword_break, keyword_case, keyword_class, keyword_def, keyword_defined, keyword_do, keyword_do_block, keyword_do_cond, keyword_else, keyword_elsif, keyword_end, keyword_END, keyword_ensure, keyword_false, keyword_for, keyword_if, keyword_in, keyword_module, keyword_next, keyword_nil, keyword_not, keyword_or, keyword_redo, keyword_rescue, keyword_retry, keyword_return, keyword_self, keyword_super, keyword_then, keyword_true, keyword_undef, keyword_unless, keyword_until, keyword_when, keyword_while, keyword_yield, lex_get_str(), lex_gets, lex_input, lex_p, lex_pbeg, LONG2NUM, modifier_if, modifier_rescue, modifier_unless, modifier_until, modifier_while, msg, name, nd_type, NIL_P, NULL, NUM2INT, OBJ_FREEZE, parser_initialize(), parser_prepare(), PRIsVALUE, Qfalse, Qnil, Qtrue, Qundef, rb_bug(), rb_cObject, rb_define_alloc_func(), rb_define_class(), rb_define_const(), rb_define_global_const(), rb_define_method(), rb_define_private_method(), rb_define_singleton_method(), rb_eArgError, rb_ensure(), rb_eTypeError, rb_funcall(), rb_funcallv_public(), rb_id2str, rb_intern, rb_intern2(), rb_intern_const, rb_io_gets(), rb_long2int, rb_mKernel, rb_obj_class(), rb_obj_classname(), rb_parser_encoding(), rb_parser_end_seen_p(), rb_parser_get_yydebug(), rb_parser_set_yydebug(), rb_raise(), rb_respond_to(), rb_scan_args(), rb_str_new_frozen(), rb_syntax_error_append(), rb_thread_current(), RB_TYPE_P, rb_usascii_str_new2, rb_vsprintf(), ripper_id2sym, ripper_init_eventids1(), ripper_init_eventids1_table(), ripper_init_eventids2(), ripper_init_eventids2_table(), RSTRING_PTR, ruby_sourcefile, ruby_sourcefile_string, ruby_sourceline, STR_NEW2, StringValue, SYMBOL_P, T_ARRAY, T_BIGNUM, T_COMPLEX, T_FILE, T_FLOAT, T_NODE, T_OBJECT, T_RATIONAL, T_STRING, TRUE, TypedData_Get_Struct, TypedData_Make_Struct, and ULONG2NUM.
Definition at line 12318 of file ripper.c.
References lex_get_str(), lex_gets, lex_gets_ptr, lex_input, lex_p, lex_pbeg, lex_pend, RB_GC_GUARD, rb_str_new_frozen(), TypedData_Get_Struct, and yycompile().
Referenced by rb_compile_cstr(), rb_compile_string(), rb_parser_compile_cstr(), and rb_parser_compile_string_path().
|
static |
Definition at line 12500 of file ripper.c.
References parser_params::cr_seen, lex_p, peek, rb_warn0, and TRUE.
Referenced by parser_nextc().
|
static |
Definition at line 13717 of file ripper.c.
References len, and rb_memcicmp().
Referenced by set_file_encoding().
|
static |
Definition at line 17677 of file ripper.c.
References lvtbl, token_info::next, vtable::prev, local_vars::prev, parser_params::token_info, tokenbuf, local_vars::vars, and xfree().
Referenced by parser_memsize().
|
static |
Definition at line 13793 of file ripper.c.
References FALSE, rb_compile_warning(), ruby_sourcefile, ruby_sourceline, strcasecmp, and TRUE.
Referenced by parser_set_compile_option_flag(), and parser_set_token_info().
|
static |
Definition at line 13529 of file ripper.c.
References compile_error, current_enc, dispatch_delayed_token, dispatch_heredoc_end, dispatch_scan_event, dispose_string(), parser_params::enc, ENC_CODERANGE_7BIT, ENC_CODERANGE_UNKNOWN, parser_params::eofp, flush_string_content, func, has_delayed_token, heredoc_indent, heredoc_line_indent, heredoc_restore, len, lex_goto_eol, lex_lastline, lex_p, lex_pend, lex_strterm, NEW_STRTERM, newtok, nextc, NULL, PARSER_ARG, parser_peek_variable_name(), parser_update_heredoc_indent(), parser_params::pend, pushback, rb_ascii8bit_encoding(), rb_enc_asciicompat, rb_enc_str_buf_cat(), rb_str_append(), rb_str_cat(), rb_str_coderange_scan_restartable(), rb_usascii_encoding(), rb_utf8_encoding(), ripper_token2eventid(), RSTRING_LEN, RSTRING_PTR, set_yylval_str, STR_FUNC_EXPAND, STR_FUNC_INDENT, STR_FUNC_REGEXP, STR_NEW, STR_NEW3, STR_TERM_END, tok, tokadd, tokadd_string, toklen, tSTRING_CONTENT, tSTRING_END, was_bol, whole_match_p, and yylval.
|
static |
Definition at line 13373 of file ripper.c.
References dedent_string(), FALSE, heredoc_dedent, heredoc_indent, input, INT2NUM, nd_type, NODE_ARRAY, NODE_DSTR, NODE_STR, NUM2UINT, StringValue, and TRUE.
|
static |
Definition at line 13240 of file ripper.c.
References compile_error, dispatch_scan_event, func, heredoc_indent, heredoc_line_indent, len, lex_goto_eol, lex_lastline, lex_p, lex_pbeg, lex_strterm, nd_set_line, newtok, nextc, NODE_HEREDOC, PARSER_ARG, parser_is_identchar, pushback, rb_node_newnode, rb_warn0, ripper_flush, ruby_sourceline, str_dquote, STR_FUNC_INDENT, STR_NEW, str_squote, str_xquote, term, tHEREDOC_BEG, tok, tokadd, tokadd_mbchar, token, tokenbuf, tokfix, tokidx, toklen, tSTRING_BEG, and tXSTRING_BEG.
|
static |
Definition at line 13323 of file ripper.c.
References dispose_string(), heredoc_end, lex_lastline, lex_p, lex_pbeg, lex_pend, lex_strterm, nd_line, rb_gc_force_recycle(), ripper_flush, RSTRING_LEN, RSTRING_PTR, and ruby_sourceline.
|
static |
Definition at line 17627 of file ripper.c.
References command_start, parser_params::debug_buffer, parser_params::enc, parser_params::error_buffer, Qfalse, Qnil, rb_utf8_encoding(), ruby_sourcefile_string, and TRUE.
Referenced by parser_compile_error(), and rb_parser_new().
|
static |
Definition at line 13896 of file ripper.c.
References FALSE, magic_comment::func, ISSPACE, len, magic_comment::length, magic_comment_marker(), magic_comments, magic_comment::name, numberof, RSTRING_PTR, str_copy, STRNCASECMP, and TRUE.
Referenced by parser_yylex().
|
static |
Definition at line 17649 of file ripper.c.
References parser_params::compile_option, parser_params::debug_buffer, parser_params::error_buffer, parser_params::heap, lex_input, lex_lastline, lex_nextline, lex_strterm, rb_gc_mark(), ruby_debug_lines, ruby_eval_tree, ruby_eval_tree_begin, and ruby_sourcefile_string.
Referenced by parser_memsize().
|
static |
Definition at line 17701 of file ripper.c.
References vtable::capa, lvtbl, parser_free(), parser_mark(), local_vars::prev, RUBY_TYPED_FREE_IMMEDIATELY, size, toksiz, and local_vars::vars.
|
static |
|
inlinestatic |
Definition at line 12515 of file ripper.c.
References lex_p, lex_pend, parser_cr(), parser_nextline(), and UNLIKELY.
|
static |
Definition at line 12455 of file ripper.c.
References parser_params::cr_seen, current_enc, parser_params::eofp, FALSE, has_delayed_token, heredoc_end, lex_getline(), lex_goto_eol, lex_input, lex_lastline, lex_nextline, lex_p, lex_pbeg, lex_pend, parser_params::line_count, NIL_P, rb_enc_associate(), rb_str_buf_cat(), rb_str_buf_new(), ripper_flush, RSTRING_LEN, RSTRING_PTR, and ruby_sourceline.
Referenced by parser_nextc().
|
static |
Definition at line 13451 of file ripper.c.
References ISALPHA, ISASCII, ISDIGIT, lex_p, nextc, NUM_SUFFIX_I, NUM_SUFFIX_R, parser_is_identchar, peekc_n, pushback, result, and yyerror.
|
static |
Definition at line 13184 of file ripper.c.
References compile_error, current_enc, parser_params::enc, parser_params::eofp, flush_string_content, func, RNode::id, ISSPACE, nd_line, nd_paren, nd_term, newtok, nextc, PARSER_ARG, parser_peek_variable_name(), parser_string_term(), pushback, ruby_sourceline, set_yylval_str, STR_FUNC_EXPAND, STR_FUNC_QWORDS, STR_FUNC_REGEXP, STR_NEW3, STR_TERM_END, term, tok, tokadd, tokadd_string, tokfix, toklen, tREGEXP_END, tSTRING_CONTENT, tSTRING_END, and RNode::u2.
|
static |
Definition at line 13139 of file ripper.c.
References command_start, is_global_name_punct(), ISALPHA, ISASCII, ISDIGIT, lex_p, lex_pend, TRUE, tSTRING_DBEG, and tSTRING_DVAR.
Referenced by parser_here_document(), and parser_parse_string().
|
static |
Definition at line 12079 of file ripper.c.
References compile_error, current_enc, len, lex_pend, MBCLEN_CHARFOUND_P, PARSER_ARG, parser_encoding_name, and rb_enc_precise_mbclen().
Referenced by parse_qmark(), and parser_tokadd_mbchar().
|
static |
Definition at line 14043 of file ripper.c.
References compile_for_eval, parser_params::enc, EOF, parser_params::has_shebang, lex_lastline, lex_p, lex_pbeg, lex_pend, nextc, peek, pushback, rb_enc_get(), rb_utf8_encoding(), RTEST, ruby_verbose, and parser_params::token_info_enabled.
Referenced by parser_compile_error(), parser_yyerror(), and yycompile0().
|
static |
|
static |
Definition at line 12684 of file ripper.c.
References ESCAPE_CONTROL, ESCAPE_META, ISASCII, lex_p, nextc, peek, pushback, read_escape, scan_oct, tok_hex, and yyerror.
|
static |
Definition at line 17490 of file ripper.c.
References rb_parser_reg_compile(), and reg_fragment_setenc.
Referenced by new_xstring_gen(), and reg_compile_gen().
|
static |
Definition at line 12855 of file ripper.c.
References compile_error, ISALPHA, newtok, nextc, options(), PARSER_ARG, pushback, rb_ascii8bit_encindex(), rb_char_to_option_kcode(), RE_OPTION_ENCODING, RE_OPTION_ONCE, tok, tokadd, tokfix, and toklen.
|
static |
Definition at line 13819 of file ripper.c.
References parser_params::compile_option, ID2SYM, parser_get_bool(), Qfalse, Qtrue, rb_hash_aset(), rb_ident_hash_new(), rb_intern, rb_obj_hide(), rb_warning1, parser_params::token_seen, val, and WARN_S.
|
static |
Definition at line 13737 of file ripper.c.
References parser_params::enc, PRIsVALUE, RARRAY_AREF, RARRAY_LEN, rb_ary_unshift(), rb_eArgError, rb_enc_asciicompat, rb_enc_associate_index(), rb_enc_find_index(), rb_enc_from_index(), rb_enc_name, rb_exc_raise(), rb_make_backtrace(), rb_make_exception(), rb_sprintf(), ruby_debug_lines, ruby_sourcefile_string, and ruby_sourceline.
Referenced by magic_comment_encoding(), and set_file_encoding().
|
static |
Definition at line 13500 of file ripper.c.
References dispatch_delayed_token, has_delayed_token, lex_goto_eol, lex_pend, NUM_SUFFIX_R, rb_rational_raw1, ripper_flush, ripper_token2eventid(), set_number_literal, STR_NEW, tHEREDOC_END, tINTEGER, tRATIONAL, and tSTRING_CONTENT.
|
static |
Definition at line 13488 of file ripper.c.
References INT2FIX, NUM_SUFFIX_I, rb_complex_raw(), SET_LEX_STATE, set_yylval_literal, and tIMAGINARY.
|
static |
Definition at line 13812 of file ripper.c.
References parser_get_bool(), and parser_params::token_info_enabled.
|
static |
Definition at line 12431 of file ripper.c.
References ENC_CODERANGE_7BIT, rb_ascii8bit_encoding(), rb_enc_asciicompat, rb_enc_associate(), rb_enc_str_coderange(), rb_enc_str_new(), rb_usascii_encoding(), rb_utf8_encoding(), and STR_FUNC_REGEXP.
|
inlinestatic |
Definition at line 13175 of file ripper.c.
References dispatch_scan_event, regx_options, set_yylval_num, STR_FUNC_REGEXP, tREGEXP_END, and tSTRING_END.
Referenced by parser_parse_string().
|
static |
|
static |
|
static |
|
static |
Definition at line 12782 of file ripper.c.
References ESCAPE_CONTROL, ESCAPE_META, lex_p, nextc, pushback, ruby_scan_oct(), tok_hex, tokadd, tokcopy, and yyerror.
|
static |
|
static |
Definition at line 12950 of file ripper.c.
References parser_params::enc, heredoc_indent, ISASCII, ISSPACE, lex_p, lex_pend, mixed_error, mixed_escape, nextc, parser_isascii, parser_tokadd_utf8(), parser_update_heredoc_indent(), pushback, read_escape, simple_re_meta(), STR_FUNC_ESCAPE, STR_FUNC_EXPAND, STR_FUNC_QWORDS, STR_FUNC_REGEXP, STR_FUNC_SYMBOL, tokadd, tokadd_escape, and tokadd_mbchar.
|
static |
Definition at line 12635 of file ripper.c.
References FALSE, ISSPACE, last, nextc, parser_tokadd_codepoint(), peek, pushback, tokadd, TRUE, and yyerror.
Referenced by parse_qmark(), and parser_tokadd_string().
|
static |
Definition at line 12775 of file ripper.c.
References len, rb_enc_codelen(), rb_enc_mbcput, and tokspace.
|
static |
|
static |
Definition at line 12924 of file ripper.c.
References FALSE, heredoc_indent, heredoc_line_indent, TAB_WIDTH, and TRUE.
Referenced by parser_here_document(), and parser_tokadd_string().
|
static |
Definition at line 15557 of file ripper.c.
References nd_line, rb_compile_warn(), and ruby_sourcefile.
|
static |
Definition at line 15550 of file ripper.c.
References nd_line, rb_compile_warning(), and ruby_sourcefile.
|
static |
|
static |
Definition at line 12090 of file ripper.c.
References ALLOCA_N, buf, compile_error, len, lex_lastline, lex_p, lex_pbeg, lex_pend, PARSER_ARG, parser_prepare(), rb_enc_get(), rb_enc_prev_char, and STR_NEW2.
Referenced by yyparse().
|
static |
Definition at line 14824 of file ripper.c.
References arg_ambiguous, brace_nest, CMDARG_LEXPOP, CMDARG_PUSH, command_start, comment_at_top(), compile_error, COND_LEXPOP, COND_P, COND_PUSH, dispatch_delayed_token, dispatch_scan_event, parser_params::eofp, EXPR_ARG_ANY, FALSE, here_document, heredoc_identifier, parser_params::in_kwarg, IS_AFTER_OPERATOR, IS_ARG, IS_BEG, IS_END, IS_LABEL_POSSIBLE, IS_LABEL_SUFFIX, IS_lex_state, IS_lex_state_all, IS_SPCARG, ISDIGIT, ISSPACE, k__END__, lambda_beginning_p, lex_goto_eol, lex_lastline, lex_nextline, lex_p, lex_pend, lex_state, lex_strterm, lpar_beg, nd_type, NEW_STRTERM, newtok, next_state(), nextc, NODE_HEREDOC, paren_nest, parse_atmark(), parse_gvar(), parse_ident(), parse_numeric(), parse_percent(), parse_qmark(), parse_string, PARSER_ARG, parser_is_identchar, parser_magic_comment(), peek, pushback, rb_gc_force_recycle(), rb_warning0, ruby__end__seen, ruby_sourceline, set_file_encoding(), SET_LEX_STATE, set_yylval_id, str_dquote, str_dsym, STR_FUNC_LABEL, str_label, str_regexp, str_squote, str_ssym, str_xquote, tAMPER, tANDDOT, tANDOP, tAREF, tASET, tASSOC, tCMP, tCOLON2, tCOLON3, tCOMMENT, tDOT2, tDOT3, tDSTAR, tEMBDOC, tEMBDOC_BEG, tEMBDOC_END, tEQ, tEQQ, tGEQ, tIGNORED_NL, tLABEL_END, tLAMBDA, tLAMBEG, tLBRACE, tLBRACE_ARG, tLBRACK, tLEQ, tLPAREN, tLPAREN_ARG, tLSHFT, tMATCH, tNEQ, tNMATCH, token, token_info_push, parser_params::token_seen, tOP_ASGN, tOROP, tPOW, tREGEXP_BEG, tREGEXP_END, tRSHFT, TRUE, tSP, tSTAR, tSTRING_BEG, tSTRING_DEND, tSTRING_END, tSYMBEG, tUMINUS, tUMINUS_NUM, tUPLUS, tXSTRING_BEG, warn_balanced, was_bol, whole_match_p, and yyerror.
Referenced by yylex().
|
static |
|
static |
Definition at line 16265 of file ripper.c.
References compile_error, nd_type, NODE_BACK_REF, NODE_NTH_REF, and PARSER_ARG.
void rb_init_parse | ( | void | ) |
Definition at line 17610 of file ripper.c.
References nodeline(), and nodetype().
Definition at line 3267 of file io.c.
Referenced by lex_io_gets(), and rb_parser_compile_cstr().
Definition at line 17537 of file ripper.c.
Referenced by process_options().
void* rb_parser_calloc | ( | struct parser_params * | parser, |
size_t | nelem, | ||
size_t | size | ||
) |
Definition at line 12386 of file ripper.c.
Referenced by rb_compile_file().
Definition at line 12392 of file ripper.c.
Referenced by iseqw_s_compile_file(), load_file_internal(), rb_iseq_compile_with_option(), and rb_parser_compile_file().
Definition at line 12343 of file ripper.c.
Referenced by process_options().
Definition at line 12349 of file ripper.c.
Referenced by load_file_internal(), rb_iseq_compile_with_option(), and rb_parser_compile_string().
Definition at line 17809 of file ripper.c.
Referenced by load_file_internal(), and parser_compile_error().
Definition at line 17794 of file ripper.c.
Referenced by load_file_internal(), and parser_compile_error().
void rb_parser_free | ( | struct parser_params * | parser, |
void * | ptr | ||
) |
Definition at line 17824 of file ripper.c.
Referenced by parser_compile_error().
void* rb_parser_malloc | ( | struct parser_params * | parser, |
size_t | size | ||
) |
VALUE rb_parser_new | ( | void | ) |
Definition at line 17739 of file ripper.c.
Referenced by iseqw_s_compile_file(), process_options(), rb_compile_cstr(), rb_compile_file(), rb_compile_string(), rb_iseq_compile_with_option(), rb_load_file_str(), and rb_load_internal0().
void rb_parser_printf | ( | struct parser_params * | parser, |
const char * | fmt, | ||
... | |||
) |
void* rb_parser_realloc | ( | struct parser_params * | parser, |
void * | ptr, | ||
size_t | size | ||
) |
VALUE rb_parser_reg_compile | ( | struct parser_params * | parser, |
VALUE | str, | ||
int | options | ||
) |
Definition at line 17497 of file ripper.c.
References rb_reg_compile(), RE_OPTION_MASK, ruby_sourcefile, and ruby_sourceline.
Referenced by parser_reg_compile(), and reg_compile_gen().
Definition at line 17749 of file ripper.c.
Referenced by iseqw_s_compile_file(), process_options(), rb_iseq_compile_with_option(), and rb_load_internal0().
Definition at line 17839 of file ripper.c.
Referenced by parser_compile_error(), and process_options().
Definition at line 17569 of file ripper.c.
Referenced by process_options().
int rb_reg_fragment_setenc | ( | struct parser_params * | parser, |
VALUE | str, | ||
int | options | ||
) |
Definition at line 17386 of file ripper.c.
References current_enc, ENC_CODERANGE_7BIT, ENCODING_GET, ENCODING_IS_ASCII8BIT, ENCODING_SET, rb_ascii8bit_encoding(), rb_char_to_option_kcode(), rb_enc_associate(), rb_enc_str_coderange(), rb_usascii_encoding(), RE_OPTION_ENCODING_IDX, and RE_OPTION_ENCODING_NONE.
Referenced by reg_compile_gen(), and reg_fragment_setenc_gen().
Definition at line 17733 of file ripper.c.
Referenced by parse_ident(), and reg_named_capture_assign_iter().
|
static |
Definition at line 16536 of file ripper.c.
References RNode::flags, nd_body, nd_else, nd_head, nd_next, nd_resq, nd_type, NEW_NIL, NODE_BEGIN, NODE_BLOCK, NODE_CASE, NODE_ENSURE, NODE_FL_NEWLINE, NODE_IF, NODE_NIL, NODE_RESCUE, NODE_RETURN, NODE_WHEN, and subnodes.
|
static |
Definition at line 17503 of file ripper.c.
References compile_error, err, NIL_P, options(), PARSER_ARG, parser_reg_compile(), PRIsVALUE, Qnil, rb_attr_get(), rb_errinfo(), rb_parser_reg_compile(), rb_reg_fragment_setenc(), rb_set_errinfo(), and reg_fragment_enc_error().
|
static |
Definition at line 17430 of file ripper.c.
References compile_error, err, PARSER_ARG, PRIsVALUE, Qnil, rb_obj_as_string(), rb_reg_check_preprocess(), and reg_fragment_setenc.
|
static |
Definition at line 17377 of file ripper.c.
References compile_error, PARSER_ARG, rb_enc_get(), and rb_enc_name.
Referenced by reg_compile_gen(), and reg_fragment_setenc_gen().
|
static |
Definition at line 17423 of file ripper.c.
References rb_reg_fragment_setenc(), and reg_fragment_enc_error().
|
static |
Definition at line 17476 of file ripper.c.
References reg_named_capture_assign_t::enc, onig_foreach_name(), reg_named_capture_assign_t::parser, rb_enc_get(), reg_named_capture_assign_iter(), RREGEXP_PTR, and reg_named_capture_assign_t::succ_block.
|
static |
Definition at line 17450 of file ripper.c.
References assignable, block_append, parser_params::enc, reg_named_capture_assign_t::enc, ID2SYM, intern_cstr, ISASCII, len, MAX_WORD_LENGTH, name, NEW_BEGIN, NEW_LIT, node_assign, reg_named_capture_assign_t::parser, rb_enc_islower, rb_enc_symname2_p(), rb_reserved_word(), ST_CONTINUE, and reg_named_capture_assign_t::succ_block.
Referenced by reg_named_capture_assign_gen().
Definition at line 16516 of file ripper.c.
References nd_type, and NODE_BEGIN.
Referenced by newline_node(), and yyparse().
Definition at line 16526 of file ripper.c.
References nd_type, and NODE_BEGIN.
|
static |
Definition at line 16994 of file ripper.c.
References append_literal_keys(), block_append, hash(), key, list_concat(), nd_line, nd_type, NODE_LIT, PRIsVALUE, rb_compile_warn(), result, ruby_sourcefile, st_data_t, st_foreach, st_free_table, st_init_numtable_with_size, st_insert, and st_lookup.
Referenced by new_hash_gen().
|
static |
Definition at line 16794 of file ripper.c.
References nd_set_type, nd_type, no_blockarg(), NODE_ARRAY, and NODE_VALUES.
|
static |
Definition at line 14000 of file ripper.c.
References ISALNUM, ISSPACE, parser_encode_length(), parser_set_encode(), rb_str_new(), rb_str_resize(), RSTRING_PTR, and STRNCASECMP.
Referenced by parser_yylex().
|
static |
Definition at line 16198 of file ripper.c.
References dvar_curr, dvar_defined_get, dyna_in_block, is_private_local_id(), local_id, LVAR_USED, lvtbl, PRIsWARN, rb_id2str, rb_warning1, ruby_sourceline, vtable_add(), and yyerror.
Referenced by new_bv_gen(), and shadowing_lvar_gen().
|
static |
Definition at line 16223 of file ripper.c.
References name, and shadowing_lvar_0().
|
static |
Definition at line 16086 of file ripper.c.
References assignable_gen(), CHAR_BIT, rb_io_write(), rb_sprintf(), rb_stdout, rb_str_cat(), rb_str_cat_cstr(), and rb_str_catf().
|
inlinestatic |
Definition at line 12911 of file ripper.c.
Referenced by parser_tokadd_string().
Definition at line 16321 of file ripper.c.
References nd_type, NODE_ARRAY, and NODE_SPLAT.
Referenced by yyparse().
|
static |
Definition at line 14526 of file ripper.c.
References nextc, parser_is_identchar, pushback, and tokadd_mbchar.
Referenced by parse_atmark(), and parse_gvar().
|
static |
Definition at line 12014 of file ripper.c.
References lex_pbeg, and TAB_WIDTH.
Referenced by token_info_pop_gen(), and token_info_push_gen().
|
static |
Definition at line 12028 of file ripper.c.
References lex_pbeg.
Referenced by token_info_pop_gen(), and token_info_push_gen().
|
static |
Definition at line 12057 of file ripper.c.
References token_info::column, len, lex_p, token_info::linenum, token_info::next, token_info::nonspc, rb_warn3L, ruby_sourceline, token_info::token, parser_params::token_info, parser_params::token_info_enabled, token_info_get_column(), token_info_has_nonspaces(), WARN_I, WARN_S, and xfree().
|
static |
Definition at line 12040 of file ripper.c.
References ALLOC, token_info::column, len, lex_p, token_info::linenum, token_info::next, token_info::nonspc, ruby_sourceline, token, token_info::token, parser_params::token_info, parser_params::token_info_enabled, token_info_get_column(), and token_info_has_nonspaces().
|
static |
Definition at line 14537 of file ripper.c.
References set_yylval_name, and TOK_INTERN.
Referenced by parse_atmark(), parse_gvar(), and parse_ident().
|
static |
Definition at line 16073 of file ripper.c.
References append_lex_state_name(), rb_io_write(), rb_stdout, rb_str_cat_cstr(), rb_str_catf(), and rb_str_new_cstr().
|
static |
Definition at line 16360 of file ripper.c.
References cond, FALSE, nd_type, NODE_AND, NODE_BEGIN, NODE_BLOCK, NODE_BREAK, NODE_IF, NODE_NEXT, NODE_OR, NODE_REDO, NODE_RETRY, NODE_RETURN, rb_warning0, TRUE, value_expr, and yyerror.
|
static |
Definition at line 16417 of file ripper.c.
References nd_line, nd_type, NODE_BACK_REF, NODE_CALL, NODE_COLON2, NODE_COLON3, NODE_CONST, NODE_CVAR, NODE_DEFINED, NODE_DOT2, NODE_DOT3, NODE_DREGX, NODE_DREGX_ONCE, NODE_DSTR, NODE_DVAR, NODE_FALSE, NODE_GVAR, NODE_IVAR, NODE_LIT, NODE_LVAR, NODE_NIL, NODE_NTH_REF, NODE_SELF, NODE_STR, NODE_TRUE, rb_id2name(), rb_warn1L, RTEST, ruby_verbose, tCMP, tEQ, tGEQ, tLEQ, tNEQ, tPOW, tUMINUS, tUPLUS, and WARN_S.
|
static |
Definition at line 16502 of file ripper.c.
References nd_type, NODE_BLOCK, RTEST, ruby_verbose, and void_expr0.
Definition at line 251 of file ripper.c.
References id, POINTER_P, PRIsVALUE, rb_bug(), rb_id2str, REALLOC_N, and VTBL_DEBUG.
Referenced by arg_var_gen(), local_var_gen(), new_args_tail_gen(), and shadowing_lvar_0().
Definition at line 227 of file ripper.c.
References ALLOC, ALLOC_N, vtable::capa, vtable::pos, vtable::prev, vtable::tbl, and VTBL_DEBUG.
Referenced by dyna_push_gen(), local_push_gen(), and new_args_tail_gen().
|
static |
Definition at line 239 of file ripper.c.
References POINTER_P, VTBL_DEBUG, and xfree().
Referenced by dyna_pop_1(), dyna_pop_vtable(), local_pop_gen(), and new_args_tail_gen().
Definition at line 275 of file ripper.c.
References POINTER_P, vtable::pos, and vtable::tbl.
Referenced by dvar_curr_gen(), dvar_defined_gen(), local_id_gen(), local_tbl_gen(), and match_op_gen().
|
static |
Definition at line 267 of file ripper.c.
References vtable::pos, and rb_bug().
Referenced by new_args_tail_gen().
Definition at line 214 of file ripper.c.
References POINTER_P, and vtable::pos.
Referenced by internal_id_gen(), local_tbl_gen(), and new_args_tail_gen().
|
static |
Definition at line 16645 of file ripper.c.
References e_option_supplied(), and parser_warn.
Referenced by cond0(), and range_op().
|
static |
Definition at line 17148 of file ripper.c.
References cnt, is_private_local_id(), LVAR_USED, vtable::pos, PRIsWARN, rb_bug(), rb_id2str, rb_warn1L, vtable::tbl, local_vars::used, and local_vars::vars.
Referenced by dyna_pop_1(), and local_pop_gen().
|
static |
Definition at line 16651 of file ripper.c.
References cond0(), e_option_supplied(), and parser_warning.
Referenced by cond0().
|
static |
Definition at line 4912 of file ripper.c.
References yy_symbol_print(), and YYFPRINTF.
|
static |
|
static |
Definition at line 4854 of file ripper.c.
References yy_stack_print(), yy_symbol_value_print(), YYFPRINTF, and YYNTOKENS.
Referenced by yy_reduce_print(), and yy_symbol_value_print().
|
static |
Definition at line 4820 of file ripper.c.
References yy_symbol_print(), YYNTOKENS, and YYUSE.
Referenced by yy_symbol_print().
|
static |
Definition at line 12257 of file ripper.c.
References rb_str_new_frozen(), rb_suppress_tracing(), RSTRING_PTR, ruby_sourcefile, ruby_sourcefile_string, ruby_sourceline, and yycompile0().
Referenced by parser_compile_string(), and rb_parser_compile_file_path().
Definition at line 12194 of file ripper.c.
References compile_for_eval, coverage(), debug_lines(), e_option_supplied(), END, lex_lastline, lex_nextline, lex_p, lex_pbeg, lex_pend, lex_strterm, NEW_NIL, NEW_PRELUDE, parser_prepare(), Qfalse, Qtrue, rb_ary_push(), rb_class_new_instance(), rb_eSyntaxError, rb_hash_aset(), rb_ident_hash_new(), rb_obj_hide(), rb_safe_level(), rb_set_errinfo(), rb_sym_intern_ascii_cstr(), ruby_coverage, ruby_debug_lines, RUBY_DTRACE_PARSE_HOOK, ruby_eval_tree, ruby_eval_tree_begin, ruby_sourcefile_string, ruby_sourceline, STR_NEW0, and yyparse.
Referenced by yycompile().
|
static |
Definition at line 5219 of file ripper.c.
References YY_SYMBOL_PRINT, yyparse, and YYUSE.
Referenced by yyparse(), and yysyntax_error().
|
static |
Definition at line 15494 of file ripper.c.
References dispatch_delayed_token, dispatch_scan_event, has_delayed_token, parser_params::lval, parser_yylex(), Qundef, and YYSTYPE::val.
int yyparse | ( | ) |
int yyparse | ( | struct parser_params * | parser | ) |
Definition at line 5279 of file ripper.c.
References alias, ALLOC_N, arg_append, arg_blk_pass(), arg_concat, arg_var, aryset, assignable, attrset, backref_assign_error, block_append, block_dup_check, brace_nest, buf, call_bin_op, call_uni_op, CMDARG_LEXPOP, CMDARG_PUSH, CMDARG_SET, cmdarg_stack, command_start, compile_error, compile_for_eval, cond, COND_POP, COND_PUSH, COND_SET, cond_stack, const_decl, const_path_field, current_arg, dsym_node, dyna_in_block, dyna_pop, dyna_push, END, evstr2dstr, fixpos(), formal_argument, get_id, get_value, gettable, hash(), heredoc_dedent, heredoc_indent, heredoc_line_indent, YYSTYPE::id, id, ID2SYM, idANDDOT, idANDOP, idCmp, idCOLON2, idEq, idEqq, idEqTilde, idGE, idGTGT, idLE, idLTLT, idNeq, idNeqTilde, idOROP, idPow, idUMinus, idUPlus, ifndef_ripper, in_def, in_defined, parser_params::in_kwarg, in_main, in_single, internal_id, is_local_id, keyword__ENCODING__, keyword__FILE__, keyword__LINE__, keyword_false, keyword_nil, keyword_self, keyword_true, kwd_append(), lex_state, lex_strterm, list_append, list_concat(), literal_concat, local_id, local_pop, local_push, logop, lpar_beg, match_op, method_cond, METHOD_VISI_PRIVATE, nd_args, nd_head, nd_iter, nd_lit, nd_next, nd_plen, nd_set_line, nd_set_type, nd_type, nd_value, negate_lit(), NEW_ALIAS, new_args, NEW_ARGS_AUX, new_args_tail, NEW_ARGSCAT, new_attr_op_assign, NEW_BEGIN, NEW_BLOCK_PASS, new_brace_body, NEW_BREAK, new_bv, NEW_CALL, NEW_CASE, NEW_CLASS, NEW_COLON2, NEW_COLON3, new_const_op_assign, NEW_CVAR, new_defined, NEW_DEFN, NEW_DEFS, new_do_body, NEW_DOT2, NEW_DOT3, NEW_DSTR, NEW_DVAR, NEW_ENSURE, NEW_ERRINFO, NEW_EVSTR, new_evstr, NEW_FCALL, NEW_FOR, NEW_GVAR, new_hash, new_if, NEW_IVAR, new_kw_arg, NEW_LAMBDA, NEW_LIST, NEW_LIT, NEW_LVAR, NEW_MASGN, NEW_MODULE, NEW_NEXT, NEW_NIL, NEW_NODE, NEW_OP_ASGN1, new_op_assign, NEW_OPT_ARG, NEW_POSTARG, NEW_POSTEXE, NEW_QCALL, NEW_REDO, new_regexp, NEW_RESBODY, NEW_RESCUE, NEW_RETRY, NEW_RETURN, NEW_SCLASS, NEW_SCOPE, NEW_SPLAT, NEW_STR, new_string1, NEW_SUPER, NEW_UNDEF, new_unless, NEW_UNTIL, NEW_VALIAS, NEW_WHEN, NEW_WHILE, new_xstring, NEW_YIELD, new_yield, NEW_ZARRAY, NEW_ZSUPER, newline_node(), YYSTYPE::node, NODE_AND, NODE_ARRAY, node_assign, NODE_BEGIN, NODE_BLOCK, NODE_BLOCK_PASS, NODE_DASGN, NODE_DASGN_CURR, NODE_DREGX, NODE_DSTR, NODE_DSYM, NODE_DXSTR, NODE_ENSURE, NODE_FL_NEWLINE, NODE_HASH, NODE_LASGN, NODE_LIT, NODE_MASGN, NODE_OR, NODE_RESCUE, NODE_SCOPE, NODE_SELF, NODE_STR, NODE_XSTR, NODE_YIELD, NODE_ZARRAY, NULL, YYSTYPE::num, paren_nest, PARSER_ARG, parser_yyerror(), Qnil, Qnone, Qundef, rb_ary_new3, rb_ary_push(), rb_assoc_new(), rb_fstring(), rb_gc_force_recycle(), rb_intern2(), rb_intern_str, rb_str_intern(), RB_TYPE_P, rb_warn0, reduce_nodes, reg_named_capture_assign, remove_begin(), ret_args, ripper_id2sym, RNODE, ruby_eval_tree, ruby_eval_tree_begin, ruby_sourceline, SET_LEX_STATE, shadowing_lvar, splat_array(), STR_NEW0, T_REGEXP, tANDDOT, tANDOP, tAREF, tASET, vtable::tbl, tCMP, tCOLON2, tDSTAR, tEQ, tEQQ, tGEQ, tLEQ, tLSHFT, tMATCH, tNEQ, tNMATCH, token_info_pop, token_info_push, tokline, top_const_field, tOROP, tPOW, tRSHFT, TRUE, tUMINUS, tUPLUS, YYSTYPE::val, val, value_expr, var_field, YYSTYPE::vars, void_expr, void_stmts, YY_, YY_REDUCE_PRINT, YY_STACK_PRINT, YY_SYMBOL_PRINT, YYABORT, YYACCEPT, yydestruct(), YYDPRINTF, YYEMPTY, YYEOF, yyerrok, yyerror, YYFINAL, YYID, YYINITDEPTH, YYLAST, YYLEX, yylval, YYMAXDEPTH, YYNTOKENS, yypact_value_is_default, YYPOPSTACK, YYSIZE_T, yyalloc::yyss_alloc, YYSTACK_ALLOC, YYSTACK_BYTES, YYSTACK_FREE, YYSTACK_RELOCATE, YYSYNTAX_ERROR, yytable_value_is_error, YYTERROR, YYTRANSLATE, and yyalloc::yyvs_alloc.
|
static |
Definition at line 5007 of file ripper.c.
References YYSIZE_T.
Referenced by yystrlen(), and yytnamerr().
|
static |
Definition at line 4983 of file ripper.c.
References YYSIZE_T, and yystpcpy().
Referenced by yysyntax_error(), and yytnamerr().
|
static |
Definition at line 5080 of file ripper.c.
References YY_, YYCASE_, yydestruct(), YYEMPTY, YYLAST, YYNTOKENS, yypact_value_is_default, YYSIZE_T, YYSTACK_ALLOC_MAXIMUM, yystrlen(), yytable_value_is_error, YYTERROR, and yytnamerr().
Definition at line 5032 of file ripper.c.
References YYSIZE_T, yystpcpy(), and yystrlen().
Referenced by yysyntax_error().
|
static |
|
static |
Definition at line 13852 of file ripper.c.
Referenced by parser_magic_comment().
|
static |
const unsigned int ruby_global_name_punct_bits |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |