aboutsummaryrefslogtreecommitdiff
path: root/pretyping/recordops.ml
diff options
context:
space:
mode:
authorGaëtan Gilbert2020-07-02 15:30:07 +0200
committerGaëtan Gilbert2020-07-05 21:03:17 +0200
commit1e92ed4d129aea5ea4e9300a24e1135cc186c341 (patch)
treec78ff50d0d156a54b950aaf7b1a80b36b2e23b14 /pretyping/recordops.ml
parentcea10e4e16c05b06693184425dd70ce6e5eba8a8 (diff)
Fix Canonical with universe polymorphism and primitive projection
Perhaps we should thread an evar map with the Var universes added through to cs_pattern_of_constr but that would be significantly more invasive. Fix #12528
Diffstat (limited to 'pretyping/recordops.ml')
-rw-r--r--pretyping/recordops.ml2
1 files changed, 1 insertions, 1 deletions
diff --git a/pretyping/recordops.ml b/pretyping/recordops.ml
index a8e934d3c6..c26da8ccc7 100644
--- a/pretyping/recordops.ml
+++ b/pretyping/recordops.ml
@@ -185,7 +185,7 @@ let rec cs_pattern_of_constr env t =
| Rel n -> Default_cs, Some n, []
| Prod (_,a,b) when Vars.noccurn 1 b -> Prod_cs, None, [a; Vars.lift (-1) b]
| Proj (p, c) ->
- let { Environ.uj_type = ty } = Typeops.infer env c in
+ let ty = Retyping.get_type_of_constr env c in
let _, params = Inductive.find_rectype env ty in
Const_cs (GlobRef.ConstRef (Projection.constant p)), None, params @ [c]
| Sort s -> Sort_cs (Sorts.family s), None, []