diff options
Diffstat (limited to 'src/libstd/sync')
| -rw-r--r-- | src/libstd/sync/mutex.rs | 1 | ||||
| -rw-r--r-- | src/libstd/sync/rwlock.rs | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/src/libstd/sync/mutex.rs b/src/libstd/sync/mutex.rs index aabc06b1986..c0cd6d127d2 100644 --- a/src/libstd/sync/mutex.rs +++ b/src/libstd/sync/mutex.rs @@ -293,6 +293,7 @@ impl<T: ?Sized> Mutex<T> { #[stable(feature = "rust1", since = "1.0.0")] impl<T: ?Sized> Drop for Mutex<T> { + #[unsafe_destructor_blind_to_params] fn drop(&mut self) { // This is actually safe b/c we know that there is no further usage of // this mutex (it's up to the user to arrange for a mutex to get diff --git a/src/libstd/sync/rwlock.rs b/src/libstd/sync/rwlock.rs index 9278481f2d6..750c9e30c5c 100644 --- a/src/libstd/sync/rwlock.rs +++ b/src/libstd/sync/rwlock.rs @@ -314,6 +314,7 @@ impl<T: ?Sized> RwLock<T> { #[stable(feature = "rust1", since = "1.0.0")] impl<T: ?Sized> Drop for RwLock<T> { + #[unsafe_destructor_blind_to_params] fn drop(&mut self) { // IMPORTANT: This code needs to be kept in sync with `RwLock::into_inner`. unsafe { self.inner.lock.destroy() } |
