pub fn count_thread_allocations<R>(f: impl FnOnce() -> R) -> (R, usize)Expand description
Run f while counting successful heap allocations on the current thread.
Restores previous state on unwind. Requires LocalAllocCounter installed.
pub fn count_thread_allocations<R>(f: impl FnOnce() -> R) -> (R, usize)Run f while counting successful heap allocations on the current thread.
Restores previous state on unwind. Requires LocalAllocCounter installed.