summaryrefslogtreecommitdiff
path: root/test/example
diff options
context:
space:
mode:
authorMax Graey <maxgraey@gmail.com>2021-10-09 05:26:08 +0300
committerGitHub <noreply@github.com>2021-10-08 19:26:08 -0700
commitef686a4d932b9b86edc34a3b9b15926f943f6f7b (patch)
tree38a89d5b555d4501b7d504a66c7aec409e45e9b1 /test/example
parent53c5e3e62db25fe3522a1fa615a1f53c4cefdf06 (diff)
downloadbinaryen-ef686a4d932b9b86edc34a3b9b15926f943f6f7b.tar.gz
binaryen-ef686a4d932b9b86edc34a3b9b15926f943f6f7b.tar.bz2
binaryen-ef686a4d932b9b86edc34a3b9b15926f943f6f7b.zip
Add table.size operation (#4224)
Diffstat (limited to 'test/example')
-rw-r--r--test/example/c-api-kitchen-sink.c2
-rw-r--r--test/example/c-api-kitchen-sink.txt1
2 files changed, 3 insertions, 0 deletions
diff --git a/test/example/c-api-kitchen-sink.c b/test/example/c-api-kitchen-sink.c
index 894fc1454..1e762579e 100644
--- a/test/example/c-api-kitchen-sink.c
+++ b/test/example/c-api-kitchen-sink.c
@@ -1026,6 +1026,8 @@ void test_core() {
BinaryenExpressionPrint(funcrefExpr2);
+ BinaryenExpressionPrint(BinaryenTableSize(module, "0"));
+
// Memory. One per module
const char* segments[] = {"hello, world", "I am passive"};
diff --git a/test/example/c-api-kitchen-sink.txt b/test/example/c-api-kitchen-sink.txt
index c28e0536d..b1afb9954 100644
--- a/test/example/c-api-kitchen-sink.txt
+++ b/test/example/c-api-kitchen-sink.txt
@@ -38,6 +38,7 @@ BinaryenFeatureAll: 32767
(table.get $0
(i32.const 0)
)
+(table.size $0)
(module
(type $i32_i64_f32_f64_=>_i32 (func (param i32 i64 f32 f64) (result i32)))
(type $i32_=>_none (func (param i32)))