Use callee side tag specification of parameterizing rules

This commit is contained in:
ydah 2024-09-24 22:09:42 +09:00 committed by Yudai Takada
parent 1e2ed31cc2
commit aa892378a1
Notes: git 2025-01-03 12:20:34 +00:00

10
parse.y
View File

@ -2965,7 +2965,7 @@ rb_parser_ary_free(rb_parser_t *p, rb_parser_ary_t *ary)
} }
; ;
%rule words(begin, word_list) %rule words(begin, word_list) <node>
: begin ' '+ word_list tSTRING_END : begin ' '+ word_list tSTRING_END
{ {
$$ = make_list($word_list, &@$); $$ = make_list($word_list, &@$);
@ -6038,7 +6038,7 @@ regexp : tREGEXP_BEG regexp_contents tREGEXP_END
} }
; ;
words : words(tWORDS_BEG, word_list) <node> words : words(tWORDS_BEG, word_list)
; ;
word_list : /* none */ word_list : /* none */
@ -6062,7 +6062,7 @@ word : string_content
} }
; ;
symbols : words(tSYMBOLS_BEG, symbol_list) <node> symbols : words(tSYMBOLS_BEG, symbol_list)
; ;
symbol_list : /* none */ symbol_list : /* none */
@ -6077,10 +6077,10 @@ symbol_list : /* none */
} }
; ;
qwords : words(tQWORDS_BEG, qword_list) <node> qwords : words(tQWORDS_BEG, qword_list)
; ;
qsymbols : words(tQSYMBOLS_BEG, qsym_list) <node> qsymbols : words(tQSYMBOLS_BEG, qsym_list)
; ;
qword_list : /* none */ qword_list : /* none */