diff options
Diffstat (limited to 'src/wasm-s-parser.h')
-rw-r--r-- | src/wasm-s-parser.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/wasm-s-parser.h b/src/wasm-s-parser.h index 1c704ac74..e2a880e51 100644 --- a/src/wasm-s-parser.h +++ b/src/wasm-s-parser.h @@ -283,6 +283,7 @@ private: void parseModuleElement(Element& curr) { IString id = curr[0]->str(); + if (id == START) return parseStart(curr); if (id == FUNC) return parseFunction(curr); if (id == MEMORY) return parseMemory(curr); if (id == EXPORT) return parseExport(curr); @@ -304,6 +305,8 @@ private: return IString((prefix + std::to_string(otherIndex++)).c_str(), false); } + void parseStart(Element& s) { wasm.addStart(s[1]->str()); } + void parseFunction(Element& s) { auto func = currFunction = allocator.alloc<Function>(); size_t i = 1; |