@@ -4445,6 +4445,10 @@ the following table:
4445
4445
<td> <dfn>\[[abortAlgorithm]]</dfn>
4446
4446
<td class="non-normative"> A promise-returning algorithm, taking one argument (the abort reason),
4447
4447
which communicates a requested abort to the [=underlying sink=]
4448
+ <tr>
4449
+ <td> <dfn>\[[abortController]]</dfn>
4450
+ <td class="non-normative"> An {{AbortController}} that can be used to abort the pending write or
4451
+ close operation when the stream is [=abort a writable stream|aborted=] .
4448
4452
<tr>
4449
4453
<td> <dfn>\[[closeAlgorithm]]</dfn>
4450
4454
<td class="non-normative"> A promise-returning algorithm which communicates a requested close to
@@ -4456,10 +4460,6 @@ the following table:
4456
4460
<td> <dfn>\[[queueTotalSize]]</dfn>
4457
4461
<td class="non-normative"> The total size of all the chunks stored in
4458
4462
[=WritableStreamDefaultController/[[queue]]=] (see [[#queue-with-sizes]] )
4459
- <tr>
4460
- <td> <dfn>\[[signal]]</dfn>
4461
- <td class="non-normative"> An {{AbortSignal}} that can be used to abort the pending write or
4462
- close operation when the stream is [=abort a writable stream|aborted=] .
4463
4463
<tr>
4464
4464
<td> <dfn>\[[started]]</dfn>
4465
4465
<td class="non-normative"> A boolean flag indicating whether the [=underlying sink=] has finished
@@ -4508,7 +4508,8 @@ closed. It is only used internally, and is never exposed to web developers.
4508
4508
The <dfn id="ws-default-controller-signal" attribute
4509
4509
for="WritableStreamDefaultController"> signal</dfn> getter steps are:
4510
4510
4511
- 1. Return [=this=] .[=WritableStreamDefaultController/[[signal]]=] .
4511
+ 1. Return [=this=] .[=WritableStreamDefaultController/[[abortController]]=] 's
4512
+ [=AbortController/signal=] .
4512
4513
</div>
4513
4514
4514
4515
<div algorithm>
@@ -4654,13 +4655,13 @@ The following abstract operations operate on {{WritableStream}} instances at a h
4654
4655
4655
4656
1. If |stream|.[=WritableStream/[[state]]=] is "`closed`" or "`errored`", return
4656
4657
[=a promise resolved with=] undefined.
4657
- 1. [=Signal abort=] on
4658
- |stream|.[=WritableStream/[[controller]]=] .[=WritableStreamDefaultController/[[signal ]]=] with
4659
- |reason|.
4658
+ 1. [=AbortController/ Signal abort=] on
4659
+ |stream|.[=WritableStream/[[controller]]=] .[=WritableStreamDefaultController/[[abortController ]]=]
4660
+ with |reason|.
4660
4661
1. Let |state| be |stream|.[=WritableStream/[[state]]=] .
4661
4662
1. If |state| is "`closed`" or "`errored`", return [=a promise resolved with=] undefined.
4662
- <p class="note"> We re-check the state because [=signaling abort=] runs author code and that might
4663
- have changed the state.
4663
+ <p class="note"> We re-check the state because [=AbortController/ signaling abort=] runs author
4664
+ code and that might have changed the state.
4664
4665
1. If |stream|.[=WritableStream/[[pendingAbortRequest]]=] is not undefined, return
4665
4666
|stream|.[=WritableStream/[[pendingAbortRequest]]=] 's [=pending abort request/promise=] .
4666
4667
1. Assert: |state| is "`writable`" or "`erroring`".
@@ -5084,7 +5085,8 @@ The following abstract operations support the implementation of the
5084
5085
1. Set |controller|.[=WritableStreamDefaultController/[[stream]]=] to |stream|.
5085
5086
1. Set |stream|.[=WritableStream/[[controller]]=] to |controller|.
5086
5087
1. Perform ! [$ResetQueue$] (|controller|).
5087
- 1. Set |controller|.[=WritableStreamDefaultController/[[signal]]=] to a new {{AbortSignal}} .
5088
+ 1. Set |controller|.[=WritableStreamDefaultController/[[abortController]]=] to a new
5089
+ {{AbortController}} .
5088
5090
1. Set |controller|.[=WritableStreamDefaultController/[[started]]=] to false.
5089
5091
1. Set |controller|.[=WritableStreamDefaultController/[[strategySizeAlgorithm]]=] to
5090
5092
|sizeAlgorithm|.
@@ -6996,11 +6998,10 @@ above [=WritableStream/set up=] algorithm:
6996
6998
[$WritableStreamDefaultControllerErrorIfNeeded$] (|stream|.[=WritableStream/[[controller]]=] , |e|).
6997
6999
6998
7000
<p> The <dfn export for="WritableStream">signal</dfn> of a {{WritableStream}} |stream| is
6999
- |stream|.[=WritableStream/[[controller]]=] .[=WritableStreamDefaultController/[[signal]]=] .
7000
- Specifications can [=AbortSignal/add=] or [=AbortSignal/remove=] algorithms to this
7001
- {{AbortSignal}} , or consult whether it is [=AbortSignal/aborted=] and its [=AbortSignal/abort
7002
- reason=] . Specifications must not [=AbortSignal/signal abort=] , as that would interfere with the
7003
- normal use of this signal to respond to the stream being [=abort a writable stream|aborted=] .
7001
+ |stream|.[=WritableStream/[[controller]]=] .[=WritableStreamDefaultController/[[abortController]]=] 's
7002
+ [=AbortController/signal=] . Specifications can [=AbortSignal/add=] or [=AbortSignal/remove=]
7003
+ algorithms to this {{AbortSignal}} , or consult whether it is [=AbortSignal/aborted=] and its
7004
+ [=AbortSignal/abort reason=] .
7004
7005
7005
7006
<p class="note"> The usual usage is, after [=WritableStream/setting up=] the {{WritableStream}} ,
7006
7007
[=AbortSignal/add=] an algorithm to its [=WritableStream/signal=] , which aborts any ongoing write
0 commit comments