assemblyscript/tests/compiler/inlining-recursive.optimized.wat
dcodeIO 16d1a833dd Always add a null function at table index zero
This allows function references (a table index internally) to be nullable
2018-09-17 01:48:35 +02:00

21 lines
588 B
Plaintext

(module
(type $v (func))
(memory $0 0)
(export "memory" (memory $0))
(export "foo" (func $inlining-recursive/foo))
(export "bar" (func $inlining-recursive/bar))
(export "baz" (func $inlining-recursive/baz))
(func $inlining-recursive/foo (; 0 ;) (; has Stack IR ;) (type $v)
(call $inlining-recursive/foo)
)
(func $inlining-recursive/baz (; 1 ;) (; has Stack IR ;) (type $v)
(call $inlining-recursive/bar)
)
(func $inlining-recursive/bar (; 2 ;) (; has Stack IR ;) (type $v)
(call $inlining-recursive/baz)
)
(func $null (; 3 ;) (; has Stack IR ;) (type $v)
(nop)
)
)