Struct rustc_data_structures::sync::Lock
[−]
[src]
pub struct Lock<T>(_);
Methods
impl<T> Lock<T>
[src]
pub fn new(inner: T) -> Self
[src]
pub fn into_inner(self) -> T
[src]
ⓘImportant traits for &'a mut Wpub fn get_mut(&mut self) -> &mut T
[src]
ⓘImportant traits for &'a mut W
pub fn lock(&self) -> LockGuard<T>
[src]
pub fn with_lock<F: FnOnce(&mut T) -> R, R>(&self, f: F) -> R
[src]
pub fn borrow(&self) -> LockGuard<T>
[src]
pub fn borrow_mut(&self) -> LockGuard<T>
[src]
Trait Implementations
impl<T: Debug> Debug for Lock<T>
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more