Arena

Arena: Arena, ~Arena, allocate, allocateArray

struct Arena

A bump allocator that keeps allocations stable until the arena is destroyed.

Arena

Arena(uint64 chunkSize = 4096)

Creates an arena whose chunks have the given minimum capacity.

~Arena

~Arena()

Frees all chunks owned by the arena.

allocate

T*? allocate<T>()

Allocates uninitialized storage for one value, or returns null on overflow or allocation failure.

T*? allocate<T>(T value)

Moves the given value into arena-owned storage, or returns null on overflow or allocation failure.

allocateArray

T[*]? allocateArray<T>(uint64 count)

Allocates uninitialized storage for count values, or returns null on overflow or allocation failure.