diff options
| author | Botahamec <botahamec@outlook.com> | 2024-05-22 17:27:35 -0400 |
|---|---|---|
| committer | Botahamec <botahamec@outlook.com> | 2024-05-22 17:27:35 -0400 |
| commit | ef191a3e8ecf4093fcd08036e35012c1af173a08 (patch) | |
| tree | 9a6986986ad8392ae147c64c436214fa290773d7 /src/collection/boxed.rs | |
| parent | ebbe3cfce28914d776f3e5f89894fab50911c57e (diff) | |
Documentation for types
Diffstat (limited to 'src/collection/boxed.rs')
| -rw-r--r-- | src/collection/boxed.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/collection/boxed.rs b/src/collection/boxed.rs index a62a33d..ea840ab 100644 --- a/src/collection/boxed.rs +++ b/src/collection/boxed.rs @@ -1,14 +1,14 @@ use std::fmt::Debug; use std::marker::PhantomData; -use crate::lockable::Lock; -use crate::{Keyable, Lockable, OwnedLockable, Sharable}; +use crate::lockable::{Lockable, OwnedLockable, RawLock, Sharable}; +use crate::Keyable; use super::{BoxedLockCollection, LockGuard}; /// returns `true` if the sorted list contains a duplicate #[must_use] -fn contains_duplicates(l: &[&dyn Lock]) -> bool { +fn contains_duplicates(l: &[&dyn RawLock]) -> bool { l.windows(2) .any(|window| std::ptr::eq(window[0], window[1])) } @@ -18,7 +18,7 @@ unsafe impl<L: Lockable> Lockable for BoxedLockCollection<L> { type ReadGuard<'g> = L::ReadGuard<'g> where Self: 'g; - fn get_ptrs<'a>(&'a self, ptrs: &mut Vec<&'a dyn Lock>) { + fn get_ptrs<'a>(&'a self, ptrs: &mut Vec<&'a dyn RawLock>) { self.data.get_ptrs(ptrs) } |
