mirror of
https://github.com/c-cube/ocaml-containers.git
synced 2025-12-06 11:15:31 -05:00
Future.sleep should take a float
This commit is contained in:
parent
170c1031a9
commit
08d33095f6
2 changed files with 2 additions and 2 deletions
|
|
@ -510,7 +510,7 @@ let spawn_process ?(pool=default_pool) ?(stdin="") ~cmd =
|
||||||
|
|
||||||
let sleep ?(pool=default_pool) time =
|
let sleep ?(pool=default_pool) time =
|
||||||
spawn ~pool
|
spawn ~pool
|
||||||
(fun () -> Unix.sleep time; ())
|
(fun () -> Thread.delay time; ())
|
||||||
|
|
||||||
module Infix = struct
|
module Infix = struct
|
||||||
let (>>=) x f = flatMap f x
|
let (>>=) x f = flatMap f x
|
||||||
|
|
|
||||||
|
|
@ -139,7 +139,7 @@ val spawn_process : ?pool:Pool.t -> ?stdin:string -> cmd:string ->
|
||||||
(** Spawn a sub-process with the given command [cmd] (and possibly input);
|
(** Spawn a sub-process with the given command [cmd] (and possibly input);
|
||||||
returns a future containing (returncode, stdout, stderr) *)
|
returns a future containing (returncode, stdout, stderr) *)
|
||||||
|
|
||||||
val sleep : ?pool:Pool.t -> int -> unit t
|
val sleep : ?pool:Pool.t -> float -> unit t
|
||||||
(** Future that returns with success in the given amount of seconds *)
|
(** Future that returns with success in the given amount of seconds *)
|
||||||
|
|
||||||
module Infix : sig
|
module Infix : sig
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue