aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorArnaud Spiwack2015-01-14 12:00:24 +0100
committerArnaud Spiwack2015-01-14 14:50:58 +0100
commit1fab386bc1a96951da011de2a5490c6dbe1b7248 (patch)
treeeb92d73f0d22d7cffa1cad0a8718ba845999e3a1 /doc
parent61ca1ce53bf160a23fc4c8af4059d9efd742f1fb (diff)
Reference manual: try and improve the documentation of lazymatch.
In particular try to avoid the use of the word "backtracking" which refers to too many things.
Diffstat (limited to 'doc')
-rw-r--r--doc/refman/RefMan-ltac.tex16
1 files changed, 12 insertions, 4 deletions
diff --git a/doc/refman/RefMan-ltac.tex b/doc/refman/RefMan-ltac.tex
index dbb71a4142..95467acd7f 100644
--- a/doc/refman/RefMan-ltac.tex
+++ b/doc/refman/RefMan-ltac.tex
@@ -701,8 +701,12 @@ then a no-matching-clause error is raised.
\item \index{lazymatch!in Ltac}
\index{Ltac!lazymatch}
-Using {\tt lazymatch} instead of {\tt match} disables the backtracking
-mechanism.
+Using {\tt lazymatch} instead of {\tt match} will perform the same
+pattern matching procedure but will commit to the first matching
+branch rather than trying a new matching if the right-hand side
+fails. If the right-hand side of the selected branch is a tactic with
+backtracking points, then subsequent failures cause this tactic to
+backtrack.
\item \index{context!in pattern}
There is a special form of patterns to match a subterm against the
@@ -808,8 +812,12 @@ the {\tt match reverse goal with} variant.
\index{Ltac!lazymatch goal}
\index{lazymatch reverse goal!in Ltac}
\index{Ltac!lazymatch reverse goal}
-Using {\tt lazymatch} instead of {\tt match} disables the backtracking
-mechanism.
+Using {\tt lazymatch} instead of {\tt match} will perform the same
+pattern matching procedure but will commit to the first matching
+branch with the first matching combination of hypotheses rather than
+trying a new matching if the right-hand side fails. If the right-hand
+side of the selected branch is a tactic with backtracking points, then
+subsequent failures cause this tactic to backtrack.
\subsubsection[Filling a term context]{Filling a term context\index{context!in expression}}