Skip to content

Commit 4334834

Browse files
authored
Rename HostGetSupportedAssertions to HostGetSupportedImportAssertions (#105)
When the name HostGetSupportedAssertions is seen out of context, it is pretty vague. A reader might initially assume that this refers to some other type of assertions. Therefore rename to HostGetSupportedImportAssertions so that there is a clearer association with this feature.
1 parent 61c13d4 commit 4334834

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

spec.html

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ <h1>Runtime Semantics: Evaluation</h1>
9090
1. <ins>Let _arg_ be ? GetValue(_argRef_).</ins>
9191
1. <ins>If _arg_ is *undefined*, let _assertions_ be an empty List.</ins>
9292
1. <ins>Otherwise,</ins>
93-
1. <ins>Let _supportedAssertions_ ! HostGetSupportedAssertions().</ins>
93+
1. <ins>Let _supportedAssertions_ ! HostGetSupportedImportAssertions().</ins>
9494
1. <ins>Let _assertionsObj_ be ? Get(_arg_, *"assert"*).</ins>
9595
1. <ins>Let _assertions_ be a new empty List.</ins>
9696
1. <ins>Let _keys_ be EnumerableOwnPropertyNames(_assertionsObj_, ~key~).</ins>
@@ -216,26 +216,26 @@ <h1>Runtime Semantics: FinishDynamicImport ( _referencingScriptOrModule_, <del>_
216216
</emu-alg>
217217
</emu-clause>
218218

219-
<emu-clause id="sec-hostgetsupportedassertions" aoid="HostGetSupportedAssertions">
220-
<h1>Static Semantics: HostGetSupportedAssertions ()</h1>
219+
<emu-clause id="sec-hostgetsupportedimportassertions" aoid="HostGetSupportedImportAssertions">
220+
<h1>Static Semantics: HostGetSupportedImportAssertions ()</h1>
221221
<p>
222-
HostGetSupportedAssertions is a host-defined abstract operation that allows host environments to specify which import assertions they support.
222+
HostGetSupportedImportAssertions is a host-defined abstract operation that allows host environments to specify which import assertions they support.
223223
Only assertions with supported keys will be provided to the host.
224224
</p>
225225

226-
<p>The implementation of HostGetSupportedAssertions must conform to the following requrements:</p>
226+
<p>The implementation of HostGetSupportedImportAssertions must conform to the following requrements:</p>
227227

228228
<ul>
229229
<li>It must return a List whose values are all StringValues, each indicating a supported assertion.</li>
230230

231231
<li>Each time this operation is called, it must return the same List instance with the same contents.</li>
232232

233-
<li>An implementation of HostGetSupportedAssertions must always complete normally (i.e., not return an abrupt completion).</li>
233+
<li>An implementation of HostGetSupportedImportAssertions must always complete normally (i.e., not return an abrupt completion).</li>
234234
</ul>
235235

236-
<p>The default implementation of HostGetSupportedAssertions is to return an empty List.</p>
236+
<p>The default implementation of HostGetSupportedImportAssertions is to return an empty List.</p>
237237

238-
<emu-note type=editor>The purpose of requiring the host to specify its supported assertions, rather than passing all assertions to the host and letting it then choose which ones it wants to handle, is to ensure that unsupported assertions are handled in a consistent way across different hosts.</emu-note>
238+
<emu-note type=editor>The purpose of requiring the host to specify its supported import assertions, rather than passing all assertions to the host and letting it then choose which ones it wants to handle, is to ensure that unsupported assertions are handled in a consistent way across different hosts.</emu-note>
239239
</emu-clause>
240240

241241
<emu-clause id="sec-assert-clause-early-errors">
@@ -262,7 +262,7 @@ <h1>Static Semantics: AssertClauseToAssertions</h1>
262262

263263
<emu-grammar> AssertEntries : AssertionKey `:` StringLiteral </emu-grammar>
264264
<emu-alg>
265-
1. Let _supportedAssertions_ be !HostGetSupportedAssertions().
265+
1. Let _supportedAssertions_ be !HostGetSupportedImportAssertions().
266266
1. Let _key_ be StringValue of |AssertionKey|.
267267
1. If _key_ is an entry of _supportedAssertions_,
268268
1. Let _entry_ be a Record { [[Key]]: _key_, [[Value]]: StringValue of |StringLiteral| }.
@@ -272,7 +272,7 @@ <h1>Static Semantics: AssertClauseToAssertions</h1>
272272

273273
<emu-grammar> AssertEntries : AssertionKey `:` StringLiteral `,` AssertEntries </emu-grammar>
274274
<emu-alg>
275-
1. Let _supportedAssertions_ be !HostGetSupportedAssertions().
275+
1. Let _supportedAssertions_ be !HostGetSupportedImportAssertions().
276276
1. Let _key_ be StringValue of |AssertionKey|.
277277
1. If _key_ is an entry of _supportedAssertions_,
278278
1. Let _entry_ be a Record { [[Key]]: _key_, [[Value]]: StringValue of |StringLiteral| }.

0 commit comments

Comments
 (0)