summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2015-12-07 11:23:50 +0100
committerBen Gamari <ben@smart-cactus.org>2015-12-07 12:15:02 +0100
commit91e985cd99e9f628e7cd01fc5dd0e6f596337446 (patch)
treedc65f6281ad1b0df3ab921f1a315903533f81eee
parent8cef8af3286f3c98f2a02e65371b875d8791b687 (diff)
downloadhaskell-91e985cd99e9f628e7cd01fc5dd0e6f596337446.tar.gz
Minor stylistic fixes in glasgow_exts.rst
-rw-r--r--docs/users_guide/glasgow_exts.rst25
1 files changed, 11 insertions, 14 deletions
diff --git a/docs/users_guide/glasgow_exts.rst b/docs/users_guide/glasgow_exts.rst
index 7e448beb9c..f86d716196 100644
--- a/docs/users_guide/glasgow_exts.rst
+++ b/docs/users_guide/glasgow_exts.rst
@@ -1721,11 +1721,12 @@ comprehensions are explained in the previous chapters
the type ``[a]`` with the type ``Monad m => m a`` for monad
comprehensions.
-Note: Even though most of these examples are using the list monad, monad
-comprehensions work for any monad. The ``base`` package offers all
-necessary instances for lists, which make ``MonadComprehensions``
-backward compatible to built-in, transform and parallel list
-comprehensions.
+.. note::
+ Even though most of these examples are using the list monad, monad
+ comprehensions work for any monad. The ``base`` package offers all
+ necessary instances for lists, which make ``MonadComprehensions``
+ backward compatible to built-in, transform and parallel list
+ comprehensions.
More formally, the desugaring is as follows. We write ``D[ e | Q]`` to
mean the desugaring of the monad comprehension ``[ e | Q]``:
@@ -6690,9 +6691,7 @@ Two things to watch out for:
specifications cannot be nested. To specify ``GMap``\ 's data
constructors, you have to list it separately.
-- Consider this example:
-
- ::
+- Consider this example: ::
module X where
data family D
@@ -6701,13 +6700,11 @@ Two things to watch out for:
import X
data instance D Int = D1 | D2
- Module Y exports all the entities defined in Y, namely the data
+ Module ``Y`` exports all the entities defined in ``Y``, namely the data
constructors ``D1`` and ``D2``, and *implicitly* the data family ``D``,
- even though it's defined in X.
- This means you can write "``import Y( D(D1,D2) )``" *without*
- giving an explicit export list like this:
-
- ::
+ even though it's defined in ``X``.
+ This means you can write ``import Y( D(D1,D2) )`` *without*
+ giving an explicit export list like this: ::
module Y( D(..) ) where ...
or module Y( module Y, D ) where ...