You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/* automatically generated by rust-bindgen 0.59.2 */#[repr(C)]#[derive(Debug,Copy,Clone)]pubstructFoo{pub_address:u8,}#[test]fnbindgen_test_layout_Foo(){assert_eq!(::std::mem::size_of::<Foo>(),1usize,
concat!("Size of: ", stringify!(Foo)));assert_eq!(::std::mem::align_of::<Foo>(),1usize,
concat!("Alignment of ", stringify!(Foo)));}extern"C"{#[link_name = "\u{1}_ZN3Foo3barEv"]pubfnFoo_bar(this:*mutFoo);}implFoo{#[inline]pubunsafefnbar(&mutself){Foo_bar(self)}}
Expected Results
Bindgen shouldn't be generating bindings for bar(). It probably gets confused by the fact that Foo's declaration doesn't specifically say that bar() is inline, but instead it should look forward for a possible inline definition.
Marking the bar() declaration with inlinedoes fix the issue, even if we don't provide an actual body.
The specific header I'm working with is this one, and it makes heavy usage of this to define std dependent helpers.
The text was updated successfully, but these errors were encountered:
Input C/C++ Header
Bindgen Invocation
Generated by
bindgen input.hpp
, no flagsExpected Results
Bindgen shouldn't be generating bindings for
bar()
. It probably gets confused by the fact thatFoo
's declaration doesn't specifically say thatbar()
is inline, but instead it should look forward for a possible inline definition.Marking the
bar()
declaration withinline
does fix the issue, even if we don't provide an actual body.The specific header I'm working with is this one, and it makes heavy usage of this to define std dependent helpers.
The text was updated successfully, but these errors were encountered: