Skip to content

Commit

Permalink
Normative: Prevent DFS invariants from being broken (#1669)
Browse files Browse the repository at this point in the history
An implementation of HostImportModuleDynamically, could, in theory, call
Evaluate() in the same tick as the call to HostImportModuleDynamically.
If that call to HostImportModuleDynamically was the direct result of
another call to Evaluate(), this may eagerly evaluate a module that
is already queued to be run at a later time.
  • Loading branch information
devsnek authored and ljharb committed Mar 23, 2020
1 parent d0b1fa8 commit 4b6d77d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions spec.html
Original file line number Diff line number Diff line change
Expand Up @@ -23162,6 +23162,7 @@ <h1>Evaluate ( ) Concrete Method</h1>
<p>This abstract method performs the following steps (most of the work is done by the auxiliary function InnerModuleEvaluation):</p>

<emu-alg>
1. Assert: This call to Evaluate is not happening at the same time as another call to Evaluate within the surrounding agent.
1. Let _module_ be this Cyclic Module Record.
1. Assert: _module_.[[Status]] is ~linked~ or ~evaluated~.
1. Let _stack_ be a new empty List.
Expand Down

0 comments on commit 4b6d77d

Please sign in to comment.