Skip to content

Commit

Permalink
Add <ins> tags to new notes
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolo-ribaudo committed Apr 6, 2023
1 parent 78446d3 commit 2b161db
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
14 changes: 7 additions & 7 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2623,7 +2623,7 @@
</ul></div><div id="menu-toggle"><svg xmlns="http://www.w3.org/2000/svg" style="width:100%; height:100%; stroke:currentColor" viewBox="0 0 120 120">
<title>Menu</title>
<path stroke-width="10" stroke-linecap="round" d="M30,60 h60 M30,30 m0,5 h60 M30,90 m0,-5 h60"></path>
</svg></div><div id="menu-spacer" class="menu-spacer"></div><div id="menu"><div id="menu-search"><input type="text" id="menu-search-box" placeholder="Search..."><div id="menu-search-results" class="inactive"></div></div><div id="menu-pins"><div class="menu-pane-header">Pins</div><ul id="menu-pins-list"></ul></div><div class="menu-pane-header">Table of Contents</div><div id="menu-toc"><ol class="toc"><li><span class="item-toggle-none"></span><a href="#intro" title="Import Attributes">Import Attributes</a></li><li><span class="item-toggle">◢</span><a href="#sec-ecmascript-language-expressions" title="ECMAScript Language: Expressions"><span class="secnum">13</span> ECMAScript Language: Expressions</a><ol class="toc"><li><span class="item-toggle">◢</span><a href="#sec-left-hand-side-expressions" title="Left-Hand-Side Expressions"><span class="secnum">13.3</span> Left-Hand-Side Expressions</a><ol class="toc"><li><span class="item-toggle">◢</span><a href="#sec-import-calls" title="Import Calls"><span class="secnum">13.3.10</span> Import Calls</a><ol class="toc"><li><span class="item-toggle-none"></span><a href="#sec-import-call-runtime-semantics-evaluation" title="Runtime Semantics: Evaluation"><span class="secnum">13.3.10.1</span> RS: Evaluation</a></li><li><span class="item-toggle-none"></span><a href="#sec-evaluate-import-call" title="EvaluateImportCall ( specifierExpression [ , optionsExpression ] )"><span class="secnum">13.3.10.2</span> <ins>EvaluateImportCall ( <var>specifierExpression</var> [ , <var>optionsExpression</var> ] )</ins></a></li></ol></li></ol></li></ol></li><li><span class="item-toggle">◢</span><a href="#sec-ecmascript-language-scripts-and-modules" title="ECMAScript Language: Scripts and Modules"><span class="secnum">16</span> ECMAScript Language: Scripts and Modules</a><ol class="toc"><li><span class="item-toggle">◢</span><a href="#sec-modules" title="Modules"><span class="secnum">16.2</span> Modules</a><ol class="toc"><li><span class="item-toggle">◢</span><a href="#sec-module-semantics" title="Module Semantics"><span class="secnum">16.2.1</span> Module Semantics</a><ol class="toc"><li><span class="item-toggle-none"></span><a href="#sec-modulerequest-record" title="ModuleRequest and ImportAttribute Records"><span class="secnum">16.2.1.1</span> <ins>ModuleRequest and ImportAttribute Records</ins></a></li><li><span class="item-toggle-none"></span><a href="#sec-static-semantics-modulerequests" title="Static Semantics: ModuleRequests"><span class="secnum">16.2.1.3</span> SS: ModuleRequests</a></li><li><span class="item-toggle-none"></span><a href="#sec-cyclic-module-records" title="Cyclic Module Records"><span class="secnum">16.2.1.5</span> Cyclic Module Records</a></li><li><span class="item-toggle-none"></span><a href="#sec-source-text-module-records" title="Source Text Module Records"><span class="secnum">16.2.1.6</span> Source Text Module Records</a></li><li><span class="item-toggle-none"></span><a href="#sec-HostLoadImportedModule" title="HostLoadImportedModule ( referrer, specifier, moduleRequest, hostDefined, payload )"><span class="secnum">16.2.1.8</span> HostLoadImportedModule ( <var>referrer</var>, <del><var>specifier</var></del>, <ins><var>moduleRequest</var></ins>, <var>hostDefined</var>, <var>payload</var> )</a></li><li><span class="item-toggle">◢</span><a href="#sec-FinishLoadingImportedModule" title="FinishLoadingImportedModule ( referrer, specifier, moduleRequest, payload, result )"><span class="secnum">16.2.1.9</span> FinishLoadingImportedModule ( <var>referrer</var>, <del><var>specifier</var></del>, <ins><var>moduleRequest</var></ins>, <var>payload</var>, <var>result</var> )</a><ol class="toc"><li><span class="item-toggle-none"></span><a href="#sec-FinishLoadingImportedModule-AttributesEqual" title="AttributesEqual ( left, right )"><span class="secnum">16.2.1.9.1</span> <ins>AttributesEqual ( <var>left</var>, <var>right</var> )</ins></a></li></ol></li><li><span class="item-toggle">◢</span><a href="#sec-AllImportAttributesSupported" title="AllImportAttributesSupported ( attributes )"><span class="secnum">16.2.1.10</span> <ins>AllImportAttributesSupported ( <var>attributes</var> )</ins></a><ol class="toc"><li><span class="item-toggle-none"></span><a href="#sec-hostgetsupportedimportattributes" title="HostGetSupportedImportAttributes ( )"><span class="secnum">16.2.1.10.1</span> <ins>HostGetSupportedImportAttributes ( )</ins></a></li></ol></li></ol></li><li><span class="item-toggle">◢</span><a href="#sec-imports" title="Imports"><span class="secnum">16.2.2</span> Imports</a><ol class="toc"><li><span class="item-toggle-none"></span><a href="#sec-imports-static-semantics-early-errors" title="Static Semantics: Early Errors"><span class="secnum">16.2.2.1</span> SS: Early Errors</a></li><li><span class="item-toggle-none"></span><a href="#sec-import-static-semantics-attribute-name" title="Static Semantics: AttributeName"><span class="secnum">16.2.2.2</span> <ins>SS: AttributeName</ins></a></li><li><span class="item-toggle-none"></span><a href="#sec-with-clause-to-attributes" title="Static Semantics: WithClauseToAttributes"><span class="secnum">16.2.2.3</span> <ins>SS: WithClauseToAttributes</ins></a></li></ol></li><li><span class="item-toggle-none"></span><a href="#sec-exports" title="Exports"><span class="secnum">16.2.3</span> Exports</a></li></ol></li></ol></li><li><span class="item-toggle-none"></span><a href="#sec-host-integration" title="Sample host integration: The Web embedding"><span class="secnum">A</span> Sample host integration: The Web embedding</a></li></ol></div></div><div id="spec-container"><h1 class="version">Stage 2 Draft / April 4, 2023</h1>
</svg></div><div id="menu-spacer" class="menu-spacer"></div><div id="menu"><div id="menu-search"><input type="text" id="menu-search-box" placeholder="Search..."><div id="menu-search-results" class="inactive"></div></div><div id="menu-pins"><div class="menu-pane-header">Pins</div><ul id="menu-pins-list"></ul></div><div class="menu-pane-header">Table of Contents</div><div id="menu-toc"><ol class="toc"><li><span class="item-toggle-none"></span><a href="#intro" title="Import Attributes">Import Attributes</a></li><li><span class="item-toggle">◢</span><a href="#sec-ecmascript-language-expressions" title="ECMAScript Language: Expressions"><span class="secnum">13</span> ECMAScript Language: Expressions</a><ol class="toc"><li><span class="item-toggle">◢</span><a href="#sec-left-hand-side-expressions" title="Left-Hand-Side Expressions"><span class="secnum">13.3</span> Left-Hand-Side Expressions</a><ol class="toc"><li><span class="item-toggle">◢</span><a href="#sec-import-calls" title="Import Calls"><span class="secnum">13.3.10</span> Import Calls</a><ol class="toc"><li><span class="item-toggle-none"></span><a href="#sec-import-call-runtime-semantics-evaluation" title="Runtime Semantics: Evaluation"><span class="secnum">13.3.10.1</span> RS: Evaluation</a></li><li><span class="item-toggle-none"></span><a href="#sec-evaluate-import-call" title="EvaluateImportCall ( specifierExpression [ , optionsExpression ] )"><span class="secnum">13.3.10.2</span> <ins>EvaluateImportCall ( <var>specifierExpression</var> [ , <var>optionsExpression</var> ] )</ins></a></li></ol></li></ol></li></ol></li><li><span class="item-toggle">◢</span><a href="#sec-ecmascript-language-scripts-and-modules" title="ECMAScript Language: Scripts and Modules"><span class="secnum">16</span> ECMAScript Language: Scripts and Modules</a><ol class="toc"><li><span class="item-toggle">◢</span><a href="#sec-modules" title="Modules"><span class="secnum">16.2</span> Modules</a><ol class="toc"><li><span class="item-toggle">◢</span><a href="#sec-module-semantics" title="Module Semantics"><span class="secnum">16.2.1</span> Module Semantics</a><ol class="toc"><li><span class="item-toggle-none"></span><a href="#sec-modulerequest-record" title="ModuleRequest and ImportAttribute Records"><span class="secnum">16.2.1.1</span> <ins>ModuleRequest and ImportAttribute Records</ins></a></li><li><span class="item-toggle-none"></span><a href="#sec-static-semantics-modulerequests" title="Static Semantics: ModuleRequests"><span class="secnum">16.2.1.3</span> SS: ModuleRequests</a></li><li><span class="item-toggle-none"></span><a href="#sec-cyclic-module-records" title="Cyclic Module Records"><span class="secnum">16.2.1.5</span> Cyclic Module Records</a></li><li><span class="item-toggle-none"></span><a href="#sec-source-text-module-records" title="Source Text Module Records"><span class="secnum">16.2.1.6</span> Source Text Module Records</a></li><li><span class="item-toggle-none"></span><a href="#sec-HostLoadImportedModule" title="HostLoadImportedModule ( referrer, specifier, moduleRequest, hostDefined, payload )"><span class="secnum">16.2.1.8</span> HostLoadImportedModule ( <var>referrer</var>, <del><var>specifier</var></del>, <ins><var>moduleRequest</var></ins>, <var>hostDefined</var>, <var>payload</var> )</a></li><li><span class="item-toggle">◢</span><a href="#sec-FinishLoadingImportedModule" title="FinishLoadingImportedModule ( referrer, specifier, moduleRequest, payload, result )"><span class="secnum">16.2.1.9</span> FinishLoadingImportedModule ( <var>referrer</var>, <del><var>specifier</var></del>, <ins><var>moduleRequest</var></ins>, <var>payload</var>, <var>result</var> )</a><ol class="toc"><li><span class="item-toggle-none"></span><a href="#sec-FinishLoadingImportedModule-AttributesEqual" title="AttributesEqual ( left, right )"><span class="secnum">16.2.1.9.1</span> <ins>AttributesEqual ( <var>left</var>, <var>right</var> )</ins></a></li></ol></li><li><span class="item-toggle">◢</span><a href="#sec-AllImportAttributesSupported" title="AllImportAttributesSupported ( attributes )"><span class="secnum">16.2.1.10</span> <ins>AllImportAttributesSupported ( <var>attributes</var> )</ins></a><ol class="toc"><li><span class="item-toggle-none"></span><a href="#sec-hostgetsupportedimportattributes" title="HostGetSupportedImportAttributes ( )"><span class="secnum">16.2.1.10.1</span> <ins>HostGetSupportedImportAttributes ( )</ins></a></li></ol></li></ol></li><li><span class="item-toggle">◢</span><a href="#sec-imports" title="Imports"><span class="secnum">16.2.2</span> Imports</a><ol class="toc"><li><span class="item-toggle-none"></span><a href="#sec-imports-static-semantics-early-errors" title="Static Semantics: Early Errors"><span class="secnum">16.2.2.1</span> SS: Early Errors</a></li><li><span class="item-toggle-none"></span><a href="#sec-import-static-semantics-attribute-name" title="Static Semantics: AttributeName"><span class="secnum">16.2.2.2</span> <ins>SS: AttributeName</ins></a></li><li><span class="item-toggle-none"></span><a href="#sec-with-clause-to-attributes" title="Static Semantics: WithClauseToAttributes"><span class="secnum">16.2.2.3</span> <ins>SS: WithClauseToAttributes</ins></a></li></ol></li><li><span class="item-toggle-none"></span><a href="#sec-exports" title="Exports"><span class="secnum">16.2.3</span> Exports</a></li></ol></li></ol></li><li><span class="item-toggle-none"></span><a href="#sec-host-integration" title="Sample host integration: The Web embedding"><span class="secnum">A</span> Sample host integration: The Web embedding</a></li></ol></div></div><div id="spec-container"><h1 class="version">Stage 2 Draft / April 6, 2023</h1>
<script>
document.addEventListener("DOMContentLoaded", () => {
Expand Down Expand Up @@ -3142,13 +3142,13 @@ <h1><span class="secnum">16.2.1.8</span> HostLoadImportedModule ( <var>referrer<
<p>The actual process performed is <emu-xref href="#host-defined"><a href="https://tc39.es/ecma262/#host-defined">host-defined</a></emu-xref>, but typically consists of performing whatever I/O operations are necessary to load the appropriate <emu-xref href="#sec-abstract-module-records"><a href="https://tc39.es/ecma262/#sec-abstract-module-records">Module Record</a></emu-xref>. Multiple different <del>(<var>referrer</var>, <var>specifier</var>) pairs</del><ins>(<var>referrer</var>, <var>moduleRequest</var>.<var class="field">[[Specifer]]</var>, <var>moduleRequest</var>.<var class="field">[[Attributes]]</var>) triples</ins> may map to the same <emu-xref href="#sec-abstract-module-records"><a href="https://tc39.es/ecma262/#sec-abstract-module-records">Module Record</a></emu-xref> instance. The actual mapping semantics is <emu-xref href="#host-defined"><a href="https://tc39.es/ecma262/#host-defined">host-defined</a></emu-xref> but typically a normalization process is applied to <var>specifier</var> as part of the mapping process. A typical normalization process would include actions such as expansion of relative and abbreviated path specifiers.</p>
<emu-note><span class="note">Note 2</span><div class="note-contents">
<p>There are three possible ways to handle multiple imports of the same module with different valid attributes:</p>
<p><ins>There are three possible ways to handle multiple imports of the same module with different valid attributes:</ins></p>
<ul>
<li><strong>Race</strong> and use the attribute that was requested by the first import. The second usage is ignored, which could lead to incorrect or unexpected behaviour depending on which import is handled first.</li>
<li><strong>Reject</strong> the module graph and don't load if attributes differ. This may be bad for composition: using two unrelated packages together could break, if they load the same module with disagreeing attributes.</li>
<li><strong>Clone</strong> and make two copies of the module, for the different ways it's transformed. These semantics would run counter to the intuition that there is just one copy of a module for each specifier.</li>
<li><ins><strong>Race</strong> and use the attribute that was requested by the first import. The second usage is ignored, which could lead to incorrect or unexpected behaviour depending on which import is handled first.</ins></li>
<li><ins><strong>Reject</strong> the module graph and don't load if attributes differ. This may be bad for composition: using two unrelated packages together could break, if they load the same module with disagreeing attributes.</ins></li>
<li><ins><strong>Clone</strong> and make two copies of the module, for the different ways it's transformed. These semantics would run counter to the intuition that there is just one copy of a module for each specifier.</ins></li>
</ul>
<p>It's possible that one of these three options may make sense for a module load, on a case-by-case basis by attribute, but it's worth careful thought before making this choice.</p>
<p><ins>It's possible that one of these three options may make sense for a module load, on a case-by-case basis by attribute, but it's worth careful thought before making this choice.</ins></p>
</div></emu-note>
</emu-clause>
Expand Down Expand Up @@ -3190,7 +3190,7 @@ <h1><span class="secnum">16.2.1.10.1</span> <ins>HostGetSupportedImportAttribute
<p>The default implementation of HostGetSupportedImportAttributes is to return a new empty <emu-xref href="#sec-list-and-record-specification-type"><a href="https://tc39.es/ecma262/#sec-list-and-record-specification-type">List</a></emu-xref>.</p>
<emu-note><span class="note">Note</span><div class="note-contents">The purpose of requiring the <emu-xref href="#host"><a href="https://tc39.es/ecma262/#host">host</a></emu-xref> to specify its supported import attributes, rather than passing all attributes to the <emu-xref href="#host"><a href="https://tc39.es/ecma262/#host">host</a></emu-xref> and letting it then choose which ones it wants to handle, is to ensure that unsupported attributes are handled in a consistent way across different <emu-xref href="#host"><a href="https://tc39.es/ecma262/#host">hosts</a></emu-xref>.</div></emu-note>
<emu-note><span class="note">Note</span><div class="note-contents"><ins>The purpose of requiring the <emu-xref href="#host"><a href="https://tc39.es/ecma262/#host">host</a></emu-xref> to specify its supported import attributes, rather than passing all attributes to the <emu-xref href="#host"><a href="https://tc39.es/ecma262/#host">host</a></emu-xref> and letting it then choose which ones it wants to handle, is to ensure that unsupported attributes are handled in a consistent way across different <emu-xref href="#host"><a href="https://tc39.es/ecma262/#host">hosts</a></emu-xref>.</ins></div></emu-note>
</emu-clause>
</emu-clause>
</emu-clause>
Expand Down

0 comments on commit 2b161db

Please sign in to comment.