diff options
| author | Botahamec <botahamec@outlook.com> | 2024-12-20 18:28:08 -0500 |
|---|---|---|
| committer | Botahamec <botahamec@outlook.com> | 2024-12-20 18:28:08 -0500 |
| commit | 85dd2106bdc3476c0eb73c97f2f4b338a3486749 (patch) | |
| tree | 096e5fd71a67949bbf45a0e79f2357d64acb96d6 /src/rwlock/rwlock.rs | |
| parent | 6514ffc5b33962c98fe9ce8f123edca6c57668d8 (diff) | |
Fix clippy issues
Diffstat (limited to 'src/rwlock/rwlock.rs')
| -rw-r--r-- | src/rwlock/rwlock.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/rwlock/rwlock.rs b/src/rwlock/rwlock.rs index fddcf5a..063ab68 100644 --- a/src/rwlock/rwlock.rs +++ b/src/rwlock/rwlock.rs @@ -62,7 +62,7 @@ impl<T: ?Sized + Debug, R: RawRwLock> Debug for RwLock<T, R> { } } -impl<T: ?Sized + Default, R: RawRwLock> Default for RwLock<T, R> { +impl<T: Default, R: RawRwLock> Default for RwLock<T, R> { fn default() -> Self { Self::new(T::default()) } @@ -140,7 +140,7 @@ impl<T: ?Sized, R: RawRwLock> RwLock<T, R> { pub fn read<'s, 'key: 's, Key: Keyable>( &'s self, key: Key, - ) -> RwLockReadGuard<'_, 'key, T, Key, R> { + ) -> RwLockReadGuard<'s, 'key, T, Key, R> { unsafe { self.raw.lock_shared(); @@ -172,7 +172,7 @@ impl<T: ?Sized, R: RawRwLock> RwLock<T, R> { pub fn try_read<'s, 'key: 's, Key: Keyable>( &'s self, key: Key, - ) -> Option<RwLockReadGuard<'_, 'key, T, Key, R>> { + ) -> Option<RwLockReadGuard<'s, 'key, T, Key, R>> { unsafe { if self.raw.try_lock_shared() { // safety: the lock is locked first @@ -233,7 +233,7 @@ impl<T: ?Sized, R: RawRwLock> RwLock<T, R> { pub fn write<'s, 'key: 's, Key: Keyable>( &'s self, key: Key, - ) -> RwLockWriteGuard<'_, 'key, T, Key, R> { + ) -> RwLockWriteGuard<'s, 'key, T, Key, R> { unsafe { self.raw.lock_exclusive(); @@ -266,7 +266,7 @@ impl<T: ?Sized, R: RawRwLock> RwLock<T, R> { pub fn try_write<'s, 'key: 's, Key: Keyable>( &'s self, key: Key, - ) -> Option<RwLockWriteGuard<'_, 'key, T, Key, R>> { + ) -> Option<RwLockWriteGuard<'s, 'key, T, Key, R>> { unsafe { if self.raw.try_lock_exclusive() { // safety: the lock is locked first |
