* parse.y (stmt): should not expand mrhs if lhs is solely starred.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4711 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
8a4abe47ca
commit
6fc88be3d9
@ -1,3 +1,7 @@
|
|||||||
|
Tue Oct 7 04:15:25 2003 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
|
* parse.y (stmt): should not expand mrhs if lhs is solely starred.
|
||||||
|
|
||||||
Tue Oct 7 02:57:53 2003 Yukihiro Matsumoto <matz@ruby-lang.org>
|
Tue Oct 7 02:57:53 2003 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||||
|
|
||||||
* parse.y (stmt): rhs of multiple assignment should not be
|
* parse.y (stmt): rhs of multiple assignment should not be
|
||||||
|
4
parse.y
4
parse.y
@ -486,7 +486,7 @@ stmt : kALIAS fitem {lex_state = EXPR_FNAME;} fitem
|
|||||||
| mlhs '=' command_call
|
| mlhs '=' command_call
|
||||||
{
|
{
|
||||||
value_expr($3);
|
value_expr($3);
|
||||||
$1->nd_value = NEW_TO_ARY($3);
|
$1->nd_value = ($1->nd_head) ? NEW_TO_ARY($3) : NEW_ARRAY($3);
|
||||||
$$ = $1;
|
$$ = $1;
|
||||||
}
|
}
|
||||||
| var_lhs tOP_ASGN command_call
|
| var_lhs tOP_ASGN command_call
|
||||||
@ -578,7 +578,7 @@ stmt : kALIAS fitem {lex_state = EXPR_FNAME;} fitem
|
|||||||
}
|
}
|
||||||
| mlhs '=' arg_value
|
| mlhs '=' arg_value
|
||||||
{
|
{
|
||||||
$1->nd_value = NEW_TO_ARY($3);
|
$1->nd_value = ($1->nd_head) ? NEW_TO_ARY($3) : NEW_ARRAY($3);
|
||||||
$$ = $1;
|
$$ = $1;
|
||||||
}
|
}
|
||||||
| mlhs '=' mrhs
|
| mlhs '=' mrhs
|
||||||
|
Loading…
x
Reference in New Issue
Block a user