diff options
author | Pierre-Marie Pédrot <pierre-marie.pedrot@inria.fr> | 2017-07-04 13:38:22 +0200 |
---|---|---|
committer | Pierre-Marie Pédrot <pierre-marie.pedrot@inria.fr> | 2017-07-26 15:11:13 +0200 |
commit | 4457e6d75affd20c1c13c0d798c490129525bcb5 (patch) | |
tree | b5eeffe5f1a07c439fe704a6d60b2b036110df7f /vernac/record.ml | |
parent | a960c4db9ae93a6445f9db620f96f62b397ba8b5 (diff) |
More precise type for universe entries.
We use an algebraic type instead of a pair of a boolean and the corresponding
data. For now, this is isomorphic, but this allows later change in the structure.
Diffstat (limited to 'vernac/record.ml')
-rw-r--r-- | vernac/record.ml | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/vernac/record.ml b/vernac/record.ml index 63ca22786..a2e443e5f 100644 --- a/vernac/record.ml +++ b/vernac/record.ml @@ -322,13 +322,16 @@ let declare_projections indsp ?(kind=StructureComponent) binder_name coers field let projtyp = it_mkProd_or_LetIn (mkProd (x,rp,ccl)) paramdecls in try + let univs = + if poly then Polymorphic_const_entry ctx + else Monomorphic_const_entry ctx + in let entry = { const_entry_body = Future.from_val (Safe_typing.mk_pure_proof proj); const_entry_secctx = None; const_entry_type = Some projtyp; - const_entry_polymorphic = poly; - const_entry_universes = ctx; + const_entry_universes = univs; const_entry_opaque = false; const_entry_inline_code = false; const_entry_feedback = None } in |