[Haskell-cafe] Small Haddock question
Denis Bueno
dbueno at gmail.com
Sat Jul 4 13:23:39 EDT 2009
On Sat, Jul 4, 2009 at 08:22, Andrew Coppin<andrewcoppin at btinternet.com> wrote:
> This is irritating me now... Suppose I have something like the following:
>
> zero = 0 :: Int
> one = 1 :: Int
> two = 2 :: Int
> three = 3 :: Int
>
> How do I add Haddock comments to the end of each line? For some reason,
> Haddock doesn't like either of
>
> zero = 0 :: Int -- | Zero
> zero = 0 :: Int -- ^ Zero
>
> Either way it whinges about parse errors. How do I make it shut up and stop
> being so dense at me? :-} It's damned obvious what I want it to do...
I think top-level definitions can only be commented in one way:
-- | Emptiness and void, as an Int.
zero = 0 :: Int
Denis
More information about the Haskell-Cafe
mailing list