umsh_sync/lib.rs
1//! Single-threaded async synchronization primitives for UMSH.
2//!
3//! - [`AsyncCondition`] — a wake-all condition variable with slab-backed
4//! ticketed deregistration.
5//! - [`AsyncRefCell`] — an async-aware `RefCell` whose `borrow()` /
6//! `borrow_mut()` futures wait instead of panicking when the cell is in
7//! use.
8//!
9//! Everything here is `no_std + alloc`, single-threaded, and executor-
10//! agnostic: it works under tokio (with a `LocalSet`), embassy, or any
11//! custom async runtime that polls futures to completion.
12
13#![no_std]
14
15extern crate alloc;
16
17pub mod async_condition;
18pub mod async_refcell;
19
20pub use async_condition::{AsyncCondition, AsyncConditionTicket, AsyncConditionWait};
21pub use async_refcell::{AsyncRefCell, Ref, RefMut, ScopedTicket};