v2 / vlib / v / tests / printing / dump_c_structs / epoll.h
12 lines · 11 sloc · 360 bytes · 6488041a749df9762348d019c4223908c476f2e2
Raw
1// Note: the name zz_epoll_data is deliberately chosen to minimise the chance of conflicts with `epoll_data` in the future.
2typedef union zz_epoll_data {
3 void *ptr;
4 int fd;
5 uint32_t u32;
6 uint64_t u64;
7} zz_epoll_data_t;
8
9struct zz_epoll_event {
10 uint32_t events; /* Epoll events */
11 zz_epoll_data_t data; /* User data variable */
12};
13