-
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
Rust error: type parameter is unused #820
Comments
This is probably workaround-able via blacklisting any involving type, but that would be annoying. |
I'm C-Reducing this right now :-P Nice to have you beat me to it :) |
It looks like we aren't following this let mut used_template_params = item.used_template_params(ctx);
let inner_rust_type = if item.is_opaque(ctx, &()) {
used_template_params = None;
self.to_opaque(ctx, item)
} else {
// Its possible that we have better layout information than
// the inner type does, so fall back to an opaque blob based
// on our layout if converting the inner item fails.
inner_item.try_to_rust_ty_or_opaque(ctx, &())
.unwrap_or_else(|_| self.to_opaque(ctx, item))
}; I would expect that teh |
Oh, it turns out we're just plain missing that case from any of our |
This allows us to properly detect structs that should be treated as opaque due to their non-type template paramaters, which in turn lets us correctly codegen template aliases to such things. Fixes rust-lang#820
Hmmm... My fix is running afoul of our regression test for #372. Investigating. |
This allows us to properly detect structs that should be treated as opaque due to their non-type template paramaters, which in turn lets us correctly codegen template aliases to such things. Fixes rust-lang#820
This allows us to properly detect structs that should be treated as opaque due to their non-type template paramaters, which in turn lets us correctly codegen template aliases to such things. Fixes rust-lang#820
This allows us to properly detect structs that should be treated as opaque due to their non-type template paramaters, which in turn lets us correctly codegen template aliases to such things. Fixes rust-lang#820
This allows us to properly detect structs that should be treated as opaque due to their non-type template paramaters, which in turn lets us correctly codegen template aliases to such things. Fixes rust-lang#820
This allows us to properly detect structs that should be treated as opaque due to their non-type template paramaters, which in turn lets us correctly codegen template aliases to such things. Fixes rust-lang#820
Input C/C++ Header
Bindgen Invocation
Actual Results
which is not valid in Rust.
Expected Results
Probably it doesn't need to generate anything in this case.
RUST_LOG=bindgen
OutputThe text was updated successfully, but these errors were encountered: