Is 78 characters still a good option? Was: [Haskell-cafe] breaking too long lines

Xiao-Yong Jin xj2106 at
Tue Apr 21 08:49:51 EDT 2009

Dusan Kolar <kolar at> writes:

> Dear all,
>  reading that
>> according the several style guides, lines shouldn't be too long
>> (longer than 78 characters).
> I would like to know, whether 78 characters bound still makes a
> sense... Even if I connect to my linux box with text terminal, it is
> not a 80x24 characters HW text terminal, but a window emulating this
> in whatever else OS, thus, I can usually extend this to see longer
> lines easily.
> Or is the reason much deeper? Or, is the bound set to 78 characters
> just because it is as good number as any other?

I believe it is a good practice too keep each line short and
easy to read.  The following is taken from python style

 Maximum Line Length

    Limit all lines to a maximum of 79 characters.

    There are still many devices around that are limited to 80 character
    lines; plus, limiting windows to 80 characters makes it possible to have
    several windows side-by-side.  The default wrapping on such devices
    disrupts the visual structure of the code, making it more difficult to
    understand.  Therefore, please limit all lines to a maximum of 79
    characters.  For flowing long blocks of text (docstrings or comments),
    limiting the length to 72 characters is recommended.

P.S.  We really need such a well written style guide for
      haskell.  Python has this nice PEP (Python Enhancement
      Proposals).  Should we start making our own HEP?
    c/*    __o/*
    <\     * (__
    */\      <

More information about the Haskell-Cafe mailing list