Struct contiguous_mem::ImplUnsafe
source · pub struct ImplUnsafe;Expand description
A marker struct representing the behavior specialization for unsafe implementation. Should be used when the container is guaranteed to outlive any pointers to data contained in represented memory block.
Trait Implementations§
source§impl Clone for ImplUnsafe
impl Clone for ImplUnsafe
source§fn clone(&self) -> ImplUnsafe
fn clone(&self) -> ImplUnsafe
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl PartialEq<ImplUnsafe> for ImplUnsafe
impl PartialEq<ImplUnsafe> for ImplUnsafe
source§fn eq(&self, other: &ImplUnsafe) -> bool
fn eq(&self, other: &ImplUnsafe) -> bool
This method tests for
self and other values to be equal, and is used
by ==.source§impl StoreData<ImplUnsafe> for ContiguousMemoryStorage<ImplUnsafe>
impl StoreData<ImplUnsafe> for ContiguousMemoryStorage<ImplUnsafe>
source§unsafe fn store_data<T: StoreRequirements>(
&mut self,
data: *mut T,
layout: Layout
) -> Result<*mut T, ContiguousMemoryError>
unsafe fn store_data<T: StoreRequirements>( &mut self, data: *mut T, layout: Layout ) -> Result<*mut T, ContiguousMemoryError>
Returns a raw pointer (*mut T) to the stored value or a
ContiguousMemoryError::NoStorageLeft indicating that the container
couldn’t store the provided data with current size.
Memory block can still be grown by calling ContiguousMemory::resize,
but it can’t be done automatically as that would invalidate all the
existing pointers without any indication.
impl Copy for ImplUnsafe
impl Eq for ImplUnsafe
impl StructuralEq for ImplUnsafe
impl StructuralPartialEq for ImplUnsafe
Auto Trait Implementations§
impl RefUnwindSafe for ImplUnsafe
impl Send for ImplUnsafe
impl Sync for ImplUnsafe
impl Unpin for ImplUnsafe
impl UnwindSafe for ImplUnsafe
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more