aboutsummaryrefslogtreecommitdiff
path: root/include/kpl/gc.h
diff options
context:
space:
mode:
authornodist <kevin.comas.git@gmail.com>2026-11-05 15:22:02 -0500
committernodist <kevin.comas.git@gmail.com>2026-11-05 15:22:02 -0500
commit7b9204a8680539bc4795a14f3d9a34e47981d0c3 (patch)
tree7aa69bba0c9cbee0cafb638fd49af64958dbb228 /include/kpl/gc.h
parentfaa937cb09cd01f4ea94f5d7722a20e9c1246df0 (diff)
more objects and special slab for gc
Diffstat (limited to 'include/kpl/gc.h')
-rw-r--r--include/kpl/gc.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/kpl/gc.h b/include/kpl/gc.h
index bd99a9a..5240c40 100644
--- a/include/kpl/gc.h
+++ b/include/kpl/gc.h
@@ -27,13 +27,14 @@ inline void kpl_gc_init(kpl_gc *gc) {
* Returns the new kpl_object, which has a pointer to the kpl_gc_object
* Only owner thread calls this
*/
-void *kpl_gc_new(kpl_thread *thread, kpl_interface *interface, int32_t object_size);
+void *kpl_gc_new(kpl_thread *thread, const kpl_interface *interface, int32_t object_size);
/*
* Delete an object on gc_head before sweeping
* *object is the object the gc is tracking NOT a kpl_object_gc
* Many objects can be removed from the gc before sweep and is done though this
* *object is not void, force casting to prevent memory errors
+ * The object and its gc parent must belong to the thread
*/
void kpl_gc_delete(kpl_thread *thread, kpl_object *object);