[][src]Struct alloc_compose::region::raw::RawSharedRegion

pub struct RawSharedRegion { /* fields omitted */ }
This is supported on crate feature alloc only.

Implementations

impl RawSharedRegion[src]

A clonable region allocator based on Rc.

This is the non-lifetime version of SharedRegion.

pub unsafe fn new(memory: NonNull<[u8]>) -> Self[src]

Creates a new region from the given memory block.

Safety

Behavior is undefined if any of the following conditions are violated:

  • memory must be valid for reads and writes for memory.len() many bytes.

  • memory must outlive the region.

  • memory.len() must be no larger than isize::MAX. See the safety documentation of pointer::offset.

For a safe variant use SharedRegion instead.

Trait Implementations

impl AllocRef for RawSharedRegion[src]

impl AllocateAll for RawSharedRegion[src]

impl Clone for RawSharedRegion[src]

impl Debug for RawSharedRegion[src]

impl GlobalAlloc for RawSharedRegion[src]

impl Owns for RawSharedRegion[src]

impl PartialEq<RawSharedRegion> for RawSharedRegion[src]

impl<'_> PartialEq<RawSharedRegion> for SharedRegion<'_>[src]

impl<'_> PartialEq<SharedRegion<'_>> for RawSharedRegion[src]

Auto Trait Implementations

impl !Send for RawSharedRegion

impl !Sync for RawSharedRegion

impl Unpin for RawSharedRegion

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.