bitcoin-sync 0.1.19

Low-level synchronization, semaphore, lock-order debugging, and interruptible thread utilities modelled after Bitcoin Core, built on parking_lot and tracing.
// ---------------- [ File: bitcoin-sync/src/types.rs ]
crate::ix!();

/**
  | Wrapped mutex: supports recursive
  | locking, but no waiting
  | 
  | TODO: We should move away from using
  | the recursive lock by default.
  |
  */
pub type RecursiveMutex<T> = AnnotatedMixin<parking_lot::ReentrantMutex<T>>;

/**
  | Wrapped mutex: supports waiting but
  | not recursive locking
  |
  */
pub type WrappedMutex = AnnotatedMixin<parking_lot::RawMutex>;

pub type DebugLock<'a, MutexArg> =
    UniqueLock<'a, RemoveReference<RemovePointer<MutexArg>>>;