summaryrefslogtreecommitdiff
path: root/lib/coq
diff options
context:
space:
mode:
authorBrian Campbell2019-06-05 15:45:32 +0100
committerBrian Campbell2019-06-05 15:45:43 +0100
commitc764daadc0e7138173ddb0895298dae846a7d8b6 (patch)
treed3b4da959dce36a819b423b0167d7b971f6286d1 /lib/coq
parentb50319867a21b66b66091e6430d36f12457bf5e7 (diff)
Coq: generalize proof terms before main solver
Ensures that dependencies in proofs don't affect rewriting.
Diffstat (limited to 'lib/coq')
-rw-r--r--lib/coq/Sail2_values.v8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/coq/Sail2_values.v b/lib/coq/Sail2_values.v
index 17d79830..be9a214b 100644
--- a/lib/coq/Sail2_values.v
+++ b/lib/coq/Sail2_values.v
@@ -1351,9 +1351,17 @@ end;
(* We may have uncovered more conjunctions *)
repeat match goal with H:and _ _ |- _ => destruct H end.
+Ltac generalize_embedded_proofs :=
+ repeat match goal with H:context [?X] |- _ =>
+ match type of X with ArithFact _ =>
+ generalize dependent X
+ end
+ end;
+ intros.
Ltac prepare_for_solver :=
(*dump_context;*)
+ generalize_embedded_proofs;
clear_irrelevant_defns;
clear_non_Z_bool_defns;
autounfold with sail in * |- *; (* You can add Hint Unfold ... : sail to let omega see through fns *)