diff options
Diffstat (limited to 'include/kpl/task.h')
| -rw-r--r-- | include/kpl/task.h | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/include/kpl/task.h b/include/kpl/task.h deleted file mode 100644 index ce183da..0000000 --- a/include/kpl/task.h +++ /dev/null @@ -1,39 +0,0 @@ -/* - * KPL task methods - */ - -#pragma once - -/* - * Create a new task - */ -kpl_object_task *kpl_object_task_create(kpl_thread *thread, int32_t variables_size, uint64_t variables_gc_mask); - -/* - * Delete object in gc before sweep - */ -inline void kpl_object_task_destroy(kpl_thread *thread, kpl_object_task *object_task) { - kpl_gc_delete(thread, (kpl_object*) object_task); -} - -/* - * Queue join task - * Done needs to be called twice, once by joining the task and once the task is done - * The joining or completing can be called in any order - * Once both done functions are called the join task is queued - */ -void kpl_object_task_done(kpl_thread *thread, kpl_object_task *object_task); - -/* - * Set the task to queue next after kpl_task_complete finishes - */ -inline void kpl_object_task_join(kpl_thread *thread, kpl_object_task *restrict object_task_complete, - kpl_object_task *restrict object_task_join) { - object_task_complete->join_task = object_task_join; - kpl_object_task_done(thread, object_task_complete); -} - -/* - * An error has occurred in the task - */ -void kpl_object_task_error(kpl_thread *thread, kpl_object_error *object_error); |
