1
0
mirror of https://github.com/janet-lang/janet synced 2025-11-09 20:13:02 +00:00

Add ev/select and ev/rselect initial implementation.

Getting closer to a CSP implmententation. Probably
useful to move scheduling fields outside of fibers
and into an external table.
This commit is contained in:
Calvin Rose
2020-08-09 00:20:27 -05:00
parent 78ffb63429
commit fb26c9b2c4
4 changed files with 124 additions and 22 deletions

View File

@@ -40,6 +40,7 @@ static void fiber_reset(JanetFiber *fiber) {
#ifdef JANET_EV
fiber->waiting = NULL;
fiber->timeout_index = -1;
fiber->sched_id = 0;
#endif
janet_fiber_set_status(fiber, JANET_STATUS_NEW);
}