Expand description
Provides stable const implementations for some things missing from the standard library.
Currently implemented are
- Functions in
result
to unwrapResult
s with generics or drop glue - Functions in the
concat
module to concat const strings and byte slices. destruct_tuple
to destructure tuples with generic types or types with drop glue in themnonnull_from
to createNonNull
s from mutable and regular references convenientlyman_drop_ref
/man_drop_mut
as a workaround for the lack of constDeref
implementations- Functions in
slice
to take subslices using ranges
Re-exports§
pub extern crate type_const;
Modules§
- concat
- Functions for concatenating slices
- mem
- Functions related to
core::mem
andcore::ptr
- result
- Functions for unwrapping
Result
s - slice
- Const variants of functions for dealing with slices
Macros§
- destruct_
tuple - Allows destructuring tuples in
const
contexts, regardless of items having drop glue.
Traits§
- Const
- Describes a type that holds an associated const value.
Functions§
- value_
of - Alias for
Const::VALUE
. Prefer this function over accessing the const directly.