mirror of
https://github.com/nodejs/node.git
synced 2026-11-26 21:58:26 -05:00
readline: make Symbol.asyncIterator support stable
PR-URL: https://github.com/nodejs/node/pull/26989 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Masashi Hirano <shisama07@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
This commit is contained in:
1 parent
00831f0293
commit
79f3844fb0
2 files changed
+7
-5
No files matched your search
+6
-2
@@ -311,10 +311,14 @@ The `rl.write()` method will write the data to the `readline` `Interface`'s
|
||||
|
||||
### rl\[Symbol.asyncIterator\]()
|
||||
<!-- YAML
|
||||
added: v10.16.0
|
||||
added: v11.4.0
|
||||
changes:
|
||||
- version: REPLACEME
|
||||
pr-url: https://github.com/nodejs/node/pull/26989
|
||||
description: Symbol.asyncIterator support is no longer experimental.
|
||||
-->
|
||||
|
||||
> Stability: 1 - Experimental
|
||||
> Stability: 2 - Stable
|
||||
|
||||
* Returns: {AsyncIterator}
|
||||
|
||||
|
||||
+1
-3
@@ -32,8 +32,8 @@ const {
|
||||
ERR_INVALID_CURSOR_POS,
|
||||
ERR_INVALID_OPT_VALUE
|
||||
} = require('internal/errors').codes;
|
||||
|
||||
const { debug, inherits } = require('util');
|
||||
const { emitExperimentalWarning } = require('internal/util');
|
||||
const { Buffer } = require('buffer');
|
||||
const EventEmitter = require('events');
|
||||
const {
|
||||
@@ -1005,8 +1005,6 @@ Interface.prototype._ttyWrite = function(s, key) {
|
||||
};
|
||||
|
||||
Interface.prototype[Symbol.asyncIterator] = function() {
|
||||
emitExperimentalWarning('readline Interface [Symbol.asyncIterator]');
|
||||
|
||||
if (this[kLineObjectStream] === undefined) {
|
||||
if (Readable === undefined) {
|
||||
Readable = require('stream').Readable;
|
||||
|
||||
Reference in new issue
Block a user