type loc = {
loc_start : Stdlib.Lexing.position;
loc_end : Stdlib.Lexing.position;
loc_ghost : bool;
}
type t =
type alert = {
kind : string;
message : string;
def : loc;
use : loc;
}
val parse_options : bool -> string -> unit
val parse_alert_option : string -> unit
Disable/enable alerts based on the parameter to the -alert command-line option. Raises
Arg.Bad
if the string is not a valid specification.
val is_active : t -> bool
val is_error : t -> bool
val defaults_w : string
val defaults_warn_error : string
type reporting_information = {
id : string;
message : string;
is_error : bool;
sub_locs : (loc * string) list;
}
val report : t -> [ `Active of reporting_information | `Inactive ]
val report_alert : alert -> [ `Active of reporting_information | `Inactive ]
val backup : unit -> state
val restore : state -> unit
val mk_lazy : (unit -> 'a) -> 'a Stdlib.Lazy.t
Like
Lazy.of_fun
, but the function is applied with the warning/alert settings at the timemk_lazy
is called.