parse.y: revert 9e064f2; fix #5647

Need to declare unnamed parameter when argument decomposition used.
This commit is contained in:
Yukihiro "Matz" Matsumoto
2022-02-16 13:54:19 +09:00
parent 1e0bdea30b
commit a8f0e79107
2 changed files with 1629 additions and 1611 deletions
+9 -2
View File
@@ -2962,6 +2962,7 @@ f_margs : f_arg
}
| f_arg ',' tSTAR
{
local_add_f(p, intern_op(mul));
$$ = list3($1, nint(-1), 0);
}
| f_arg ',' tSTAR ',' f_arg
@@ -2978,11 +2979,16 @@ f_margs : f_arg
}
| tSTAR
{
local_add_f(p, intern_op(mul));
$$ = list3(0, nint(-1), 0);
}
| tSTAR ',' f_arg
| tSTAR ','
{
$$ = list3(0, nint(-1), $3);
local_add_f(p, intern_op(mul));
}
f_arg
{
$$ = list3(0, nint(-1), $4);
}
;
@@ -3864,6 +3870,7 @@ f_arg_item : f_norm_arg
{
$$ = new_masgn_param(p, $3, p->locals->car);
local_resume(p, $<nd>2);
local_add_f(p, 0);
}
;
File diff suppressed because it is too large Load Diff