pub struct Arena<R: Rootable, A = Global>where
A: Allocator,{ /* private fields */ }Expand description
A garbage collected arena, inside which garbage collected pointers can be allocated.
Implementations§
Source§impl<R, A> Arena<R, A>
impl<R, A> Arena<R, A>
pub fn new_in<F>(f: F, alloc: A) -> Arena<R, A>
pub fn new_paced_in<F>(f: F, pacing: Pacing, alloc: A) -> Arena<R, A>
pub fn view<F, Ret>(&self, f: F) -> Ret
pub fn view_mut<F, Ret>(&mut self, f: F) -> Ret
pub fn run_collection(&mut self)
pub fn complete_collection(&mut self)
pub fn allocations(&self) -> usize
Auto Trait Implementations§
impl<R, A> Freeze for Arena<R, A>
impl<R, A = Global> !RefUnwindSafe for Arena<R, A>
impl<R, A = Global> !Send for Arena<R, A>
impl<R, A = Global> !Sync for Arena<R, A>
impl<R, A> Unpin for Arena<R, A>
impl<R, A = Global> !UnwindSafe for Arena<R, A>
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