-
Notifications
You must be signed in to change notification settings - Fork 197
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: unused_unsafe in generated code #752
Comments
The warning is a result of the Rust code generation from |
thanks @peterhuene |
I may have already fixed this with 560cf56, but Do you happen to have a repro case so that I can ensure that updating dependencies to include the fix will also address your issue? |
// src/lib.rs
cargo_component_bindings::generate!();
use bindings::Guest;
pub struct Component;
impl Guest for Component {
fn run(_config: String) {
todo!()
}
} |
I've confirmed that this is fixed by the above commit; the next release of cargo-component should prevent the unused unsafe warning. |
I'm going to close the issue as fixed, but if for some reason you still encounter the warning after the next cargo-component release (should be immediately following Wasmtime 15), please reactive and let us know. Thanks for reporting this! |
Also, I'll put up a cargo-component PR in just a few minutes to get the deps updated in main so that if you build cargo-component from source it'll have the fix. |
I got this clippy failure on generated code
The text was updated successfully, but these errors were encountered: