Trait AllocatorNightly
pub trait AllocatorNightly: Allocator
Allocator marker trait that is only implemented stably for Global.
This trait is used as a bound whenever a function constructing
a type with an #[unstable] A: Allocator = Global parameter
may be callable for A != Global.
This is to prevent stable code from e.g. constructing Arc<T, NotGlobal>
using the From<Box<T, A>> for Arc<T, A> impl.
Note that this trait will be removed in the future, but downstream allocators should still feel free to implement it on nightly, to allow use of all containers with unstable allocator support.
Implementors
impl<A: Allocator + ?Sized> AllocatorNightly for &Aimpl<A: Allocator + ?Sized> AllocatorNightly for &mut Aimpl<P> AllocatorNightly for Pin<P> where P: Deref<Target: Allocator> + PinSafePointer,