Module Sugar__.Strict_result_builder

How to create a strict result monad:


  module MyError = struct
    type t = A | B | Unexpected of exn

    let panic e = Unexpected e
  end

  module MyResult = Sugar.Result.Make (MyError)
  

The generated module will have the signature of Sugar.S.Strict_result

module Make : functor (UserError : Sugar.S.Params.Strict_error) -> Sugar.S.Strict_result with type error = UserError.t

A parametric module that implements the blocking interface.