Skip to content

Commit

Permalink
Editorial: remove "rethrow" per Infra
Browse files Browse the repository at this point in the history
  • Loading branch information
annevk committed Sep 6, 2017
1 parent bc23529 commit 829e56d
Showing 1 changed file with 35 additions and 46 deletions.
81 changes: 35 additions & 46 deletions fetch.bs
Original file line number Diff line number Diff line change
Expand Up @@ -623,8 +623,7 @@ user-agent-defined <a for=header>value</a> for the

<ol>
<li><p>Let «<var>out1</var>, <var>out2</var>» be the result of
<a lt=tee for=ReadableStream>teeing</a> <var>body</var>'s
<a for=body>stream</a>. Rethrow any exceptions.
<a lt=tee for=ReadableStream>teeing</a> <var>body</var>'s <a for=body>stream</a>.

<li><p>Set <var>body</var>'s <a for=body>stream</a> to <var>out1</var>.

Expand Down Expand Up @@ -1149,10 +1148,9 @@ or "<code>worker</code>".
<li><p>Let <var>newRequest</var> be a copy of <var>request</var>, except for its
<a for=request>body</a>.

<li><p>If <var>request</var>'s <a for=request>body</a> is non-null, set
<var>newRequest</var>'s <a for=request>body</a> to the result of
<a lt=clone for=body>cloning</a> <var>request</var>'s
<a for=request>body</a>. Rethrow any exceptions.
<li><p>If <var>request</var>'s <a for=request>body</a> is non-null, set <var>newRequest</var>'s
<a for=request>body</a> to the result of <a lt=clone for=body>cloning</a> <var>request</var>'s
<a for=request>body</a>.

<li><p>Return <var>newRequest</var>.
</ol>
Expand Down Expand Up @@ -1392,18 +1390,16 @@ is a <a>filtered response</a> whose
<a for=/>response</a> <var>response</var>, run these steps:

<ol>
<li><p>If <var>response</var> is a <a>filtered response</a>,
return a new identical filtered response whose <a lt="internal response" for=internal>internal
response</a> is a <a for=response>clone</a> of <var>response</var>'s
<a for=internal>internal response</a>. Rethrow any exceptions.
<li><p>If <var>response</var> is a <a>filtered response</a>, then return a new identical filtered
response whose <a lt="internal response" for=internal>internal response</a> is a
<a for=response>clone</a> of <var>response</var>'s <a for=internal>internal response</a>.

<li><p>Let <var>newResponse</var> be a copy of <var>response</var>, except for its
<a for=response>body</a>.

<li><p>If <var>response</var>'s <a for=response>body</a> is non-null, set
<var>newResponse</var>'s <a for=response>body</a> to the result of
<a lt=clone for=body>cloning</a> <var>response</var>'s
<a for=response>body</a>. Rethrow any exceptions.
<li><p>If <var>response</var>'s <a for=response>body</a> is non-null, then set
<var>newResponse</var>'s <a for=response>body</a> to the result of <a lt=clone for=body>cloning</a>
<var>response</var>'s <a for=response>body</a>.

<li><p>Return <var>newResponse</var>.
</ol>
Expand Down Expand Up @@ -1662,7 +1658,7 @@ we define common operations for {{ReadableStream}} objects. [[!STREAMS]]
<ol>
<li><p>Call
<a abstract-op>ReadableStreamDefaultControllerEnqueue</a>(<var>stream</var>.\[[readableStreamController]],
<var>chunk</var>). Rethrow any exceptions.
<var>chunk</var>).
</ol>

<p>To <dfn abstract-op export for=ReadableStream id=concept-close-readablestream>close</dfn> a
Expand All @@ -1671,7 +1667,6 @@ we define common operations for {{ReadableStream}} objects. [[!STREAMS]]
<ol>
<li><p>Call
<a abstract-op>ReadableStreamDefaultControllerClose</a>(<var>stream</var>.\[[readableStreamController]]).
Rethrow any exceptions.
</ol>

<p>To <dfn abstract-op export for=ReadableStream id=concept-error-readablestream>error</dfn> a
Expand All @@ -1680,7 +1675,7 @@ we define common operations for {{ReadableStream}} objects. [[!STREAMS]]
<ol>
<li><p>Call
<a abstract-op>ReadableStreamDefaultControllerError</a>(<var>stream</var>.\[[readableStreamController]]).
<var>reason</var>). Rethrow any exceptions.
<var>reason</var>).
</ol>

<p>To
Expand All @@ -1698,7 +1693,7 @@ are optional, run these steps:
<var>cancel</var> is given.

<li><p>Let <var>stream</var> be the result of calling the initial value of {{ReadableStream}} as
constructor with <var>init</var> and <var>strategy</var> if given. Rethrow any exceptions.
constructor with <var>init</var> and <var>strategy</var> if given.

<li><p>Return <var>stream</var>.
</ol>
Expand All @@ -1710,12 +1705,12 @@ with given <var>chunks</var>, run these steps:
<ol>
<li><p>Let <var>stream</var> be the result of
<a lt="construct a ReadableStream object" for=ReadableStream>constructing</a> a {{ReadableStream}}
object. Rethrow any exceptions.
object.

<li><p>For each <var>chunk</var> in <var>chunks</var>, <a for=ReadableStream>enqueue</a>
<var>chunk</var> into <var>stream</var>. Rethrow any exceptions.
<var>chunk</var> into <var>stream</var>.

<li><p><a lt=close abstract-op>Close</a> <var>stream</var>. Rethrow any exceptions.
<li><p><a lt=close abstract-op>Close</a> <var>stream</var>.

<li>Return <var>stream</var>.
</ol>
Expand All @@ -1725,7 +1720,7 @@ with given <var>chunks</var>, run these steps:

<ol>
<li><p>Let <var>reader</var> be the result of calling
<a abstract-op>AcquireReadableStreamDefaultReader</a>(<var>stream</var>). Rethrow any exceptions.
<a abstract-op>AcquireReadableStreamDefaultReader</a>(<var>stream</var>).

<li><p>Return <var>reader</var>.
</ol>
Expand Down Expand Up @@ -1778,9 +1773,7 @@ to read cannot be observed. Implementations could use more direct mechanism if c
object <var>stream</var>, run these steps:

<ol>
<li><p>Return the result of calling
<a abstract-op>ReadableStreamTee</a>(<var>stream</var>, true).
Rethrow any exception.
<li><p>Return the result of calling <a abstract-op>ReadableStreamTee</a>(<var>stream</var>, true).
</ol>

<p>An <dfn export for=ReadableStream id=concept-empty-readablestream>empty</dfn> {{ReadableStream}}
Expand Down Expand Up @@ -4241,14 +4234,13 @@ run these steps:
<li><p>If <var>header</var> does not contain exactly two items, then <a>throw</a> a
<code>TypeError</code>.

<li><p><a lt=append for=Headers>Append</a>
<var>header</var>'s first item/<var>header</var>'s second item to
<var>headers</var>. Rethrow any exception.
<li><p><a lt=append for=Headers>Append</a> <var>header</var>'s first item/<var>header</var>'s
second item to <var>headers</var>.
</ol>

<li><p>Otherwise, <var>object</var> is a <a>record</a>, then <a for=map>for each</a> <var>key</var>
<var>value</var> in <var>object</var>, <a lt=append for=Headers>append</a>
<var>key</var>/<var>value</var> to <var>headers</var>. Rethrow any exception.
<var>key</var>/<var>value</var> to <var>headers</var>.
</ol>

<p>The
Expand All @@ -4259,15 +4251,15 @@ constructor, when invoked, must run these steps:
<li><p>Let <var>headers</var> be a new {{Headers}} object whose
<a for=Headers>guard</a> is "<code>none</code>".

<li><p>If <var>init</var> is given, <a for=Headers>fill</a>
<var>headers</var> with <var>init</var>. Rethrow any exception.
<li><p>If <var>init</var> is given, <a for=Headers>fill</a> <var>headers</var> with
<var>init</var>.

<li><p>Return <var>headers</var>.
</ol>

<p>The <dfn export for=Headers method><code>append(<var>name</var>, <var>value</var>)</code></dfn>
method, when invoked, must <a for=Headers>append</a> <var>name</var>/<var>value</var> to
<a>context object</a> and rethrow any exception.
<a>context object</a>.

<p>The <dfn export for=Headers method><code>delete(<var>name</var>)</code></dfn>
method, when invoked, must run these steps:
Expand Down Expand Up @@ -4509,8 +4501,10 @@ runs the associated steps:

<dl class=switch>
<dt><i>ArrayBuffer</i>
<dd><p>Return an <code>ArrayBuffer</code> whose contents are <var>bytes</var>. Rethrow any
exceptions.
<dd>
<p>Return a new <code>ArrayBuffer</code> whose contents are <var>bytes</var>.

<p class="note">Allocating an <code>ArrayBuffer</code> can throw a {{RangeError}}.

<dt><i>Blob</i>
<dd><p>Return a {{Blob}} whose contents are <var>bytes</var> and {{Blob/type}} attribute is
Expand Down Expand Up @@ -4572,10 +4566,9 @@ runs the associated steps:
<p>Otherwise, <a>throw</a> a <code>TypeError</code>.

<dt><i>JSON</i>
<dd>
<p>Return the result of invoking the initial value of the <code>parse</code> property of the
<code>JSON</code> object with the result of running <a>UTF-8 decode</a> on <var>bytes</var> as
argument. Rethrow any exceptions.
<dd><p>Return the result of invoking the initial value of the <code>parse</code> property of the
<code>JSON</code> object with the result of running <a>UTF-8 decode</a> on <var>bytes</var> as
argument.

<dt><i>text</i>
<dd><p>Return the result of running <a>UTF-8 decode</a> on
Expand Down Expand Up @@ -4968,19 +4961,16 @@ constructor must run these steps:
<li><p>Let <var>Content-Type</var> be null.

<li><p>If <var>init</var>'s <code>keepalive</code> member is present and is true, then set
<var>body</var> and <var>Content-Type</var> to the result of
<a lt=extract>extracting</a> <var>init</var>'s <code>body</code>
member, with <var>keepalive flag</var> set. Rethrow any exceptions.
<var>body</var> and <var>Content-Type</var> to the result of <a lt=extract>extracting</a>
<var>init</var>'s <code>body</code> member, with <var>keepalive flag</var> set.

<li><p>Otherwise, set <var>body</var> and <var>Content-Type</var> to the result of
<a lt=extract for=BodyInit>extracting</a> <var>init</var>'s
<code>body</code> member. Rethrow any exceptions.
<a lt=extract for=BodyInit>extracting</a> <var>init</var>'s <code>body</code> member.

<li><p>If <var>Content-Type</var> is non-null and <var>r</var>'s <a for=Request>headers</a>'s
<a for=Headers>header list</a> <a for="header list">does not contain</a>
`<code>Content-Type</code>`, then <a for=Headers>append</a>
`<code>Content-Type</code>`/<var>Content-Type</var> to <var>r</var>'s <a for=Request>headers</a>.
Rethrow any exception.
</ol>

<li>
Expand Down Expand Up @@ -5176,7 +5166,6 @@ constructor, when invoked, must run these steps:

<li><p>If <var>init</var>'s <code>headers</code> member is present, then <a for=Headers>fill</a>
<var>r</var>'s <a for=Response>headers</a> with <var>init</var>'s <code>headers</code> member.
Rethrow any exceptions.

<li>
<p>If <var>body</var> is non-null, run these substeps:
Expand All @@ -5193,7 +5182,7 @@ constructor, when invoked, must run these steps:

<li><p>Set <var>r</var>'s <a for=Response>response</a>'s
<a for=response>body</a> and <var>Content-Type</var> to the result of
<a lt=extract for=BodyInit>extracting</a> <var>body</var>. Rethrow any exceptions.
<a lt=extract for=BodyInit>extracting</a> <var>body</var>.

<li><p>If <var>Content-Type</var> is non-null and <var>r</var>'s <a for=Response>response</a>'s
<a for=response>header list</a> <a for="header list">does not contain</a>
Expand Down

0 comments on commit 829e56d

Please sign in to comment.