summaryrefslogtreecommitdiff
path: root/src/wasm-validator.h
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2016-07-20 21:31:46 -0700
committerGitHub <noreply@github.com>2016-07-20 21:31:46 -0700
commit12abb63203788cba23f5c65a971a2af922e05bfc (patch)
tree47160f540810e408ccd74ae8e4b422afaf59e0fb /src/wasm-validator.h
parent5e9058c9b108298406da7474c524e8d452431710 (diff)
parentfa60ade30e03c6a13bbce26ff81c03ed1ae4da0b (diff)
downloadbinaryen-12abb63203788cba23f5c65a971a2af922e05bfc.tar.gz
binaryen-12abb63203788cba23f5c65a971a2af922e05bfc.tar.bz2
binaryen-12abb63203788cba23f5c65a971a2af922e05bfc.zip
Merge pull request #648 from WebAssembly/relooper-opts
Relooper improvements
Diffstat (limited to 'src/wasm-validator.h')
-rw-r--r--src/wasm-validator.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/wasm-validator.h b/src/wasm-validator.h
index b9ad30c73..066ab57da 100644
--- a/src/wasm-validator.h
+++ b/src/wasm-validator.h
@@ -312,7 +312,12 @@ public:
void doWalkFunction(Function* func) {
PostWalker<WasmValidator, Visitor<WasmValidator>>::doWalkFunction(func);
- shouldBeTrue(breakTypes.size() == 0, "break targets", "all break targets must be valid");
+ if (!shouldBeTrue(breakTypes.size() == 0, "break targets", "all break targets must be valid")) {
+ for (auto& target : breakTypes) {
+ std::cerr << " - " << target.first << '\n';
+ }
+ breakTypes.clear();
+ }
}
private: