That image fails at making its point however. Even without the brackets, who considers "cond = 1 ag ad recurse carry augend addend 1" a beautiful line of code?
IMHO, without parens you will end up aiming for ml and matching. Otherwise removing everything will turn anything into ...
Without punctuation:
int thing int a int b while c = a ++ > b b = 0 a = b + c return c
Well almost gibberish, I have to admit, infix and some mandatory keyword do help. But Lisps have this tendency to be structural ... so their syntax and idioms go along with that very often. It's somehow twisted to remove that from them.
Without types:
thing a b while c = ++ a > b b = 0 a = b + c return c
Without most operator symbols:
thing a b while c eq inc! a > b b = 0 a = sum b c return c
Keeping the process
thing a b while c eq inc! a > b b isnow 0 a set-to sum b c return c
thing a b while c eq inc! a gt b b isnow 0 a isnow sum b c c
Recovering a bit of alternative syntax:
(int thing int a int b) while (c = a ++ > b. b = 0) a = b + c return c
Nope. Tried Gun Emacs with such a mode for a bit recently because that came as a default in a Clojure editing recipe I found, but having using versions of EMACS to edit LISP since 1980 I found it more annoying than helpful, there are times when I want to mangle the text and fix the parens afterwards.
For me the two keys are smart indention and the habit of counting off each opening paren at the beginning of an indented line as I close it. I did this sort of work on GoldHill's EMACS clone in the brief period I worked for them, getting it to blink the opening paren when the point is positioned to the right of the closing paren.
Comments
That image fails at making its point however. Even without the brackets, who considers "cond = 1 ag ad recurse carry augend addend 1" a beautiful line of code?
IMHO, without parens you will end up aiming for ml and matching. Otherwise removing everything will turn anything into ...
Without punctuation:
Well almost gibberish, I have to admit, infix and some mandatory keyword do help. But Lisps have this tendency to be structural ... so their syntax and idioms go along with that very often. It's somehow twisted to remove that from them.Without types:
Without most operator symbols: Keeping the process Recovering a bit of alternative syntax: <digression/>Eh, it's a Zen sort of thing, we both see and don't see the parens.
More specifically, we don't focus on the parens. And in the image, they're still there, just a very light yellow....
May I ask if you use paredit-like editors ? sexp make it easier to manipulate code, something that people can't appreciate on an image.
Nope. Tried Gun Emacs with such a mode for a bit recently because that came as a default in a Clojure editing recipe I found, but having using versions of EMACS to edit LISP since 1980 I found it more annoying than helpful, there are times when I want to mangle the text and fix the parens afterwards.
For me the two keys are smart indention and the habit of counting off each opening paren at the beginning of an indented line as I close it. I did this sort of work on GoldHill's EMACS clone in the brief period I worked for them, getting it to blink the opening paren when the point is positioned to the right of the closing paren.
Strange, I'm quite fond of paredit sexp transformation, wrap, unwrap, slurp etc. It's a nice 'UX' algebra.
Me too. I miss paredit in languages that don't really allow for it.