Dusan Kolar <ko...@fit.vutbr.cz> writes: > Dear all, > > reading that > >> according the several style guides, lines shouldn't be too long >> (longer than 78 characters). >> >> http://www.cs.caltech.edu/courses/cs11/material/haskell/misc/haskell_style_guide.html >> http://www.haskell.org/haskellwiki/Programming_guidelines >> > 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 guide. 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. http://www.python.org/dev/peps/pep-0008/ 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/* <\ * (__ */\ < _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe