"Rob Lachlan" <robertlach...@gmail.com> wrote: >Because the compiler is upset that it doesn't know what n is. r is a >long, but n is ???. The following works: > >(defn ^:static fact [^long n] > (loop [n n r 1] > (if (zero? n) > r > (recur (dec n) (* r n))))) > >Or see Dnolen's version above. But yeah, I wish that it still worked, >because it used to work just fine.
Is there reason the compiler can't box r instead of throwing an exception? -- Sent from my Android phone with K-9 Mail. Please excuse my brevity. -- 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