summaryrefslogtreecommitdiff
path: root/test/parse/expr/callref-internal-function.txt
blob: 5cc27cc6823a481d529d58ea0cd19ca000148801 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
;;; TOOL: wat2wasm
;;; ARGS: --enable-function-references
(module
  (func (export "main") (result i32)
    (call_ref (i32.const 10)
              (ref.func $foo)
    )
  )
  (func $foo (param $x i32) (result i32)
    (i32.add (local.get $x)
             (i32.const 19))
  )
  (elem declare funcref (ref.func $foo))
)