MmapPool.allocate

Allocates size bytes of memory.

class MmapPool
@nogc @trusted nothrow
void[]
allocate
(
size_t size
)

Parameters

size size_t

Amount of memory to allocate.

Return Value

Type: void[]

The pointer to the new allocated memory.

Examples

auto p = MmapPool.instance.allocate(20);

assert(p);

MmapPool.instance.deallocate(p);

Meta