aboutsummaryrefslogtreecommitdiff
path: root/tactics
diff options
context:
space:
mode:
authorPierre-Marie Pédrot2019-06-28 22:04:25 +0200
committerPierre-Marie Pédrot2019-10-16 17:38:49 +0200
commit1f2a3fe97be66fd3201b9c98e5744953d4149b91 (patch)
tree9e1e992d5f2f706505e4184d990f2790e41df6ca /tactics
parentf22205ee06f9170a74dc8cefba2b42deeaeb246b (diff)
Cleaning up the previous code by ensuring statically invariants on opaque proofs.
We return the typing context directly instead of hiding it into the opaque data, and we take advantage of this to remove a few assertions known to hold statically.
Diffstat (limited to 'tactics')
-rw-r--r--tactics/declare.ml8
1 files changed, 4 insertions, 4 deletions
diff --git a/tactics/declare.ml b/tactics/declare.ml
index 61321cd605..719430e71c 100644
--- a/tactics/declare.ml
+++ b/tactics/declare.ml
@@ -259,17 +259,17 @@ let define_constant ~side_effect ~name cd =
let export = get_roles export eff in
let de = { de with proof_entry_body = Future.from_val (body, ()) } in
let cd = Entries.DefinitionEntry (cast_proof_entry de) in
- export, ConstantEntry (PureEntry, cd), false
+ export, ConstantEntry cd, false
else
let map (body, eff) = body, eff.Evd.seff_private in
let body = Future.chain de.proof_entry_body map in
let de = { de with proof_entry_body = body } in
let de = cast_opaque_proof_entry de in
- [], ConstantEntry (EffectEntry, Entries.OpaqueEntry de), false
+ [], OpaqueEntry de, false
| ParameterEntry e ->
- [], ConstantEntry (PureEntry, Entries.ParameterEntry e), not (Lib.is_modtype_strict())
+ [], ConstantEntry (Entries.ParameterEntry e), not (Lib.is_modtype_strict())
| PrimitiveEntry e ->
- [], ConstantEntry (PureEntry, Entries.PrimitiveEntry e), false
+ [], ConstantEntry (Entries.PrimitiveEntry e), false
in
let kn, eff = Global.add_constant ~side_effect name decl in
if unsafe || is_unsafe_typing_flags() then feedback_axiom();