| Context of 'a
| Warn of string
| String of string
+ | Loc
type ('a, 'b) specs = {
pp_term : 'a -> F.formatter -> 'b -> unit;
let level = ref 0
+let loc = ref 0
+
(* Internal functions *******************************************************)
let std = F.std_formatter
| Context c -> F.fprintf frm "%a" st.pp_context c
| Warn s -> F.fprintf frm "@,%s" s
| String s -> F.fprintf frm "%s " s
+ | Loc -> F.fprintf frm " (line %u)" !loc
in
let iter map frm l = List.iter (map frm) l in
if !level >= l then F.fprintf frm "%a" (iter pp_item) items