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

Fix documentation in threadext.mli #81

Merged
merged 2 commits into from
Nov 22, 2023
Merged
Changes from all commits
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
18 changes: 9 additions & 9 deletions lib/xapi-stdext-threads/threadext.mli
Original file line number Diff line number Diff line change
Expand Up @@ -11,25 +11,25 @@
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*)
module Mutex :
sig
module Mutex : sig
val execute : Mutex.t -> (unit -> 'a) -> 'a
end

val thread_iter_all_exns: ('a -> unit) -> 'a list -> ('a * exn) list
val thread_iter: ('a -> unit) -> 'a list -> unit
val thread_iter_all_exns : ('a -> unit) -> 'a list -> ('a * exn) list

module Delay :
sig
val thread_iter : ('a -> unit) -> 'a list -> unit

module Delay : sig
type t

val make : unit -> t

val wait : t -> float -> bool
(** Blocks the calling thread for a given period of time with the option of
returning early if someone calls 'signal'. Returns true if the full time
period elapsed and false if signalled. Note that multple 'signals' are
coalesced; 'signals' sent before 'wait' is called are not lost. *)

val wait : t -> float -> bool
(** Sends a signal to a waiting thread. See 'wait' *)

val signal : t -> unit
(** Sends a signal to a waiting thread. See 'wait' *)
end
Loading