*unchecked-math*

clojure.core

While bound to true, compilations of +, -, *, inc, dec and the
coercions will be done without overflow checks. Default: false.

0 Examples top

Log in to add / edit an example.

See Also top

Log in to add a see also.

Comments top

1 comment(s) for *unchecked-math*.

Note that, even if *unchecked-math* is true when compiling, the unchecked operations are used only when both operands are primitive; if either operand is boxed, normal Clojure arithmetic is used (see this message from Stuart Sierra on the Clojure Google group). This can be worked around by adding type hints (e.g. ^long) where necessary.

Log in to add a comment.