v2 / vlib / v / fmt / tests / fixed_array_new_syntax_keep.vv
15 lines · 14 sloc · 170 bytes · 88c336512f2eb210ef2e3b379bd802b68bfab448
Raw
1const rows = 2
2const cols = 2
3
4fn main() {
5 row1 := [..]int[1, 2]
6 row2 := [..]int[3, 4]
7 _ := [..][..]int[
8 row1,
9 row2,
10 ]
11 _ = [rows][cols]int[
12 row1,
13 row2,
14 ]
15}
16