| /* automatically generated by rust-bindgen */ |
| |
| |
| #![allow(non_snake_case)] |
| |
| |
| #[repr(C)] |
| #[derive(Debug, Default, Copy)] |
| pub struct A { |
| pub x: ::std::os::raw::c_uchar, |
| pub _bitfield_1: [u8; 2usize], |
| pub y: ::std::os::raw::c_uchar, |
| pub __bindgen_align: [u32; 0usize], |
| } |
| #[test] |
| fn bindgen_test_layout_A() { |
| assert_eq!(::std::mem::size_of::<A>() , 4usize , concat ! ( |
| "Size of: " , stringify ! ( A ) )); |
| assert_eq! (::std::mem::align_of::<A>() , 4usize , concat ! ( |
| "Alignment of " , stringify ! ( A ) )); |
| assert_eq! (unsafe { & ( * ( 0 as * const A ) ) . x as * const _ as usize |
| } , 0usize , concat ! ( |
| "Alignment of field: " , stringify ! ( A ) , "::" , stringify |
| ! ( x ) )); |
| assert_eq! (unsafe { & ( * ( 0 as * const A ) ) . y as * const _ as usize |
| } , 3usize , concat ! ( |
| "Alignment of field: " , stringify ! ( A ) , "::" , stringify |
| ! ( y ) )); |
| } |
| impl Clone for A { |
| fn clone(&self) -> Self { *self } |
| } |
| #[repr(C)] |
| #[derive(Debug, Default, Copy)] |
| pub struct B { |
| pub _bitfield_1: u32, |
| pub __bindgen_align: [u32; 0usize], |
| } |
| #[test] |
| fn bindgen_test_layout_B() { |
| assert_eq!(::std::mem::size_of::<B>() , 4usize , concat ! ( |
| "Size of: " , stringify ! ( B ) )); |
| assert_eq! (::std::mem::align_of::<B>() , 4usize , concat ! ( |
| "Alignment of " , stringify ! ( B ) )); |
| } |
| impl Clone for B { |
| fn clone(&self) -> Self { *self } |
| } |
| #[repr(C)] |
| #[derive(Debug, Default, Copy)] |
| pub struct C { |
| pub x: ::std::os::raw::c_uchar, |
| pub _bitfield_1: u8, |
| pub baz: ::std::os::raw::c_uint, |
| } |
| #[test] |
| fn bindgen_test_layout_C() { |
| assert_eq!(::std::mem::size_of::<C>() , 8usize , concat ! ( |
| "Size of: " , stringify ! ( C ) )); |
| assert_eq! (::std::mem::align_of::<C>() , 4usize , concat ! ( |
| "Alignment of " , stringify ! ( C ) )); |
| assert_eq! (unsafe { & ( * ( 0 as * const C ) ) . x as * const _ as usize |
| } , 0usize , concat ! ( |
| "Alignment of field: " , stringify ! ( C ) , "::" , stringify |
| ! ( x ) )); |
| assert_eq! (unsafe { |
| & ( * ( 0 as * const C ) ) . baz as * const _ as usize } , |
| 4usize , concat ! ( |
| "Alignment of field: " , stringify ! ( C ) , "::" , stringify |
| ! ( baz ) )); |
| } |
| impl Clone for C { |
| fn clone(&self) -> Self { *self } |
| } |
| #[repr(C)] |
| #[derive(Debug, Default, Copy)] |
| pub struct Date1 { |
| pub _bitfield_1: [u8; 2usize], |
| pub _bitfield_2: u8, |
| pub __bindgen_align: [u16; 0usize], |
| } |
| #[test] |
| fn bindgen_test_layout_Date1() { |
| assert_eq!(::std::mem::size_of::<Date1>() , 4usize , concat ! ( |
| "Size of: " , stringify ! ( Date1 ) )); |
| assert_eq! (::std::mem::align_of::<Date1>() , 2usize , concat ! ( |
| "Alignment of " , stringify ! ( Date1 ) )); |
| } |
| impl Clone for Date1 { |
| fn clone(&self) -> Self { *self } |
| } |
| #[repr(C)] |
| #[derive(Debug, Default, Copy)] |
| pub struct Date2 { |
| pub _bitfield_1: [u8; 2usize], |
| pub _bitfield_2: u8, |
| pub byte: ::std::os::raw::c_uchar, |
| pub __bindgen_align: [u16; 0usize], |
| } |
| #[test] |
| fn bindgen_test_layout_Date2() { |
| assert_eq!(::std::mem::size_of::<Date2>() , 4usize , concat ! ( |
| "Size of: " , stringify ! ( Date2 ) )); |
| assert_eq! (::std::mem::align_of::<Date2>() , 2usize , concat ! ( |
| "Alignment of " , stringify ! ( Date2 ) )); |
| assert_eq! (unsafe { |
| & ( * ( 0 as * const Date2 ) ) . byte as * const _ as usize } |
| , 3usize , concat ! ( |
| "Alignment of field: " , stringify ! ( Date2 ) , "::" , |
| stringify ! ( byte ) )); |
| } |
| impl Clone for Date2 { |
| fn clone(&self) -> Self { *self } |
| } |