summaryrefslogtreecommitdiff
path: root/src/asm2wasm.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/asm2wasm.h')
-rw-r--r--src/asm2wasm.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/asm2wasm.h b/src/asm2wasm.h
index 1c528d7f3..e926e381f 100644
--- a/src/asm2wasm.h
+++ b/src/asm2wasm.h
@@ -797,13 +797,17 @@ void Asm2WasmBuilder::processAsm(Ref ast) {
switch (curr->type) {
case i32: replaceCurrent(parent->builder.makeUnary(TruncSFloat64ToInt32, curr)); break;
case f32: replaceCurrent(parent->builder.makeUnary(DemoteFloat64, curr)); break;
- case none: replaceCurrent(parent->builder.makeDrop(curr)); break;
+ case none: {
+ // this function returns a value, but we are not using it, so it must be dropped.
+ // autodrop will do that for us.
+ break;
+ }
default: WASM_UNREACHABLE();
}
} else {
assert(curr->type == none);
// we don't want a return value here, but the import does provide one
- replaceCurrent(parent->builder.makeDrop(curr));
+ // autodrop will do that for us.
}
curr->type = importResult;
}