Warn when feature is not required explicitly, but required by a transitive dependency #14375
Labels
A-features
Area: features — conditional compilation
A-new-lint
Area: new lint
C-feature-request
Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`
S-triage
Status: This issue is waiting on initial triage.
Uh oh!
There was an error while loading. Please reload this page.
Problem
this compiles with a cargo.toml that looks like this:
When removing rusoto_credential from cargo.toml I get this error:
The trait bound
DateTime<Utc>: Deserialize<'_>
is not satisfied [E0277] the traitDeserialize<'_>
is not implemented forDateTime<Utc>
This is because rusoto_credential also depends on chrono with the feature serde.
So adding that feature to my import of chrono solves it.
Proposed Solution
A warning about used features thats not explicitly imported would be nice, or something smarter that I cant think off <3
Notes
No response
The text was updated successfully, but these errors were encountered: