aboutsummaryrefslogtreecommitdiff
path: root/kernel/cooking.ml
diff options
context:
space:
mode:
authorMaxime Dénès2019-05-27 13:20:32 +0200
committerMaxime Dénès2019-05-27 13:20:32 +0200
commit13034bc2a322d250a971c9cc73881a34f9d64025 (patch)
treee8f3046a5fb5faf034ff516de046fed3df91a671 /kernel/cooking.ml
parent1df3b08cb40bab6db1177b0289995d40287437f5 (diff)
parentd782dabc61251834e35a77c43e070ea8b4e0b04a (diff)
Merge PR #10198: Centralize the hashconsing of constant declarations.
Reviewed-by: maximedenes
Diffstat (limited to 'kernel/cooking.ml')
-rw-r--r--kernel/cooking.ml7
1 files changed, 2 insertions, 5 deletions
diff --git a/kernel/cooking.ml b/kernel/cooking.ml
index 9b6e37251f..13851319cd 100644
--- a/kernel/cooking.ml
+++ b/kernel/cooking.ml
@@ -212,7 +212,7 @@ let lift_univs cb subst auctx0 =
let auctx' = Univ.subst_univs_level_abstract_universe_context substf auctx in
subst, (Polymorphic (AUContext.union auctx0 auctx'))
-let cook_constant ~hcons { from = cb; info } =
+let cook_constant { from = cb; info } =
let { Opaqueproof.modlist; abstract } = info in
let cache = RefTable.create 13 in
let abstract, usubst, abs_ctx = abstract in
@@ -220,10 +220,7 @@ let cook_constant ~hcons { from = cb; info } =
let expmod = expmod_constr_subst cache modlist usubst in
let hyps0 = Context.Named.map expmod abstract in
let hyps = abstract_context hyps0 in
- let map c =
- let c = abstract_constant_body (expmod c) hyps in
- if hcons then Constr.hcons c else c
- in
+ let map c = abstract_constant_body (expmod c) hyps in
let body = on_body modlist (hyps0, usubst, abs_ctx)
map
cb.const_body