package devkit

  1. Overview
  2. Docs
Development kit - general purpose library

Install

dune-project
 Dependency

Authors

Maintainers

Sources

1.20261006.tar.gz
md5=a39dbbce04bd5562a9b4443daf39c582
sha512=b10104b61384b2151521b785e7f3c3250134c75eae09b42cad69bc4a22a9a5e429beb891ee87cedf376c23d9c40f09d3f71c3fd48aa35df490c0f69dc17f3242

doc/devkit.core/Devkit_core/Exn/index.html

Module Devkit_core.ExnSource

Dealing with exceptions

Sourcetype 'a result = [
  1. | `Ok of 'a
  2. | `Exn of exn
]
Sourceval catch : ('a -> 'b) -> 'a -> 'b option
Sourceval default : 'a -> ('b -> 'a) -> 'b -> 'a
Sourceval suppress : ('a -> unit) -> 'a -> unit
Sourceval map : ('a -> 'b) -> 'a -> [> `Exn of exn | `Ok of 'b ]
Sourceval to_string : exn -> string
Sourceval str : exn -> string
Sourceval fail : ?exn:??? -> ('a, unit, string, 'b) format4 -> 'a

The original backtrace is captured via `Printexc.get_raw_backtrace ()`. However, note that this backtrace might not correspond to the provided `exn` if another exception was raised before `fail` is called.

Sourceval invalid_arg : ('a, unit, string, 'b) format4 -> 'a
Sourceval get_backtrace : unit -> string list