From 521e9a2fc8e0ef1dffe4e590d0d4f65292f0d1df Mon Sep 17 00:00:00 2001 From: "@syxhe" Date: Mon, 21 Apr 2025 21:26:23 -0500 Subject: Implement a Concurrent Queue --- src/shared.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/shared.h') diff --git a/src/shared.h b/src/shared.h index 1a629e6..3b0a5f7 100644 --- a/src/shared.h +++ b/src/shared.h @@ -76,10 +76,13 @@ int cleanup_fire(cleanup * const loc); /* Cleanup environment creator. Automatically defines the variables `__CLEANUP`, `__CLEANUP_FUNCS`, and `__CLEANUP_ARGS` and initializes // via `cleanup_init()` using these variables. */ -#define cleanup_create(size) \ +#define cleanup_CREATE(size) \ cleanup __CLEANUP; \ cleanup_callback __CLEANUP_FUNCS[(size)]; \ void *__CLEANUP_ARGS[(size)]; \ cleanup_init(&__CLEANUP, (size), __CLEANUP_FUNCS, __CLEANUP_ARGS) +#define cleanup_REGISTER(cb, arg) cleanup_register(&__CLEANUP, (cb), (arg)) +#define cleanup_CNDREGISTER(flag, cb, arg) cleanup_cndregister(&__CLEANUP, (flag), (cb), (arg)) + #endif \ No newline at end of file -- cgit v1.2.3