From ef8cf82668a794f116ae714749f434e3505880d1 Mon Sep 17 00:00:00 2001 From: Matthieu Sozeau Date: Mon, 29 May 2017 18:34:47 +0200 Subject: tactics cleanup: remove constr_of_global calls --- engine/eConstr.ml | 3 +++ engine/eConstr.mli | 2 ++ 2 files changed, 5 insertions(+) (limited to 'engine') diff --git a/engine/eConstr.ml b/engine/eConstr.ml index c0485e4e7..5a05150d4 100644 --- a/engine/eConstr.ml +++ b/engine/eConstr.ml @@ -782,6 +782,9 @@ let fresh_global ?loc ?rigid ?names env sigma reference = Sigma.fresh_global ?loc ?rigid ?names env sigma reference in Sigma.Sigma (of_constr t,sigma,p) +let is_global sigma gr c = + Globnames.is_global gr (to_constr sigma c) + module Unsafe = struct let to_sorts = ESorts.unsafe_to_sorts diff --git a/engine/eConstr.mli b/engine/eConstr.mli index 9d705b4d5..9f45187cf 100644 --- a/engine/eConstr.mli +++ b/engine/eConstr.mli @@ -261,6 +261,8 @@ val fresh_global : ?loc:Loc.t -> ?rigid:Evd.rigid -> ?names:Univ.Instance.t -> Environ.env -> 'r Sigma.t -> Globnames.global_reference -> (t, 'r) Sigma.sigma +val is_global : Evd.evar_map -> Globnames.global_reference -> t -> bool + (** {5 Extra} *) val of_named_decl : (Constr.t, Constr.types) Context.Named.Declaration.pt -> (t, types) Context.Named.Declaration.pt -- cgit v1.2.3