Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(345)

Unified Diff: third_party/WebKit/Source/core/streams/ReadableStream.js

Issue 2432863004: Fix ReadableStream getReader({mode: 'byob'}) (Closed)
Patch Set: Unconditionally throw if mode is 'byob' Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/streams/chromium/get-reader-byob.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/streams/ReadableStream.js
diff --git a/third_party/WebKit/Source/core/streams/ReadableStream.js b/third_party/WebKit/Source/core/streams/ReadableStream.js
index efac76a889537de85632d6713cd1642caaf30c68..a03e652fd95fc65b51f5f235b9c7ceaf387cf680 100644
--- a/third_party/WebKit/Source/core/streams/ReadableStream.js
+++ b/third_party/WebKit/Source/core/streams/ReadableStream.js
@@ -172,11 +172,13 @@
}
if (mode === 'byob') {
- if (IsReadableByteStreamDefaultController(this[readableStreamController]) === false) {
- throw new TypeError(errGetReaderNotByteStream);
- }
-
- return AcquireReadableStreamBYOBReader(this);
+ // TODO(ricea): When BYOB readers are supported:
+ //
+ // a. If
+ // ! IsReadableByteStreamController(this.[[readableStreamController]])
+ // is false, throw a TypeError exception.
+ // b. Return ? AcquireReadableStreamBYOBReader(this).
+ throw new TypeError(errGetReaderNotByteStream);
}
if (mode === undefined) {
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/streams/chromium/get-reader-byob.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698