aboutsummaryrefslogtreecommitdiff
path: root/tactics
AgeCommit message (Collapse)Author
2014-08-25Fixing bug #3377 by giving env and sigma to constrMathching. Now it's possibleMatthieu Sozeau
to match on a primitive projection application c.(p) using "?f _", binding f to (fun x => x.(p)) with the correct typing.
2014-08-25Add an is_cofix tacticJason Gross
Should we also add is_* tactics for other things? is_rel, is_meta, is_sort, is_cast, is_prod, is_lambda, is_letin, is_app, is_const, is_ind, is_constructor, is_case, is_proj?
2014-08-25instanciation is French, instantiation is EnglishJason Gross
2014-08-25Fixing previous commit.Pierre-Marie Pédrot
2014-08-25Fixing a bug introduced in the extension of 'apply in' + simplifying code.Hugo Herbelin
2014-08-23Tactics.is_quantified_hypothesis does not reduce anymore to decide whetherPierre-Marie Pédrot
a variable is quantified in the goal. This is only used by induction, and it should be a bad practice to depend on an invisible binder.
2014-08-23Tactics.unify in the new monad.Pierre-Marie Pédrot
2014-08-22Move UnsatisfiableConstraints to a pretype error.Matthieu Sozeau
2014-08-21Removing unused parts of the Goal.sensitive monad.Pierre-Marie Pédrot
Some legacy code remains to keep the newish refine tactic working, but ultimately it should be removed. I did not manage to do it properly though, i.e. without breaking the test-suite furthermore.
2014-08-21Removing a Goal.sensitive in Rewrite.Pierre-Marie Pédrot
2014-08-21Removing a use of tclSENSITIVE in Rewrite.Pierre-Marie Pédrot
2014-08-21Removing a use of tclSENSITIVE in Rewrite.Pierre-Marie Pédrot
2014-08-21Removing a use of tclSENSITIVE in Rewrite.Pierre-Marie Pédrot
2014-08-19Removing a use of Goal.refine.Pierre-Marie Pédrot
2014-08-18Lazy interpretation of patterns so that expressions such as "intros H H'/H"Hugo Herbelin
can be given with second H bound by the first one. Not very satisfied by passing closure to tactics.ml, but otherwise tactics would have to be aware of glob_constr.
2014-08-18Adding a new intro-pattern for "apply in" on the fly. Using syntaxHugo Herbelin
"pat/term" for "apply term on current_hyp as pat".
2014-08-18Improving error message when applying rewrite to an expression which is not ↵Hugo Herbelin
an equality.
2014-08-18Factorizing cutrewrite (to be made obsolote) and dependent rewrite (toHugo Herbelin
integrate to "rewrite"?) with the code of "replace". Incidentally, "inversion" relies on dependent rewrite, with an incompatibility introduced. Left-to-right rewriting is now done with "eq_rec_r" while before it was done using "eq_rec" of "eq_sym". The first one reduces to the second one but simpl is not anymore able to reduce "eq_rec_r eq_refl". Hopefully cbn is able to do it (see Zdigits).
2014-08-18A few more comments in tactics.mli and hippatern.ml.Hugo Herbelin
2014-08-18Slight simplification of naming of tactics in equality.ml (hopefully).Hugo Herbelin
Isolating a core tactic in replace, shareable to cutrewrite.
2014-08-18A reorganization of the "assert" tactics (hopefully uniform namingHugo Herbelin
scheme, redundancies, possibility of chaining a tactic knowing the name of introduced hypothesis, new proof engine).
2014-08-18Reorganisation of intropattern codeHugo Herbelin
- emphasizing the different kinds of patterns - factorizing code of the non-naming intro-patterns Still some questions: - Should -> and <- apply to hypotheses or not (currently they apply to hypotheses either when used in assert-style tactics or apply in, or when the term to rewrite is a variable, in which case "subst" is applied)? - Should "subst" be used when the -> or <- rewrites an equation x=t posed by "assert" (i.e. rewrite everywhere and clearing x and hyp)? - Should -> and <- be applicable in non assert-style if the lemma has quantifications?
2014-08-18Reorganization of tactics:Hugo Herbelin
- made "apply" tactics of type Proofview.tactic, as well as other inner functions about elim and assert - used same hypothesis naming policy for intros and internal_cut (towards a reorganization of intro patterns) - "apply ... in H as pat" now supports any kind of introduction pattern (doc not changed)
2014-08-18Refine patch for behavior of unify_to_subterm to allow backtracking onMatthieu Sozeau
unsatisfiable constraint failures but give sensible error messages if an occurrence was found and only typeclass resolution failed. Fixes MathClasses.
2014-08-18Moving the TacAlias node out of atomic tactics.Pierre-Marie Pédrot
2014-08-18Moving the TacExtend node from atomic to plain tactics.Pierre-Marie Pédrot
Also taking advantage of the change to rename it into TacML. Ultimately should allow ML tactic to return values.
2014-08-16Better printing of Ltac values.Pierre-Marie Pédrot
2014-08-16Fixing too restrictive detection of resolution of evars in "apply in"Hugo Herbelin
(revealed by contribution PTSF).
2014-08-15More self-contained code for tclWITHHOLES.Pierre-Marie Pédrot
2014-08-15Removing unused Refiner.tclWITHHOLES.Pierre-Marie Pédrot
2014-08-14Remove confusing behavior of unify_with_subterm that could fail withMatthieu Sozeau
NoOccurenceFound when only typeclass resolution failed. Might break some scripts relying on backtracking on typeclass resolution failures to find other terms to rewrite, which can be fixed using occurrences or directly setoid_rewrite.
2014-08-14Restore the error-handling behavior of [change], which was silently failingMatthieu Sozeau
when conversion in the goal failed.
2014-08-14Fix elimschemes accessing directly the universe context of inductives (fixes ↵Matthieu Sozeau
test-suite file HoTT_coq_089.v).
2014-08-07Better structure for Ltac pretyping environments.Pierre-Marie Pédrot
2014-08-07In Hipattern: some functions not working modulo evar instantiation.Arnaud Spiwack
In theory [Proofview.Goal.env] should be, itself, marked as requiring a normalised goals (as it includes [hyps] which does). However, it is impractical as it is very common to pass a goal environment to a function reasoning modulo evars. So I guess we are bound to mark the appropriate functions by hand.
2014-08-07Removing simple induction / destruct from the AST.Pierre-Marie Pédrot
2014-08-07Instead of relying on a trick to make the constructor tactic parse, putPierre-Marie Pédrot
all the tactics using the constructor keyword in one entry. This has the side-effect to also remove the other variant of constructor from the AST. I also needed to hack around the "tauto" tactic to make it work, by calling directly the ML tactic through a TacExtend node. This may be generalized to get rid of the intermingled dependencies between this tactic and the infamous Ltac quotation mechanism.
2014-08-07Removing the "constructor" tactic from the AST.Pierre-Marie Pédrot
2014-08-06Revert the change in Constrintern introduced by "Add a type of untyped term ↵Arnaud Spiwack
to Ltac's value." It was commit 52247f50fa9aed83cc4a9a714b6b8f779479fd9b. The closure in uconstr renders these changes (pertaining to substitution of ltac variables during internalisation) obsolete.
2014-08-06[uconstr]: use a closure instead of eager substitution.Arnaud Spiwack
This avoids relying on detyping. As Matthieu Sozeau pointed out to me, [understand∘detyping] has no reason to be the identity. This may create surprising behaviour some times (when a detyped term loses its relations to the current context, in particular in terms of universes), and downright incompatibilities in the case of refine. As a bonus this should be a faster implementation of [uconstr] with a leaner memory profile.
2014-08-06Removing "intros untils" from the AST.Pierre-Marie Pédrot
2014-08-05Experimentally adding an option for automatically erasing anHugo Herbelin
hypothesis when using it in apply or rewrite (prefix ">", undocumented), and a modifier to explicitly keep it in induction or destruct (prefix "!", reminiscent of non-linerarity). Also added undocumented option "Set Default Clearing Used Hypotheses" which makes apply and rewrite default to erasing the hypothesis they use (if ever their argument is indeed an hypothesis of the context).
2014-08-05Adding a syntax "enough" for the variant of "assert" with the order ofHugo Herbelin
subgoals and the role of the "by tac" clause swapped.
2014-08-05A new step in the new "standard" naming policy for propositional hypothesesHugo Herbelin
obtained from case analysis or induction. Made it under experimental status. This replaces commit bf7d2a3ad2535e7d57db79c17c81aaf67d956965 which was acting at the level of logic.ml. Now acting in tactics.ml. Parts of things to be done about naming (not related to Propositions): induction on H:nat+bool produces hypotheses n and b but destruct on H produces a and b. This is because induction takes the dependent scheme whose names are statically inferred to be a and b while destruct dynamically builds a new scheme.
2014-08-05STM: new "par:" goal selector, like "all:" but in parallelEnrico Tassi
par: distributes the goals among a number of workers given by -async-proofs-tac-j (defaults to 2).
2014-08-05Ltac's [idtac] is now interpreted outside of a goal if possible.Arnaud Spiwack
It avoids printing several times the same things when no constr are involved in the message. It also allows to print messages even after all goals have been solved.
2014-08-05Ltac's idtac is now implemented using the new API.Arnaud Spiwack
2014-08-05Tacinterp: [interp_message] and associate now only require an environment ↵Arnaud Spiwack
rather than an entire goal.
2014-08-05Tactics: [tclENV] is now sensitive to [Proofview.Goal.enter].Arnaud Spiwack
When "entering" in a goal, the environment observed by [tclENV] is changed (in the scope of the goal) to be that of the goal. I'm not entirely sure it is the right semantics. But it allows to write tactics which are agnostic of whether they are run in a goal or not.
2014-08-05Fix interpretation bug in [uconstr].Arnaud Spiwack
Substitution of the Ltac variables would only occur if the internalised [uconstr] was of the form [glob, Some expr], which is the case only in tactics defined inside a proof, but not in tactics defined in [Ltac].