1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
//! Asynchronous synchronization primitives based on intrusive collections.
//!
//! This module provides various primitives for synchronizing concurrently
//! executing futures.

mod manual_reset_event;

pub use self::manual_reset_event::{
    GenericManualResetEvent, GenericWaitForEventFuture, LocalManualResetEvent,
    LocalWaitForEventFuture,
};

#[cfg(feature = "alloc")]
pub use self::manual_reset_event::{ManualResetEvent, WaitForEventFuture};

mod mutex;

pub use self::mutex::{
    GenericMutex, GenericMutexGuard, GenericMutexLockFuture, LocalMutex,
    LocalMutexGuard, LocalMutexLockFuture,
};

#[cfg(feature = "alloc")]
pub use self::mutex::{Mutex, MutexGuard, MutexLockFuture};

mod semaphore;

pub use self::semaphore::{
    GenericSemaphore, GenericSemaphoreAcquireFuture, GenericSemaphoreReleaser,
    LocalSemaphore, LocalSemaphoreAcquireFuture, LocalSemaphoreReleaser,
};

#[cfg(feature = "alloc")]
pub use self::semaphore::{
    Semaphore, SemaphoreAcquireFuture, SemaphoreReleaser,
};