Debian Codegraph @

js/src/tests/test262/language/module-code/import-attributes/allow-nlt-before-with.js

raw
1 // Copyright (C) 2021 the V8 project authors. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
3 /*---
4 description: >
5 `with` AttributesKeyword in WithClause in ImportDeclaration can
6 be preceded by a line terminator
7 esid: sec-modules
8 info: |
9 ImportDeclaration:
10 import ModuleSpecifier WithClause;
11
12 WithClause:
13 AttributesKeyword {}
14 AttributesKeyword { WithEntries ,opt }
15
16 AttributesKeyword:
17 with
18 [no LineTerminator here] assert
19
20 negative:
21 phase: resolution
22 type: SyntaxError
23 features: [import-attributes, globalThis]
24 flags: [module, raw]
25 ---*/
26
27 throw "Test262: This statement should not be evaluated.";
28
29 import "./ensure-linking-error_FIXTURE.js";
30
31 import * as x from './import-attribute-1_FIXTURE.js'
32 with
33 {};