Michael Haufe wrote:
In 2008 I first proposed the addition of an integer division operator
to the language. At the time Brendan noted his regret for this
oversight and desire for the operator as well. I am not seeing this
operator available in the current draft. Can/will this be rectified?
a div b = (a - a % b) / b
This turns out to be equivalent to
(a/b)|0
which is how asm.js optimizes to avoid the FPU already.
/be
_______________________________________________
es-discuss mailing list
es-discuss@mozilla.org
https://mail.mozilla.org/listinfo/es-discuss