-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Normative: change idempotency for HostImportModuleDynamically #1645
Conversation
Are there test262 tests for this change? (or, is it hard to test/not currently tested?) |
@ljharb under language/expressions/dynamic-import are at least the following tests affected by this change:
Since this PR removes required idempotency for double error, I think that those test are no longer needed. Also |
@Snapstromegon in that case, a merged test262 PR for those changes would be needed here. Want to file it? :-D |
Due to changing idempotenxy for dynamic import on failures these tests are no longer needed. After tc39/ecma262#1645 idempotency is only required after completing normally.
82854a7
to
d417f5d
Compare
) This allows failures to become successes on later calls. This better matches HostResolveImportedModule, which only requires idempotency when it completes normally (which is analogous to the success case here). Closes tc39/proposal-dynamic-import#80, at least on the ECMAScript side.
Where did this change actually end up? I had a look at the rendered output of https://tc39.es/proposal-dynamic-import/ and it only contained the old text, before this change. Then I tried searching the actual speco of ecma-262, but found hits on either pre or post text. The most relevant sections seems to be 13.3.10 Import Calls and HostLoadImportedModule |
We unified the HostResolveImportedModule and HostImportModuleDynamically hooks, the requirement is now the second bullet point of https://tc39.es/ecma262/#sec-HostLoadImportedModule. |
This better matches HostResolveImportedModule, which only requires idempotency when it completes normally (which is analogous to the success case here).
Closes tc39/proposal-dynamic-import#80, at least on the ECMAScript side.
To be presented at TC39 today; I thought it'd be easier to have a concrete needs-consensus PR rather than trying to page through tc39/proposal-dynamic-import#80.