Skip to content

Commit

Permalink
Update NODE_BLOCK check logic in void_expr_error.
Browse files Browse the repository at this point in the history
  • Loading branch information
matz committed Jun 2, 2017
1 parent 563036e commit 31e3068
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions mrbgems/mruby-compiler/core/parse.y
Expand Up @@ -3474,12 +3474,11 @@ void_expr_error(parser_state *p, node *n)
void_expr_error(p, n->cdr->cdr);
break;
case NODE_BEGIN:
if (n->cdr) {
while (n->cdr) {
n = n->cdr;
}
void_expr_error(p, n->car);
n = n->cdr;
while (n->cdr) {
n = n->cdr;
}
void_expr_error(p, n->car);
break;
default:
break;
Expand Down

0 comments on commit 31e3068

Please sign in to comment.