Op woensdag 8 juli 2015 05:20:51 UTC+2 schreef Herwig Hochleitner: > > The way I would do it: Define multiply as a function calling (.multiply > amount ^Number x), for higher order usage, and then add an :inline function > to its metadata, which returns `(.multiply ~amount ~x). > That acts as a compiler macro, which inlines the call to .multiply, that > way, its parameter type can be assigned via local type inferrence (which > clojure does). > See http://www.bytopia.org/2014/07/07/inline-functions-in-clojure/#sec-3 > Beware, that inline functions aren't public API and subject to change. > > One more question. What does :inline-arities exactly do?
-- 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 --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.