v2 / vlib / v / tests / structs / modules / structs_with_noinit / shapes.v
22 lines · 16 sloc · 261 bytes · 6488041a749df9762348d019c4223908c476f2e2
Raw
1module structs_with_noinit
2
3@[noinit]
4pub struct Image {}
5
6@[noinit]
7pub struct Rect {}
8
9@[noinit]
10pub struct Circle {}
11
12pub fn make_circle() Circle {
13 return Circle{}
14}
15
16pub fn make_image() Image {
17 return Image{}
18}
19
20pub fn make_rect() Rect {
21 return Rect{}
22}
23