summaryrefslogtreecommitdiff
path: root/py/gc.h
diff options
context:
space:
mode:
authorDan Halbert <halbert@halwitz.org>2018-07-11 16:45:30 -0400
committerDan Halbert <halbert@halwitz.org>2018-07-11 16:45:30 -0400
commit7c219600a246d8956d0b23ea3f5d125a820e6b6a (patch)
tree4cf793a66284322d48a8f430815c31cd1c9ffa1d /py/gc.h
parent4962468ffffac9ec4e36b2b1fc3f132516df3127 (diff)
parent25ae98f07cb3c4488cb955403dfe56b8bb8db6f0 (diff)
WIP: after merge; before testing
Diffstat (limited to 'py/gc.h')
-rw-r--r--py/gc.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/py/gc.h b/py/gc.h
index e5878e1ee..64f4b0d17 100644
--- a/py/gc.h
+++ b/py/gc.h
@@ -46,6 +46,10 @@ void gc_collect_root(void **ptrs, size_t len);
void gc_collect_end(void);
void *gc_alloc(size_t n_bytes, bool has_finaliser, bool long_lived);
+
+// Use this function to sweep the whole heap and run all finalisers
+void gc_sweep_all(void);
+
void gc_free(void *ptr); // does not call finaliser
size_t gc_nbytes(const void *ptr);
bool gc_has_finaliser(const void *ptr);