diff options
| author | Hugo Herbelin | 2018-10-09 20:47:46 +0200 |
|---|---|---|
| committer | Hugo Herbelin | 2018-10-19 16:55:40 +0200 |
| commit | 9b5ceabc9b62cdf9b806bb4abdff73642113e12e (patch) | |
| tree | 06a671e2a3b7867a6e8302a64c159362234ac344 /pretyping | |
| parent | 6a52d22067727da3d5b2128ea1ac67f8037138b1 (diff) | |
Deprecating Global.type_of_global_in_context.
Removing a few Global.env in the way.
Diffstat (limited to 'pretyping')
| -rw-r--r-- | pretyping/classops.ml | 2 | ||||
| -rw-r--r-- | pretyping/typeclasses.ml | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/pretyping/classops.ml b/pretyping/classops.ml index b026397abf..543eea59c1 100644 --- a/pretyping/classops.ml +++ b/pretyping/classops.ml @@ -380,7 +380,7 @@ type coercion = { (* Computation of the class arity *) let reference_arity_length ref = - let t, _ = Global.type_of_global_in_context (Global.env ()) ref in + let t, _ = Typeops.type_of_global_in_context (Global.env ()) ref in List.length (fst (Reductionops.splay_arity (Global.env()) Evd.empty (EConstr.of_constr t))) (** FIXME *) let projection_arity_length p = diff --git a/pretyping/typeclasses.ml b/pretyping/typeclasses.ml index ce12aaeeb0..0bc35e5358 100644 --- a/pretyping/typeclasses.ml +++ b/pretyping/typeclasses.ml @@ -279,7 +279,7 @@ let build_subclasses ~check env sigma glob { hint_priority = pri } = (fun () -> incr i; Nameops.add_suffix _id ("_subinstance_" ^ string_of_int !i)) in - let ty, ctx = Global.type_of_global_in_context env glob in + let ty, ctx = Typeops.type_of_global_in_context env glob in let inst, ctx = UnivGen.fresh_instance_from ctx None in let ty = Vars.subst_instance_constr inst ty in let ty = EConstr.of_constr ty in @@ -420,7 +420,7 @@ let remove_instance i = remove_instance_hint i.is_impl let declare_instance info local glob = - let ty, _ = Global.type_of_global_in_context (Global.env ()) glob in + let ty, _ = Typeops.type_of_global_in_context (Global.env ()) glob in let info = Option.default {hint_priority = None; hint_pattern = None} info in match class_of_constr Evd.empty (EConstr.of_constr ty) with | Some (rels, ((tc,_), args) as _cl) -> |
