Signatures.MISC
val opt_print : (Format.formatter -> 'a -> unit) -> Format.formatter -> 'a option -> unit
val with_input_file : ?bin:bool -> string -> (in_channel -> 'a) -> 'a
val with_output_file : ?bin:bool -> string -> (out_channel -> 'a) -> 'a
val copy_chan : in_channel -> out_channel -> unit
val print_string_list : Format.formatter -> string list -> unit
val (!*) : 'a Lazy.t -> 'a
A shortcut to force lazy value (See
azy.force
).
The right associative application. Useful when writing to much parentheses: << f (g x ... t) >> becomes << f& g x ... t >> << f (g (h x)) >> becomes << f& g& h x >>
The reversed application combinator. Useful to describe some operations chaining. << f x (g y (h z)) >> becomes << z |> h |> g y |> f x >>
val (@:=) : 'a list ref -> 'a list -> unit
r @:= l
is equivalent to r := !r @ l