diff --git a/std/src/sync/mutex.rs b/std/src/sync/mutex.rs index 3ea0a6c39..aacc893ba 100644 --- a/std/src/sync/mutex.rs +++ b/std/src/sync/mutex.rs @@ -192,6 +192,7 @@ unsafe impl Sync for Mutex {} points can cause deadlocks, delays, \ and cause Futures to not implement `Send`"] #[stable(feature = "rust1", since = "1.0.0")] +#[clippy::has_significant_drop] pub struct MutexGuard<'a, T: ?Sized + 'a> { lock: &'a Mutex, poison: poison::Guard, diff --git a/std/src/sync/rwlock.rs b/std/src/sync/rwlock.rs index ed62fa977..9ec0903f0 100644 --- a/std/src/sync/rwlock.rs +++ b/std/src/sync/rwlock.rs @@ -99,6 +99,7 @@ unsafe impl Sync for RwLock {} points can cause deadlocks, delays, \ and cause Futures to not implement `Send`"] #[stable(feature = "rust1", since = "1.0.0")] +#[clippy::has_significant_drop] pub struct RwLockReadGuard<'a, T: ?Sized + 'a> { lock: &'a RwLock, } @@ -122,6 +123,7 @@ unsafe impl Sync for RwLockReadGuard<'_, T> {} points can cause deadlocks, delays, \ and cause Future's to not implement `Send`"] #[stable(feature = "rust1", since = "1.0.0")] +#[clippy::has_significant_drop] pub struct RwLockWriteGuard<'a, T: ?Sized + 'a> { lock: &'a RwLock, poison: poison::Guard,