Registry / utility / lock-api

lock-api

JSON →
library0.4.14rscratesunverified

Provides wrappers to create fully-featured Mutex and RwLock types, compatible with no_std environments.

# Cargo.toml [dependencies] lock_api = "0.4.14"
INSTALL
IMPORT
SIG · LOCK-API
L
lock-api
utilityrustv0.4.14
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Mutex
use lock_api::Mutex;

Creates a Mutex using lock_api with parking_lot's RawMutex.

use lock_api::Mutex; use parking_lot::RawMutex; fn main() { let mutex = Mutex::<RawMutex, i32>::new(0); { let mut data = mutex.lock(); *data += 1; } println!("Value: {}", *mutex.lock()); }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.4.14latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
3 hits · last 30 days
node
2
Amazon
1
Resources
lock-api — cargo add lock-api · libregistry