Module arena

Module arena 

Source
Expand description

Arena allocators. Small and fast.

Structs§

Arena
An arena allocator.
ArenaString
A custom string type, because std lacks allocator support for String.
ScratchArena
Borrows an Arena for temporary allocations.

Functions§

init
Initialize the scratch arenas with a given capacity. Call this before using scratch_arena.
scratch_arena
Need an arena for temporary allocations? scratch_arena got you covered. Call scratch_arena and it’ll return an Arena that resets when it goes out of scope.