-
Notifications
You must be signed in to change notification settings - Fork 707
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
*_enum() takes item name after parse_callbacks processing instead of before #1891
Comments
Yeah, I agree the inconsitency is wrong. This seems like a long-standing bug. The issue is that this line: rust-bindgen/src/ir/enum_ty.rs Line 156 in 57db723
Is using Should be a pretty easy bug to fix. |
I searched through the code base and issues a little bit and found #1125 and #1162 , and it seems that whitelist/blacklist was using rust-bindgen/src/ir/template.rs Lines 309 to 317 in d5cdad2
which I believe may have the same issue when using |
There are multiple occurrences of both canonical_path and namespace_aware_canonical_path in However yes, I think that code should probably also be using |
Input C/C++ Header
enum Test { OptionA, OptionB, OptionC };
Bindgen Invocation
Actual Results
Expected Results
Should generate bitfield enum. I figured out that changing the invocation to
will generate expected bindings.
This may not be a bug but it is definitely not documented. And it seems inconsistent with other APIs, since other APIs like
whitelist_type()
asks for name beforeparse_callbacks
processing.The text was updated successfully, but these errors were encountered: