On Sep 15, 2010, at 10:15 PM, Lee Spector wrote:

> Also, this would have a smaller impact but I'm curious about it: is there a 
> way to treat method names as data and then make calls to them, as one can 
> with clojure functions? Then I could pass things like fillRect, or map rect 
> to fillRect, etc. This would make things slightly simpler here but be handy 
> in other cases... but I don't see how to do it.

As you've discovered, Java method names are unfortunately not first-class 
functions in Clojure. You have to wrap them with memfn or a lambda like 
#(.fillRect %).

-- 
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

Reply via email to