aboutsummaryrefslogtreecommitdiff
path: root/dev
diff options
context:
space:
mode:
authorHugo Herbelin2015-07-28 19:25:51 +0200
committerHugo Herbelin2015-07-30 13:54:22 +0200
commit5e60af46bdcb5aa487737961859f80181486516b (patch)
treebd312fe6ccedd8ad9be803193710ed1bc1f60363 /dev
parent5cf7ce6afae0e8e5310755f05a26450f428da04f (diff)
A printer for printing constants of the env (maybe useful when there are not too many of them).
Diffstat (limited to 'dev')
-rw-r--r--dev/top_printers.ml5
1 files changed, 5 insertions, 0 deletions
diff --git a/dev/top_printers.ml b/dev/top_printers.ml
index f969f01329..f9f2e1b09e 100644
--- a/dev/top_printers.ml
+++ b/dev/top_printers.ml
@@ -229,6 +229,11 @@ let ppenv e = pp
(str "[" ++ pr_named_context_of e Evd.empty ++ str "]" ++ spc() ++
str "[" ++ pr_rel_context e Evd.empty (rel_context e) ++ str "]")
+let ppenvwithcst e = pp
+ (str "[" ++ pr_named_context_of e Evd.empty ++ str "]" ++ spc() ++
+ str "[" ++ pr_rel_context e Evd.empty (rel_context e) ++ str "]" ++ spc() ++
+ str "{" ++ Cmap_env.fold (fun a _ s -> pr_con a ++ spc () ++ s) (Obj.magic e).Pre_env.env_globals.Pre_env.env_constants (mt ()) ++ str "}")
+
let pptac = (fun x -> pp(Pptactic.pr_glob_tactic (Global.env()) x))
let ppobj obj = Format.print_string (Libobject.object_tag obj)