@@ -13,34 +13,29 @@ pub mod root {
13
13
use self :: super :: super :: root;
14
14
#[ repr( C ) ]
15
15
#[ derive( Debug , Default , Copy ) ]
16
- pub struct _bindgen_ty_1 {
16
+ pub struct typedef_struct {
17
17
pub foo : :: std:: os:: raw:: c_int ,
18
18
}
19
19
#[ test]
20
- fn bindgen_test_layout__bindgen_ty_1 ( ) {
21
- assert_eq ! ( :: std:: mem:: size_of:: <_bindgen_ty_1 >( ) , 4usize ,
22
- concat ! ( "Size of: " , stringify ! ( _bindgen_ty_1 )
20
+ fn bindgen_test_layout_typedef_struct ( ) {
21
+ assert_eq ! ( :: std:: mem:: size_of:: <typedef_struct >( ) , 4usize ,
22
+ concat ! ( "Size of: " , stringify ! ( typedef_struct )
23
23
) ) ;
24
- assert_eq ! ( :: std:: mem:: align_of:: <_bindgen_ty_1 >( ) , 4usize ,
24
+ assert_eq ! ( :: std:: mem:: align_of:: <typedef_struct >( ) , 4usize ,
25
25
concat ! (
26
- "Alignment of " , stringify ! ( _bindgen_ty_1 ) ) ) ;
26
+ "Alignment of " , stringify ! ( typedef_struct ) ) ) ;
27
27
assert_eq ! ( unsafe {
28
- & ( * ( 0 as * const _bindgen_ty_1 ) ) . foo as *
28
+ & ( * ( 0 as * const typedef_struct ) ) . foo as *
29
29
const _ as usize } , 0usize , concat ! (
30
- "Alignment of field: " , stringify ! ( _bindgen_ty_1 )
31
- , "::" , stringify ! ( foo ) ) ) ;
30
+ "Alignment of field: " , stringify ! ( typedef_struct
31
+ ) , "::" , stringify ! ( foo ) ) ) ;
32
32
}
33
- impl Clone for _bindgen_ty_1 {
33
+ impl Clone for typedef_struct {
34
34
fn clone ( & self ) -> Self { * self }
35
35
}
36
- pub type typedef_struct = root:: whatever:: _bindgen_ty_1 ;
37
- pub const whatever_BAR: root:: whatever:: _bindgen_ty_2 =
38
- _bindgen_ty_2:: BAR ;
39
36
#[ repr( u32 ) ]
40
37
#[ derive( Debug , Copy , Clone , PartialEq , Eq , Hash ) ]
41
- pub enum _bindgen_ty_2 { BAR = 1 , }
42
- pub use self :: super :: super :: root:: whatever:: _bindgen_ty_2 as
43
- typedef_enum;
38
+ pub enum typedef_enum { BAR = 1 , }
44
39
}
45
40
pub mod _bindgen_mod_id_12 {
46
41
#[ allow( unused_imports) ]
0 commit comments