diff options
| author | Emilio Jesus Gallego Arias | 2016-02-23 01:35:00 +0100 |
|---|---|---|
| committer | Emilio Jesus Gallego Arias | 2017-05-27 20:27:21 +0200 |
| commit | 6841c6db48d57911d3886057e1ca47a5aa161ca7 (patch) | |
| tree | 771c992268c4ceb50349d7ac23829f174e4039ea /vernac | |
| parent | 2eb27e56ea4764fa2f2acec6f951eef2642ff1be (diff) | |
[coqlib] Deprecate redundant Coqlib functions.
We remove redundant functions `coq_constant`, `gen_reference`, and
`gen_constant`.
This is a first step towards a lazy binding of libraries references.
We have also chosen to untangle `constr` from `Coqlib`, as how to
instantiate the reference (in particular wrt universes) is a
client-side issue. (The client may want to provide an `evar_map` ?)
c.f. #186
Diffstat (limited to 'vernac')
| -rw-r--r-- | vernac/command.ml | 5 | ||||
| -rw-r--r-- | vernac/obligations.ml | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/vernac/command.ml b/vernac/command.ml index 8a9bbb8846..9382da3fb4 100644 --- a/vernac/command.ml +++ b/vernac/command.ml @@ -906,8 +906,9 @@ let subtac_dir = [contrib_name] let fixsub_module = subtac_dir @ ["Wf"] let tactics_module = subtac_dir @ ["Tactics"] -let init_reference dir s () = Coqlib.gen_reference "Command" dir s -let init_constant dir s () = EConstr.of_constr (Coqlib.gen_constant "Command" dir s) +let init_reference dir s () = Coqlib.coq_reference "Command" dir s +let init_constant dir s () = EConstr.of_constr @@ Universes.constr_of_global (Coqlib.coq_reference "Command" dir s) + let make_ref l s = init_reference l s let fix_proto = init_constant tactics_module "fix_proto" let fix_sub_ref = make_ref fixsub_module "Fix_sub" diff --git a/vernac/obligations.ml b/vernac/obligations.ml index 64c1560309..be58c67a9e 100644 --- a/vernac/obligations.ml +++ b/vernac/obligations.ml @@ -260,7 +260,7 @@ let eterm_obligations env name evm fs ?status t ty = let tactics_module = ["Program";"Tactics"] let safe_init_constant md name () = Coqlib.check_required_library ("Coq"::md); - Coqlib.gen_constant "Obligations" md name + Universes.constr_of_global (Coqlib.coq_reference "Obligations" md name) let hide_obligation = safe_init_constant tactics_module "obligation" let pperror cmd = CErrors.user_err ~hdr:"Program" cmd |
