Bad error message when a strong dep features's depedency is an unused optional dependency #14016
Labels
A-editions
Area: edition-specific issues
A-features
Area: features — conditional compilation
C-bug
Category: bug
S-needs-team-input
Status: Needs input from team on whether/how to proceed.
Problem
If nothing can activate an optional dependency, cargo acts as if the dependency doesn't exist which creates poor error messages.
Also, with how things are arranged, the unused optional dependency lint doesn't get reported which could at least reduce the burden on the error message.
Steps
Baseline
Cargo.toml
:Add the following to
Cargo.toml
:Possible Solution(s)
dep:serde
ifserde/derive
is usedserde/derive
syntax, removing it in a new edition (Transition out weak feature syntax in an edition #10556)Notes
This was split out of #14015 assuming we'll go with a different solution than it
Version
No response
The text was updated successfully, but these errors were encountered: