- About Scala
- Documentation
- Code Examples
- Software
- Scala Developers
Re: Re: Code style: Length of lines
Mon, 2011-04-04, 01:54
Why do newspapers have their content in columns, instead of just flowing text across the page? I could be wrong but I thought I read once that people find it easier to read because your eyes don't have to move too much.
On Mon, Mar 14, 2011 at 2:22 PM, Rex Kerr <ichoran@gmail.com> wrote:
On Mon, Mar 14, 2011 at 2:22 PM, Rex Kerr <ichoran@gmail.com> wrote:
On Mon, Mar 14, 2011 at 1:04 PM, Matthew Pocock <turingatemyhamster@gmail.com> wrote:
i still think this is ridiculus. i'd refuse to be crippled for 99.9% of the time just because no one bothers to fix the actual problem.
Do you feel crippled by sticking within 80 columns
Yes, absolutely.
Sometimes you start
an idea and it's easier to follow
it if it's all on one line.
Don't you think?
80 characters is not consistently enough unless one uses very short variable and method names, and doesn't have very deep nesting. Depending on the code I'm working on, 80 can either be more than adequate or feel hopelessly limiting.
and indenting your code consistently?
No, not at all. Consistent indentation of code is helpful in the _same way that breaking 80 columns is helpful_. That is, it lets you consolidate ideas in a visually instructive manner.
(Incidentally, vim will soft-wrap lines for you; 80+ character problem solved, for the occasional quick fix remotely.)
--Rex