mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
eliminate unused hash expression more aggresively
This commit is contained in:
+3
-3
@@ -1327,13 +1327,13 @@ codegen(codegen_scope *s, node *tree, int val)
|
||||
int len = 0;
|
||||
|
||||
while (tree) {
|
||||
codegen(s, tree->car->car, VAL);
|
||||
codegen(s, tree->car->cdr, VAL);
|
||||
codegen(s, tree->car->car, val);
|
||||
codegen(s, tree->car->cdr, val);
|
||||
len++;
|
||||
tree = tree->cdr;
|
||||
}
|
||||
pop_n(len*2);
|
||||
if (val) {
|
||||
pop_n(len*2);
|
||||
genop(s, MKOP_ABC(OP_HASH, cursp(), cursp(), len));
|
||||
push();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user