package containers

  1. Overview
  2. Docs

Debugging utils. EXPERIMENTAL

  • since 3.6
val trace_fail : string -> 'a t -> 'a t

trace_fail name p behaves like p, but prints the error message of p on stderr whenever p fails.

  • parameter name

    used as a prefix of all trace messages.

val trace_success : string -> print:('a -> string) -> 'a t -> 'a t

trace_success name ~print p behaves like p, but prints successful runs of p using print.

val trace_success_or_fail : string -> print:('a -> string) -> 'a t -> 'a t

Trace both error or success

OCaml

Innovation. Community. Security.