cargo clippy error when using compile option --emit=obj, and crate-type = ["staticlib"] #13661
Labels
C-bug
Category: bug
S-needs-info
Status: Needs more info, such as a reproduction or more background for a feature request.
Problem
I have a simple crate, the crate-type is staticlib, and depends on lazy_static, when add compile option --emit=obj, cargo clippy error.
Steps
rust_project/Cargo.toml:
rust_project/src/lib.rs:
rust_project/.cargo/config.toml
Then
cargo build
is successful.But
cargo clippy
fails with the following error:When the crate-type is a dylib, the cargo clippy has the same error.
Is there a way to make clippy not report an error, but the --emit=obj option and crate-type = ["staticlib"] can't be changed?
Possible Solution(s)
No response
Notes
No response
Version
The text was updated successfully, but these errors were encountered: