aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Hugo Herbelin <Hugo.Herbelin@inria.fr>2014-06-16 19:06:24 +0200
committerGravatar Hugo Herbelin <Hugo.Herbelin@inria.fr>2014-06-16 19:12:37 +0200
commit74d0de5bd391bcca928a361ca8ce307e823f9c1a (patch)
treec36ce285c51021214cd1769b51faccbce1388e02
parent73c153101b8b7ccc0c279161869265b596032b0e (diff)
Unification in HoTT_coq_061.v was looping with previous commit (while
it was failing with Not_found before previous commit). This "fixes" the loop by expanding local defs in "imitate" rather than keeping them explicit. The example is otherwise too large for me to be able to understand where does the loop come from.
-rw-r--r--pretyping/evarsolve.ml2
-rw-r--r--test-suite/bugs/closed/HoTT_coq_061.v (renamed from test-suite/bugs/opened/HoTT_coq_061.v)8
2 files changed, 9 insertions, 1 deletions
diff --git a/pretyping/evarsolve.ml b/pretyping/evarsolve.ml
index aaf6e2a3d..7222085e1 100644
--- a/pretyping/evarsolve.ml
+++ b/pretyping/evarsolve.ml
@@ -1260,6 +1260,8 @@ let rec invert_definition conv_algo choose env evd pbty (evk,argsv as ev) rhs =
| Some b ->
try project_variable t
with NotInvertibleUsingOurAlgorithm _ -> imitate envk b)
+ | LetIn (na,b,u,c) ->
+ imitate envk (subst1 b c)
| Evar (evk',args' as ev') ->
if Evar.equal evk evk' then raise (OccurCheckIn (evd,rhs));
(* Evar/Evar problem (but left evar is virtual) *)
diff --git a/test-suite/bugs/opened/HoTT_coq_061.v b/test-suite/bugs/closed/HoTT_coq_061.v
index 7b48e4e01..26c1f963d 100644
--- a/test-suite/bugs/opened/HoTT_coq_061.v
+++ b/test-suite/bugs/closed/HoTT_coq_061.v
@@ -1,4 +1,10 @@
-(* File reduced by coq-bug-finder from 9039 lines to 7786 lines, then from 7245 lines to 476 lines, then from 417 lines to 249 lines, then from 171 lines to 127 lines. *)
+(* There are some problems in materialize_evar with local definitions,
+ as CO below; this is not completely sorted out yet, but at least
+ it fails in a smooth way at the time of today [HH] *)
+
+(* File reduced by coq-bug-finder from 9039 lines to 7786 lines, then
+ from 7245 lines to 476 lines, then from 417 lines to 249 lines,
+ then from 171 lines to 127 lines. *)
Set Implicit Arguments.
Set Universe Polymorphism.