diff options
author | Pierre-Marie Pédrot <pierre-marie.pedrot@inria.fr> | 2016-11-06 19:59:28 +0100 |
---|---|---|
committer | Pierre-Marie Pédrot <pierre-marie.pedrot@inria.fr> | 2017-02-14 17:26:34 +0100 |
commit | 258c8502eafd3e078a5c7478a452432b5c046f71 (patch) | |
tree | d4ce21b23a67056242410fbd78362213700af099 /tactics | |
parent | 77e638121b6683047be915da9d0499a58fcb6e52 (diff) |
Constr_matching API using EConstr.
Diffstat (limited to 'tactics')
-rw-r--r-- | tactics/auto.ml | 2 | ||||
-rw-r--r-- | tactics/class_tactics.ml | 2 | ||||
-rw-r--r-- | tactics/hipattern.ml | 4 |
3 files changed, 4 insertions, 4 deletions
diff --git a/tactics/auto.ml b/tactics/auto.ml index 17fe7362d..7462b8d85 100644 --- a/tactics/auto.ml +++ b/tactics/auto.ml @@ -139,7 +139,7 @@ let conclPattern concl pat tac = | None -> Proofview.tclUNIT Id.Map.empty | Some pat -> try - Proofview.tclUNIT (Constr_matching.matches env sigma pat concl) + Proofview.tclUNIT (Constr_matching.matches env sigma pat (EConstr.of_constr concl)) with Constr_matching.PatternMatchingFailure -> Tacticals.New.tclZEROMSG (str "conclPattern") in diff --git a/tactics/class_tactics.ml b/tactics/class_tactics.ml index a31e581e8..bef43d20b 100644 --- a/tactics/class_tactics.ml +++ b/tactics/class_tactics.ml @@ -305,7 +305,7 @@ let matches_pattern concl pat = | None -> Proofview.tclUNIT () | Some pat -> let sigma = Sigma.to_evar_map sigma in - if Constr_matching.is_matching env sigma pat concl then + if Constr_matching.is_matching env sigma pat (EConstr.of_constr concl) then Proofview.tclUNIT () else Tacticals.New.tclZEROMSG (str "conclPattern") diff --git a/tactics/hipattern.ml b/tactics/hipattern.ml index a42a51fc0..d27e4afb7 100644 --- a/tactics/hipattern.ml +++ b/tactics/hipattern.ml @@ -276,8 +276,8 @@ let coq_refl_jm_pattern = open Globnames -let is_matching x y = is_matching (Global.env ()) Evd.empty x y -let matches x y = matches (Global.env ()) Evd.empty x y +let is_matching x y = is_matching (Global.env ()) Evd.empty x (EConstr.of_constr y) +let matches x y = matches (Global.env ()) Evd.empty x (EConstr.of_constr y) let match_with_equation t = if not (isApp t) then raise NoEquationFound; |