diff options
author | Max Graey <maxgraey@gmail.com> | 2021-10-09 05:26:08 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-08 19:26:08 -0700 |
commit | ef686a4d932b9b86edc34a3b9b15926f943f6f7b (patch) | |
tree | 38a89d5b555d4501b7d504a66c7aec409e45e9b1 /src/wasm.h | |
parent | 53c5e3e62db25fe3522a1fa615a1f53c4cefdf06 (diff) | |
download | binaryen-ef686a4d932b9b86edc34a3b9b15926f943f6f7b.tar.gz binaryen-ef686a4d932b9b86edc34a3b9b15926f943f6f7b.tar.bz2 binaryen-ef686a4d932b9b86edc34a3b9b15926f943f6f7b.zip |
Add table.size operation (#4224)
Diffstat (limited to 'src/wasm.h')
-rw-r--r-- | src/wasm.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/wasm.h b/src/wasm.h index c87b8c197..197b8bd84 100644 --- a/src/wasm.h +++ b/src/wasm.h @@ -629,6 +629,7 @@ public: RefEqId, TableGetId, TableSetId, + TableSizeId, TryId, ThrowId, RethrowId, @@ -1301,6 +1302,16 @@ public: void finalize(); }; +class TableSize : public SpecificExpression<Expression::TableSizeId> { +public: + TableSize() { type = Type::i32; } + TableSize(MixedArena& allocator) : TableSize() {} + + Name table; + + void finalize(); +}; + class Try : public SpecificExpression<Expression::TryId> { public: Try(MixedArena& allocator) : catchTags(allocator), catchBodies(allocator) {} |