pub type DerefMemAllocFn<T> = Box<dyn Fn(usize) -> DerefMem<T>>;
Expand description

Generic memory allocator for DerefMem that hides concrete memory type

The intended use-case is when a callee (such as a library) must allocate memory. In this case, the caller can pass in a generic memory allocator This allows the callee to generalize over all memory types.