diff options
author | Daniel Wirtz <dcode@dcode.io> | 2020-09-14 11:51:59 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-14 11:51:59 +0200 |
commit | 18716065cc470c3bc29a4fecf3889891a9bf604b (patch) | |
tree | f106abf584fcc2ab1e14320682962326357479e8 /src/wasm-s-parser.h | |
parent | 0ade3f2761b0661ab4d1290ab704c594c1d90df9 (diff) | |
download | binaryen-18716065cc470c3bc29a4fecf3889891a9bf604b.tar.gz binaryen-18716065cc470c3bc29a4fecf3889891a9bf604b.tar.bz2 binaryen-18716065cc470c3bc29a4fecf3889891a9bf604b.zip |
Implement module and local names in name section (#3115)
Adds support for the module and local subsections of the name section plus the respective C and JS APIs to populate and obtain local names.
C API:
* BinaryenFunctionGetNumLocals(func)
* BinaryenFunctionHasLocalName(func, index)
* BinaryenFunctionGetLocalName(func, index)
* BinaryenFunctionSetLocalName(func, index, name)
JS API:
* Function.getNumLocals(func)
* Function.hasLocalName(func, index)
* Function.getLocalName(func, index)
* Function.setLocalName(func, index, name)
Diffstat (limited to 'src/wasm-s-parser.h')
-rw-r--r-- | src/wasm-s-parser.h | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/wasm-s-parser.h b/src/wasm-s-parser.h index a4559012d..85ca217e7 100644 --- a/src/wasm-s-parser.h +++ b/src/wasm-s-parser.h @@ -126,10 +126,7 @@ class SExpressionWasmBuilder { public: // Assumes control of and modifies the input. - SExpressionWasmBuilder(Module& wasm, - Element& module, - IRProfile profile, - Name* moduleName = nullptr); + SExpressionWasmBuilder(Module& wasm, Element& module, IRProfile profile); private: // pre-parse types and function definitions, so we know function return types |