class
StaticAlloc::MemBlock
A single block of memory within a static allocator.
Public
Constructors
MemBlock
MemBlock(u8 *data, u32 size)
Methods
Alloc
u8 *Alloc(u32 amount)
Allocates a piece of memory within the block.
Caller must ensure the block has enough empty space.
Free
void Free(u8 *data, u32 allocSize)
Frees a piece of memory within the block.
If the memory isn't the last allocated memory, no deallocation happens and that memory is instead orphaned.
Clear
void Clear()
Releases all allocations within a block but doesn't actually free the memory.