api

BatchAllocator.ch

Declarations in BatchAllocator.ch

4 declarationscompiler

Declarations

Public only
BatchAllocator#
Publicinterface
interface BatchAllocator
TODO: remove retained, once we have runtime magic val
allocate_size#
Publicfunction
func allocate_size(self : &BatchAllocator, obj_size : size_t, alignment : size_t) : *char
* allocate a pointer with given object size, you must destruct the allocated pointer * otherwise there'll be a memory leak
allocate_str_size#
PublicfunctionExtension
func allocate_str_size(allocator : &BatchAllocator, size : size_t) : *char
adds +1 to size to accomodate for the last null terminator \0 in string
allocate_str#
PublicfunctionExtension
func allocate_str(allocator : &BatchAllocator, data : *char, size : size_t) : *char
TODO: remove retained, once we have runtime magic val
allocate_view#
PublicfunctionExtension
func allocate_view(allocator : &BatchAllocator, view : &string_view) : string_view
TODO: remove retained, once we have runtime magic val