mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
parse.y: skip unnecessary local_add_f(p, 0).
This commit is contained in:
@@ -2954,7 +2954,6 @@ f_margs : f_arg
|
||||
}
|
||||
| f_arg ',' tSTAR
|
||||
{
|
||||
local_add_f(p, 0);
|
||||
$$ = list3($1, nint(-1), 0);
|
||||
}
|
||||
| f_arg ',' tSTAR ',' f_arg
|
||||
@@ -2971,16 +2970,11 @@ f_margs : f_arg
|
||||
}
|
||||
| tSTAR
|
||||
{
|
||||
local_add_f(p, 0);
|
||||
$$ = list3(0, nint(-1), 0);
|
||||
}
|
||||
| tSTAR ','
|
||||
| tSTAR ',' f_arg
|
||||
{
|
||||
local_add_f(p, 0);
|
||||
}
|
||||
f_arg
|
||||
{
|
||||
$$ = list3(0, nint(-1), $4);
|
||||
$$ = list3(0, nint(-1), $3);
|
||||
}
|
||||
;
|
||||
|
||||
@@ -3861,7 +3855,6 @@ f_arg_item : f_norm_arg
|
||||
{
|
||||
$$ = new_masgn_param(p, $3, p->locals->car);
|
||||
local_resume(p, $<nd>2);
|
||||
local_add_f(p, 0);
|
||||
}
|
||||
;
|
||||
|
||||
|
||||
+1570
-1581
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user