summaryrefslogtreecommitdiff
path: root/test/spec/func_ptrs.txt
blob: 49f2e428b8898553297f5857e184e59c76dfc38a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
;;; TOOL: run-interp-spec
;;; STDIN_FILE: third_party/testsuite/func_ptrs.wast
(;; STDOUT ;;;
assert_invalid error:
  out/third_party/testsuite/func_ptrs.wast:31:26: table variable out of range (max 0)
(assert_invalid (module (elem (i32.const 0))) "unknown table")
                         ^^^^
assert_invalid error:
  out/third_party/testsuite/func_ptrs.wast:32:26: table variable out of range (max 0)
(assert_invalid (module (elem (i32.const 0) 0) (func)) "unknown table")
                         ^^^^
assert_invalid error:
  out/third_party/testsuite/func_ptrs.wast:35:36: type mismatch at elem segment offset. got i64, expected i32
  (module (table 1 anyfunc) (elem (i64.const 0)))
                                   ^^^^^^^^^^^
assert_invalid error:
  out/third_party/testsuite/func_ptrs.wast:39:29: invalid elem segment offset, must be a constant expression; either *.const or get_global.
  (module (table 1 anyfunc) (elem (i32.ctz (i32.const 0))))
                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
assert_invalid error:
  out/third_party/testsuite/func_ptrs.wast:43:29: invalid elem segment offset, must be a constant expression; either *.const or get_global.
  (module (table 1 anyfunc) (elem (nop)))
                            ^^^^^^^^^^^^
assert_invalid error:
  out/third_party/testsuite/func_ptrs.wast:47:37: function type variable out of range (max 0)
(assert_invalid (module (func (type 42))) "unknown type")
                                    ^^
assert_invalid error:
  out/third_party/testsuite/func_ptrs.wast:48:64: function type variable out of range (max 0)
...invalid (module (import "spectest" "print" (func (type 43)))) "unknown type")
                                                          ^^
called host spectest.print(i32:83) =>
four(i32:83) =>
out/third_party/testsuite/func_ptrs.wast:31: assert_invalid passed:
  error: @0x0000000b: elem section without table section
out/third_party/testsuite/func_ptrs.wast:32: assert_invalid passed:
  error: @0x00000015: elem section without table section
out/third_party/testsuite/func_ptrs.wast:35: assert_invalid passed:
  error: type mismatch in elem segment, expected i32 but got i64
  error: @0x00000015: end_elem_segment_init_expr callback failed
out/third_party/testsuite/func_ptrs.wast:39: assert_invalid passed:
  error: @0x00000015: expected END opcode after initializer expression
out/third_party/testsuite/func_ptrs.wast:43: assert_invalid passed:
  error: @0x00000013: unexpected opcode in initializer expression: 1 (0x1)
out/third_party/testsuite/func_ptrs.wast:47: assert_invalid passed:
  error: @0x0000000c: invalid function signature index: 42
out/third_party/testsuite/func_ptrs.wast:48: assert_invalid passed:
  error: @0x0000001c: invalid import signature index
33/33 tests passed.
;;; STDOUT ;;)