1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 | import * as math from './math.js'
|
8 | import * as binary from './binary.js'
|
9 |
|
10 | export const MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER
|
11 | export const MIN_SAFE_INTEGER = Number.MIN_SAFE_INTEGER
|
12 |
|
13 | export const LOWEST_INT32 = 1 << 31
|
14 |
|
15 |
|
16 |
|
17 | export const HIGHEST_INT32 = binary.BITS31
|
18 |
|
19 |
|
20 |
|
21 |
|
22 |
|
23 |
|
24 | export const isInteger = Number.isInteger || (num => typeof num === 'number' && isFinite(num) && math.floor(num) === num)
|
25 | export const isNaN = Number.isNaN
|
26 | export const parseInt = Number.parseInt
|