Commit decf673c authored by Francois Bobot's avatar Francois Bobot

A chaque fichier alt-ergo.ml remet à zero son printer, plus simple que pour pretty

parent 11525d04
......@@ -115,6 +115,9 @@ let forget_id (indices,values,_) id =
Hashtbl.remove values id.id_tag
with Not_found -> ()
let forget_all (indices,values,_) =
Hashtbl.clear indices; Hashtbl.clear values
(** Sanitizers *)
exception Unsanitizable
......
......@@ -79,6 +79,8 @@ val id_unique :
(* forget an ident *)
val forget_id : ident_printer -> ident -> unit
(* forget all the idents *)
val forget_all : ident_printer -> unit
(* generic sanitizer taking a separate encoder for the first letter *)
val sanitizer : (char -> string) -> (char -> string) -> string -> string
......
......@@ -211,7 +211,10 @@ let print_context drv fmt ctxt =
let decls = Context.get_decls ctxt in
ignore (print_list_opt newline2 (print_decl drv ctxt) fmt decls)
let () = Driver.register_printer "alt-ergo" print_context
let () = Driver.register_printer "alt-ergo"
(fun drv fmt ctxt ->
forget_all ident_printer;
print_context drv fmt ctxt)
let print_goal drv fmt (id, f, ctxt) =
print_context drv fmt ctxt;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment