[][src]Trait swim_mem::lease::DynamicLease

pub trait DynamicLease<'a>: Holder<'a> + Lease {
    unsafe fn resize(&mut self, layout: Layout) -> Result<(), HoldError>;
unsafe fn realloc(&mut self, layout: Layout) -> Result<(), HoldError>; }

A resizeable memory Lease.

Required methods

unsafe fn resize(&mut self, layout: Layout) -> Result<(), HoldError>

Resizes the leased memory block in place to fit the new layout, leaves the existing memory block in its original state on failure.

unsafe fn realloc(&mut self, layout: Layout) -> Result<(), HoldError>

Reallocates the leased memory block to fit the new layout; leaves the existing memory block in its original state on failure.

Loading content...

Implementors

impl<'a, R: Resident> DynamicLease<'a> for Mut<'a, R>[src]

impl<'a, R: Resident> DynamicLease<'a> for Ptr<'a, R>[src]

impl<'a, R: Resident> DynamicLease<'a> for Raw<'a, R>[src]

Loading content...