Debian Codegraph @

packages/babel-parser/test/fixtures/es2015/modules/duplicate-named-export-variable-declaration/output.json

raw
1 {
2 "type": "File",
3 "start":0,"end":39,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":2,"column":23,"index":39}},
4 "errors": [
5 "SyntaxError: `foo` has already been exported. Exported identifiers must be unique. (2:13)"
6 ],
7 "program": {
8 "type": "Program",
9 "start":0,"end":39,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":2,"column":23,"index":39}},
10 "sourceType": "module",
11 "interpreter": null,
12 "body": [
13 {
14 "type": "ExportNamedDeclaration",
15 "start":0,"end":15,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":15,"index":15}},
16 "specifiers": [
17 {
18 "type": "ExportSpecifier",
19 "start":9,"end":12,"loc":{"start":{"line":1,"column":9,"index":9},"end":{"line":1,"column":12,"index":12}},
20 "local": {
21 "type": "Identifier",
22 "start":9,"end":12,"loc":{"start":{"line":1,"column":9,"index":9},"end":{"line":1,"column":12,"index":12},"identifierName":"foo"},
23 "name": "foo"
24 },
25 "exported": {
26 "type": "Identifier",
27 "start":9,"end":12,"loc":{"start":{"line":1,"column":9,"index":9},"end":{"line":1,"column":12,"index":12},"identifierName":"foo"},
28 "name": "foo"
29 }
30 }
31 ],
32 "source": null,
33 "declaration": null
34 },
35 {
36 "type": "ExportNamedDeclaration",
37 "start":16,"end":39,"loc":{"start":{"line":2,"column":0,"index":16},"end":{"line":2,"column":23,"index":39}},
38 "specifiers": [],
39 "source": null,
40 "declaration": {
41 "type": "VariableDeclaration",
42 "start":23,"end":39,"loc":{"start":{"line":2,"column":7,"index":23},"end":{"line":2,"column":23,"index":39}},
43 "declarations": [
44 {
45 "type": "VariableDeclarator",
46 "start":29,"end":38,"loc":{"start":{"line":2,"column":13,"index":29},"end":{"line":2,"column":22,"index":38}},
47 "id": {
48 "type": "Identifier",
49 "start":29,"end":32,"loc":{"start":{"line":2,"column":13,"index":29},"end":{"line":2,"column":16,"index":32},"identifierName":"foo"},
50 "name": "foo"
51 },
52 "init": {
53 "type": "Identifier",
54 "start":35,"end":38,"loc":{"start":{"line":2,"column":19,"index":35},"end":{"line":2,"column":22,"index":38},"identifierName":"bar"},
55 "name": "bar"
56 }
57 }
58 ],
59 "kind": "const"
60 }
61 }
62 ],
63 "directives": []
64 }
65 }