Created
September 22, 2017 19:08
-
-
Save pepyakin/9447c2a7f2ecb33979f8400ed7d2e79a to your computer and use it in GitHub Desktop.
Failed rust-bindgen tests
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Apple LLVM version 8.1.0 (clang-802.0.42) | |
Target: x86_64-apple-darwin16.6.0 | |
Thread model: posix | |
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
failures: | |
---- header_issue_769_bad_instantiation_test_hpp stdout ---- | |
/Users/pepyakin/dev/etc/rust-bindgen/tests/headers/issue-769-bad-instantiation-test.hpp:9:19: warning: alias declarations are a C++11 extension [-Wc++11-extensions], err: false | |
/Users/pepyakin/dev/etc/rust-bindgen/tests/headers/issue-769-bad-instantiation-test.hpp:10:25: warning: alias declarations are a C++11 extension [-Wc++11-extensions], err: false | |
diff expected generated | |
--- expected: "/Users/pepyakin/dev/etc/rust-bindgen/tests/expectations/tests/libclang-3.9/issue-769-bad-instantiation-test.rs" | |
+++ generated from: "/Users/pepyakin/dev/etc/rust-bindgen/tests/headers/issue-769-bad-instantiation-test.hpp" | |
/* automatically generated by rust-bindgen */ | |
#![allow(dead_code, non_snake_case, non_camel_case_types, non_upper_case_globals)] | |
#[allow(non_snake_case, non_camel_case_types, non_upper_case_globals)] | |
pub mod root { | |
#[allow(unused_imports)] | |
use self::super::root; | |
#[repr(C)] | |
#[derive(Debug, Copy, Clone)] | |
pub struct Rooted<T> { | |
pub member: T, | |
pub _phantom_0: ::std::marker::PhantomData<::std::cell::UnsafeCell<T>>, | |
} | |
impl<T> Default for Rooted<T> { | |
fn default() -> Self { | |
unsafe { ::std::mem::zeroed() } | |
} | |
} | |
+ pub type AutoValueVector_Alias = ::std::os::raw::c_int; | |
#[test] | |
fn __bindgen_test_layout_Rooted_open0_int_close0_instantiation() { | |
assert_eq!( | |
::std::mem::size_of::<root::Rooted<::std::os::raw::c_int>>(), | |
4usize, | |
concat!( | |
"Size of template specialization: ", | |
stringify!(root::Rooted<::std::os::raw::c_int>) | |
) | |
); | |
assert_eq!( | |
::std::mem::align_of::<root::Rooted<::std::os::raw::c_int>>(), | |
4usize, | |
concat!( | |
"Alignment of template specialization: ", | |
stringify!(root::Rooted<::std::os::raw::c_int>) | |
) | |
); | |
} | |
#[test] | |
- fn __bindgen_test_layout_Rooted_open0_int_close0_instantiation_1() { | |
+ fn __bindgen_test_layout_Rooted_open0_AutoValueVector_Alias_close0_instantiation() { | |
assert_eq!( | |
- ::std::mem::size_of::<root::Rooted<::std::os::raw::c_int>>(), | |
+ ::std::mem::size_of::<root::Rooted<root::AutoValueVector_Alias>>(), | |
4usize, | |
concat!( | |
"Size of template specialization: ", | |
- stringify!(root::Rooted<::std::os::raw::c_int>) | |
+ stringify!(root::Rooted<root::AutoValueVector_Alias>) | |
) | |
); | |
assert_eq!( | |
- ::std::mem::align_of::<root::Rooted<::std::os::raw::c_int>>(), | |
+ ::std::mem::align_of::<root::Rooted<root::AutoValueVector_Alias>>(), | |
4usize, | |
concat!( | |
"Alignment of template specialization: ", | |
- stringify!(root::Rooted<::std::os::raw::c_int>) | |
+ stringify!(root::Rooted<root::AutoValueVector_Alias>) | |
) | |
); | |
} | |
} | |
thread 'header_issue_769_bad_instantiation_test_hpp' panicked at 'Header and binding differ!', /Users/pepyakin/dev/etc/rust-bindgen/target/debug/build/bindgen-9a6f64720e0c2fd0/out/tests.rs:164:0 | |
note: Run with `RUST_BACKTRACE=1` for a backtrace. | |
---- header_objc_template_h stdout ---- | |
diff expected generated | |
--- expected: "/Users/pepyakin/dev/etc/rust-bindgen/tests/expectations/tests/libclang-3.9/objc_template.rs" | |
+++ generated from: "/Users/pepyakin/dev/etc/rust-bindgen/tests/headers/objc_template.h" | |
/* automatically generated by rust-bindgen */ | |
#![allow(dead_code, non_snake_case, non_camel_case_types, non_upper_case_globals)] | |
#![cfg(target_os = "macos")] | |
#[macro_use] | |
extern crate objc; | |
#[allow(non_camel_case_types)] | |
pub type id = *mut objc::runtime::Object; | |
pub trait Foo { | |
- unsafe fn get(self) -> id; | |
+ unsafe fn get(self) -> *mut ObjectType; | |
} | |
impl Foo for id { | |
- unsafe fn get(self) -> id { | |
+ unsafe fn get(self) -> *mut ObjectType { | |
msg_send!(self, get) | |
} | |
} | |
thread 'header_objc_template_h' panicked at 'Header and binding differ!', /Users/pepyakin/dev/etc/rust-bindgen/target/debug/build/bindgen-9a6f64720e0c2fd0/out/tests.rs:234:0 | |
---- header_type_alias_template_specialized_hpp stdout ---- | |
diff expected generated | |
--- expected: "/Users/pepyakin/dev/etc/rust-bindgen/tests/expectations/tests/libclang-3.9/type_alias_template_specialized.rs" | |
+++ generated from: "/Users/pepyakin/dev/etc/rust-bindgen/tests/headers/type_alias_template_specialized.hpp" | |
/* automatically generated by rust-bindgen */ | |
#![allow(dead_code, non_snake_case, non_camel_case_types, non_upper_case_globals)] | |
#[repr(C)] | |
-#[derive(Debug, Default, Copy)] | |
+#[derive(Debug, Copy)] | |
pub struct Rooted { | |
- pub ptr: ::std::os::raw::c_int, | |
+ pub ptr: MaybeWrapped<::std::os::raw::c_int>, | |
} | |
#[test] | |
fn bindgen_test_layout_Rooted() { | |
assert_eq!( | |
::std::mem::size_of::<Rooted>(), | |
4usize, | |
concat!("Size of: ", stringify!(Rooted)) | |
); | |
assert_eq!( | |
::std::mem::align_of::<Rooted>(), | |
4usize, | |
concat!("Alignment of ", stringify!(Rooted)) | |
); | |
assert_eq!( | |
unsafe { &(*(0 as *const Rooted)).ptr as *const _ as usize }, | |
0usize, | |
concat!( | |
"Alignment of field: ", | |
stringify!(Rooted), | |
"::", | |
stringify!(ptr) | |
) | |
); | |
} | |
impl Clone for Rooted { | |
fn clone(&self) -> Self { | |
*self | |
} | |
} | |
+impl Default for Rooted { | |
+ fn default() -> Self { | |
+ unsafe { ::std::mem::zeroed() } | |
+ } | |
+} | |
/// <div rustbindgen replaces="MaybeWrapped"></div> | |
pub type MaybeWrapped<a> = a; | |
+#[test] | |
+fn __bindgen_test_layout_MaybeWrapped_open0_int_close0_instantiation() { | |
+ assert_eq!( | |
+ ::std::mem::size_of::<MaybeWrapped<::std::os::raw::c_int>>(), | |
+ 4usize, | |
+ concat!( | |
+ "Size of template specialization: ", | |
+ stringify!(MaybeWrapped<::std::os::raw::c_int>) | |
+ ) | |
+ ); | |
+ assert_eq!( | |
+ ::std::mem::align_of::<MaybeWrapped<::std::os::raw::c_int>>(), | |
+ 4usize, | |
+ concat!( | |
+ "Alignment of template specialization: ", | |
+ stringify!(MaybeWrapped<::std::os::raw::c_int>) | |
+ ) | |
+ ); | |
+} | |
thread 'header_type_alias_template_specialized_hpp' panicked at 'Header and binding differ!', /Users/pepyakin/dev/etc/rust-bindgen/target/debug/build/bindgen-9a6f64720e0c2fd0/out/tests.rs:310:0 | |
failures: | |
header_issue_769_bad_instantiation_test_hpp | |
header_objc_template_h | |
header_type_alias_template_specialized_hpp | |
test result: FAILED. 357 passed; 3 failed; 0 ignored; 0 measured; 0 filtered out | |
error: test failed, to rerun pass '--test tests' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment