Commit b3173244 authored by Simon Marlow's avatar Simon Marlow
Browse files

reorder bullet points in description of guards to match syntax

parent f839df8c
......@@ -825,9 +825,9 @@ pattern (see Section~\ref{pattern-matching}) of type "t" and "e" is an
expression type "t"\footnote{Note that the syntax of a pattern guard is the same as that of a generator in a list comprehension.
The contextual difference is that, in a list comprehension, a pattern of type "t" goes with an expression of type "@[@t@]@".}.
They succeed if the expression "e" matches the pattern "p", and introduce the bindings of the pattern to the environment.
\item {\em local bindings} are of the form "@let @decls". They always succeed, and they introduce the names defined in "decls" to the environment.
\item {\em boolean guards}\index{boolean guard} are arbitrary expressions of
type @Bool@. They succeed if the expression evaluates to @True@, and they do not introduce new names to the environment. A boolean guard, "g", is semantically equivalent to the pattern guard "@True <- @g".
\item {\em local bindings} are of the form "@let @decls". They always succeed, and they introduce the names defined in "decls" to the environment.
\end{itemize}
\end{haskellprime}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment