Please note, this is a STATIC archive of website developer.mozilla.org from 03 Nov 2016, cach3.com does not collect or store any user information, there is no "phishing" involved.

lukewestby

Member since
lukewestby

Recent Docs Activity

View all activity
Page Date Comment

Math.trunc()


~~x truncates but also clamps 64-bit numbers to 32-bit integers. Using the current polyfill will only work for the range (-858993459, 858993459). The one I added works for all numbers in (-Number.MAX_SAFE_INTEGER, Number.MAX_SAFE_INTEGER). Thanks!