Mmm, I don't think what you're saying is true?
I'll be honest I haven't touched Java in a long time, and I'm haven't had to extend my Clojure code this much before (but it's nice to know that I can - and use protocols with confidence)
Say LibraryA has some record..
LibraryB and LibraryC `extend-type` the record and implement additional functionality by implementing protocols..
Now you want to us both libraries in your application and use this record with both extensions.
In Java this is forbidden due to diamond dependencies restrictions.
You can use multiple protocols in Java, but you can't have the protocols implemented (there are default methods but they don't have access to the Record's state)
Is there some way around this..? As far as I understand there isn't.
Furthermore, all the extensions need wrappers and need names. Nobody is doing this b/c you'd go nuts. But in Clojure it'd be a natural way to extend a library.
For instance
(defprotocol MyProtocol
(foo [x]))
(extend-type clojure.lang.PersistentVector
MyProtocol
(foo [x] (str "Vector of size " (count x))))
(extend-type clojure.lang.PersistentList
MyProtocol
(foo [x] (str "List of size " (count x))))
I can keep using vectors and lists as before and have new functionality. I don't need a new wrapper to think about