diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/s2wasm.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/s2wasm.h b/src/s2wasm.h index 8dac81b4c..a1805e659 100644 --- a/src/s2wasm.h +++ b/src/s2wasm.h @@ -695,6 +695,15 @@ private: curr->value = getInput(); } bstack.back()->list.push_back(curr); + } else if (match("tableswitch")) { + auto curr = allocator.alloc<Switch>(); + curr->value = getInput(); + skipComma(); + curr->default_ = getCommaSeparated(); + while (skipComma()) { + curr->targets.push_back(getCommaSeparated()); + } + bstack.back()->list.push_back(curr); } else if (match("unreachable")) { bstack.back()->list.push_back(allocator.alloc<Unreachable>()); } else if (match("memory_size")) { |