[−][src]Struct shared_arena::PoolBox
A pointer to T
in Pool
PoolBox
implements DerefMut
so it is directly mutable
(without mutex or other synchronization methods).
It is not clonable and cannot be sent to others threads.
let pool = Pool::new(); let mut my_opt: PoolBox<Option<i32>> = pool.alloc(Some(10)); assert!(my_opt.is_some()); assert_eq!(my_opt.take(), Some(10)); assert!(my_opt.is_none());
Trait Implementations
impl<T> Deref for PoolBox<T>
[src]
impl<T> DerefMut for PoolBox<T>
[src]
impl<T> Drop for PoolBox<T>
[src]
Drop the PoolBox
The value pointed by this PoolBox is also dropped
Auto Trait Implementations
impl<T> !RefUnwindSafe for PoolBox<T>
impl<T> !Send for PoolBox<T>
impl<T> !Sync for PoolBox<T>
impl<T> Unpin for PoolBox<T>
impl<T> !UnwindSafe for PoolBox<T>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,