Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

How retarded, look at Clojure instead


How cavalier of you... never mind that there are many thousands of people who may not have a choice but to use Java. Anything that eases the pain of boilerplate is a good thing.


What are you talking about? Clojure is a lisp for java, written in java and itself, published as a jar.


And your point is? Because it is written in Java and packaged as a jar does nothing to convince my boss and team members that we should write all of our code in Clojure. I wish it were that easy.


I cannot help you with that. Maybe you should be on the outloook of more interesting things to do? I don't know...


retarded is too harsh :) however the same can be accomplished through macros in a way that is better integrated with the language (when debugging lombok generated code lombok tags are not of much use i would imagine, forcing one to understand the generated code).

something like:

(defdata mountain name :setter :getter latitude :getter etc ...)

might not be too hard to implement on top of clos (or on top of defstruct - but clos has the advantage of already having flexible accessors) not sure about clojure.


Clojure would look something like this:

    (defstruct mountain :name :latitude :longitude :country) 
    (struct mountain "Zugspitze" 47.416667 10.983333 "Germany")




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: