Skip to content
This repository was archived by the owner on Jan 25, 2022. It is now read-only.

Commit 239dc0f

Browse files
add more missing [[SourceText]] assignments
1 parent b2815d8 commit 239dc0f

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

proposal.html

+28
Original file line numberDiff line numberDiff line change
@@ -542,6 +542,34 @@ <h1>(<emu-xref href="#sec-class-definitions-runtime-semantics-evaluation">14.5.1
542542
</emu-clause>
543543

544544

545+
<!-- 14.7.10 -->
546+
<emu-clause id="proposal-sec-async-function-definitions-InstantiateFunctionObject">
547+
<h1>(<emu-xref href="sec-async-function-definitions-InstantiateFunctionObject">14.7.10</emu-xref>) Runtime Semantics: InstantiateFunctionObject</h1>
548+
<p>With parameter _scope_.</p>
549+
<emu-grammar>
550+
AsyncFunctionDeclaration : `async` [no LineTerminator here] `function` BindingIdentifier `(` FormalParameters `)` `{` AsyncFunctionBody `}`
551+
</emu-grammar>
552+
<emu-alg>
553+
1. If the function code for |AsyncFunctionDeclaration| is strict mode code, let _strict_ be *true*. Otherwise, let _strict_ be *false*.
554+
1. Let _name_ be StringValue of |BindingIdentifier|.
555+
1. Let _F_ be ! AsyncFunctionCreate(~Normal~, |FormalParameters|, |AsyncFunctionBody|, _scope_, _strict_).
556+
1. Perform ! SetFunctionName(_F_, _name_).
557+
1. <ins>Set _F_.[[SourceText]] to the source text matched by |AsyncFunctionDeclaration|.</ins>
558+
1. Return _F_.
559+
</emu-alg>
560+
<emu-grammar>
561+
AsyncFunctionDeclaration : `async` [no LineTerminator here] `function` `(` FormalParameters `)` `{` AsyncFunctionBody `}`
562+
</emu-grammar>
563+
<emu-alg>
564+
1. If the function code for |AsyncFunctionDeclaration| is strict mode code, let _strict_ be *true*. Otherwise, let _strict_ be *false*.
565+
1. Let _F_ be ! AsyncFunctionCreate(~Normal~, |FormalParameters|, |AsyncFunctionBody|, _scope_, _strict_).
566+
1. Perform ! SetFunctionName(_F_, `"default"`).
567+
1. <ins>Set _F_.[[SourceText]] to the source text matched by |AsyncFunctionDeclaration|.</ins>
568+
1. Return _F_.
569+
</emu-alg>
570+
</emu-clause>
571+
572+
545573
<!-- 14.7.12 -->
546574
<emu-clause id="proposal-sec-async-function-definitions-PropertyDefinitionEvaluation">
547575
<h1>(<emu-xref href="sec-async-function-definitions-PropertyDefinitionEvaluation">14.7.12</emu-xref>) Runtime Semantics: PropertyDefinitionEvaluation</h1>

0 commit comments

Comments
 (0)