-
Notifications
You must be signed in to change notification settings - Fork 743
Unable to compile (or blacklist) typedef with union #1281
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Any chance you could use See https://github.com/rust-lang-nursery/rust-bindgen/blob/6355f0a3dce637512b4ea279dbd4b1737fc46ce2/CONTRIBUTING.md#using-creduce-to-minimize-test-cases for instructions. Thank you! |
This is unrelated to the blacklisting, it's about this pattern of forward-declaring a struct and then defining it inside other semantic scope, which trips our assumptions. I think that assertion is just wrong. |
Reduced test-case: struct drr_begin;
struct dmu_replay_record {
struct drr_begin {
int foo;
} u;
}; |
You can define a struct declared in an outer scope inside another struct. C, what a language. Fixes rust-lang#1281
You can define a struct declared in an outer scope inside another struct, and the compiler won't even complain... C, what a language. Fixes rust-lang#1281
ir: Remove an assertion that happens to be invalid. You can define a struct declared in an outer scope inside another struct. C, what a language. Fixes #1281
Thanks! @emilio do you know when a there will be a new release with this fix included? |
rustc fail to compile variadic function with ms_abi: error[E0045]: variadic function must have C or cdecl calling convention As suggested in issue, this short term fix: not generate binding and emit a warning. Fixes rust-lang#1281
The following typedef does not compile on latest bindgen (0.33.2). Additionally there does not appear to be a way for me to ignore it and the error emitted. Bindings were able to be generated up to 0.30.0.
Input C/C++ Header
https://github.com/zfsonlinux/zfs/blob/387b6856d6d6997ae5849b8ad9155433fff6f077/include/sys/zfs_ioctl.h#L187-L333
Bindgen Invocation
Actual Results
Expected Results
Bindings to be generated.
The text was updated successfully, but these errors were encountered: