1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00
v/vlib/v/tests/option_array_init_test.v

11 lines
160 B
V

fn test_main() {
a := []?int{len: 3, init: none}
mut t := a[0]
assert t == none
t = a[1]
assert t == none
t = a[2]
assert t == none
assert a.len == 3
}