From 5b7eafd0f00a16d78f99a27f5c7d5a0de77dc7e6 Mon Sep 17 00:00:00 2001 From: Stephane Glondu Date: Wed, 21 Jul 2010 09:46:51 +0200 Subject: Imported Upstream snapshot 8.3~beta0+13298 --- tactics/equality.mli | 112 +++++++++++++++++++++++++-------------------------- 1 file changed, 56 insertions(+), 56 deletions(-) (limited to 'tactics/equality.mli') diff --git a/tactics/equality.mli b/tactics/equality.mli index 86ad3293..b5c14739 100644 --- a/tactics/equality.mli +++ b/tactics/equality.mli @@ -6,7 +6,7 @@ (* * GNU Lesser General Public License Version 2.1 *) (************************************************************************) -(*i $Id: equality.mli 11576 2008-11-10 19:13:15Z msozeau $ i*) +(*i $Id$ i*) (*i*) open Util @@ -25,43 +25,56 @@ open Tacexpr open Termops open Rawterm open Genarg +open Ind_tables (*i*) -val general_rewrite_bindings : - bool -> occurrences -> constr with_bindings -> evars_flag -> tactic -val general_rewrite : - bool -> occurrences -> constr -> tactic +type dep_proof_flag = bool (* true = support rewriting dependent proofs *) -(* Obsolete, use [general_rewrite_bindings l2r] -[val rewriteLR_bindings : constr with_bindings -> tactic] -[val rewriteRL_bindings : constr with_bindings -> tactic] -*) +type orientation = bool + +type conditions = + | Naive (* Only try the first occurence of the lemma (default) *) + | FirstSolved (* Use the first match whose side-conditions are solved *) + | AllMatches (* Rewrite all matches whose side-conditions are solved *) + +val general_rewrite_bindings : + orientation -> occurrences -> dep_proof_flag -> + ?tac:(tactic * conditions) -> constr with_bindings -> evars_flag -> tactic +val general_rewrite : + orientation -> occurrences -> dep_proof_flag -> + ?tac:(tactic * conditions) -> constr -> tactic (* Equivalent to [general_rewrite l2r] *) -val rewriteLR : constr -> tactic -val rewriteRL : constr -> tactic +val rewriteLR : ?tac:(tactic * conditions) -> constr -> tactic +val rewriteRL : ?tac:(tactic * conditions) -> constr -> tactic (* Warning: old [general_rewrite_in] is now [general_rewrite_bindings_in] *) -val register_general_setoid_rewrite_clause : - (identifier option -> bool -> - occurrences -> open_constr -> new_goals:constr list -> tactic) -> unit -val register_is_applied_setoid_relation : (constr -> bool) -> unit +val register_general_rewrite_clause : + (identifier option -> orientation -> + occurrences -> constr with_bindings -> new_goals:constr list -> tactic) -> unit +val register_is_applied_rewrite_relation : (env -> evar_map -> rel_context -> constr -> constr option) -> unit + +val general_rewrite_ebindings_clause : identifier option -> + orientation -> occurrences -> dep_proof_flag -> ?tac:(tactic * conditions) -> + constr with_bindings -> evars_flag -> tactic val general_rewrite_bindings_in : - bool -> occurrences -> identifier -> constr with_bindings -> evars_flag -> tactic + orientation -> occurrences -> dep_proof_flag -> ?tac:(tactic * conditions) -> + identifier -> constr with_bindings -> evars_flag -> tactic val general_rewrite_in : - bool -> occurrences -> identifier -> constr -> evars_flag -> tactic + orientation -> occurrences -> dep_proof_flag -> ?tac:(tactic * conditions) -> + identifier -> constr -> evars_flag -> tactic + +val general_multi_rewrite : + orientation -> evars_flag -> ?tac:(tactic * conditions) -> constr with_bindings -> clause -> tactic -val general_multi_rewrite : - bool -> evars_flag -> open_constr with_bindings -> clause -> tactic -val general_multi_multi_rewrite : - evars_flag -> (bool * multi * open_constr with_bindings) list -> clause -> - tactic option -> tactic +type delayed_open_constr_with_bindings = + env -> evar_map -> evar_map * constr with_bindings -val conditional_rewrite : bool -> tactic -> open_constr with_bindings -> tactic -val conditional_rewrite_in : - bool -> identifier -> tactic -> open_constr with_bindings -> tactic +val general_multi_multi_rewrite : + evars_flag -> (bool * multi * delayed_open_constr_with_bindings) list -> + clause -> (tactic * conditions) option -> tactic val replace_in_clause_maybe_by : constr -> constr -> clause -> tactic option -> tactic val replace : constr -> constr -> tactic @@ -69,24 +82,24 @@ val replace_in : identifier -> constr -> constr -> tactic val replace_by : constr -> constr -> tactic -> tactic val replace_in_by : identifier -> constr -> constr -> tactic -> tactic -val discr : evars_flag -> constr with_ebindings -> tactic +val discr : evars_flag -> constr with_bindings -> tactic val discrConcl : tactic val discrClause : evars_flag -> clause -> tactic val discrHyp : identifier -> tactic val discrEverywhere : evars_flag -> tactic -val discr_tac : evars_flag -> - constr with_ebindings induction_arg option -> tactic +val discr_tac : evars_flag -> + constr with_bindings induction_arg option -> tactic val inj : intro_pattern_expr located list -> evars_flag -> - constr with_ebindings -> tactic -val injClause : intro_pattern_expr located list -> evars_flag -> - constr with_ebindings induction_arg option -> tactic + constr with_bindings -> tactic +val injClause : intro_pattern_expr located list -> evars_flag -> + constr with_bindings induction_arg option -> tactic val injHyp : identifier -> tactic val injConcl : tactic -val dEq : evars_flag -> constr with_ebindings induction_arg option -> tactic -val dEqThen : evars_flag -> (int -> tactic) -> constr with_ebindings induction_arg option -> tactic +val dEq : evars_flag -> constr with_bindings induction_arg option -> tactic +val dEqThen : evars_flag -> (int -> tactic) -> constr with_bindings induction_arg option -> tactic -val make_iterated_tuple : +val make_iterated_tuple : env -> evar_map -> constr -> (constr * types) -> constr * constr * constr (* The family cutRewriteIn expect an equality statement *) @@ -100,26 +113,6 @@ val rewriteInConcl : bool -> constr -> tactic (* Expect the proof of an equality; fails with raw internal errors *) val substClause : bool -> constr -> identifier option -> tactic -(* -(* [substHypInConcl l2r id] is obsolete: use [rewriteInConcl l2r (mkVar id)] *) -val substHypInConcl : bool -> identifier -> tactic - -(* [substConcl] is an obsolete synonym for [cutRewriteInConcl] *) -val substConcl : bool -> constr -> tactic - -(* [substHyp] is an obsolete synonym of [cutRewriteInHyp] *) -val substHyp : bool -> types -> identifier -> tactic -*) - -(* Obsolete, use [rewriteInConcl lr (mkVar id)] in concl - or [rewriteInHyp lr (mkVar id) (Some hyp)] in hyp - (which, if they fail, raise only UserError, not PatternMatchingFailure) - or [substClause lr (mkVar id) None] - or [substClause lr (mkVar id) (Some hyp)] -[val hypSubst_LR : identifier -> clause -> tactic] -[val hypSubst_RL : identifier -> clause -> tactic] -*) - val discriminable : env -> evar_map -> constr -> constr -> bool val injectable : env -> evar_map -> constr -> constr -> bool @@ -127,12 +120,19 @@ val injectable : env -> evar_map -> constr -> constr -> bool val unfold_body : identifier -> tactic +type subst_tactic_flags = { + only_leibniz : bool; + rewrite_dependent_proof : bool +} +val subst_gen : bool -> identifier list -> tactic val subst : identifier list -> tactic -val subst_all : tactic +val subst_all : ?flags:subst_tactic_flags -> tactic (* Replace term *) -(* [replace_multi_term dir_opt c cl] +(* [replace_multi_term dir_opt c cl] perfoms replacement of [c] by the first value found in context (according to [dir] if given to get the rewrite direction) in the clause [cl] *) val replace_multi_term : bool option -> constr -> clause -> tactic + +val set_eq_dec_scheme_kind : mutual scheme_kind -> unit -- cgit v1.2.3