Name Description Size Coverage
condvar.rs 42758 -
deadlock.rs \[Experimental\] Deadlock detection This feature is optional and can be enabled via the `deadlock_detection` feature flag. # Example ``` #[cfg(feature = "deadlock_detection")] { // only for #[cfg] use std::thread; use std::time::Duration; use parking_lot::deadlock; // Create a background thread which checks for deadlocks every 10s thread::spawn(move || { loop { thread::sleep(Duration::from_secs(10)); let deadlocks = deadlock::check_deadlock(); if deadlocks.is_empty() { continue; } println!("{} deadlocks detected", deadlocks.len()); for (i, threads) in deadlocks.iter().enumerate() { println!("Deadlock #{}", i); for t in threads { println!("Thread Id {:#?}", t.thread_id()); println!("{:#?}", t.backtrace()); } } } }); } // only for #[cfg] ``` 6113 -
elision.rs 3340 -
fair_mutex.rs 8816 -
lib.rs This library provides implementations of `Mutex`, `RwLock`, `Condvar` and `Once` that are smaller, faster and more flexible than those in the Rust standard library. It also provides a `ReentrantMutex` type. 2143 -
mutex.rs 10007 -
once.rs 13806 -
raw_fair_mutex.rs 1634 -
raw_mutex.rs 11796 -
raw_rwlock.rs 38354 -
remutex.rs 5545 -
rwlock.rs 19824 -
util.rs 1006 -