2018-02-06 14:39:03 +00:00
|
|
|
(** Error reporting *)
|
|
|
|
|
|
|
|
(** Captures the backtrace and report an error.
|
|
|
|
|
|
|
|
Because jbuilder doesn't stop at the first error, it might end up reporting the same
|
|
|
|
error twice about missing libraries for instance. To avoid this, we keep a cache of
|
|
|
|
reported errors and ignore errors that have already been reported.
|
|
|
|
|
|
|
|
We cache what is actually printed to the screen.
|
|
|
|
*)
|
|
|
|
val report : exn -> unit
|
|
|
|
|
2018-02-20 11:46:10 +00:00
|
|
|
(** Register an error reporter. The callbacks takes an exception to
|
|
|
|
report and must return [true] if it was reported. *)
|
|
|
|
val register : (Format.formatter -> exn -> bool) -> unit
|
|
|
|
|
2018-02-06 14:39:03 +00:00
|
|
|
(**/**)
|
|
|
|
val map_fname : (string -> string) ref
|