Skip to content

Commit a5ce38f

Browse files
committed
[DO NOT MERGE] Try run running with stable again, not to be merged.
1 parent a9d9a13 commit a5ce38f

File tree

92 files changed

+467
-189
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

92 files changed

+467
-189
lines changed

tests/expectations/accessors.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/annotation_hide.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/anon_enum.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/anon_enum_whitelist.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/anon_union.rs

Lines changed: 30 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,31 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

7+
#[derive(Debug)]
88
#[repr(C)]
9+
pub struct __BindgenUnionField<T>(::std::marker::PhantomData<T>);
10+
impl <T> __BindgenUnionField<T> {
11+
#[inline]
12+
pub fn new() -> Self { __BindgenUnionField(::std::marker::PhantomData) }
13+
#[inline]
14+
pub unsafe fn as_ref(&self) -> &T { ::std::mem::transmute(self) }
15+
#[inline]
16+
pub unsafe fn as_mut(&mut self) -> &mut T { ::std::mem::transmute(self) }
17+
}
18+
impl <T> ::std::default::Default for __BindgenUnionField<T> {
19+
#[inline]
20+
fn default() -> Self { Self::new() }
21+
}
22+
impl <T> ::std::clone::Clone for __BindgenUnionField<T> {
23+
#[inline]
24+
fn clone(&self) -> Self { Self::new() }
25+
}
26+
impl <T> ::std::marker::Copy for __BindgenUnionField<T> { }
27+
#[repr(C)]
28+
#[derive(Debug, Copy, Clone)]
929
pub struct TErrorResult<T> {
1030
pub mResult: ::std::os::raw::c_int,
1131
pub __bindgen_anon_1: TErrorResult__bindgen_ty_bindgen_id_10<T>,
@@ -31,12 +51,15 @@ pub struct TErrorResult_DOMExceptionInfo<T> {
3151
pub _phantom_0: ::std::marker::PhantomData<T>,
3252
}
3353
#[repr(C)]
34-
pub union TErrorResult__bindgen_ty_bindgen_id_10<T> {
35-
pub mMessage: *mut TErrorResult_Message<T>,
36-
pub mDOMExceptionInfo: *mut TErrorResult_DOMExceptionInfo<T>,
54+
#[derive(Debug, Copy, Clone)]
55+
pub struct TErrorResult__bindgen_ty_bindgen_id_10<T> {
56+
pub mMessage: __BindgenUnionField<*mut TErrorResult_Message<T>>,
57+
pub mDOMExceptionInfo: __BindgenUnionField<*mut TErrorResult_DOMExceptionInfo<T>>,
58+
pub bindgen_union_field: u64,
3759
pub _phantom_0: ::std::marker::PhantomData<T>,
3860
}
3961
#[repr(C)]
62+
#[derive(Debug, Copy)]
4063
pub struct ErrorResult {
4164
pub _base: TErrorResult<::std::os::raw::c_int>,
4265
}
@@ -45,3 +68,6 @@ fn bindgen_test_layout_ErrorResult() {
4568
assert_eq!(::std::mem::size_of::<ErrorResult>() , 24usize);
4669
assert_eq!(::std::mem::align_of::<ErrorResult>() , 8usize);
4770
}
71+
impl Clone for ErrorResult {
72+
fn clone(&self) -> Self { *self }
73+
}

tests/expectations/arg_keyword.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/blocks.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/class.rs

Lines changed: 26 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,29 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

7+
#[derive(Debug)]
8+
#[repr(C)]
9+
pub struct __BindgenUnionField<T>(::std::marker::PhantomData<T>);
10+
impl <T> __BindgenUnionField<T> {
11+
#[inline]
12+
pub fn new() -> Self { __BindgenUnionField(::std::marker::PhantomData) }
13+
#[inline]
14+
pub unsafe fn as_ref(&self) -> &T { ::std::mem::transmute(self) }
15+
#[inline]
16+
pub unsafe fn as_mut(&mut self) -> &mut T { ::std::mem::transmute(self) }
17+
}
18+
impl <T> ::std::default::Default for __BindgenUnionField<T> {
19+
#[inline]
20+
fn default() -> Self { Self::new() }
21+
}
22+
impl <T> ::std::clone::Clone for __BindgenUnionField<T> {
23+
#[inline]
24+
fn clone(&self) -> Self { Self::new() }
25+
}
26+
impl <T> ::std::marker::Copy for __BindgenUnionField<T> { }
827
#[repr(C)]
928
pub struct C {
1029
pub a: ::std::os::raw::c_int,
@@ -26,10 +45,11 @@ fn bindgen_test_layout_WithDtor() {
2645
assert_eq!(::std::mem::align_of::<WithDtor>() , 4usize);
2746
}
2847
#[repr(C)]
29-
#[derive(Copy)]
30-
pub union Union {
31-
pub d: f32,
32-
pub i: ::std::os::raw::c_int,
48+
#[derive(Debug, Copy)]
49+
pub struct Union {
50+
pub d: __BindgenUnionField<f32>,
51+
pub i: __BindgenUnionField<::std::os::raw::c_int>,
52+
pub bindgen_union_field: u32,
3353
}
3454
#[test]
3555
fn bindgen_test_layout_Union() {
@@ -40,7 +60,7 @@ impl Clone for Union {
4060
fn clone(&self) -> Self { *self }
4161
}
4262
#[repr(C)]
43-
#[derive(Copy)]
63+
#[derive(Debug, Copy)]
4464
pub struct WithUnion {
4565
pub data: Union,
4666
}

tests/expectations/class_nested.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/class_no_members.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/class_static.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/class_use_as.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/class_with_dtor.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/class_with_inner_struct.rs

Lines changed: 35 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,31 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

7+
#[derive(Debug)]
88
#[repr(C)]
9-
#[derive(Copy)]
9+
pub struct __BindgenUnionField<T>(::std::marker::PhantomData<T>);
10+
impl <T> __BindgenUnionField<T> {
11+
#[inline]
12+
pub fn new() -> Self { __BindgenUnionField(::std::marker::PhantomData) }
13+
#[inline]
14+
pub unsafe fn as_ref(&self) -> &T { ::std::mem::transmute(self) }
15+
#[inline]
16+
pub unsafe fn as_mut(&mut self) -> &mut T { ::std::mem::transmute(self) }
17+
}
18+
impl <T> ::std::default::Default for __BindgenUnionField<T> {
19+
#[inline]
20+
fn default() -> Self { Self::new() }
21+
}
22+
impl <T> ::std::clone::Clone for __BindgenUnionField<T> {
23+
#[inline]
24+
fn clone(&self) -> Self { Self::new() }
25+
}
26+
impl <T> ::std::marker::Copy for __BindgenUnionField<T> { }
27+
#[repr(C)]
28+
#[derive(Debug, Copy)]
1029
pub struct A {
1130
pub c: ::std::os::raw::c_uint,
1231
pub named_union: A__bindgen_ty_bindgen_id_9,
@@ -27,9 +46,10 @@ impl Clone for A_Segment {
2746
fn clone(&self) -> Self { *self }
2847
}
2948
#[repr(C)]
30-
#[derive(Copy)]
31-
pub union A__bindgen_ty_bindgen_id_9 {
32-
pub f: ::std::os::raw::c_int,
49+
#[derive(Debug, Copy)]
50+
pub struct A__bindgen_ty_bindgen_id_9 {
51+
pub f: __BindgenUnionField<::std::os::raw::c_int>,
52+
pub bindgen_union_field: u32,
3353
}
3454
#[test]
3555
fn bindgen_test_layout_A__bindgen_ty_bindgen_id_9() {
@@ -40,9 +60,10 @@ impl Clone for A__bindgen_ty_bindgen_id_9 {
4060
fn clone(&self) -> Self { *self }
4161
}
4262
#[repr(C)]
43-
#[derive(Copy)]
44-
pub union A__bindgen_ty_bindgen_id_14 {
45-
pub d: ::std::os::raw::c_int,
63+
#[derive(Debug, Copy)]
64+
pub struct A__bindgen_ty_bindgen_id_14 {
65+
pub d: __BindgenUnionField<::std::os::raw::c_int>,
66+
pub bindgen_union_field: u32,
4667
}
4768
#[test]
4869
fn bindgen_test_layout_A__bindgen_ty_bindgen_id_14() {
@@ -97,16 +118,17 @@ pub enum StepSyntax {
97118
FunctionalWithEndKeyword = 3,
98119
}
99120
#[repr(C)]
100-
#[derive(Copy)]
121+
#[derive(Debug, Copy)]
101122
pub struct C {
102123
pub d: ::std::os::raw::c_uint,
103124
pub __bindgen_anon_1: C__bindgen_ty_bindgen_id_31,
104125
}
105126
#[repr(C)]
106-
#[derive(Copy)]
107-
pub union C__bindgen_ty_bindgen_id_31 {
108-
pub mFunc: C__bindgen_ty_bindgen_id_31__bindgen_ty_bindgen_id_32,
109-
pub __bindgen_anon_1: C__bindgen_ty_bindgen_id_31__bindgen_ty_bindgen_id_43,
127+
#[derive(Debug, Copy)]
128+
pub struct C__bindgen_ty_bindgen_id_31 {
129+
pub mFunc: __BindgenUnionField<C__bindgen_ty_bindgen_id_31__bindgen_ty_bindgen_id_32>,
130+
pub __bindgen_anon_1: __BindgenUnionField<C__bindgen_ty_bindgen_id_31__bindgen_ty_bindgen_id_43>,
131+
pub bindgen_union_field: [u32; 4usize],
110132
}
111133
#[repr(C)]
112134
#[derive(Debug, Copy)]

tests/expectations/class_with_typedef.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/const_ptr.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/const_resolved_ty.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/const_tparam.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/crtp.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/decl_ptr_to_array.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/duplicated_constants_in_ns.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/empty_template_param_name.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/enum.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/enum_alias.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/enum_and_vtable_mangling.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/enum_dupe.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/enum_explicit_type.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

tests/expectations/enum_negative.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* automatically generated by rust-bindgen */
22

33

4-
#![feature(untagged_unions)]
54
#![allow(non_snake_case)]
65

76

0 commit comments

Comments
 (0)