summaryrefslogtreecommitdiff
path: root/test/multi-table.wast
diff options
context:
space:
mode:
Diffstat (limited to 'test/multi-table.wast')
-rw-r--r--test/multi-table.wast14
1 files changed, 11 insertions, 3 deletions
diff --git a/test/multi-table.wast b/test/multi-table.wast
index cbfa369e0..a98c9e4b0 100644
--- a/test/multi-table.wast
+++ b/test/multi-table.wast
@@ -1,7 +1,13 @@
(module
+ (type $none_=>_none (func))
+ (type $A (struct))
+ (global $g1 (ref null $none_=>_none) (ref.func $f))
+ (global $g2 i32 (i32.const 0))
+
(import "a" "b" (table $t1 1 10 funcref))
(table $t2 3 3 funcref)
(table $t3 4 4 funcref)
+ (table $textern 0 externref)
;; add to $t1
(elem (i32.const 0) $f)
@@ -10,10 +16,12 @@
(elem (table $t2) (i32.const 0) func $f)
(elem $activeNonZeroOffset (table $t2) (offset (i32.const 1)) func $f $g)
- (elem $e3-1 (table $t3) (i32.const 0) funcref (ref.func $f) (ref.null func))
- (elem $e3-2 (table $t3) (offset (i32.const 2)) funcref (item ref.func $f) (item (ref.func $g)))
+ (elem $e3-1 (table $t3) (global.get $g2) funcref (ref.func $f) (ref.null func))
+ (elem $e3-2 (table $t3) (offset (i32.const 2)) (ref null $none_=>_none) (item ref.func $f) (item (ref.func $g)))
- (elem $passive funcref (item ref.func $f) (item (ref.func $g)) (ref.null func))
+ (elem $passive-1 func $f $g)
+ (elem $passive-2 funcref (item ref.func $f) (item (ref.func $g)) (ref.null func))
+ (elem $passive-3 (ref null $none_=>_none) (item ref.func $f) (item (ref.func $g)) (ref.null $none_=>_none) (global.get $g1))
(elem $empty func)
(elem $declarative declare func $h)