mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Refined argument name
This commit is contained in:
parent
6df8cfb771
commit
07f27383b7
1 changed files with 3 additions and 3 deletions
6
parse.y
6
parse.y
|
@ -11306,7 +11306,7 @@ new_args(struct parser_params *p, NODE *pre_args, NODE *opt_args, ID rest_arg, N
|
|||
}
|
||||
|
||||
static NODE*
|
||||
new_args_tail(struct parser_params *p, NODE *kw_args, ID kw_rest_arg, ID block, const YYLTYPE *loc)
|
||||
new_args_tail(struct parser_params *p, NODE *kw_args, ID kw_rest_arg, ID block, const YYLTYPE *kw_rest_loc)
|
||||
{
|
||||
int saved_line = p->ruby_sourceline;
|
||||
NODE *node;
|
||||
|
@ -11355,14 +11355,14 @@ new_args_tail(struct parser_params *p, NODE *kw_args, ID kw_rest_arg, ID block,
|
|||
if (kw_rest_arg) arg_var(p, kw_rest_arg);
|
||||
if (block) arg_var(p, block);
|
||||
|
||||
args->kw_rest_arg = NEW_DVAR(kw_rest_arg, loc);
|
||||
args->kw_rest_arg = NEW_DVAR(kw_rest_arg, kw_rest_loc);
|
||||
args->kw_rest_arg->nd_cflag = kw_bits;
|
||||
}
|
||||
else if (kw_rest_arg == idNil) {
|
||||
args->no_kwarg = 1;
|
||||
}
|
||||
else if (kw_rest_arg) {
|
||||
args->kw_rest_arg = NEW_DVAR(kw_rest_arg, loc);
|
||||
args->kw_rest_arg = NEW_DVAR(kw_rest_arg, kw_rest_loc);
|
||||
}
|
||||
|
||||
p->ruby_sourceline = saved_line;
|
||||
|
|
Loading…
Reference in a new issue