From 031c55702bd3770cbf014b7f834e8765dd22a158 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Wed, 1 Jun 2016 11:11:25 -0700 Subject: note default in type checking of switches --- src/wasm.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/wasm.cpp') diff --git a/src/wasm.cpp b/src/wasm.cpp index d00ddd42f..48a0f276a 100644 --- a/src/wasm.cpp +++ b/src/wasm.cpp @@ -40,6 +40,7 @@ struct TypeSeeker : public PostWalker> { for (auto name : curr->targets) { if (name == targetName) types.push_back(curr->value ? curr->value->type : none); } + if (curr->default_ == targetName) types.push_back(curr->value ? curr->value->type : none); } void visitBlock(Block* curr) { -- cgit v1.2.3