> > And now any of those implementations can easily change at anytime without > any external considerations. So what's the problem?
Well if you want to amend all of them at the same time, you have to modify all of them. On your advice of using extend-type: maybe I am wrong but I think it has a performance cost. I am not sure for the 1%, but the good metric is to look at the percentage of deftypes, not the whole code base. I think in a typical program, deftype already amount at less than 10% of the code. I wrote some code with a lot of different types implementing the same interfaces and that are made by composing different parts. I ended up splitting aspects in different types and use composition and "fake" protocols to implement cross-cutting aspects. I would have loved to have traits to do that instead: would have been easier, more performant and more natural to read. I could also have copied and pasted a lot, but it is asking for problem if you modify things later. -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en