Expand description
Crate-internal prelude: fills the no_std gaps with alloc/core items.
In std builds the std prelude already provides most of these; the glob
import here is harmless (same types) and only activates under no_std.
Structs§
- Arc
- A thread-safe reference-counting pointer. ‘Arc’ stands for ‘Atomically Reference Counted’.
- BTree
Map - An ordered map based on a B-Tree.
- BTree
Set - An ordered set based on a B-Tree.
- Box
- A pointer type that uniquely owns a heap allocation of type
T. - Duration
- A
Durationtype to represent a span of time, typically used for system timeouts. - Ipv4
Addr - An IPv4 address.
- String
- A UTF-8–encoded, growable string.
- Vec
- A contiguous growable array type, written as
Vec<T>, short for ‘vector’. - Weak
Weakis a version ofArcthat holds a non-owning reference to the managed allocation.
Enums§
- Cow
- A clone-on-write smart pointer.
- IpAddr
- An IP address, either IPv4 or IPv6.
- Socket
Addr - An internet socket address, either IPv4 or IPv6.
Traits§
- ToOwned
- A generalization of
Cloneto borrowed data.