pub unsafe trait RawRwLockUpgradeDowngrade: RawRwLockUpgrade + RawRwLockDowngrade {
// Required methods
unsafe fn downgrade_upgradable(&self);
unsafe fn downgrade_to_upgradable(&self);
}
Expand description
Additional methods for RwLocks which support upgradable locks and lock downgrading.
Required Methods§
Sourceunsafe fn downgrade_upgradable(&self)
unsafe fn downgrade_upgradable(&self)
Downgrades an upgradable lock to a shared lock.
§Safety
This method may only be called if an upgradable lock is held in the current context.
Sourceunsafe fn downgrade_to_upgradable(&self)
unsafe fn downgrade_to_upgradable(&self)
Downgrades an exclusive lock to an upgradable lock.
§Safety
This method may only be called if an exclusive lock is held in the current context.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.