[Haskell-cafe] Coding conventions for Haskell?

Max Rabkin max.rabkin at gmail.com
Mon Sep 27 17:07:55 EDT 2010


On Mon, Sep 27, 2010 at 22:57, Andrew Coppin
<andrewcoppin at btinternet.com> wrote:
>  data Foo a b =
>      Foo    a   |
>      Bar      b |
>      Foobar a b
>    deriving (Eq, Ord)
>
> It honestly annoys me that Haddock disagrees with me on this point...

I disagree with you too, and so does your version control (if I'm
wrong, please tell me, so I can switch). If you add a constructor, you
have to make a change to the line containing the old last constructor,
even though you didn't actually change that line.

Also, either your pipes don't line up, or you violate your own rule

> I generally try to structure my code so that all blocks indent by 2 spaces, and the size of indentation never depends on the length of an identifier.

...except that the spaces here are not indentation.

--Max

(exhausted from real work, so taking some time out to paint the bikeshed)


More information about the Haskell-Cafe mailing list