[−][src]Struct interloc::InterAlloc
An allocator that watches the calls to its API, sends them to a struct, and then makes the calls.
To use this struct, use the #[global_allocator]
compiler directive and
construct the allocator with your own custom monitor, or one of the builtins.
Note that the new method of interloc::StatsMonitor
is a const fn
.
Fields
inner: T
Inner allocator
monitor: &'a F
Monitor on the calls to the allocator
Methods
impl<'a, T, F> InterAlloc<'a, T, F> where
T: GlobalAlloc,
F: AllocMonitor,
[src]
T: GlobalAlloc,
F: AllocMonitor,
Trait Implementations
impl<'a, T, F> GlobalAlloc for InterAlloc<'a, T, F> where
T: GlobalAlloc,
F: AllocMonitor,
[src]
T: GlobalAlloc,
F: AllocMonitor,
Auto Trait Implementations
impl<'a, T, F> Send for InterAlloc<'a, T, F> where
F: Sync,
T: Send,
F: Sync,
T: Send,
impl<'a, T, F> Sync for InterAlloc<'a, T, F> where
F: Sync,
T: Sync,
F: Sync,
T: Sync,
Blanket Implementations
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>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,