mirror of
https://github.com/ruby/ruby.git
synced 2025-09-15 16:44:01 +02:00
merge revision(s) 3d19409637
: [Backport #20090]
Use index for referring to symbols in `args` rule instead of named references In `args: args ',' arg_splat`, `args` is not unique name. Currently the associated rule is interpreted as `$$ = rest_arg_append(p, $$, $3, &@$);`. The action works as expected because `$$` is initialized with `$1` before each action is executed. However it's misleading then change to use index. --- parse.y | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
This commit is contained in:
parent
9f18cbd796
commit
f8f0d342e4
2 changed files with 3 additions and 3 deletions
4
parse.y
4
parse.y
|
@ -3800,9 +3800,9 @@ args : arg_value
|
||||||
| args ',' arg_splat
|
| args ',' arg_splat
|
||||||
{
|
{
|
||||||
/*%%%*/
|
/*%%%*/
|
||||||
$$ = rest_arg_append(p, $args, $arg_splat, &@$);
|
$$ = rest_arg_append(p, $1, $3, &@$);
|
||||||
/*% %*/
|
/*% %*/
|
||||||
/*% ripper: args_add_star!($args, $arg_splat) %*/
|
/*% ripper: args_add_star!($1, $3) %*/
|
||||||
}
|
}
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|
|
@ -11,7 +11,7 @@
|
||||||
# define RUBY_VERSION_MINOR RUBY_API_VERSION_MINOR
|
# define RUBY_VERSION_MINOR RUBY_API_VERSION_MINOR
|
||||||
#define RUBY_VERSION_TEENY 0
|
#define RUBY_VERSION_TEENY 0
|
||||||
#define RUBY_RELEASE_DATE RUBY_RELEASE_YEAR_STR"-"RUBY_RELEASE_MONTH_STR"-"RUBY_RELEASE_DAY_STR
|
#define RUBY_RELEASE_DATE RUBY_RELEASE_YEAR_STR"-"RUBY_RELEASE_MONTH_STR"-"RUBY_RELEASE_DAY_STR
|
||||||
#define RUBY_PATCHLEVEL 2
|
#define RUBY_PATCHLEVEL 3
|
||||||
|
|
||||||
#include "ruby/version.h"
|
#include "ruby/version.h"
|
||||||
#include "ruby/internal/abi.h"
|
#include "ruby/internal/abi.h"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue