Gitly
English
Русский
Español
日本語
中文
Português
Log in
Register
v2
/
vlib
/
v
/
tests
/
fixed_array_update_c_struct_alias_test.v
17
lines
·
14
sloc
·
273 bytes
·
9ec44dfc70336d05867680cd0c2a99aa2789ca69
Raw
1
module
main
2
3
import
sokol.sapp
4
5
struct
Event {
6
touches [8]sapp.TouchPoint
7
}
8
9
fn
test_fixed_array_update_with_c_struct_alias() {
10
e := Event{}
11
ev := Event{
12
...e
13
}
14
assert ev.touches.len == 8
15
assert ev.touches[0].identifier == 0
16
assert ev.touches[7].identifier == 0
17
}
18