Crate mycelium_util
source ·Expand description
mycelium-util
🍄 a “standard library” for programming in the Mycelium kernel and related libraries.
overview
This crate is a collection of general-purpose utility types and traits for use in the Mycelium operating system and its related libraries.
Warning This crate is not really intended for general public consumption — it’s written specifically for use in Mycelium. While it can be used elsewhere, it may have a number of Mycelium-specific quirks and design decisions. It’s being published to crates.io primarily so that other crates which depend on it can be published, not because it’s expected to be broadly useful outside of Mycelium.
Also, because this crate exists primarily for use in Mycelium, breaking changes may be released frequently, and previous major versions will generally not be supported.
features
The following features are available (this list is incomplete; you can help by expanding it.)
Feature | Default | Explanation |
---|---|---|
no-cache-pad | false | Inhibits cache padding for the CachePadded struct. When this feature is NOT enabled, the size will be determined based on target platform. |
alloc | false | Enables liballoc dependency |
Re-exports
pub use cordyceps as intrusive;
pub use mycelium_bitfield as bits;
Modules
- An
Error
trait based onstd::error::Error
. - Text formatting utilities.
- A modified version of the Rust standard library’s
std::io
module, suitable for use in Mycelium and other kernels. - Math utilities.
- Basic functions for dealing with memory.
- Synchronization primitives, and utilities for implementing them.
Macros
- Variadic version of
core::cmp::max
. - Variadic version of
core::cmp::min
. - Indicates unreachable code that we are confident is truly unreachable.