Hi, Am 07.12.2009 um 21:37 schrieb Bob Hutchison:
>> Please note that in clojure, it's the dispatch on the class that's the >> "trick", not on the type ;-) > > Sorry, I don't understand what you mean. Could you expand on that a bit? Dispatch on the class (or interface) is sometimes the "trick" in clojure. That means a special case, which solves the problem. Eg. the print-method which causes things to be printed by print dispatches on type. Now, type recognises any type tag on the metadata of a thing. But when there is no method defined for this type, print would barf. So the default print-method simply dissocs the type tag from the metadata and retries causing basically a dispatch on the class of the underlying container. Most likely some Map or so. So dispatching on the class is here the trick. Dispatching on type the usual case. Sincerely Meikel
smime.p7s
Description: S/MIME cryptographic signature