diff options
| author | Fabrice <fabrice@schaub-dev.xyz> | 2026-04-16 18:31:23 +0200 |
|---|---|---|
| committer | Fabrice <fabrice@schaub-dev.xyz> | 2026-04-16 18:31:23 +0200 |
| commit | f8db0a0820b30aec21942d29bba26af47e1c7c68 (patch) | |
| tree | c13e99b4ba8b6322a2b39b6940b22021e877c6d6 /omni | |
| parent | 4748386b4e22a5bfe0c4d3f0d65c43f37e09536e (diff) | |
Diffstat (limited to 'omni')
| -rw-r--r-- | omni/BUILD.bazel | 2 | ||||
| -rw-r--r-- | omni/log.h (renamed from omni/assert.h) | 0 | ||||
| -rw-r--r-- | omni/memory.h | 25 |
3 files changed, 1 insertions, 26 deletions
diff --git a/omni/BUILD.bazel b/omni/BUILD.bazel index 9278b8f..be1b50c 100644 --- a/omni/BUILD.bazel +++ b/omni/BUILD.bazel @@ -6,7 +6,7 @@ cc_library( ":stdint.h", ":platform.h", ":intrin.h", - ":memory.h" + ":log.h" ], visibility = ["//visibility:public"] ) diff --git a/omni/assert.h b/omni/log.h index f3e865b..f3e865b 100644 --- a/omni/assert.h +++ b/omni/log.h diff --git a/omni/memory.h b/omni/memory.h deleted file mode 100644 index def1cc0..0000000 --- a/omni/memory.h +++ /dev/null @@ -1,25 +0,0 @@ -#ifndef OMNI_MEMORY_H -#define OMNI_MEMORY_H - -#include "stdint.h" - -struct Layout { - usize size; - usize align; - - template <typename T> - constexpr static Layout of(usize n) noexcept { - return Layout{n * sizeof(T), alignof(T)}; - } - - static bool from(usize size, usize align) noexcept { - return Layout{size, align}; - } -}; - -struct Allocator { - virtual u8* allocate(Layout layout) noexcept; - virtual void deallocate(u8* ptr); -}; - -#endif |
