mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
codegen.c: stop peephole optimization for headless case statement.
This fixes #5815
This commit is contained in:
@@ -2623,7 +2623,7 @@ codegen(codegen_scope *s, node *tree, int val)
|
||||
else {
|
||||
pop();
|
||||
}
|
||||
tmp = genjmp2(s, OP_JMPIF, cursp(), pos2, NOVAL);
|
||||
tmp = genjmp2(s, OP_JMPIF, cursp(), pos2, !head);
|
||||
pos2 = tmp;
|
||||
n = n->cdr;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user