Expand description
Utility
This module is exempt from the API stability guarantee unless specified otherwise. It’s exposed mostly because it’s needed by macros.
Re-exports
Zeroable
,ZeroableInOption
: Re-exported frombytemuck
^1
.Zeroable
is a marker trait used inHunkDefiner::zeroed
and suchlike. It can be derived for struct types. These re-exports are subject to the application-side API stability guarantee.
Modules
Structs
- Untyped storage of the specified size and alignment. This is analogous to C++’s
std::aligned_storage_t
. - The
AllocError
error indicates an allocation failure that may be due to resource exhaustion or to something wrong when combining the given input arguments with this allocator. - Compile-time allocator.
- Erases interior mutability by preventing reference forming.
- Like
UnsafeCell
, but implementsSync
.
Traits
const fn
-compatiblecore::alloc::Allocator
.- Trait for types having a constant default value. This is essentially a constant version of
Default
. - Trait for types that can be safely created with
zeroed
.
Type Definitions
- A phantom type that is invariant over
T
.
Derive Macros
- Derive the
Zeroable
trait for a struct