5 ms·
Once you look at enough of it, your brain starts to see lisps differently. The parens fade away, and you mostly just see the indentation. It looks a little like
by actsasbuffoon 10y ago
Once you look at enough of it, your brain starts to see lisps differently. The parens fade away, and you mostly just see the indentation. It looks a little like Python once you adjust.
- peatmoss 10y agoThat's exactly right--kind of like working with an RPN calculator or staring at one of those "is it a vase or two faces?" pictures. Further, once the brain flip happens, languages that don't use S-expressions start to feel uncomfortably... uncontained.
- hashkb 10y agoLisp critics have heard this argument, and are choosing to continue hating on the parens. It's easy to find a superficial reason to hate things.
- kazinator 10y agoYes; that argument actually has to be experienced and no only heard. In my experience, the parens nonsense comes almost entirely from programmers with no Lisp coding experience. It's based on "that looks as if it might be hard to edit".
- peatmoss 10y agoWhich is why lisp proponents have such a hard time understanding lisp critics: "Wait, you mean you were willing to reason through pointer arithmetic, monads, implementing a b-tree, etc. but you simply saw the parens and decided that would forever be the thing that you cannot, will not overcome? I mean in spite of all the fairly objective benefits of having a perfectly regular syntax, and code that can be processed by computers?"
- qwertyuiop924 10y agoIndeed. And with wisp (a scheme preprocessor/language extension), you can even write indentation-sensitive code, like it's python.
- actsasbuffoon 10y agoParinfer explores some of the same ideas, but as an editor extension: https://shaunlebron.github.io/parinfer/ https://shaunlebron.github.io/parinfer/
- qwertyuiop924 10y agoThat's a little more like Paredit, honestly.
- horrido 10y agoYou're over-generalizing. This is very much a matter of personal taste/inclination. Do ALL Lispers love the Lisp style of syntax? Of course not. Moreover, for many programmers, it's asking too much of them to wrap their heads around a syntax where you need to give it time for the parens to "fade" away. This cognitive hurdle is real and it's why Lisp isn't more popular. Let's not bury our heads in the sand.
- lispm 10y agoIt's not just the parentheses. It's the whole code-as-data and interactive development thing. Code is different. Programming is different. Lisp uses different working styles and tools. You have to learn the whole set. It's possible to learn that and to learn it well, but it might take some time. Lisp code can be very readable, but it's also to write very complex code - more complex that in most languages, since Lisp provides many mechanisms under developer control.
- kazinator 10y agoEven if you don't care about using code as data, Lisp is simply more readable, period. You don't have to crack open a reference manual to look at grammar rules or precedence tables to work out what the shape of the syntax tree is; you can read anything just from the symbolic prefix, plus a smattering of minor notations like sharpsign-this and sharpsign-that. A programmer who doesn't know Lisp can still instinctively tell that in (foo (x y) (z w)), the x and y go together more tightly than foo and x, or y and z. The meaning is determined by foo. But foo is a word. And words have the nice property that you can look them up easily in manuals (potentially with just a mouse click). Those who say Lisp is not readable are trolls and liars. They are liars because they see it's obviously more readable, but it threatens their self-image of being a competent programmer. It does that because their self-image is rooted in having memorized a bunch of arcane syntax and believing that that is what makes a software developer. Look at this comment, for instance: https://news.ycombinator.com/item?id=12883362 https://news.ycombinator.com/item?id=12883362 "If only the LISP syntax looked like a programming language and made logical sense." Very good representative comment which captures the mindset aptly. A programming language can only possibly be legit only if programs in that look like what you already know.