Error throw when defining function with return type hint

2014-02-10 Thread macdevign mac
Hi, I'm new to the clojure and try to learn this language. Referring to this at http://clojure.org/java_interop#Java%20Interop-Type%20Hints when trying this code (defn testing (^String []) (.toUpperCase hello world)) clojure throws java.lang.IllegalArgumentException: Parameter

Re: Error throw when defining function with return type hint

2014-02-10 Thread macdevign mac
I get it. Thank :} On Monday, February 10, 2014 11:19:06 PM UTC+8, Jim foo.bar wrote: On 10/02/14 15:08, macdevign mac wrote: (defn testing (^String []) (.toUpperCase hello world)) ;;syntax for overloading (defn testing (^String [] ;;notice the omitted bracket

Re: Error throw when defining function with return type hint

2014-02-10 Thread Jim - FooBar();
On 10/02/14 15:08, macdevign mac wrote: (defn testing (^String []) (.toUpperCase hello world)) ;;syntax for overloading (defn testing (^String [] ;;notice the omitted bracket (.toUpperCase hello world)) (^String [^String a] (.toUpperCase a)) ) ;;non-overloaded fns (defn