v2 / vlib / v / slow_tests / inout / struct_dump_option_fields.vv
35 lines · 30 sloc · 308 bytes · 0c8ce3bcb9fd4a2e5bd5f991a5a07da976d780d7
Raw
1type Alias = int
2
3type SumType = int | string
4
5enum Abc {
6 a
7 b
8 c
9}
10
11struct Other {
12 a ?int
13}
14
15struct Test {
16 a ?int
17 b ?string
18 c ?[]int
19 d ?&int
20 e ?Alias
21 f ?SumType
22 g ?Other
23 h ?&&int
24 i ?Abc
25 j ?fn (int)
26 k []?int
27 l []?string
28 m []?Other
29 n ?Other = Other{}
30}
31
32fn main() {
33 t := Test{}
34 println(t)
35}
36