Debian Codegraph @

packages/babel-parser/test/fixtures/flow/declare-module/invalid-import/output.json

raw
1 {
2 "type": "File",
3 "start":0,"end":42,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":42,"index":42}},
4 "errors": [
5 "SyntaxError: Imports within a `declare module` body must always be `import type` or `import typeof`. (1:21)"
6 ],
7 "program": {
8 "type": "Program",
9 "start":0,"end":42,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":42,"index":42}},
10 "sourceType": "module",
11 "interpreter": null,
12 "body": [
13 {
14 "type": "DeclareModule",
15 "start":0,"end":42,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":42,"index":42}},
16 "id": {
17 "type": "StringLiteral",
18 "start":15,"end":18,"loc":{"start":{"line":1,"column":15,"index":15},"end":{"line":1,"column":18,"index":18}},
19 "extra": {
20 "rawValue": "M",
21 "raw": "\"M\""
22 },
23 "value": "M"
24 },
25 "body": {
26 "type": "BlockStatement",
27 "start":19,"end":42,"loc":{"start":{"line":1,"column":19,"index":19},"end":{"line":1,"column":42,"index":42}},
28 "body": [
29 {
30 "type": "ImportDeclaration",
31 "start":21,"end":40,"loc":{"start":{"line":1,"column":21,"index":21},"end":{"line":1,"column":40,"index":40}},
32 "specifiers": [
33 {
34 "type": "ImportDefaultSpecifier",
35 "start":28,"end":29,"loc":{"start":{"line":1,"column":28,"index":28},"end":{"line":1,"column":29,"index":29}},
36 "local": {
37 "type": "Identifier",
38 "start":28,"end":29,"loc":{"start":{"line":1,"column":28,"index":28},"end":{"line":1,"column":29,"index":29},"identifierName":"T"},
39 "name": "T"
40 }
41 }
42 ],
43 "importKind": "value",
44 "source": {
45 "type": "StringLiteral",
46 "start":35,"end":39,"loc":{"start":{"line":1,"column":35,"index":35},"end":{"line":1,"column":39,"index":39}},
47 "extra": {
48 "rawValue": "TM",
49 "raw": "\"TM\""
50 },
51 "value": "TM"
52 }
53 }
54 ]
55 },
56 "kind": "CommonJS"
57 }
58 ],
59 "directives": []
60 }
61 }