Skip to content

Commit 351495e

Browse files
committed
lib,test: handle new Iterator global
Refs: v8/v8@80fb767 PR-URL: #51362 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: Antoine du Hamel <[email protected]> Reviewed-By: Rafael Gonzaga <[email protected]>
1 parent cdc4437 commit 351495e

File tree

3 files changed

+4
-0
lines changed

3 files changed

+4
-0
lines changed

lib/.eslintrc.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,8 @@ rules:
6565
# disabled with --without-intl build flag.
6666
- name: Intl
6767
message: Use `const { Intl } = globalThis;` instead of the global.
68+
- name: Iterator
69+
message: Use `const { Iterator } = globalThis;` instead of the global.
6870
- name: MessageChannel
6971
message: Use `const { MessageChannel } = require('internal/worker/io');` instead of the global.
7072
- name: MessageEvent

test/common/globals.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ const intrinsics = new Set([
6363
'SharedArrayBuffer',
6464
'Atomics',
6565
'WebAssembly',
66+
'Iterator',
6667
]);
6768

6869
if (global.gc) {

test/parallel/test-repl-tab-complete.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -632,6 +632,7 @@ const builtins = [
632632
'Int32Array',
633633
'Int8Array',
634634
...(common.hasIntl ? ['Intl'] : []),
635+
'Iterator',
635636
'inspector',
636637
'isFinite',
637638
'isNaN',

0 commit comments

Comments
 (0)