Lines Matching refs:T
145 pub struct SpinLock<T> {
148 data: UnsafeCell<T>,
155 pub struct SpinLockGuard<'a, T: 'a> {
156 lock: &'a SpinLock<T>,
161 unsafe impl<T> Sync for SpinLock<T> where T: Send {}
163 impl<T> SpinLock<T> {
164 pub const fn new(value: T) -> Self { in new()
172 pub fn lock(&self) -> SpinLockGuard<T> { in lock() argument
180 impl<T> Deref for SpinLockGuard<'_, T> {
181 type Target = T;
189 impl<T> DerefMut for SpinLockGuard<'_, T> {
196 impl<T> Drop for SpinLockGuard<'_, T> {