Skip to content

Commit 73dd82e

Browse files
committed
parse.y: lparen_arg statement
allow parenthesised statement as a method argument. reported [Feature:12686] in bugs.ruby-lang.org fixed in CRuby 2.4.
1 parent 0597f66 commit 73dd82e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

mrbgems/mruby-compiler/core/parse.y

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2090,7 +2090,7 @@ primary : literal
20902090
$<stack>$ = p->cmdarg_stack;
20912091
p->cmdarg_stack = 0;
20922092
}
2093-
expr {p->lstate = EXPR_ENDARG;} rparen
2093+
stmt {p->lstate = EXPR_ENDARG;} rparen
20942094
{
20952095
p->cmdarg_stack = $<stack>2;
20962096
$$ = $3;

0 commit comments

Comments
 (0)