You have discovered a very recent change. The idea is to automatically switch to longs for performance when it is clear that overflow will not occur.
https://github.com/clojure/clojure/commit/684fca15040e1ec8753429909b2d463e99d857e7 There are still some problems with this optimization, which will hopefully be worked out before the final 1.3 release. http://dev.clojure.org/jira/browse/CLJ-836 On Thu, Sep 8, 2011 at 6:25 AM, Dominikus <dominikus.herzb...@gmail.com> wrote: > In Clojure 1.3, BigInts are said to be "contagious" across operations. > > """ > When different types of numbers are used in a math operation, the > result will be the larger or more general of the two types. For > example, any integer operation involving a BigInt will result in a > BigInt, [...]. > """ > http://dev.clojure.org/display/doc/Documentation+for+1.3+Numerics > > However (type (- 2 1N)) results in java.lang.Long and does not seem to > work accordingly. What's going on here? > -- 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