I also recommend the book "Grokking Simplicity" by Eric Normand for a longer exploration of functional software design (not Clojure-specific). The linked blog post uses Clojure examples, but this approach to software design is universally applicable (especially in functional programming!).
Abstract Clojure
31–40 of 43 posts
Re: Abstract Clojure
#32> The protocol is another form of abstraction we can use to decouple modules, the approach is more object-oriented than functional That's not true that the approach is more OO. People get confused because a lot of OO languages like Java eventually added support for something protocol-like, in Java it was interfaces for example, but for a long time Java, an OO language, didn't have interfaces, you only had Classes and…
Are you sure about Java? http://titanium.cs.berkeley.edu/doc/java-langspec-1.0/ talked about interfaces in 1996 and I don’t remember any version that didn’t have them.
smalltalk on the other hand, did not have explicit interfaces: http://www.jot.fm/issues/issue_2002_05/article1/
Re: Abstract Clojure
#33Earlier quoted context omitted.
Not writing Java (although you do have to do lots of interop with Java).
It's true it's "not writing Java", that's true for every language besides Java! But the second part is definitely not true. First, you can very much use JVM Clojure without touching Java, I've done so many times. Secondly, you can use ClojureScript which cannot even do interop with Java since it "compiles" to JavaScript and doesn't run on the JVM. Thirdly, you can use Babashka to run Clojure code with GraalVM and SCI…
When I said 'not writing Java' I was obviously talking about the JVM.
Re: Abstract Clojure
#34What is Clojure's main selling point?
If you have an hour spare, probably the best way to understand Clojure's main selling points is to watch this talk: https://www.infoq.com/presentations/Simple-Made-Easy/ InfoQ list the Key Takeaways as: - We should aim for simplicity because simplicity is a prerequisite for reliability. - Simple is often erroneously mistaken for easy. "Easy" means "to be at hand", "to be approachable". "Simple" is the opposite of "co…
Re: Abstract Clojure
#35What is Clojure's main selling point?
Not writing Java (although you do have to do lots of interop with Java).
Re: Abstract Clojure
#36What is Clojure's main selling point?
Re: Abstract Clojure
#37Earlier quoted context omitted.
It's true it's "not writing Java", that's true for every language besides Java! But the second part is definitely not true. First, you can very much use JVM Clojure without touching Java, I've done so many times. Secondly, you can use ClojureScript which cannot even do interop with Java since it "compiles" to JavaScript and doesn't run on the JVM. Thirdly, you can use Babashka to run Clojure code with GraalVM and SCI…
If you are writing toy programs in your mom's basement sure but every real world clojure project I have work with had to use Java libraries. When I said 'not writing Java' I was obviously talking about the JVM.
That's OK, most real world Clojure and ClojureScript projects I've worked on didn't had to use Java libraries, maybe 10% of them had to have Java code or used Clojure-wrapped Java libraries. Everyone's experience is different :)
> When I said 'not writing Java' I was obviously talking about the JVM.
Yeah, that's not super obvious as normally people consider Java the language to be something else than JVM the runtime.
Re: Abstract Clojure
#38> The protocol is another form of abstraction we can use to decouple modules, the approach is more object-oriented than functional That's not true that the approach is more OO. People get confused because a lot of OO languages like Java eventually added support for something protocol-like, in Java it was interfaces for example, but for a long time Java, an OO language, didn't have interfaces, you only had Classes and…
Re: Abstract Clojure
#39Re: Abstract Clojure
#40> The protocol is another form of abstraction we can use to decouple modules, the approach is more object-oriented than functional That's not true that the approach is more OO. People get confused because a lot of OO languages like Java eventually added support for something protocol-like, in Java it was interfaces for example, but for a long time Java, an OO language, didn't have interfaces, you only had Classes and…
Are you sure about Java? http://titanium.cs.berkeley.edu/doc/java-langspec-1.0/ talked about interfaces in 1996 and I don’t remember any version that didn’t have them.