Description
#[clippy::has_significant_drop] was added for the lint clippy::significant_drop_in_scrutinee.
The clippy::let_underscore_lock currently uses a hardcoded list of type paths to lint against:
|
const SYNC_GUARD_PATHS: [&[&str]; 5] = [ |
|
&paths::MUTEX_GUARD, |
|
&paths::RWLOCK_READ_GUARD, |
|
&paths::RWLOCK_WRITE_GUARD, |
|
&paths::PARKING_LOT_RAWMUTEX, |
|
&paths::PARKING_LOT_RAWRWLOCK, |
|
]; |
Instead, it should use the presence of the new #[clippy::has_significant_drop] attribute.
Checking for the parking_lot types by path might need to stay around for a while until most parking_lot consumers are using a version with the #[clippy::has_significant_drop] attribute.
Version
Additional Labels
@rustbot label +C-enhancement +C-an-interesting-project
(I guess)
Description
#[clippy::has_significant_drop]was added for the lintclippy::significant_drop_in_scrutinee.The
clippy::let_underscore_lockcurrently uses a hardcoded list of type paths to lint against:rust-clippy/clippy_lints/src/let_underscore.rs
Lines 108 to 114 in a98e7ab
Instead, it should use the presence of the new
#[clippy::has_significant_drop]attribute.Checking for the
parking_lottypes by path might need to stay around for a while until mostparking_lotconsumers are using a version with the#[clippy::has_significant_drop]attribute.Version
Additional Labels
@rustbot label +C-enhancement +C-an-interesting-project
(I guess)