Draft
Conversation
e90ec63 to
ac34904
Compare
Based to unlanded normative PR tc39/proposal-esm-phase-imports#58
Implementing normative change tc39/proposal-esm-phase-imports#61, pending approval In addition this better obtains coverage against cross-context imports, allowing us to remove the complex agent test harness
634ab92 to
53f8ac5
Compare
53f8ac5 to
0facc6a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This implements a draft 262 test suite for ESM Phase Imports, which is based to the following two normative changes that have not yet obtained consensus in plenary:
This includes full coverage of the detailed module keying semantics for the behaviour of
import(source)for a module source including consolidation with string imports, injective behaviour across contexts and cross realm imports.Since there is no ModuleConstructor, we depend on a host intrinsic
$262.createModuleSource(sourceText, id)to create module sources.To carefully ensure we can determine module identity, we also define
$262.importMetaHookwhich allows us to defineimport.meta.moduleIdas a proxy forimport.meta.urlto ensure we can validate cross-keying semantics.