package calculon

  1. Overview
  2. Docs

Lwt+Result Monad

type 'a t = ('a, string) Stdlib.result Lwt.t
val return : 'a -> ('a, 'b) Stdlib.result Lwt.t
val fail : 'a -> ('b, 'a) Stdlib.result Lwt.t
val lift : ('a, string) Stdlib.result -> 'a t
val ok : 'a Lwt.t -> 'a t
val (>>=) : 'a t -> ('a -> 'b t) -> 'b t
val (>>?=) : 'a t -> ('a -> ('b, string) Stdlib.result) -> 'b t
val (>|=) : 'a t -> ('a -> 'b) -> 'b t
val map_s : ('a -> 'b t) -> 'a list -> 'b list t
val map_err : (string -> string) -> 'a t -> 'a t
OCaml

Innovation. Community. Security.