let_underscore_drop false positive for references to types that implement Drop #6633
Labels
C-bug
Category: Clippy is not doing the correct thing
E-medium
Call for participation: Medium difficulty level problem and requires some initial experience.
I-false-positive
Issue: The lint was triggered on code it shouldn't have
T-middle
Type: Probably requires verifiying types
Lint name:
let_underscore_drop
let_underscore_drop
complains aboutlet _ = ...
bindings where the right-hand side is a reference to a type that implementsDrop
, even when the reference type itself does not implementDrop
.Example:
let_underscore_drop
complains about thelet _ = ...
line, but the right-hand side of thelet
binding has type&mut ImplementsDrop
, which is a reference type that does not implementDrop
, even thoughImplementsDrop
does.Meta
cargo clippy -V
: clippy 0.1.51 (4d0dd02 2021-01-23)rustc -Vv
:The text was updated successfully, but these errors were encountered: