diff --git a/ChangeLog b/ChangeLog index 85ca8029f1..841e686086 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Tue Oct 7 04:15:25 2003 Nobuyoshi Nakada + + * parse.y (stmt): should not expand mrhs if lhs is solely starred. + Tue Oct 7 02:57:53 2003 Yukihiro Matsumoto * parse.y (stmt): rhs of multiple assignment should not be diff --git a/parse.y b/parse.y index 59ef2a891f..93d395717e 100644 --- a/parse.y +++ b/parse.y @@ -486,7 +486,7 @@ stmt : kALIAS fitem {lex_state = EXPR_FNAME;} fitem | mlhs '=' command_call { value_expr($3); - $1->nd_value = NEW_TO_ARY($3); + $1->nd_value = ($1->nd_head) ? NEW_TO_ARY($3) : NEW_ARRAY($3); $$ = $1; } | var_lhs tOP_ASGN command_call @@ -578,7 +578,7 @@ stmt : kALIAS fitem {lex_state = EXPR_FNAME;} fitem } | mlhs '=' arg_value { - $1->nd_value = NEW_TO_ARY($3); + $1->nd_value = ($1->nd_head) ? NEW_TO_ARY($3) : NEW_ARRAY($3); $$ = $1; } | mlhs '=' mrhs