Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
154 commits
Select commit Hold shift + click to select a range
ef21e41
Initial polyfill; no compat data yet
johnzhou721 Feb 15, 2026
8aad1fb
Lint, export
johnzhou721 Feb 15, 2026
54133b5
Merge branch 'zloirock:master' into requestidlecallback
johnzhou721 Feb 15, 2026
2aa3acf
Update tests following import of dependencies into web
johnzhou721 Feb 15, 2026
6851678
Add test for request-idle-callback loading
johnzhou721 Feb 15, 2026
80a9db3
Use internal module for idle callbacks
johnzhou721 Feb 15, 2026
2862cf0
Use internals in public module
johnzhou721 Feb 15, 2026
81175ab
Export cancel idle callback
johnzhou721 Feb 15, 2026
5c5984d
Remove extra import
johnzhou721 Feb 15, 2026
83a3168
Lint
johnzhou721 Feb 15, 2026
c0e6a92
Typo; space
johnzhou721 Feb 15, 2026
f31647e
Refactor requestIdleCallback export syntax
johnzhou721 Feb 16, 2026
e949b9f
Es3
johnzhou721 Feb 16, 2026
3aa5871
Feature detection
johnzhou721 Feb 16, 2026
bbd9d29
Merge remote-tracking branch 'fork/requestidlecallback' into requesti…
johnzhou721 Feb 16, 2026
04e094e
Correct entry points
johnzhou721 Feb 16, 2026
ac8dffb
Update entry point
johnzhou721 Feb 16, 2026
8805667
Update moments
johnzhou721 Feb 16, 2026
a6a7d4e
Write... some... tests...
johnzhou721 Feb 16, 2026
ac1a0c7
Fixes
johnzhou721 Feb 16, 2026
404f8c6
Update data and tests
johnzhou721 Feb 16, 2026
5fe5409
Degrade tests
johnzhou721 Feb 16, 2026
1a62d70
Fix test
johnzhou721 Feb 16, 2026
6f7ef12
Debug test
johnzhou721 Feb 16, 2026
58785ad
Try to fix test again
johnzhou721 Feb 16, 2026
f85ce5b
Working
johnzhou721 Feb 16, 2026
b4d1147
Fixes for global
johnzhou721 Feb 16, 2026
8b67fe5
Add pure tests
johnzhou721 Feb 16, 2026
b83f7be
import cancael
johnzhou721 Feb 16, 2026
a9a3a9a
Fix test
johnzhou721 Feb 16, 2026
ddc073f
Lint
johnzhou721 Feb 16, 2026
7227e00
Try to fix tests
johnzhou721 Feb 16, 2026
ccd38f6
Bump timeouts
johnzhou721 Feb 16, 2026
d9cd6a4
Remove stray test that we can't mock
johnzhou721 Feb 16, 2026
5ba7969
Lint.
johnzhou721 Feb 16, 2026
69b8311
Idle callback polyfills
johnzhou721 Feb 16, 2026
3649db5
Rerun CI for Karma
johnzhou721 Feb 16, 2026
a2fff3f
Restore package lock
johnzhou721 Feb 16, 2026
451a4ea
Polish docs
johnzhou721 Feb 16, 2026
501ffe6
Correct entry point
johnzhou721 Feb 16, 2026
857b648
Typo
johnzhou721 Feb 16, 2026
b317613
Remove GLOBAL prefix from requestIdleCallback checks
johnzhou721 Feb 20, 2026
bae4024
Remove hardcoded timeout
johnzhou721 Feb 20, 2026
929285d
Attempt to fix Karma
johnzhou721 Feb 20, 2026
7c2d0ca
Run karam
johnzhou721 Feb 20, 2026
f9b38cd
Run Karma (extra push to run karma
johnzhou721 Feb 20, 2026
07f6bb8
rerun CI
johnzhou721 Feb 20, 2026
a07dd7c
Refactor idle callbacks to use sharedStore
johnzhou721 Feb 20, 2026
136a2d1
Fix formatting issues in idle-callbacks.js
johnzhou721 Feb 20, 2026
5bf66e6
Remove handle from idle callback maps on timeout
johnzhou721 Feb 20, 2026
24ed606
If global, export cancelIdleCallback in requestIdleCallback
johnzhou721 Feb 20, 2026
509047a
If global, export requestIdleCallback in cancelIdleCallback
johnzhou721 Feb 20, 2026
2f09fa6
Improve assertions in web.request-idle-callback tests
johnzhou721 Feb 20, 2026
c26e6c0
Update idle-callback.md with usage notes
johnzhou721 Feb 20, 2026
b16bb2a
Enhance assertions in web.request-idle-callback tests
johnzhou721 Feb 20, 2026
65fdaca
single quotes
johnzhou721 Feb 21, 2026
3c2384e
Merge branch 'master' into requestidlecallback
johnzhou721 Mar 1, 2026
e3a42dc
Fix typo
johnzhou721 Mar 10, 2026
6b76f57
Repair double ticks
johnzhou721 Mar 10, 2026
c552f81
Remove ES deps from web
johnzhou721 Mar 10, 2026
392b4bc
Remove opera and edge data
johnzhou721 Mar 10, 2026
92e7393
Update idle-callbacks.js
johnzhou721 Mar 10, 2026
4bdd50d
Remove references to map
johnzhou721 Mar 10, 2026
dc4458b
Update cancel-idle-callback.js
johnzhou721 Mar 10, 2026
47c8ed3
Update request-idle-callback.js
johnzhou721 Mar 10, 2026
c6bbf4c
tighten check
johnzhou721 Mar 10, 2026
52a2cda
Do not specify arity
johnzhou721 Mar 10, 2026
9c73899
Remove arity
johnzhou721 Mar 10, 2026
20b708d
Reuse indexOf polyfill
johnzhou721 Mar 10, 2026
a1955df
Clean up timed out timers
johnzhou721 Mar 12, 2026
ef7690d
restore comment
johnzhou721 Mar 12, 2026
6a92377
Add syntactic sugar for easy adoption of Queue
johnzhou721 Mar 12, 2026
c1b626f
Add removal functionality to queue
johnzhou721 Mar 12, 2026
077f9e4
Clean up previous and next in remove
johnzhou721 Mar 12, 2026
b30289b
Refactor queue
johnzhou721 Mar 12, 2026
7e0e1c1
Use a doubly-linked list to track callbacks
johnzhou721 Mar 12, 2026
e8e808e
Two safeguards
johnzhou721 Mar 12, 2026
5a8cb1e
Use correct indexing
johnzhou721 Mar 12, 2026
d974e48
Update idle-callback.md
johnzhou721 Mar 12, 2026
bbde98c
Remove cross import
johnzhou721 Mar 12, 2026
6379601
Remove cross imports
johnzhou721 Mar 12, 2026
47eae65
Add a script to fix linting, and ran it
johnzhou721 Mar 12, 2026
dee7996
Fix linting
johnzhou721 Mar 12, 2026
6971d72
Simplify compat tests
johnzhou721 Mar 12, 2026
c013218
Expose IdleDeadline publically
johnzhou721 Mar 14, 2026
7534520
Fix arity of IdleDeadline
johnzhou721 Mar 14, 2026
eb361f8
Fix karma; consistent tests
johnzhou721 Mar 14, 2026
40f88b5
Fix linter
johnzhou721 Mar 14, 2026
a741685
Lint
johnzhou721 Mar 14, 2026
b404d5b
Remove es.map dep
johnzhou721 Mar 14, 2026
391c358
remove es.map ref
johnzhou721 Mar 14, 2026
b0bd670
Update idle-callbacks.js
johnzhou721 Mar 14, 2026
3414db4
Fix properties of the object
johnzhou721 Mar 14, 2026
50a95e5
Update idle-callbacks.js
johnzhou721 Mar 14, 2026
9be5daf
Add validation
johnzhou721 Mar 14, 2026
90f0474
Update idle-callbacks.js
johnzhou721 Mar 14, 2026
13f58fd
stupid es3 compat
johnzhou721 Mar 14, 2026
d02b60d
test invalid args
johnzhou721 Mar 14, 2026
27d99f1
Update web.request-idle-callback.js
johnzhou721 Mar 14, 2026
b2d700e
Update web.request-idle-callback.js
johnzhou721 Mar 14, 2026
a5a8c1e
Coerce instead of validate
johnzhou721 Mar 14, 2026
6fbb293
Update tests
johnzhou721 Mar 14, 2026
4b3c528
Update web.request-idle-callback.js
johnzhou721 Mar 14, 2026
1060992
Update idle-callbacks.js
johnzhou721 Mar 14, 2026
ae06608
return if nan
johnzhou721 Mar 14, 2026
e92849f
Lint
johnzhou721 Mar 14, 2026
7b1295c
Work around firefox bug
johnzhou721 Mar 14, 2026
b5b2e79
Update compat data
johnzhou721 Mar 14, 2026
6ae903a
Document idle deadline
johnzhou721 Mar 14, 2026
5854a9e
Fix lint; tweak impl for ff
johnzhou721 Mar 14, 2026
c22c0f9
Fix lint
johnzhou721 Mar 14, 2026
1b79af7
beef up tests, change impl
johnzhou721 Mar 14, 2026
b102cb8
fix
johnzhou721 Mar 14, 2026
8fda7ad
Update web.request-idle-callback.js
johnzhou721 Mar 14, 2026
aa6a412
fix lint
johnzhou721 Mar 14, 2026
742e069
Refactor: Use unsigned long parsing for IDL, move toNumber abstract
johnzhou721 Mar 15, 2026
79ee4a2
Use ES3
johnzhou721 Mar 15, 2026
53e0457
Lint
johnzhou721 Mar 15, 2026
75b73c8
Update web.request-idle-callback.js
johnzhou721 Mar 16, 2026
2a22bd8
Update web.request-idle-callback.js
johnzhou721 Mar 16, 2026
f7615ec
Update to-unsigned-long.js
johnzhou721 Mar 16, 2026
369b5d9
Update idle-callbacks.js
johnzhou721 Mar 16, 2026
8329144
typo
johnzhou721 Mar 16, 2026
0fc485a
Update queue.js
johnzhou721 Mar 16, 2026
6a9fc63
cache cT
johnzhou721 Mar 16, 2026
76abf09
delete timeout handle on timeout
johnzhou721 Mar 16, 2026
9d50da0
ES3
johnzhou721 Mar 16, 2026
c98ef09
Remove the use of token
johnzhou721 Mar 16, 2026
546b628
fix caching of performance.now
johnzhou721 Mar 16, 2026
b785a90
Fix modulo behavior
johnzhou721 Mar 16, 2026
9b4e461
Update idle-callbacks.js
johnzhou721 Mar 16, 2026
f590ee1
Remove sharedStore
johnzhou721 Mar 16, 2026
4bba93e
Update idle-callbacks.js
johnzhou721 Mar 16, 2026
1e66c1a
Update idle-callbacks.js
johnzhou721 Mar 16, 2026
ddec6fa
Update web.request-idle-callback.js
johnzhou721 Mar 16, 2026
a05c407
Update idle-callback.md
johnzhou721 Mar 16, 2026
ad53f17
Update idle-callbacks.js
johnzhou721 Mar 16, 2026
13cfc6f
Update idle-callbacks.js
johnzhou721 Mar 16, 2026
ab94c0d
Update idle-callbacks.js
johnzhou721 Mar 16, 2026
e4f5333
Fix eslint
johnzhou721 Mar 16, 2026
aaf6740
Attempt at combining
johnzhou721 Mar 16, 2026
037e6f5
Merge branch 'master' into requestidlecallback
johnzhou721 Mar 16, 2026
8b65c40
Fix compat testin
johnzhou721 Mar 16, 2026
e1fcc1a
no trail
johnzhou721 Mar 16, 2026
88d6e4a
Update tests.js
johnzhou721 Mar 16, 2026
fbf848b
Update idle-callback.md
johnzhou721 Mar 16, 2026
3abf9d6
rAF optimization
johnzhou721 Mar 16, 2026
28f7a79
Merge branch 'master' into requestidlecallback
johnzhou721 Mar 17, 2026
37855ec
Apply @zloirock's suggestion for single quoting
johnzhou721 Mar 17, 2026
24b5631
Update modules-by-versions.mjs
johnzhou721 Mar 18, 2026
03b8233
Update package.json
johnzhou721 Mar 19, 2026
6b4a16b
Delete tests/eslint/fix-runner.mjs
johnzhou721 Mar 19, 2026
6cd8aeb
Merge branch 'master' into requestidlecallback
johnzhou721 Mar 19, 2026
f4102ed
Merge branch 'master' into requestidlecallback
johnzhou721 Mar 25, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Changelog
### Unreleased
- Added polyfill for `requestIdleCallback`
- Improved the way of inner iterators cleaning in iterator helpers
- Slight performance improvement for engines with native `Array#fill` on `ArrayBuffer` constructor and `%TypedArray%#fill`
- Compat data improvements:
Expand Down
42 changes: 42 additions & 0 deletions docs/web/docs/features/web-standards/idle-callback.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# Idle Callback
[Specification](https://w3c.github.io/requestidlecallback/)\
[MDN](https://developer.mozilla.org/en-US/docs/Web/API/Window/requestIdleCallback)

Note that `requestIdleCallback` cannot really be polyfilled as we don't know when an idle period happens. However, the polyfill contained in core-js uses `requestAnimationFrame` to ensure that operations contained in `requestIdleCallback` will not significantly throttle the rendering of graphics.

## Modules
[`web.request-idle-callback`](https://github.com/zloirock/core-js/blob/master/packages/core-js/modules/web.request-idle-callback.js)

## Built-ins signatures
```ts
function requestIdleCallback(
callback: (deadline: IdleDeadline) => void,
options?: { timeout: number }
): number;
function cancelIdleCallback(handle: number): void;
interface IdleDeadline {
timeRemaining(): number;
readonly didTimeout: boolean;
}
```

## [Entry points]({docs-version}/docs/usage#h-entry-points)
```plaintext
core-js(-pure)/stable|actual|full|web/request-idle-callback
core-js(-pure)/stable|actual|full|web/cancel-idle-callback
core-js(-pure)/stable|actual|full|web/idle-deadline
```

- Some browsers (like Safari's Technical Preview) has only some components `requestIdleCallback`, `cancelIdleCallback`, and `IdleDeadline` exposed. In this case, importing any of those functions will use polyfilled versions.
- Polyfilled versions are not compatible with browser native versions in terms of request / cancel. Therefore it is strongly recommended to import all of the above-mentioned entry points together.
- Multiple polyfilled instances also do not have handles compatible with each other.

## Examples
```js
requestIdleCallback(
deadline => {
console.log('Did timeout:', deadline.didTimeout, '| Time remaining (ms):', deadline.timeRemaining());
},
{ timeout: 2000 } // forces callback with timeout after 2 seconds max
);
```
4 changes: 4 additions & 0 deletions docs/web/docs/menu.json
Original file line number Diff line number Diff line change
Expand Up @@ -413,6 +413,10 @@
{
"title": "Iterable DOM collections",
"url": "{docs-version}/docs/features/web-standards/iterable-dom-collections"
},
{
"title": "Idle Callback",
"url": "{docs-version}/docs/features/web-standards/idle-callback"
}
]
},
Expand Down
4 changes: 4 additions & 0 deletions packages/core-js-compat/src/data.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -3210,6 +3210,10 @@ export const data = {
node: '19.8',
safari: '17.0',
},
'web.request-idle-callback': {
chrome: '47',
// firefox: '55', -- incorrect type for timeout
},
};

export const renamed = new Map([
Expand Down
3 changes: 3 additions & 0 deletions packages/core-js-compat/src/modules-by-versions.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -323,4 +323,7 @@ export default {
'es.weak-map.get-or-insert',
'es.weak-map.get-or-insert-computed',
],
'3.50': [
'web.request-idle-callback',
],
};
4 changes: 4 additions & 0 deletions packages/core-js/actual/cancel-idle-callback.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
'use strict';
var parent = require('../stable/cancel-idle-callback');

module.exports = parent;
4 changes: 4 additions & 0 deletions packages/core-js/actual/idle-deadline.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
'use strict';
var parent = require('../stable/idle-deadline');

module.exports = parent;
4 changes: 4 additions & 0 deletions packages/core-js/actual/request-idle-callback.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
'use strict';
var parent = require('../stable/request-idle-callback');

module.exports = parent;
4 changes: 4 additions & 0 deletions packages/core-js/full/cancel-idle-callback.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
'use strict';
var parent = require('../actual/cancel-idle-callback');

module.exports = parent;
4 changes: 4 additions & 0 deletions packages/core-js/full/idle-deadline.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
'use strict';
var parent = require('../actual/idle-deadline');

module.exports = parent;
4 changes: 4 additions & 0 deletions packages/core-js/full/request-idle-callback.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
'use strict';
var parent = require('../actual/request-idle-callback');

module.exports = parent;
6 changes: 6 additions & 0 deletions packages/core-js/internals/idle-callback-detection.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
'use strict';
var globalThis = require('../internals/global-this');
var Firefox = require('../internals/environment-ff-version');

exports.BASIC = globalThis.requestIdleCallback && globalThis.cancelIdleCallback && globalThis.IdleDeadline;
exports.BOUNDS = !Firefox;
42 changes: 40 additions & 2 deletions packages/core-js/internals/queue.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,57 @@ var Queue = function () {

Queue.prototype = {
add: function (item) {
var entry = { item: item, next: null };
var entry = { item: item, next: null, prev: this.tail, queue: this };
var tail = this.tail;
if (tail) tail.next = entry;
else this.head = entry;
this.tail = entry;
return entry;
},
addEntry: function (entry) {
var queue = entry.queue;
if (queue) queue.erase(entry);

entry.prev = this.tail;
entry.next = null;
entry.queue = this;

var tail = this.tail;
if (tail) tail.next = entry;
else this.head = entry;
this.tail = entry;
return entry;
},
get: function () {
var entry = this.getEntry();
if (entry) return entry.item;
},
getEntry: function () {
var entry = this.head;
if (entry) {
var next = this.head = entry.next;
if (next === null) this.tail = null;
return entry.item;
else next.prev = null;
entry.prev = null;
entry.next = null;
entry.queue = null;
return entry;
}
},
erase: function (entry) {
if (entry.queue !== this) return;
var prev = entry.prev;
var next = entry.next;
if (prev) prev.next = next;
else this.head = next;
if (next) next.prev = prev;
else this.tail = prev;
entry.prev = null;
entry.next = null;
entry.queue = null;
},
empty: function () {
return !this.head;
}
};

Expand Down
51 changes: 51 additions & 0 deletions packages/core-js/internals/to-number.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
'use strict';
var globalThis = require('./global-this');
var uncurryThis = require('./function-uncurry-this');
var isSymbol = require('./is-symbol');
var toPrimitive = require('./to-primitive');
var trim = require('./string-trim').trim;

var TypeError = globalThis.TypeError;
var stringSlice = uncurryThis(''.slice);
var charCodeAt = uncurryThis(''.charCodeAt);

// `ToNumber` abstract operation
// https://tc39.es/ecma262/#sec-tonumber
module.exports = function (argument) {
var it = toPrimitive(argument, 'number');
var first, third, radix, maxCode, digits, length, index, code;
if (isSymbol(it)) throw new TypeError('Cannot convert a Symbol value to a number');
if (typeof it == 'string' && it.length > 2) {
it = trim(it);
first = charCodeAt(it, 0);
if (first === 43 || first === 45) {
third = charCodeAt(it, 2);
if (third === 88 || third === 120) return NaN; // Number('+0x1') should be NaN, old V8 fix
} else if (first === 48) {
switch (charCodeAt(it, 1)) {
// fast equal of /^0b[01]+$/i
case 66:
case 98:
radix = 2;
maxCode = 49;
break;
// fast equal of /^0o[0-7]+$/i
case 79:
case 111:
radix = 8;
maxCode = 55;
break;
default:
return +it;
}
digits = stringSlice(it, 2);
length = digits.length;
for (index = 0; index < length; index++) {
code = charCodeAt(digits, index);
// parseInt parses a string to a first unavailable symbol
// but ToNumber should return NaN if a string contains unavailable symbols
if (code < 48 || code > maxCode) return NaN;
} return parseInt(digits, radix);
}
} return +it;
};
20 changes: 20 additions & 0 deletions packages/core-js/internals/to-unsigned-long.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
'use strict';
var toNumber = require('./to-number');

var $isNaN = isNaN;
var abs = Math.abs;
var floor = Math.floor;
var MOD = 0x100000000;

// WebIDL Unsigned Long
module.exports = function toUnsignedLong(value) {
value = toNumber(value);
// Normalize -0
if (value === 0) value = 0;
if ($isNaN(value) || value === Infinity || value === -Infinity) return 0;
var r = floor(abs(value));
if (value < 0) r = -r;
value = r;
value = ((value % MOD) + MOD) % MOD;
return value;
};
48 changes: 1 addition & 47 deletions packages/core-js/modules/es.number.constructor.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,22 @@ var IS_PURE = require('../internals/is-pure');
var DESCRIPTORS = require('../internals/descriptors');
var globalThis = require('../internals/global-this');
var path = require('../internals/path');
var uncurryThis = require('../internals/function-uncurry-this');
var isForced = require('../internals/is-forced');
var hasOwn = require('../internals/has-own-property');
var inheritIfRequired = require('../internals/inherit-if-required');
var isPrototypeOf = require('../internals/object-is-prototype-of');
var isSymbol = require('../internals/is-symbol');
var toPrimitive = require('../internals/to-primitive');
var fails = require('../internals/fails');
var getOwnPropertyNames = require('../internals/object-get-own-property-names').f;
var getOwnPropertyDescriptor = require('../internals/object-get-own-property-descriptor').f;
var defineProperty = require('../internals/object-define-property').f;
var thisNumberValue = require('../internals/this-number-value');
var trim = require('../internals/string-trim').trim;
var toNumber = require('../internals/to-number');

var NUMBER = 'Number';
var NativeNumber = globalThis[NUMBER];
var PureNumberNamespace = path[NUMBER];
var NumberPrototype = NativeNumber.prototype;
var TypeError = globalThis.TypeError;
var stringSlice = uncurryThis(''.slice);
var charCodeAt = uncurryThis(''.charCodeAt);

// `ToNumeric` abstract operation
// https://tc39.es/ecma262/#sec-tonumeric
Expand All @@ -33,47 +28,6 @@ var toNumeric = function (value) {
return typeof primValue == 'bigint' ? primValue : toNumber(primValue);
};

// `ToNumber` abstract operation
// https://tc39.es/ecma262/#sec-tonumber
var toNumber = function (argument) {
var it = toPrimitive(argument, 'number');
var first, third, radix, maxCode, digits, length, index, code;
if (isSymbol(it)) throw new TypeError('Cannot convert a Symbol value to a number');
if (typeof it == 'string' && it.length > 2) {
it = trim(it);
first = charCodeAt(it, 0);
if (first === 43 || first === 45) {
third = charCodeAt(it, 2);
if (third === 88 || third === 120) return NaN; // Number('+0x1') should be NaN, old V8 fix
} else if (first === 48) {
switch (charCodeAt(it, 1)) {
// fast equal of /^0b[01]+$/i
case 66:
case 98:
radix = 2;
maxCode = 49;
break;
// fast equal of /^0o[0-7]+$/i
case 79:
case 111:
radix = 8;
maxCode = 55;
break;
default:
return +it;
}
digits = stringSlice(it, 2);
length = digits.length;
for (index = 0; index < length; index++) {
code = charCodeAt(digits, index);
// parseInt parses a string to a first unavailable symbol
// but ToNumber should return NaN if a string contains unavailable symbols
if (code < 48 || code > maxCode) return NaN;
} return parseInt(digits, radix);
}
} return +it;
};

var FORCED = isForced(NUMBER, !NativeNumber(' 0o1') || !NativeNumber('0b1') || NativeNumber('+0x1'));

var calledWithNew = function (dummy) {
Expand Down
Loading