(module (type $t0 (;0;) (sub (struct))) (type $t1 (;1;) (sub $t0 (struct (field i32)))) (type $t1' (;2;) (sub $t0 (struct (field i32)))) (type $t2 (;3;) (sub $t1 (struct (field i32) (field i32)))) (type $t2' (;4;) (sub $t1' (struct (field i32) (field i32)))) (type $t3 (;5;) (sub $t0 (struct (field i32) (field i32)))) (type $t0' (;6;) (sub $t0 (struct))) (type $t4 (;7;) (sub $t0' (struct (field i32) (field i32)))) (type (;8;) (func)) (table (;0;) 20 structref) (export "test-sub" (func 1)) (export "test-canon" (func 2)) (func $init (;0;) (type 8) i32.const 0 struct.new_default $t0 table.set 0 i32.const 10 struct.new_default $t0' table.set 0 i32.const 1 struct.new_default $t1 table.set 0 i32.const 11 struct.new_default $t1' table.set 0 i32.const 2 struct.new_default $t2 table.set 0 i32.const 12 struct.new_default $t2' table.set 0 i32.const 3 struct.new_default $t3 table.set 0 i32.const 4 struct.new_default $t4 table.set 0 ) (func (;1;) (type 8) call $init block $l (result structref) block (result structref) ;; label = @2 ref.null struct br_on_cast 0 (;@2;) structref (ref $t0) end drop block (result structref) ;; label = @2 i32.const 0 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0) end drop block (result structref) ;; label = @2 i32.const 1 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0) end drop block (result structref) ;; label = @2 i32.const 2 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0) end drop block (result structref) ;; label = @2 i32.const 3 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0) end drop block (result structref) ;; label = @2 i32.const 4 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0) end drop block (result structref) ;; label = @2 ref.null struct br_on_cast 0 (;@2;) structref (ref $t1) end drop block (result structref) ;; label = @2 i32.const 1 table.get 0 br_on_cast 0 (;@2;) structref (ref $t1) end drop block (result structref) ;; label = @2 i32.const 2 table.get 0 br_on_cast 0 (;@2;) structref (ref $t1) end drop block (result structref) ;; label = @2 ref.null struct br_on_cast 0 (;@2;) structref (ref $t2) end drop block (result structref) ;; label = @2 i32.const 2 table.get 0 br_on_cast 0 (;@2;) structref (ref $t2) end drop block (result structref) ;; label = @2 ref.null struct br_on_cast 0 (;@2;) structref (ref $t3) end drop block (result structref) ;; label = @2 i32.const 3 table.get 0 br_on_cast 0 (;@2;) structref (ref $t3) end drop block (result structref) ;; label = @2 ref.null struct br_on_cast 0 (;@2;) structref (ref $t4) end drop block (result structref) ;; label = @2 i32.const 4 table.get 0 br_on_cast 0 (;@2;) structref (ref $t4) end drop i32.const 0 table.get 0 br_on_cast $l anyref (ref $t1) i32.const 3 table.get 0 br_on_cast $l anyref (ref $t1) i32.const 4 table.get 0 br_on_cast $l anyref (ref $t1) i32.const 0 table.get 0 br_on_cast $l anyref (ref $t2) i32.const 1 table.get 0 br_on_cast $l anyref (ref $t2) i32.const 3 table.get 0 br_on_cast $l anyref (ref $t2) i32.const 4 table.get 0 br_on_cast $l anyref (ref $t2) i32.const 0 table.get 0 br_on_cast $l anyref (ref $t3) i32.const 1 table.get 0 br_on_cast $l anyref (ref $t3) i32.const 2 table.get 0 br_on_cast $l anyref (ref $t3) i32.const 4 table.get 0 br_on_cast $l anyref (ref $t3) i32.const 0 table.get 0 br_on_cast $l anyref (ref $t4) i32.const 1 table.get 0 br_on_cast $l anyref (ref $t4) i32.const 2 table.get 0 br_on_cast $l anyref (ref $t4) i32.const 3 table.get 0 br_on_cast $l anyref (ref $t4) return end unreachable ) (func (;2;) (type 8) call $init block $l block (result structref) ;; label = @2 i32.const 0 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0') end drop block (result structref) ;; label = @2 i32.const 1 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0') end drop block (result structref) ;; label = @2 i32.const 2 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0') end drop block (result structref) ;; label = @2 i32.const 3 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0') end drop block (result structref) ;; label = @2 i32.const 4 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0') end drop block (result structref) ;; label = @2 i32.const 10 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0) end drop block (result structref) ;; label = @2 i32.const 11 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0) end drop block (result structref) ;; label = @2 i32.const 12 table.get 0 br_on_cast 0 (;@2;) structref (ref $t0) end drop block (result structref) ;; label = @2 i32.const 1 table.get 0 br_on_cast 0 (;@2;) structref (ref $t1') end drop block (result structref) ;; label = @2 i32.const 2 table.get 0 br_on_cast 0 (;@2;) structref (ref $t1') end drop block (result structref) ;; label = @2 i32.const 11 table.get 0 br_on_cast 0 (;@2;) structref (ref $t1) end drop block (result structref) ;; label = @2 i32.const 12 table.get 0 br_on_cast 0 (;@2;) structref (ref $t1) end drop block (result structref) ;; label = @2 i32.const 2 table.get 0 br_on_cast 0 (;@2;) structref (ref $t2') end drop block (result structref) ;; label = @2 i32.const 12 table.get 0 br_on_cast 0 (;@2;) structref (ref $t2) end drop return end unreachable ) )