reformat…

This commit is contained in:
Simon Cruanes 2024-05-20 16:19:22 -04:00
parent c50798bf96
commit 4c2a9f1602
No known key found for this signature in database
GPG key ID: EBFFF6F283F3A2B4
3 changed files with 15 additions and 17 deletions

View file

@ -149,7 +149,7 @@ let () =
Printf.printf "pi=%.6f (pi=%.6f, diff=%.3f)%s\n%!" res Float.pi Printf.printf "pi=%.6f (pi=%.6f, diff=%.3f)%s\n%!" res Float.pi
(abs_float (Float.pi -. res)) (abs_float (Float.pi -. res))
(if !time then (if !time then
spf " in %.4fs" elapsed spf " in %.4fs" elapsed
else else
""); "");
() ()

View file

@ -1,14 +1,13 @@
open Common_ open Common_
class type t = class type t = object
object method input : bytes -> int -> int -> int
method input : bytes -> int -> int -> int (** Read into the slice. Returns [0] only if the
(** Read into the slice. Returns [0] only if the
stream is closed. *) stream is closed. *)
method close : unit -> unit method close : unit -> unit
(** Close the input. Must be idempotent. *) (** Close the input. Must be idempotent. *)
end end
let create ?(close = ignore) ~input () : t = let create ?(close = ignore) ~input () : t =
object object

View file

@ -1,12 +1,11 @@
open Common_ open Common_
class type t = class type t = object
object method output_char : char -> unit
method output_char : char -> unit method output : bytes -> int -> int -> unit
method output : bytes -> int -> int -> unit method flush : unit -> unit
method flush : unit -> unit method close : unit -> unit
method close : unit -> unit end
end
let create ?(flush = ignore) ?(close = ignore) ~output_char ~output () : t = let create ?(flush = ignore) ?(close = ignore) ~output_char ~output () : t =
object object