Adjust stack position of NODE_RESCUE.

This commit is contained in:
Masamitsu MURASE
2013-02-25 00:20:10 +09:00
parent bbd50cca2f
commit c6d2cde148
+4
View File
@@ -1083,6 +1083,7 @@ codegen(codegen_scope *s, node *tree, int val)
}
if (n3->cdr->cdr->car) {
codegen(s, n3->cdr->cdr->car, val);
if (val) pop();
}
tmp = new_label(s);
genop(s, MKOP_sBx(OP_JMP, exend));
@@ -1102,6 +1103,9 @@ codegen(codegen_scope *s, node *tree, int val)
if (tree->car) {
codegen(s, tree->car, val);
}
else if (val) {
push();
}
dispatch_linked(s, exend);
loop_pop(s, NOVAL);
}