From 0ec2b20d2f1339ab1e4d41567f9b37d733802968 Mon Sep 17 00:00:00 2001 From: ko1 Date: Sat, 7 Jul 2007 07:16:05 +0000 Subject: * parse.y: fix node construction (around f_margs). [ruby-dev:31143] * bootstraptest/test_block.rb: add a test for above. * insnhelper.ci: fix indent. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12720 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- parse.y | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'parse.y') diff --git a/parse.y b/parse.y index d24cf06157..bb39af8e30 100644 --- a/parse.y +++ b/parse.y @@ -3003,7 +3003,7 @@ f_marg : f_norm_arg | tLPAREN f_margs rparen { /*%%%*/ - $$ = $2; + $$ = NEW_LIST($2); /*% $$ = dispatch1(mlhs_paren, $2); %*/ @@ -3013,7 +3013,7 @@ f_marg : f_norm_arg f_marg_head : f_marg { /*%%%*/ - $$ = NEW_LIST($1); + $$ = $1; /*% $$ = mlhs_add(mlhs_new(), $1); %*/ @@ -3047,7 +3047,7 @@ f_margs : f_marg_head | f_marg_head ',' tSTAR f_norm_arg ',' f_marg { /*%%%*/ - $$ = NEW_MASGN($1, NEW_POSTARG($4,$6)); + $$ = NEW_MASGN($1, NEW_POSTARG(assignable($4, 0), $6)); /*% $$ = mlhs_add_star($1, $4); %*/ @@ -3063,7 +3063,7 @@ f_margs : f_marg_head | f_marg_head ',' tSTAR ',' f_marg { /*%%%*/ - $$ = NEW_MASGN($1, NEW_POSTARG(-1,$5)); + $$ = NEW_MASGN($1, NEW_POSTARG(-1, $5)); /*% $$ = mlhs_add_star($1, $5); %*/ -- cgit v1.2.3