Comment by AshamedCaptain

5 years ago

> I think it's a mistake to think that because you can't read the code, that it is the code that is somehow unreadable, instead of a language you simply haven't learned to read.

This argument is significantly weakened when simply removing the meaningless macros and adding whitespace improves readability.

It's not like it is complicated because it is written in a structurally different language, nor will you actually leverage any benefit from learning this language. It's just obfuscated under the guise of abbreviation.

> This argument is significantly weakened when simply removing the meaningless macros and adding whitespace improves readability.

I disagree wholeheartedly. Whitespace tends to move code further away from the code that uses it; scrolling and tab-flipping requires the developer hold that code in their head where it is most likely to degrade. It is much much better to make them remember as little as possible.

It also helps reuse: If you don't scroll, you can see more code, so you can see if something is a good candidate for abstracting, just because you can see them doing the same thing.

Macros like this help with that, and so they aren't "meaningless". Less whitespace helps with that, and so it actually improves readability (to those who have to read it!).

The trade-off is that you can't hire someone with "C" on their CV and expect them to be productive on their first day, but in a complex codebase, this might not be possible for other reasons.

  • I have a hard time believing that increasing the size of your terminal "helps reuse".

    First, I do not agree that working memory is any significant limit when analyzing code, specially because one of the first steps is going to create the mental abstraction that allows you to, precisaly, understand the code. The density of that abstraction is definitely uncorrelated to the amount of whitespace. Thus, scrolling is only going to be an issue for the first couple of reads.

    Second, say your patented steganography mechanism manages to fit 3x the amount of "code" in the same terminal size (and I am being generous). Is this going to increase "code reuse" by any significant amount?

    • > one of the first steps is going to create the mental abstraction that allows you to, precisaly, understand the code.

      Precisely.

      Now a short program is "short enough" that you can convince yourself it is correct; That is to say, I'm sure you can imagine writing "hello world" without making a mistake, and that there is some threshold of program length where your confidence in error-free programming will be lost. For every seeing-programmer I have ever met, and I suspect strongly all seeing-programmers, that length is measured in "source-code pixels". Not lines, or characters, but literal field of view. Smaller screen? More bugs.

      Where you are forced to deal with your application in terms of the mental abstraction, rather than what the code actually says it does, it is simply because that code is off-screen, and that mental abstraction is a sieve: If you had any true confidence in it, you would not believe that program length correlates with bugs.

      > scrolling is only going to be an issue for the first couple of reads.

      I've worked on codebases large enough that they've taken a few years to read fully, and codebases changing so quickly that there's no point to learn everything. Sometimes you can read a program, and sometimes you can't, but when you can't, the damage that scrolling does seems infinitely worse.

      > Is this going to increase "code reuse" by any significant amount?

      Yes, and usually by a factor of a thousand or more.

      2 replies →

> This argument is significantly weakened when simply removing the meaningless macros and adding whitespace improves readability.

Yes, but for this case adding whitespace actually decreases readability. At least if you know Whitney's hate of scrolling.