summaryrefslogtreecommitdiff
path: root/src/wasm-linker.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/wasm-linker.cpp')
-rw-r--r--src/wasm-linker.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/wasm-linker.cpp b/src/wasm-linker.cpp
index 757fc88ca..c2fc00562 100644
--- a/src/wasm-linker.cpp
+++ b/src/wasm-linker.cpp
@@ -82,11 +82,12 @@ void Linker::layout() {
// behavior.
for (auto* call : f.second) {
auto type = call->type;
- auto operands = std::move(call->operands);
+ ExpressionList operands(out.wasm.allocator);
+ operands.swap(call->operands);
auto target = call->target;
CallImport* newCall = ExpressionManipulator::convert<Call, CallImport>(call, out.wasm.allocator);
newCall->type = type;
- newCall->operands = std::move(operands);
+ newCall->operands.swap(operands);
newCall->target = target;
}
}