Found on proggit: Krug, a new experimental programming language, compiler written in D
Walter Bright
newshound2 at digitalmars.com
Thu Apr 26 23:26:30 UTC 2018
On 4/26/2018 3:29 PM, Nick Sabalausky (Abscissa) wrote:
> The theory goes:
>
> A. "less syntax => easier to read".
> B. "There's no technical need to require it, and everything that can be removed
> should be removed, thus it should be removed".
>
> Personally, I find the lack of parens gives my brain's visual parser
> insufficient visual cues to work with, so I always find it harder to read. And
> regarding "B", I just don't believe in "less is more" - at least not as an
> immutable, universal truth anyway. Sometimes it's true, sometimes it's not.
Haskell seems to take the "minimal syntax" as far as possible (well, not as far
as APL which has a reputation for being write only). Personally, I find it makes
Haskell much harder to read than necessary.
Having redundancy in the syntax makes for better, more accurate error
diagnostics. In the worst case, for a language with zero redundancy, every
sequence of characters is a valid program. Hence, no errors can be diagnosed!
Besides, redundancy can make a program easier to read (English has a lot of it,
and is hence easy to read). And I don't know about others, but I read code an
awful lot more than I write it.
I posit that redundancy is something programmers learn to appreciate as they
gain experience, and that eliminating redundancy is something new programmers
think is a new idea :-)
P.S. Yes, excessive redundancy and verbosity can be bad. See COBOL.
More information about the Digitalmars-d
mailing list