commit 365f59bca9264afe4945eed8946565610da458d6 Author: cfif Date: Mon Jun 2 13:26:40 2025 +0300 Init diff --git a/MemoryAllocationInterface.h b/MemoryAllocationInterface.h new file mode 100644 index 0000000..3be3958 --- /dev/null +++ b/MemoryAllocationInterface.h @@ -0,0 +1,22 @@ +// +// Created by xemon on 28.11.22. +// + +#ifndef UVEOS_ON_NATION_MEMORYALLOCATIONINTERFACE_H +#define UVEOS_ON_NATION_MEMORYALLOCATIONINTERFACE_H + +#include "stddef.h" + +typedef struct { + void *env; + + void *(*alloc)(void *env, size_t size); + + void (*free)(void *env, void *pointer); +} tMemAllocInterface; + +#define Mem_Alloc(ENV, SIZE) (ENV)->alloc((ENV)->env,SIZE) +#define Mem_Free(ENV, PTR) (ENV)->free((ENV)->env,PTR) + + +#endif //UVEOS_ON_NATION_MEMORYALLOCATIONINTERFACE_H diff --git a/modular.json b/modular.json new file mode 100644 index 0000000..5e4ed34 --- /dev/null +++ b/modular.json @@ -0,0 +1,12 @@ +{ + "dep": [ + ], + "cmake": { + "inc_dirs": [ + "./" + ], + "srcs": [ + "./**.c" + ] + } +} \ No newline at end of file