Re: [whatwg/streams] TransformStream cleanup using "Transformer.cancel" (PR #1283)

@domenic commented on this pull request.



> @@ -7106,9 +7175,11 @@ reason.
 <div algorithm="create a TransformStream">
  To <dfn export for="TransformStream" lt="set up|setting up">set up</dfn> a
  newly-[=new|created-via-Web IDL=] {{TransformStream}} |stream| given an algorithm <dfn export
- for="TransformStream/set up"><var>transformAlgorithm</var></dfn> and an optional algorithm <dfn
- export for="TransformStream/set up"><var>flushAlgorithm</var></dfn>, perform the following steps.
- |transformAlgorithm| and, if given, |flushAlgorithm|, may return a promise.
+ for="TransformStream/set up"><var>transformAlgorithm</var></dfn>, an optional algorithm <dfn
+ export for="TransformStream/set up"><var>flushAlgorithm</var></dfn>, and an optional algorithm <dfn
+ export for="TransformStream/set up"><var>cancelAlgorithm</var></dfn>, perform the following steps.
+ |transformAlgorithm|, if given, |flushAlgorithm|, and, if given, |cancelAlgorithm|, may return a

I think @saschanaz's phrasing is correct English and implies `Option<FlushAlgorithm>` and `Option<CancelAlgorithm>`. Consider:

> Dogs, and if present, cats and birds, may bite you in the park.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/streams/pull/1283#discussion_r1227403653
You are receiving this because you are subscribed to this thread.

Message ID: <whatwg/streams/pull/1283/review/1476059506@github.com>

Received on Tuesday, 13 June 2023 01:18:30 UTC