mirror of https://github.com/tc39/test262.git
Generate Tests
This commit is contained in:
parent
8e28caa214
commit
3589fa9d82
|
@ -0,0 +1,37 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/nested-arrow.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (nested arrow)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
let f = () => {
|
||||
import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
};
|
||||
|
||||
f();
|
|
@ -0,0 +1,37 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/nested-async-function-await.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (nested in async function, awaited)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
async function f() {
|
||||
await import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
}
|
||||
|
||||
f();
|
|
@ -0,0 +1,38 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/nested-async-function.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (nested in async function)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
async function f() {
|
||||
import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
}
|
||||
|
||||
f();
|
||||
|
|
@ -0,0 +1,37 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/nested-async-function-return-await.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (nested in async function, returns awaited)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
async function f() {
|
||||
return await import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
}
|
||||
|
||||
f();
|
|
@ -0,0 +1,35 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/nested-block.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (nested block)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
{
|
||||
import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
};
|
|
@ -0,0 +1,35 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/nested-block-labeled.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (nested block syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
label: {
|
||||
import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
};
|
|
@ -0,0 +1,35 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/nested-do-while.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (nested do while syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
do {
|
||||
import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
} while (false);
|
|
@ -0,0 +1,37 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/nested-else.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (nested else)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
if (false) {
|
||||
|
||||
} else {
|
||||
import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
}
|
|
@ -0,0 +1,36 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/nested-function.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (nested function)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
function f() {
|
||||
import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
}
|
||||
f();
|
|
@ -0,0 +1,35 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/nested-if.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (nested if)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
if (true) {
|
||||
import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
}
|
|
@ -0,0 +1,37 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/nested-while.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (nested while)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
let x = 0;
|
||||
while (!x) {
|
||||
x++;
|
||||
import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
};
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/eval-rqstd-abrupt-typeerror.case
|
||||
// - src/dynamic-import/catch/nested-with.template
|
||||
/*---
|
||||
description: Abrupt completion during module evaluation precludes further evaluation (nested with)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async, noStrict]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
[...]
|
||||
6. For each String required that is an element of
|
||||
module.[[RequestedModules]] do,
|
||||
a. Let requiredModule be ? HostResolveImportedModule(module, required).
|
||||
b. Perform ? requiredModule.ModuleEvaluation().
|
||||
|
||||
---*/
|
||||
|
||||
with ({}) {
|
||||
import('./eval-rqstd-abrupt-err-type_FIXTURE.js').catch(error => {
|
||||
|
||||
assert.sameValue(error.name, 'TypeError');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
}
|
||||
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/eval-rqstd-abrupt-urierror.case
|
||||
// - src/dynamic-import/catch/nested-with.template
|
||||
/*---
|
||||
description: Abrupt completion during module evaluation precludes further evaluation (nested with)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async, noStrict]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
[...]
|
||||
6. For each String required that is an element of
|
||||
module.[[RequestedModules]] do,
|
||||
a. Let requiredModule be ? HostResolveImportedModule(module, required).
|
||||
b. Perform ? requiredModule.ModuleEvaluation().
|
||||
|
||||
---*/
|
||||
|
||||
with ({}) {
|
||||
import('./eval-rqstd-abrupt-err-uri_FIXTURE.js').catch(error => {
|
||||
|
||||
assert.sameValue(error.name, 'URIError');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
}
|
||||
|
|
@ -0,0 +1,36 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/nested-with.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (nested with)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async, noStrict]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
with ({}) {
|
||||
import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
}
|
||||
|
|
@ -0,0 +1,60 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/instn-iee-err-ambiguous-import.case
|
||||
// - src/dynamic-import/catch/nested-with.template
|
||||
/*---
|
||||
description: IndirectExportEntries validation - ambiguous imported bindings (nested with)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async, noStrict]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
[...]
|
||||
9. For each ExportEntry Record e in module.[[IndirectExportEntries]], do
|
||||
a. Let resolution be ? module.ResolveExport(e.[[ExportName]], « », « »).
|
||||
b. If resolution is null or resolution is "ambiguous", throw a
|
||||
SyntaxError exception.
|
||||
[...]
|
||||
|
||||
15.2.1.16.3 ResolveExport
|
||||
|
||||
[...]
|
||||
9. Let starResolution be null.
|
||||
10. For each ExportEntry Record e in module.[[StarExportEntries]], do
|
||||
a. Let importedModule be ? HostResolveImportedModule(module,
|
||||
e.[[ModuleRequest]]).
|
||||
b. Let resolution be ? importedModule.ResolveExport(exportName,
|
||||
resolveSet, exportStarSet).
|
||||
c. If resolution is "ambiguous", return "ambiguous".
|
||||
d. If resolution is not null, then
|
||||
i. If starResolution is null, let starResolution be resolution.
|
||||
ii. Else,
|
||||
1. Assert: there is more than one * import that includes the
|
||||
requested name.
|
||||
2. If resolution.[[Module]] and starResolution.[[Module]] are
|
||||
not the same Module Record or
|
||||
SameValue(resolution.[[BindingName]],
|
||||
starResolution.[[BindingName]]) is false, return "ambiguous".
|
||||
|
||||
---*/
|
||||
|
||||
with ({}) {
|
||||
import('./instn-iee-err-ambiguous-export_FIXTURE.js').catch(error => {
|
||||
|
||||
assert.sameValue(error.name, 'SyntaxError');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
}
|
||||
|
|
@ -0,0 +1,49 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/instn-iee-err-circular.case
|
||||
// - src/dynamic-import/catch/nested-with.template
|
||||
/*---
|
||||
description: IndirectExportEntries validation - circular imported bindings (nested with)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async, noStrict]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
[...]
|
||||
9. For each ExportEntry Record e in module.[[IndirectExportEntries]], do
|
||||
a. Let resolution be ? module.ResolveExport(e.[[ExportName]], « », « »).
|
||||
b. If resolution is null or resolution is "ambiguous", throw a
|
||||
SyntaxError exception.
|
||||
[...]
|
||||
|
||||
15.2.1.16.3 ResolveExport
|
||||
|
||||
[...]
|
||||
2. For each Record {[[Module]], [[ExportName]]} r in resolveSet, do:
|
||||
a. If module and r.[[Module]] are the same Module Record and
|
||||
SameValue(exportName, r.[[ExportName]]) is true, then
|
||||
i. Assert: this is a circular import request.
|
||||
ii. Return null.
|
||||
|
||||
---*/
|
||||
|
||||
with ({}) {
|
||||
import('./instn-iee-err-circular-1_FIXTURE.js').catch(error => {
|
||||
|
||||
assert.sameValue(error.name, 'SyntaxError');
|
||||
|
||||
}).then($DONE, $DONE);
|
||||
}
|
||||
|
|
@ -0,0 +1,33 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/file-does-not-exist.case
|
||||
// - src/dynamic-import/catch/top-level.template
|
||||
/*---
|
||||
description: Non existent file can't resolve to a Script or Module Record (top level)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, async]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
If a Module Record corresponding to the pair referencingModulereferencingScriptOrModule,
|
||||
specifier does not exist or cannot be created, an exception must be thrown.
|
||||
|
||||
---*/
|
||||
|
||||
import('./THIS_FILE_DOES_NOT_EXIST.js').catch(error => {
|
||||
|
||||
assert.notSameValue(typeof error, 'undefined');
|
||||
|
||||
}).then($DONE, $DONE);
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -0,0 +1,37 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-arrow-assignment-expression.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
let f = () => import('', '');
|
|
@ -0,0 +1,37 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-arrow-assignment-expression.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
let f = () => import('',);
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-arrow.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
let f = () => {
|
||||
import('', '');
|
||||
};
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-arrow.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
let f = () => {
|
||||
import('',);
|
||||
};
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-async-function-await.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
async function f() {
|
||||
await import('', '');
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-async-function-await.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
async function f() {
|
||||
await import('',);
|
||||
}
|
|
@ -0,0 +1,40 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-async-function.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
async function f() {
|
||||
import('', '');
|
||||
}
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-async-function.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
async function f() {
|
||||
import('',);
|
||||
}
|
||||
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -0,0 +1,40 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-async-function-return-await.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
async function f() {
|
||||
return await import('', '');
|
||||
}
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-async-function-return-await.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
async function f() {
|
||||
return await import('',);
|
||||
}
|
||||
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested block syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested block syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-block-labeled.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested block syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
label: {
|
||||
import('', '');
|
||||
};
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-block-labeled.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested block syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
label: {
|
||||
import('',);
|
||||
};
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-block.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested block syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
{
|
||||
import('', '');
|
||||
};
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-block.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested block syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
{
|
||||
import('',);
|
||||
};
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested do while syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-do-while.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested do while syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
do {
|
||||
import('', '');
|
||||
} while (false);
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-do-while.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested do while syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
do {
|
||||
import('',);
|
||||
} while (false);
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested else syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested else syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-else-braceless.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested else syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
if (false) {
|
||||
|
||||
} else import('', '');
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-else-braceless.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested else syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
if (false) {
|
||||
|
||||
} else import('',);
|
|
@ -0,0 +1,41 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-else.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested else syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
if (false) {
|
||||
|
||||
} else {
|
||||
import('', '');
|
||||
}
|
|
@ -0,0 +1,41 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-else.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested else syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
if (false) {
|
||||
|
||||
} else {
|
||||
import('',);
|
||||
}
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested function syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-function.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested function syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
function fn() {
|
||||
import('', '');
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-function.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested function syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
function fn() {
|
||||
import('',);
|
||||
}
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested function syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-function-return.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested function syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
function fn() {
|
||||
return import('', '');
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-function-return.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested function syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
function fn() {
|
||||
return import('',);
|
||||
}
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested if syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested if syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -0,0 +1,37 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-if-braceless.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested if syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
if (true) import('', '');
|
|
@ -0,0 +1,37 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-if-braceless.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested if syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
if (true) import('',);
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-if.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested if syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
if (true) {
|
||||
import('', '');
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-if.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested if syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
if (true) {
|
||||
import('',);
|
||||
}
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (nested while syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -0,0 +1,41 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-while.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested while syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
let x = 0;
|
||||
while (!x) {
|
||||
x++;
|
||||
import('', '');
|
||||
};
|
|
@ -0,0 +1,41 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-while.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested while syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
let x = 0;
|
||||
while (!x) {
|
||||
x++;
|
||||
import('',);
|
||||
};
|
|
@ -0,0 +1,37 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/assignment-expr-not-optional.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-with.template
|
||||
/*---
|
||||
description: It's a SyntaxError if AssignmentExpression is omitted (nested with syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, noStrict]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
with ({}) {
|
||||
import();
|
||||
}
|
||||
|
||||
/* The params region intentionally empty */
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-with.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (nested with syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, noStrict]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
with ({}) {
|
||||
import('', '');
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/nested-with.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (nested with syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, noStrict]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
with ({}) {
|
||||
import('',);
|
||||
}
|
|
@ -5,7 +5,7 @@
|
|||
description: It's a SyntaxError if AssignmentExpression is omitted (top level syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
|
|
|
@ -0,0 +1,27 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-args.case
|
||||
// - src/dynamic-import/syntax/invalid/top-level.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - no arguments list (top level syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
import('', '');
|
|
@ -0,0 +1,27 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/not-extensible-no-trailing-comma.case
|
||||
// - src/dynamic-import/syntax/invalid/top-level.template
|
||||
/*---
|
||||
description: ImportCall is not extensible - trailing comma (top level syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: parse
|
||||
type: SyntaxError
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
|
||||
ImportCall :
|
||||
import( AssignmentExpression[+In, ?Yield] )
|
||||
|
||||
Forbidden Extensions
|
||||
|
||||
- ImportCall must not be extended.
|
||||
---*/
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
import('',);
|
|
@ -5,7 +5,7 @@
|
|||
description: Calling import('') (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
|
|
@ -0,0 +1,25 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-arrow-assignment-expression.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
let f = () => import(import(import('./empty_FIXTURE.js')));
|
|
@ -0,0 +1,29 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-arrow-assignment-expression.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
let f = () => import('./script-code-valid.js');
|
|
@ -0,0 +1,27 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-arrow.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
let f = () => {
|
||||
import(import(import('./empty_FIXTURE.js')));
|
||||
};
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-arrow.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
let f = () => {
|
||||
import('./script-code-valid.js');
|
||||
};
|
|
@ -0,0 +1,27 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-async-function-await.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
async function f() {
|
||||
await import(import(import('./empty_FIXTURE.js')));
|
||||
}
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-async-function-await.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
async function f() {
|
||||
await import('./script-code-valid.js');
|
||||
}
|
|
@ -0,0 +1,28 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-async-function.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
async function f() {
|
||||
import(import(import('./empty_FIXTURE.js')));
|
||||
}
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-async-function-return-await.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
async function f() {
|
||||
return await import(import(import('./empty_FIXTURE.js')));
|
||||
}
|
||||
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-async-function-return-await.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
async function f() {
|
||||
return await import('./script-code-valid.js');
|
||||
}
|
||||
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-async-function.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested arrow syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
async function f() {
|
||||
import('./script-code-valid.js');
|
||||
}
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-block-labeled.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested block syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
label: {
|
||||
import(import(import('./empty_FIXTURE.js')));
|
||||
};
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-block-labeled.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested block syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
label: {
|
||||
import('./script-code-valid.js');
|
||||
};
|
|
@ -0,0 +1,27 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-block.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested block syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
{
|
||||
import(import(import('./empty_FIXTURE.js')));
|
||||
};
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-block.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested block syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
{
|
||||
import('./script-code-valid.js');
|
||||
};
|
|
@ -0,0 +1,27 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-do-while.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested do while syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
do {
|
||||
import(import(import('./empty_FIXTURE.js')));
|
||||
} while (false);
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-do-while.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested do while syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
do {
|
||||
import('./script-code-valid.js');
|
||||
} while (false);
|
|
@ -0,0 +1,27 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-else-braceless.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested else syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
if (false) {
|
||||
|
||||
} else import(import(import('./empty_FIXTURE.js')));
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-else-braceless.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested else syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
if (false) {
|
||||
|
||||
} else import('./script-code-valid.js');
|
|
@ -0,0 +1,29 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-else.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested else syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
if (false) {
|
||||
|
||||
} else {
|
||||
import(import(import('./empty_FIXTURE.js')));
|
||||
}
|
|
@ -0,0 +1,33 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-else.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested else syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
if (false) {
|
||||
|
||||
} else {
|
||||
import('./script-code-valid.js');
|
||||
}
|
|
@ -5,7 +5,7 @@
|
|||
description: Calling import('') (nested function syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
|
|
@ -0,0 +1,27 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-function.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested function syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
function fn() {
|
||||
import(import(import('./empty_FIXTURE.js')));
|
||||
}
|
|
@ -5,7 +5,7 @@
|
|||
description: Calling import('') (nested function syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
|
|
@ -0,0 +1,27 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-function-return.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested function syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
function fn() {
|
||||
return import(import(import('./empty_FIXTURE.js')));
|
||||
}
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-function-return.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested function syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
function fn() {
|
||||
return import('./script-code-valid.js');
|
||||
}
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-function.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested function syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
function fn() {
|
||||
import('./script-code-valid.js');
|
||||
}
|
|
@ -0,0 +1,25 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-if-braceless.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested if syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
if (true) import(import(import('./empty_FIXTURE.js')));
|
|
@ -0,0 +1,29 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-if-braceless.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested if syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
if (true) import('./script-code-valid.js');
|
|
@ -0,0 +1,27 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/nested-imports.case
|
||||
// - src/dynamic-import/syntax/valid/nested-if.template
|
||||
/*---
|
||||
description: ImportCall is a CallExpression can be nested in other import calls (nested if syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
|
||||
if (true) {
|
||||
import(import(import('./empty_FIXTURE.js')));
|
||||
}
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/dynamic-import/script-code-valid.case
|
||||
// - src/dynamic-import/syntax/valid/nested-if.template
|
||||
/*---
|
||||
description: import() can be used in script code (nested if syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
||||
1. Let referencingScriptOrModule be ! GetActiveScriptOrModule().
|
||||
2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null).
|
||||
3. Let argRef be the result of evaluating AssignmentExpression.
|
||||
4. Let specifier be ? GetValue(argRef).
|
||||
5. Let promiseCapability be ! NewPromiseCapability(%Promise%).
|
||||
6. Let specifierString be ToString(specifier).
|
||||
7. IfAbruptRejectPromise(specifierString, promiseCapability).
|
||||
8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability).
|
||||
9. Return promiseCapability.[[Promise]].
|
||||
|
||||
---*/
|
||||
// It is a Syntax Error if ModuleItemList Contains NewTarget
|
||||
// This is still valid in script code
|
||||
new.target;
|
||||
|
||||
|
||||
if (true) {
|
||||
import('./script-code-valid.js');
|
||||
}
|
|
@ -5,7 +5,7 @@
|
|||
description: Calling import('') (nested while syntax)
|
||||
esid: sec-import-call-runtime-semantics-evaluation
|
||||
features: [dynamic-import]
|
||||
flags: [generated, module]
|
||||
flags: [generated]
|
||||
info: |
|
||||
ImportCall :
|
||||
import( AssignmentExpression )
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue