Skip to content

Commit

Permalink
fix(13): typos, denoted
Browse files Browse the repository at this point in the history
Colon changed to semicolon. Used "written" to indicate that it is notation.
  • Loading branch information
spl authored and soonhokong committed Feb 4, 2016
1 parent 3997afa commit 6187d60
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions 13_More_Tactics.org
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ the introduction rule for =true=, respectively.
** Combinators

Combinators are used to combine tactics. The most basic one is the
=and_then= combinator, denoted by a colon, which applies tactics
=and_then= combinator, written with a semicolon (=;=), which applies tactics
successively. This is not the same as listing tactics separated by
commas in a =begin ... end= block, since when multiple solutions are
available, =and_then= will backtrack until it finds a solution or
Expand All @@ -255,7 +255,7 @@ replace the semicolon by a comma:
example (p q : Prop) (Hq : q) : p ∨ q :=
begin constructor; assumption end
#+END_SRC
The constructor tactic creates a /stream/ of outcomes, one for each
The =constructor= tactic creates a /stream/ of outcomes, one for each
possible result. A comma forces the tactic to commit to an answer at
that point, whereas the semicolon causes Lean to systematically try
all the possibilities. Here is a more elaborate example:
Expand All @@ -273,7 +273,7 @@ returns a stream of solutions rather than the first one that
matches. In this case, the first solution that matches =p ?x= is
ultimately not the right choice, and backtracking is crucial.

The =par= tactic, denoted by =|=, tries one tactic and then the other,
The =par= combinator, written with a vertical bar (=|=), tries one tactic and then the other,
using the first one that succeeds. The =repeat= tactic applies a
tactic repeatedly. Here is an example of these in use:
#+BEGIN_SRC lean
Expand Down

0 comments on commit 6187d60

Please sign in to comment.