tibbe / haskell-style-guide

A style guide for Haskell code.
957 stars 75 forks source link

In export lists, why indent "section" comments further? #19

Open jubobs opened 9 years ago

jubobs commented 9 years ago

For export lists, you recommend indenting commented "section" lines two spaces further than the opening and closing braces and commas:

Format export lists as follows:

module Data.Set
    (
      -- * The @Set@ type
      Set
    , empty
    , singleton

      -- * Querying
    , member
    ) where

However, you don't seem to follow this recommendation in your own packages (cassava, unordered-containers etc.).

Is this recommendation intentional? If so, are there real benefits to it? Why not simply start the comment in the same column as braces and commas? Like so:

module Data.Set
    (
    -- * The @Set@ type
      Set
    , empty
    , singleton

    -- * Querying
    , member
    ) where