]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-48159.rs
Enable full revision in const generics ui tests
[rust.git] / src / test / ui / issues / issue-48159.rs
1 // run-pass
2 #![allow(non_camel_case_types)]
3
4 use std::mem;
5
6 pub enum c_void {}
7
8 type uintptr_t = usize;
9 type int16_t = u16;
10 type uint16_t = int16_t;
11 type uint32_t = u32;
12 type intptr_t = uintptr_t;
13
14 #[repr(C)]
15 #[repr(packed(4))]
16 pub struct kevent {
17     pub ident: uintptr_t,
18     pub filter: int16_t,
19     pub flags: uint16_t,
20     pub fflags: uint32_t,
21     pub data: intptr_t,
22     pub udata: *mut c_void,
23 }
24
25 fn main() {
26     assert_eq!(mem::align_of::<kevent>(), 4);
27 }