From b2eddfabffeb78fc5b49f9c17d70175d2dfed2e0 Mon Sep 17 00:00:00 2001 From: Steven Le Rouzic Date: Tue, 31 Dec 2024 01:16:12 +0100 Subject: Some work on buffer move --- asl/allocator.hpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'asl/allocator.hpp') diff --git a/asl/allocator.hpp b/asl/allocator.hpp index eb03e0f..5f8f9b6 100644 --- a/asl/allocator.hpp +++ b/asl/allocator.hpp @@ -7,7 +7,7 @@ namespace asl { template -concept allocator = moveable && +concept allocator = moveable && equality_comparable && requires(T& alloc, layout layout, void* ptr) { { alloc.alloc(layout) } -> same_as; @@ -21,6 +21,8 @@ public: static void* alloc(const layout&); static void* realloc(void* ptr, const layout& old, const layout& new_layout); static void dealloc(void* ptr, const layout&); + + constexpr bool operator==(const GlobalHeap&) const { return true; } }; static_assert(allocator); -- cgit