diff options
| author | Guillaume Melquiond | 2016-05-03 14:06:17 +0200 |
|---|---|---|
| committer | Guillaume Melquiond | 2016-05-03 14:10:46 +0200 |
| commit | 443857fe1bbecf089eb40d522a71a014273c5a23 (patch) | |
| tree | 6217f4e3b9d9c77e68ad8c5cf869f3f89ca9fa1a | |
| parent | 780f3424fb741385f063864d9b15b2c3e3fc419a (diff) | |
Use the canonical name when looking for an eliminator (bug #4670).
Disclaimer: I have no idea what I am doing.
| -rw-r--r-- | pretyping/indrec.ml | 2 | ||||
| -rw-r--r-- | test-suite/bugs/closed/4670.v | 7 |
2 files changed, 8 insertions, 1 deletions
diff --git a/pretyping/indrec.ml b/pretyping/indrec.ml index 0588dcc87f..589b8d82ab 100644 --- a/pretyping/indrec.ml +++ b/pretyping/indrec.ml @@ -598,7 +598,7 @@ let make_elimination_ident id s = add_suffix id (elimination_suffix s) let lookup_eliminator ind_sp s = let kn,i = ind_sp in - let mp,dp,l = repr_mind kn in + let mp,dp,l = KerName.repr (MutInd.canonical kn) in let ind_id = (Global.lookup_mind kn).mind_packets.(i).mind_typename in let id = add_suffix ind_id (elimination_suffix s) in (* Try first to get an eliminator defined in the same section as the *) diff --git a/test-suite/bugs/closed/4670.v b/test-suite/bugs/closed/4670.v new file mode 100644 index 0000000000..6113992953 --- /dev/null +++ b/test-suite/bugs/closed/4670.v @@ -0,0 +1,7 @@ +Require Import Coq.Vectors.Vector. +Module Bar. + Definition foo A n (l : Vector.t A n) : True. + Proof. + induction l ; exact I. + Defined. +End Bar. |
