Live data from Hacker News

Clojure is cool

ahungry.com

11–20 of 133 posts

Re: Clojure is cool

#11

LISPs seem to me the best candidates for an alternative to the traditional text editor. I could imagine a mind-map sort of view which would allow you to expand and collapse sub-trees etc. Does anything like this exist? To me, that would be reason to experiment with something like Clojure.

You might find this repo interesting: https://github.com/shaunlebron/history-of-lisp-parens

Re: Clojure is cool

#12
post #6

So... awful and bloated Java code (with javadocs, why?!) compared to short counter-examples from Clojure. IMHO quite terrible way to compare the two…

Exactly. Java code looks artificially bloated (who uses 8 spaces for tabulation anyway?!). Class CookieMap is completely unnecessary, for example - it extends the j.u.Map with couple operations, which could be easily done with Java 8 streams (looks like it's older version of language - diamond operator is not used).

Re: Clojure is cool

#13
Thankfully Clojure will go nowhere beyond a few edge places. I saw a decent sized project written in Clojure script that had to be rewritten once the original authors moved on as new hires struggled to get anything done. Small features took enormous amounts of time.

Re: Clojure is cool

#15
post #6

So... awful and bloated Java code (with javadocs, why?!) compared to short counter-examples from Clojure. IMHO quite terrible way to compare the two…

And the Clojure cookie (de)serializer doesn't even deal with all the fields the original does?

Re: Clojure is cool

#16

LISPs seem to me the best candidates for an alternative to the traditional text editor. I could imagine a mind-map sort of view which would allow you to expand and collapse sub-trees etc. Does anything like this exist? To me, that would be reason to experiment with something like Clojure.

There is a long history (going back to the 1970s) of structure editors for Lisp and there was a discussion of them on HN recently. Interlisp and Interlisp-D were the primary proponents of this approach; I used to use D-Edit when I worked in Interlisp at PARC, though it wasn't really for me as it heavily depended on the mouse.

IMHO structure editing emphasizes the wrong part of code development. In practice collapsing graph structure is less important in code as opposed to, say, JSON. Whereas you want to be able to use your eye to hop around, and free-form alignment sometimes helps to show parallel constructs.

Remember also that in a structure editor even your comments have to be part of the code and can only be inserted in places where an expression won't change the flow of control (e.g. you can't do (if (* this is a comment*) some-condition result))

Re: Clojure is cool

#17
post #10

This has a great explanation of the clojure REPL. I think a lot of people hear about the REPL and think, oh my language has a REPL too, no big deal. Maybe the clojure REPL should be renamed to something else to differentiate it from other language REPLs

Maybe the other languages should rename what they are doing as Read Eval Print Loop comes from Lisp; read, eval and print don't have the same semantics in any other language (read especially).

Re: Clojure is cool

#18
I like verbosity in programming language. It becomes pretty easy to read the code, compared to lambdas or other concise languages.

If you are not working for a startup, majority of the time, you will be maintaining legacy code or bug fixing. I would take easily understandable verbose code over "clever" concise code every time.

Re: Clojure is cool

#19
post #13

Thankfully Clojure will go nowhere beyond a few edge places. I saw a decent sized project written in Clojure script that had to be rewritten once the original authors moved on as new hires struggled to get anything done. Small features took enormous amounts of time.

Literally interviewed at a company that is doing the same thing. B series, clojure/scala codebase, moving away to Elixir Phoenix.

Re: Clojure is cool

#20
post #13

Thankfully Clojure will go nowhere beyond a few edge places. I saw a decent sized project written in Clojure script that had to be rewritten once the original authors moved on as new hires struggled to get anything done. Small features took enormous amounts of time.

Your experience appears to be an outlier. Lots of companies are using Clojure for large scale projects, and my own team has been happily using it for nearly a decade now. The fact that your team struggled to get anything done probably says more about your team than Clojure to be honest.

https://clojure.org/community/success_stories

Post reply on HN