pub trait AllocatorDefault:
Allocator
+ Clone
+ Default {
const DEFAULT: Self;
}Expand description
A trait implemented by allocators supporting a constant initializer.
This cannot use ConstDefault as it is not implemented for the external
Global allocator.
Required Associated Constants§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.
Implementors§
Source§impl AllocatorDefault for Global
Available on crate feature alloc only.
impl AllocatorDefault for Global
Available on crate feature
alloc only.Source§impl<'a, A: AllocatorDefault> AllocatorDefault for Spill<'a, A>
impl<'a, A: AllocatorDefault> AllocatorDefault for Spill<'a, A>
Source§impl<A: AllocatorDefault> AllocatorDefault for ZeroizingAlloc<A>
Available on crate feature zeroize only.
impl<A: AllocatorDefault> AllocatorDefault for ZeroizingAlloc<A>
Available on crate feature
zeroize only.