1 #ifndef HAT_ALLOCATOR_H
2 #define HAT_ALLOCATOR_H
50 return a->
realloc(a, size, NULL);
63 return a->
realloc(a, size, old);
void *(* hat_allocator_realloc_t)(hat_allocator_t *a, size_t size, void *old)
Custom allocator implementation function.
Definition: allocator.h:28
static void hat_allocator_free(hat_allocator_t *a, void *old)
Free memory block.
Definition: allocator.h:70
static void * hat_allocator_alloc(hat_allocator_t *a, size_t size)
Allocate new memory block.
Definition: allocator.h:49
static void * hat_allocator_realloc(hat_allocator_t *a, size_t size, void *old)
Reallocate existing memory block.
Definition: allocator.h:61
Allocator base struct.
Definition: allocator.h:36
hat_allocator_realloc_t realloc
custom realloc implementation
Definition: allocator.h:38