]> git.proxmox.com Git - rustc.git/blame - vendor/parking_lot-0.9.0/src/lib.rs
New upstream version 1.48.0+dfsg1
[rustc.git] / vendor / parking_lot-0.9.0 / src / lib.rs
CommitLineData
83c7162d
XL
1// Copyright 2016 Amanieu d'Antras
2//
3// Licensed under the Apache License, Version 2.0, <LICENSE-APACHE or
4// http://apache.org/licenses/LICENSE-2.0> or the MIT license <LICENSE-MIT or
5// http://opensource.org/licenses/MIT>, at your option. This file may not be
6// copied, modified, or distributed except according to those terms.
7
8//! This library provides implementations of `Mutex`, `RwLock`, `Condvar` and
9//! `Once` that are smaller, faster and more flexible than those in the Rust
10//! standard library. It also provides a `ReentrantMutex` type.
11
12#![warn(missing_docs)]
e1599b0c 13#![warn(rust_2018_idioms)]
83c7162d 14#![cfg_attr(feature = "nightly", feature(asm))]
83c7162d 15
b7449926 16mod condvar;
83c7162d 17mod elision;
b7449926
XL
18mod mutex;
19mod once;
83c7162d 20mod raw_mutex;
83c7162d 21mod raw_rwlock;
83c7162d
XL
22mod remutex;
23mod rwlock;
b7449926 24mod util;
83c7162d
XL
25
26#[cfg(feature = "deadlock_detection")]
27pub mod deadlock;
28#[cfg(not(feature = "deadlock_detection"))]
29mod deadlock;
30
e1599b0c
XL
31pub use ::lock_api as lock_api;
32pub use self::condvar::{Condvar, WaitTimeoutResult};
33pub use self::mutex::{MappedMutexGuard, Mutex, MutexGuard};
34pub use self::once::{Once, OnceState};
35pub use self::raw_mutex::RawMutex;
36pub use self::raw_rwlock::RawRwLock;
37pub use self::remutex::{
38 MappedReentrantMutexGuard, RawThreadId, ReentrantMutex, ReentrantMutexGuard,
39};
40pub use self::rwlock::{
b7449926
XL
41 MappedRwLockReadGuard, MappedRwLockWriteGuard, RwLock, RwLockReadGuard,
42 RwLockUpgradableReadGuard, RwLockWriteGuard,
43};