diff --git a/parse.y b/parse.y index d6645c5f4f..df07940d76 100644 --- a/parse.y +++ b/parse.y @@ -767,7 +767,7 @@ static void token_info_pop(struct parser_params*, const char *token); %type args call_args opt_call_args %type paren_args opt_paren_args args_tail opt_args_tail block_args_tail opt_block_args_tail %type command_args aref_args opt_block_arg block_arg var_ref var_lhs -%type command_asgn mrhs superclass block_call block_command +%type command_asgn mrhs mrhs_arg superclass block_call block_command %type f_block_optarg f_block_opt %type f_arglist f_args f_arg f_arg_item f_optarg f_marg f_marg_list f_margs %type assoc_list assocs assoc undef_list backref string_dvar for_var @@ -1238,16 +1238,7 @@ stmt : keyword_alias fitem {lex_state = EXPR_FNAME;} fitem $$ = dispatch2(assign, $1, $3); %*/ } - | mlhs '=' arg_value - { - /*%%%*/ - $1->nd_value = $3; - $$ = $1; - /*% - $$ = dispatch2(massign, $1, $3); - %*/ - } - | mlhs '=' mrhs + | mlhs '=' mrhs_arg { /*%%%*/ $1->nd_value = $3; @@ -2528,6 +2519,10 @@ args : arg_value } ; +mrhs_arg : mrhs + | arg_value + ; + mrhs : args ',' arg_value { /*%%%*/