diff options
Diffstat (limited to 'test/example/c-api-multiple-tables.txt')
-rw-r--r-- | test/example/c-api-multiple-tables.txt | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/test/example/c-api-multiple-tables.txt b/test/example/c-api-multiple-tables.txt new file mode 100644 index 000000000..c0f2da53b --- /dev/null +++ b/test/example/c-api-multiple-tables.txt @@ -0,0 +1,20 @@ +(module + (type $i32_i32_=>_i32 (func (param i32 i32) (result i32))) + (table $tab 1 1 funcref) + (elem (table $tab) (i32.const 0) func $adder) + (table $t2 1 1 funcref) + (elem (table $t2) (i32.const 0) func $adder) + (func $adder (param $0 i32) (param $1 i32) (result i32) + (i32.add + (local.get $0) + (local.get $1) + ) + ) + (func $call_adder_indirect (param $0 i32) (param $1 i32) (result i32) + (call_indirect $t2 (type $i32_i32_=>_i32) + (local.get $0) + (local.get $1) + (i32.const 0) + ) + ) +) |