Skip to content

Commit

Permalink
more return types
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelficarra committed Jan 20, 2022
1 parent 71edba0 commit 8c5a8ec
Showing 1 changed file with 21 additions and 21 deletions.
42 changes: 21 additions & 21 deletions spec.html
Original file line number Diff line number Diff line change
Expand Up @@ -25876,7 +25876,7 @@ <h1>Static Semantics: Early Errors</h1>
<h1>
Static Semantics: ImportedLocalNames (
_importEntries_: a List of ImportEntry Records,
)
): a List of Strings
</h1>
<dl class="header">
<dt>description</dt>
Expand All @@ -25891,7 +25891,7 @@ <h1>
</emu-clause>

<emu-clause id="sec-static-semantics-modulerequests" oldids="sec-module-semantics-static-semantics-modulerequests,sec-imports-static-semantics-modulerequests,sec-exports-static-semantics-modulerequests" type="sdo">
<h1>Static Semantics: ModuleRequests</h1>
<h1>Static Semantics: ModuleRequests (): a List of Strings</h1>
<dl class="header">
</dl>
<emu-grammar>Module : [empty]</emu-grammar>
Expand Down Expand Up @@ -26226,7 +26226,7 @@ <h1>Cyclic Module Records</h1>
</emu-table>

<emu-clause id="sec-moduledeclarationlinking" type="concrete method" oldids="sec-moduledeclarationinstantiation">
<h1>Link ( )</h1>
<h1>Link (): a Completion Record normally containing ~unused~</h1>
<dl class="header">
<dt>for</dt>
<dd>a Cyclic Module Record _module_</dd>
Expand All @@ -26244,10 +26244,10 @@ <h1>Link ( )</h1>
1. Assert: _m_.[[Status]] is ~linking~.
1. Set _m_.[[Status]] to ~unlinked~.
1. Assert: _module_.[[Status]] is ~unlinked~.
1. Return _result_.
1. Return Completion(_result_).
1. Assert: _module_.[[Status]] is ~linked~, ~evaluating-async~, or ~evaluated~.
1. Assert: _stack_ is empty.
1. Return *undefined*.
1. Return NormalCompletion(~unused~).
</emu-alg>

<emu-clause id="sec-InnerModuleLinking" type="abstract operation" oldids="sec-innermoduleinstantiation">
Expand All @@ -26256,7 +26256,7 @@ <h1>
_module_: a Module Record,
_stack_: unknown,
_index_: a non-negative integer,
)
): a Completion Record normally containing a non-negative integer
</h1>
<dl class="header">
<dt>description</dt>
Expand All @@ -26266,9 +26266,9 @@ <h1>
<emu-alg>
1. If _module_ is not a Cyclic Module Record, then
1. Perform ? _module_.Link().
1. Return _index_.
1. Return NormalCompletion(_index_).
1. If _module_.[[Status]] is ~linking~, ~linked~, ~evaluating-async~, or ~evaluated~, then
1. Return _index_.
1. Return NormalCompletion(_index_).
1. Assert: _module_.[[Status]] is ~unlinked~.
1. Set _module_.[[Status]] to ~linking~.
1. Set _module_.[[DFSIndex]] to _index_.
Expand All @@ -26294,13 +26294,13 @@ <h1>
1. Assert: _requiredModule_ is a Cyclic Module Record.
1. Set _requiredModule_.[[Status]] to ~linked~.
1. If _requiredModule_ and _module_ are the same Module Record, set _done_ to *true*.
1. Return _index_.
1. Return NormalCompletion(_index_).
</emu-alg>
</emu-clause>
</emu-clause>

<emu-clause id="sec-moduleevaluation" type="concrete method">
<h1>Evaluate ( )</h1>
<h1>Evaluate (): a Promise</h1>
<dl class="header">
<dt>for</dt>
<dd>a Cyclic Module Record _module_</dd>
Expand Down Expand Up @@ -26343,7 +26343,7 @@ <h1>
_module_: a Module Record,
_stack_: unknown,
_index_: a non-negative integer,
)
): a Completion Record normally containing a non-negative integer
</h1>
<dl class="header">
<dt>description</dt>
Expand All @@ -26356,11 +26356,11 @@ <h1>
1. Assert: _promise_.[[PromiseState]] is not ~pending~.
1. If _promise_.[[PromiseState]] is ~rejected~, then
1. Return ThrowCompletion(_promise_.[[PromiseResult]]).
1. Return _index_.
1. Return NormalCompletion(_index_).
1. If _module_.[[Status]] is ~evaluating-async~ or ~evaluated~, then
1. If _module_.[[EvaluationError]] is ~empty~, return _index_.
1. Otherwise, return _module_.[[EvaluationError]].
1. If _module_.[[Status]] is ~evaluating~, return _index_.
1. If _module_.[[EvaluationError]] is ~empty~, return NormalCompletion(_index_).
1. Otherwise, return Completion(_module_.[[EvaluationError]]).
1. If _module_.[[Status]] is ~evaluating~, return NormalCompletion(_index_).
1. Assert: _module_.[[Status]] is ~linked~.
1. Set _module_.[[Status]] to ~evaluating~.
1. Set _module_.[[DFSIndex]] to _index_.
Expand All @@ -26380,7 +26380,7 @@ <h1>
1. Else,
1. Set _requiredModule_ to _requiredModule_.[[CycleRoot]].
1. Assert: _requiredModule_.[[Status]] is ~evaluating-async~ or ~evaluated~.
1. If _requiredModule_.[[EvaluationError]] is not ~empty~, return _requiredModule_.[[EvaluationError]].
1. If _requiredModule_.[[EvaluationError]] is not ~empty~, return Completion(_requiredModule_.[[EvaluationError]]).
1. If _requiredModule_.[[AsyncEvaluation]] is *true*, then
1. Set _module_.[[PendingAsyncDependencies]] to _module_.[[PendingAsyncDependencies]] + 1.
1. Append _module_ to _requiredModule_.[[AsyncParentModules]].
Expand All @@ -26402,7 +26402,7 @@ <h1>
1. Otherwise, set _requiredModule_.[[Status]] to ~evaluating-async~.
1. If _requiredModule_ and _module_ are the same Module Record, set _done_ to *true*.
1. Set _requiredModule_.[[CycleRoot]] to _module_.
1. Return _index_.
1. Return NormalCompletion(_index_).
</emu-alg>
<emu-note>
<p>A module is ~evaluating~ while it is being traversed by InnerModuleEvaluation. A module is ~evaluated~ on execution completion or ~evaluating-async~ during execution if its [[HasTLA]] field is *true* or if it has asynchronous dependencies.</p>
Expand Down Expand Up @@ -27430,7 +27430,7 @@ <h1>
_sourceText_: ECMAScript source text,
_realm_: unknown,
_hostDefined_: unknown,
)
): a Source Text Module Record or a List of *SyntaxError* objects
</h1>
<dl class="header">
<dt>description</dt>
Expand Down Expand Up @@ -27475,7 +27475,7 @@ <h1>
<h1>
GetExportedNames (
optional _exportStarSet_: a List of Source Text Module Records,
)
): a Completion Record normally containing a List of Strings or *null*
</h1>
<dl class="header">
<dt>for</dt>
Expand All @@ -27485,7 +27485,7 @@ <h1>
1. If _exportStarSet_ is not present, set _exportStarSet_ to a new empty List.
1. If _exportStarSet_ contains _module_, then
1. Assert: We've reached the starting point of an `export *` circularity.
1. Return a new empty List.
1. Return NormalCompletion(&laquo; &raquo;).
1. Append _module_ to _exportStarSet_.
1. Let _exportedNames_ be a new empty List.
1. For each ExportEntry Record _e_ of _module_.[[LocalExportEntries]], do
Expand All @@ -27501,7 +27501,7 @@ <h1>
1. If SameValue(_n_, *"default"*) is *false*, then
1. If _n_ is not an element of _exportedNames_, then
1. Append _n_ to _exportedNames_.
1. Return _exportedNames_.
1. Return NormalCompletion(_exportedNames_).
</emu-alg>
<emu-note>
<p>GetExportedNames does not filter out or throw an exception for names that have ambiguous star export bindings.</p>
Expand Down

0 comments on commit 8c5a8ec

Please sign in to comment.