Lines Matching full:guard
34 /// let guard = v.try_access()?;
35 /// Some(guard.a + guard.b)
56 /// let guard = rcu::read_lock();
57 /// let e = v.try_access_with_guard(&guard)?;
96 /// Returns a guard that gives access to the object otherwise; the object is guaranteed to
97 /// remain accessible while the guard is alive. In such cases, callers are not allowed to sleep
100 let guard = rcu::read_lock(); in try_access() localVariable
104 Some(RevocableGuard::new(self.data.get(), guard)) in try_access()
115 /// remain accessible while the rcu read side guard is alive. In such cases, callers are not
118 pub fn try_access_with_guard<'a>(&'a self, _guard: &'a rcu::Guard) -> Option<&'a T> { in try_access_with_guard()
128 /// Tries to access the wrapped object and run a closure on it while the guard is held.
131 /// guard is dropped afterwards. [`Self::try_access`] carries the risk that the caller will
132 /// forget to explicitly drop that returned guard before calling sleepable code; this method
199 /// [`Revocable::try_access`] beforehand and still haven't dropped the returned guard), this
227 /// A guard that allows access to a revocable object and keeps it alive.
234 /// The RCU read-side lock is held while the guard is alive.
241 _rcu_guard: rcu::Guard,
246 fn new(data_ref: *const T, rcu_guard: rcu::Guard) -> Self { in new()