summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteven Le Rouzic <steven.lerouzic@gmail.com>2025-03-26 21:35:18 +0100
committerSteven Le Rouzic <steven.lerouzic@gmail.com>2025-03-26 21:35:18 +0100
commit2d309a2cff4754c381353a73872a55b20b1a8019 (patch)
tree543761aa0c2e2c12a1f7a9e27cd3f7a707671bef
parentf19d93a69a0ec5c7a89dcb4c064c984aac90ba71 (diff)
Separate allocator from memory
-rw-r--r--asl/containers/BUILD.bazel3
-rw-r--r--asl/memory/BUILD.bazel13
-rw-r--r--asl/types/BUILD.bazel2
-rw-r--r--todo.txt3
4 files changed, 18 insertions, 3 deletions
diff --git a/asl/containers/BUILD.bazel b/asl/containers/BUILD.bazel
index a8d6b4e..ba9c6f1 100644
--- a/asl/containers/BUILD.bazel
+++ b/asl/containers/BUILD.bazel
@@ -13,6 +13,7 @@ cc_library(
],
deps = [
"//asl/memory",
+ "//asl/memory:allocator",
"//asl/base",
"//asl/types:span",
"//asl/hashing",
@@ -28,6 +29,7 @@ cc_library(
deps = [
"//asl/base",
"//asl/memory",
+ "//asl/memory:allocator",
"//asl/types:maybe_uninit",
"//asl/hashing",
],
@@ -42,6 +44,7 @@ cc_library(
deps = [
"//asl/base",
"//asl/memory",
+ "//asl/memory:allocator",
"//asl/hashing",
":hash_set",
],
diff --git a/asl/memory/BUILD.bazel b/asl/memory/BUILD.bazel
index 7305da0..83dcfd0 100644
--- a/asl/memory/BUILD.bazel
+++ b/asl/memory/BUILD.bazel
@@ -9,15 +9,26 @@ package(
cc_library(
name = "memory",
hdrs = [
- "allocator.hpp",
"layout.hpp",
"memory.hpp",
],
+ deps = [
+ "//asl/base",
+ ],
+ visibility = ["//visibility:public"],
+)
+
+cc_library(
+ name = "allocator",
+ hdrs = [
+ "allocator.hpp",
+ ],
srcs = [
"allocator.cpp",
],
deps = [
"//asl/base",
+ "//asl/memory",
],
visibility = ["//visibility:public"],
)
diff --git a/asl/types/BUILD.bazel b/asl/types/BUILD.bazel
index 53905a3..16a2a7a 100644
--- a/asl/types/BUILD.bazel
+++ b/asl/types/BUILD.bazel
@@ -14,6 +14,7 @@ cc_library(
deps = [
"//asl/base",
"//asl/memory",
+ "//asl/memory:allocator",
"//asl/hashing",
],
visibility = ["//visibility:public"],
@@ -86,6 +87,7 @@ cc_library(
deps = [
"//asl/base",
"//asl/memory",
+ "//asl/memory:allocator",
],
visibility = ["//visibility:public"],
)
diff --git a/todo.txt b/todo.txt
index 1823626..8a1d00b 100644
--- a/todo.txt
+++ b/todo.txt
@@ -1,2 +1 @@
-Separate memory and allocator
-Add invoke_t & co
+Add invoke_r & co