On Wed, May 23, 2012 at 7:58 PM, Cedric Greevey <cgree...@gmail.com> wrote:
> (defn f [^java.awt.image.BufferedImage bi x]
>  (.setSample (.getRaster bi) 0 0 0 (double x)))
> #<CompilerException java.lang.IllegalArgumentException: More than one
> matching method found: setSample, compiling:(NO_SOURCE_PATH:1)>
>
> The only way I was able to find to fix this is
>
> (defn f [^java.awt.image.BufferedImage bi]
>  (.setSample (.getRaster bi) 0 0 0 ^Double (double x)))

I'm entirely not sure what's going on, but this seems to be good in the repl:

    (defn f [^java.awt.image.BufferedImage bi x]
        (.setSample (.getRaster bi) (int 0) (int 0) (int 0) ^double x))

I tried creating an object and running it through the function as well
with no warnings.

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