module Result: Result
type ('a, 'b)
t =
include Sexpable.S2
include Binable.S2
include Monad.S2
val fail : 'a -> ('b, 'a) t
val is_ok : ('a, 'b) t -> bool
val is_error : ('a, 'b) t -> bool
val ok : ('a, 'b) t -> 'a option
val error : ('a, 'b) t -> 'b option
val iter : ('a, 'b) t -> f:('a -> unit) -> unit
val map : ('a, 'b) t -> f:('a -> 'c) -> ('c, 'b) t
val call : f:('a -> unit, 'b) t -> 'a -> unit
val apply : f:('a -> 'b, 'c) t -> 'a -> ('b, 'c) t
val ok_fst : ('a, 'b) t -> [ `Fst of 'a | `Snd of 'b ]
val trywith : (unit -> 'a) -> ('a, exn) t