Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

moonpool.unix: tentative event loop integration #21

Draft
wants to merge 26 commits into
base: main
Choose a base branch
from
Draft
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
cleanup
c-cube committed Feb 8, 2024
commit f0f90d2651ac9b5d2158432ffbb9ed8d7cdf9da9
2 changes: 0 additions & 2 deletions src/fib/fiber.ml
Original file line number Diff line number Diff line change
@@ -144,8 +144,6 @@ let add_child_ ~protect (self : _ t) (child : _ t) =
()
done

exception Cancelled of Exn_bt.t

(** Key to access the current fiber. *)
let k_current_fiber : any option Task_local_storage.key =
Task_local_storage.new_key ~init:(fun () -> None) ()
8 changes: 0 additions & 8 deletions src/fib/fiber.mli
Original file line number Diff line number Diff line change
@@ -9,10 +9,6 @@
of structured concurrency
*)

(**/**)

(**/**)

type 'a t
(** A fiber returning a value of type ['a]. *)

@@ -48,10 +44,6 @@ val yield : unit -> unit
(** Yield control to the scheduler from the current fiber.
@raise Failure if not run from inside a fiber. *)

exception Cancelled of Exn_bt.t
(** Exception for fibers that are cancelled. Polling points such
as {!yield} and {!await} will raise this if the fiber has been cancelled. *)

val with_cancel_callback : _ t -> cancel_callback -> (unit -> 'a) -> 'a
(** [with_cancel_callback fib cb (fun () -> <e>)] evaluates [e]
in a scope in which, if the fiber [fib] is cancelled,