summaryrefslogtreecommitdiff
path: root/src/wasm/wasm-binary.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/wasm/wasm-binary.cpp')
-rw-r--r--src/wasm/wasm-binary.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wasm/wasm-binary.cpp b/src/wasm/wasm-binary.cpp
index 7a459eb7f..f70f74c56 100644
--- a/src/wasm/wasm-binary.cpp
+++ b/src/wasm/wasm-binary.cpp
@@ -2375,7 +2375,7 @@ void WasmBinaryBuilder::visitBlock(Block *curr) {
throw ParseException("block cannot pop from outside");
}
pushBlockElements(curr, start, end);
- curr->finalize(curr->type);
+ curr->finalize(curr->type, breakTargetNames.find(curr->name) != breakTargetNames.end() /* hasBreak */);
breakStack.pop_back();
breakTargetNames.erase(curr->name);
}