package picos

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Source file common.ml

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
module type Intf = sig
  type t = { exn : exn; bt : Printexc.raw_backtrace }
  (** An exception and a backtrace. *)

  val get : exn -> t
  (** [get exn] is equivalent to
      [{ exn; bt = Printexc.get_raw_backtrace () }]. *)

  val get_callstack : int -> exn -> t
  (** [get_callstack n exn] is equivalent to
      [{ exn; bt = Printexc.get_callstack n }].

      Note that [Printexc.get_callstack 0] effectively returns a constant value
      and this function is optimized to take that into account. *)

  val raise : t -> 'a
  (** [raise exn_bt] is equivalent to
      [Printexc.raise_with_backtrace exn_bt.exn exn_bt.bt]. *)
end

type t = { exn : exn; bt : Printexc.raw_backtrace }
OCaml

Innovation. Community. Security.