Files
ss/include/egg/core/eggAllocator.h
T
Elijah Thomas 26af4db82d update from dtk-template - clangd :) (#66)
* update from dtk-template and start work towards using clangd

* include <a> -> "a"

* Update build.yml

* remove/add non-trivial class in union warning
2024-10-16 15:36:02 -04:00

30 lines
634 B
C++

#ifndef EGG_ALLOCATOR_H
#define EGG_ALLOCATOR_H
#include "common.h"
#include "rvl/MEM.h" // IWYU pragma: export
void MEMInitAllocatorFor_Heap(MEMAllocator *alloc, s32 align, void *heap);
namespace EGG {
class Heap;
class Allocator : public MEMAllocator {
public:
Allocator(Heap *heap, s32 align);
public:
/* vt 0x08 */ virtual ~Allocator();
/* vt 0x0C */ virtual void *alloc(u32 size);
/* vt 0x10 */ virtual void free(void *block);
inline MEMAllocator *getHandle() {
return static_cast<MEMAllocator *>(this);
}
/* 0x14 */ Heap *mHeap;
/* 0x18 */ s32 align;
};
}; // namespace EGG
#endif