Expand description
Odds and ends — collection miscellania.
- Utilities for debug-checked, release-unchecked indexing and slicing
- Fixpoint combinator for closures
- String and Vec extensions
The odds crate has the following crate feature flags:
std-vec
- Enable Vec extensions
- Implies
std
std-string
- Enable String extensions
- Implies
std
std
- Enable basic libstd usage.
unstable
.- Optional.
- Requires nightly channel.
- Implement the closure traits for Fix.
If none of the std features are enabled (they are not enabled by default),
then the crate is no_std
.
§Rust Version
This version of the crate requires Rust 1.15 or later.
Modules§
- char
- Extra functions for
char
- prelude
- prelude of often used traits and functions
- slice
- Extra functions for slices
- stride
- Slice iterator with custom step size
- string
- Extensions to
&str
andString
- vec
- Extensions to
Vec
Structs§
- Fix
- Fixpoint combinator for rust closures, generalized over the return type.
Traits§
- Index
Range - IndexRange is implemented by Rust’s built-in range types, produced
by range syntax like
..
,a..
,..b
orc..d
.
Functions§
- debug_
assert_ ⚠unreachable - Act as
debug_assert!
in debug mode, asserting that this point is not reached. - fix
- Fixpoint combinator for rust closures, generalized over the return type.
- raw_
byte_ ⚠repr - Safe to use with any wholly initialized memory
ptr
- ref_
slice - Create a length 1 slice out of a reference
- ref_
slice_ mut - Create a length 1 mutable slice out of a reference