Struct composable_allocators::Impossible
source · [−]pub struct Impossible(pub !);
Tuple Fields
0: !
Trait Implementations
sourceimpl Allocator for Impossible
impl Allocator for Impossible
sourcefn allocate(&self, _layout: Layout) -> Result<NonNull<[u8]>, AllocError>
fn allocate(&self, _layout: Layout) -> Result<NonNull<[u8]>, AllocError>
🔬 This is a nightly-only experimental API. (
allocator_api
)Attempts to allocate a block of memory. Read more
sourceunsafe fn deallocate(&self, _ptr: NonNull<u8>, _layout: Layout)
unsafe fn deallocate(&self, _ptr: NonNull<u8>, _layout: Layout)
🔬 This is a nightly-only experimental API. (
allocator_api
)Deallocates the memory referenced by ptr
. Read more
sourceunsafe fn grow(
&self,
_ptr: NonNull<u8>,
_old_layout: Layout,
_new_layout: Layout
) -> Result<NonNull<[u8]>, AllocError>
unsafe fn grow(
&self,
_ptr: NonNull<u8>,
_old_layout: Layout,
_new_layout: Layout
) -> Result<NonNull<[u8]>, AllocError>
🔬 This is a nightly-only experimental API. (
allocator_api
)Attempts to extend the memory block. Read more
sourceunsafe fn shrink(
&self,
_ptr: NonNull<u8>,
_old_layout: Layout,
_new_layout: Layout
) -> Result<NonNull<[u8]>, AllocError>
unsafe fn shrink(
&self,
_ptr: NonNull<u8>,
_old_layout: Layout,
_new_layout: Layout
) -> Result<NonNull<[u8]>, AllocError>
🔬 This is a nightly-only experimental API. (
allocator_api
)Attempts to shrink the memory block. Read more
sourcefn allocate_zeroed(&self, layout: Layout) -> Result<NonNull<[u8]>, AllocError>
fn allocate_zeroed(&self, layout: Layout) -> Result<NonNull<[u8]>, AllocError>
🔬 This is a nightly-only experimental API. (
allocator_api
)Behaves like allocate
, but also ensures that the returned memory is zero-initialized. Read more
sourceimpl Clone for Impossible
impl Clone for Impossible
sourcefn clone(&self) -> Impossible
fn clone(&self) -> Impossible
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Fallbackable for Impossible
impl Fallbackable for Impossible
impl Copy for Impossible
Auto Trait Implementations
impl RefUnwindSafe for Impossible
impl Send for Impossible
impl Sync for Impossible
impl Unpin for Impossible
impl UnwindSafe for Impossible
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more