Files: a338912f819bd6fa4333e0c982768e58f6f2219f / tests / wast / funcRef_caller.wast
717 bytesRaw
1 | (module |
2 | (import "func" "internalize" (func $internalize (param i32 i32))) |
3 | (import "test" "check" (func $check (param i32 i32))) |
4 | (import "module" "self" (func $self (result i32))) |
5 | (import "module" "exports" (func $exports (param i32 i32 i32) (result i32))) |
6 | (memory (export "memory") 1) |
7 | (data (i32.const 0) "callback") |
8 | (table (export "table") 1 1 anyfunc) |
9 | (func $call (param i32) |
10 | call $self |
11 | i32.const 0 |
12 | i32.const 8 |
13 | call $exports |
14 | i32.const 0 |
15 | get_local 0 |
16 | call $internalize |
17 | i32.const 0 |
18 | call_indirect (param i32) |
19 | ) |
20 | (func $callback (param i32) |
21 | get_local 0 |
22 | i32.const 5 |
23 | call $check |
24 | ) |
25 | (export "call" (func $call)) |
26 | (export "callback" (func $callback))) |
27 |
Built with git-ssb-web