On Fri, Jan 28, 2011 at 12:55 PM, Benny Tsai <benny.t...@gmail.com> wrote:
> It seems that 'unchecked-add' returns a primitive (note that in the
> first version, 'recur' happily accepts the return from 'unchecked-add'
> without coercion), but when 'unchecked-add' is bound to a new name,
> the return gets boxed.
>
> Is this the correct interpretation, or am I missing something?

It's correct. Clojure's compiler inlines certain functions, including
clojure.core/unchecked-foo and, when the arity is 2, clojure.core/+ --
but not a bare, un-qualified +, which might (or might not) at runtime
refer to clojure.core/+ or clojure.core/unchecked-add or whatever.

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