extra_unused_lifetimes
doesn't warn for lifetimes declared on impl
and never used
#6437
Labels
C-enhancement
Category: Enhancement of lints, like adding more cases or adding help messages
E-medium
Call for participation: Medium difficulty level problem and requires some initial experience.
I-false-negative
Issue: The lint should have been triggered on code, but wasn't
I tried this code (simplified from the actual code):
I expected to see this happen: I expected to get an unused lifetime warning for all the lifetimes in this example:
'a
because it's not used anywhere in theAddAssign
impl block (andAddAssign
's definition doesn't have any lifetimes),'b
because it's not used anywhere in theimpl Scalar
block, and'c
because it's not used anywhere infn something
.Instead, this happened: I only see a warning for
'c
:Meta
cargo clippy -V
: On the playground: 0.0.212 (2020-12-03 5be3f9f)rustc -Vv
: Stable on the playground: 1.48.0The text was updated successfully, but these errors were encountered: