Skip to main content

LockTokenWrite

Trait LockTokenWrite 

Source
pub trait LockTokenWrite<Class, Idx = TokenIndexHere> { }
Expand description

Trait implemented by lock tokens that grant exclusive (write) access to a cell guarded by Class.

When a cell is guarded by a single lock C, holding &mut LockToken<'_, C> grants write access. When a cell is guarded by multiple locks (C0, C1, ...), write access requires a joined mutable token proving exclusive ownership of ALL constituent locks simultaneously.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<Class> LockTokenWrite<Class> for LockToken<'_, Class>