Skip to content

Commit cb9c2a1

Browse files
committed
Use _isOwning private slot
1 parent ecc2615 commit cb9c2a1

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

reference-implementation/lib/abstract-ops/queue-with-sizes.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ exports.EnqueueValueWithSize = (container, value, size, transferList) => {
2424
if (size === Infinity) {
2525
throw new RangeError('Size must be a finite, non-NaN, non-negative number.');
2626
}
27-
if (container.isOwning) {
27+
if (container._isOwning) {
2828
value = StructuredTransferOrClone(value, transferList);
2929
}
3030
container._queue.push({ value, size });
@@ -42,7 +42,7 @@ exports.PeekQueueValue = container => {
4242
exports.ResetQueue = container => {
4343
assert('_queue' in container && '_queueTotalSize' in container);
4444

45-
if (container.isOwning) {
45+
if (container._isOwning) {
4646
while (container._queue.length > 0) {
4747
const value = exports.DequeueValue(container);
4848
if (typeof value.close === 'function') {

reference-implementation/lib/abstract-ops/readable-streams.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@ function ReadableStreamTee(stream, cloneForBranch2) {
340340
if (ReadableByteStreamController.isImpl(stream._controller)) {
341341
return ReadableByteStreamTee(stream);
342342
}
343-
return ReadableStreamDefaultTee(stream, stream._controller.isOwning ? true : cloneForBranch2);
343+
return ReadableStreamDefaultTee(stream, stream._controller._isOwning ? true : cloneForBranch2);
344344
}
345345

346346
function ReadableStreamDefaultTee(stream, cloneForBranch2) {
@@ -1082,7 +1082,7 @@ function ReadableStreamDefaultControllerEnqueue(controller, chunk, transferList)
10821082
const stream = controller._stream;
10831083

10841084
if (IsReadableStreamLocked(stream) === true && ReadableStreamGetNumReadRequests(stream) > 0) {
1085-
if (controller.isOwning) {
1085+
if (controller._isOwning) {
10861086
try {
10871087
chunk = StructuredTransferOrClone(chunk, transferList);
10881088
} catch (chunkCloneError) {
@@ -1177,7 +1177,7 @@ function SetUpReadableStreamDefaultController(
11771177
controller._pullAlgorithm = pullAlgorithm;
11781178
controller._cancelAlgorithm = cancelAlgorithm;
11791179

1180-
controller.isOwning = isOwning;
1180+
controller._isOwning = isOwning;
11811181

11821182
stream._controller = controller;
11831183

0 commit comments

Comments
 (0)