aboutsummaryrefslogtreecommitdiff
path: root/kernel/indtypes.ml
diff options
context:
space:
mode:
authorPierre-Marie Pédrot2017-07-07 16:33:47 +0200
committerPierre-Marie Pédrot2017-07-11 14:50:47 +0200
commit0d9a91113c4112eece0680e433f435fdfb39ea4b (patch)
treecf90d290a92c02a2297b3a13b77190db9aa4db70 /kernel/indtypes.ml
parentb5ad6a80107f196fa8ffcc4f5dff58bea8c4f70e (diff)
Getting rid of simple calls to AUContext.instance.
This function breaks the abstraction barrier of abstract universe contexts, as it provides a way to observe the bound names of such a context. We remove all the uses that can be easily get rid of with the current API.
Diffstat (limited to 'kernel/indtypes.ml')
-rw-r--r--kernel/indtypes.ml7
1 files changed, 2 insertions, 5 deletions
diff --git a/kernel/indtypes.ml b/kernel/indtypes.ml
index 04971f83dc..e248436ec4 100644
--- a/kernel/indtypes.ml
+++ b/kernel/indtypes.ml
@@ -961,13 +961,10 @@ let build_inductive env prv iu env_ar paramsctxt kn isrecord isfinite inds nmr r
&& pkt.mind_consnrealargs.(0) > 0 ->
(** The elimination criterion ensures that all projections can be defined. *)
let u =
- let process auctx =
- subst_univs_level_instance substunivs (Univ.AUContext.instance auctx)
- in
match aiu with
| Monomorphic_ind _ -> Univ.Instance.empty
- | Polymorphic_ind auctx -> process auctx
- | Cumulative_ind acumi -> process (Univ.ACumulativityInfo.univ_context acumi)
+ | Polymorphic_ind auctx -> Univ.make_abstract_instance auctx
+ | Cumulative_ind acumi -> Univ.make_abstract_instance (Univ.ACumulativityInfo.univ_context acumi)
in
let indsp = ((kn, 0), u) in
let rctx, indty = decompose_prod_assum (subst1 (mkIndU indsp) pkt.mind_nf_lc.(0)) in