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
37
38
39
40
//! Completion-based async runtime with optional orchestration.
//!
//! This crate is the sole user entry point: every item re-exported here
//! is the supported surface over the workspace crates, and nothing
//! outside it is a stability promise. The runtime is scheduler-explicit
//! by design -- construct [`runtime::Runtime::affine`] for a pinned
//! thread-per-core worker or [`runtime::Runtime::stealing`] for a
//! work-stealing crew; there is no default scheduler.
//!
//! Tasks fan out through structured scopes ([`task::scope`] and the
//! `Send`-bounded [`task::scope_send`]) rather than a free-standing
//! spawn, so every child settles before its scope resolves.
//! [`time::sleep`] suspends a task for a wall-clock duration.
//!
//! Network and filesystem endpoints live under the `net` and `fs`
//! modules, each gated behind its own feature (`net`, `fs`, or `full`)
//! so a minimal build pulls in neither. Every runtime task carries a
//! tree-structured identity for tracing, but the runtime does not hand
//! it back yet.
//!
//! # Examples
//!
//! ```rust
//! let mut runtime = kwokka::runtime::Runtime::affine()?;
//! let value = runtime.block_on(async { 41 + 1 });
//! assert_eq!(value, 42);
//! # Ok::<(), std::io::Error>(())
//! ```
pub use main;