assemblyscript/tests/compiler/class-with-boolean-field.untouched.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

23 lines
461 B
Plaintext

(module
(type $i (func (result i32)))
(type $v (func))
(global $HEAP_BASE i32 (i32.const 8))
(table 1 1 anyfunc)
(elem (i32.const 0) $null)
(memory $0 0)
(export "memory" (memory $0))
(export "test" (func $class-with-boolean-field/test))
(func $class-with-boolean-field/test (; 0 ;) (type $i) (result i32)
(local $0 i32)
(i32.store8
(get_local $0)
(i32.const 1)
)
(i32.load8_u
(get_local $0)
)
)
(func $null (; 1 ;) (type $v)
)
)