Debian Codegraph @

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

raw
1 {
2 "type": "File",
3 "start":0,"end":54,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":2,"column":28,"index":54}},
4 "errors": [
5 "SyntaxError: Identifier 'foo' has already been declared. (2:15)",
6 "SyntaxError: `foo` has already been exported. Exported identifiers must be unique. (2:15)"
7 ],
8 "program": {
9 "type": "Program",
10 "start":0,"end":54,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":2,"column":28,"index":54}},
11 "sourceType": "module",
12 "interpreter": null,
13 "body": [
14 {
15 "type": "ExportNamedDeclaration",
16 "start":0,"end":25,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":25,"index":25}},
17 "specifiers": [],
18 "source": null,
19 "declaration": {
20 "type": "VariableDeclaration",
21 "start":7,"end":25,"loc":{"start":{"line":1,"column":7,"index":7},"end":{"line":1,"column":25,"index":25}},
22 "declarations": [
23 {
24 "type": "VariableDeclarator",
25 "start":13,"end":24,"loc":{"start":{"line":1,"column":13,"index":13},"end":{"line":1,"column":24,"index":24}},
26 "id": {
27 "type": "ArrayPattern",
28 "start":13,"end":18,"loc":{"start":{"line":1,"column":13,"index":13},"end":{"line":1,"column":18,"index":18}},
29 "elements": [
30 {
31 "type": "Identifier",
32 "start":14,"end":17,"loc":{"start":{"line":1,"column":14,"index":14},"end":{"line":1,"column":17,"index":17},"identifierName":"foo"},
33 "name": "foo"
34 }
35 ]
36 },
37 "init": {
38 "type": "Identifier",
39 "start":21,"end":24,"loc":{"start":{"line":1,"column":21,"index":21},"end":{"line":1,"column":24,"index":24},"identifierName":"bar"},
40 "name": "bar"
41 }
42 }
43 ],
44 "kind": "const"
45 }
46 },
47 {
48 "type": "ExportNamedDeclaration",
49 "start":26,"end":54,"loc":{"start":{"line":2,"column":0,"index":26},"end":{"line":2,"column":28,"index":54}},
50 "specifiers": [],
51 "source": null,
52 "declaration": {
53 "type": "VariableDeclaration",
54 "start":33,"end":54,"loc":{"start":{"line":2,"column":7,"index":33},"end":{"line":2,"column":28,"index":54}},
55 "declarations": [
56 {
57 "type": "VariableDeclarator",
58 "start":39,"end":53,"loc":{"start":{"line":2,"column":13,"index":39},"end":{"line":2,"column":27,"index":53}},
59 "id": {
60 "type": "ObjectPattern",
61 "start":39,"end":46,"loc":{"start":{"line":2,"column":13,"index":39},"end":{"line":2,"column":20,"index":46}},
62 "properties": [
63 {
64 "type": "ObjectProperty",
65 "start":41,"end":44,"loc":{"start":{"line":2,"column":15,"index":41},"end":{"line":2,"column":18,"index":44}},
66 "key": {
67 "type": "Identifier",
68 "start":41,"end":44,"loc":{"start":{"line":2,"column":15,"index":41},"end":{"line":2,"column":18,"index":44},"identifierName":"foo"},
69 "name": "foo"
70 },
71 "computed": false,
72 "method": false,
73 "shorthand": true,
74 "value": {
75 "type": "Identifier",
76 "start":41,"end":44,"loc":{"start":{"line":2,"column":15,"index":41},"end":{"line":2,"column":18,"index":44},"identifierName":"foo"},
77 "name": "foo"
78 },
79 "extra": {
80 "shorthand": true
81 }
82 }
83 ]
84 },
85 "init": {
86 "type": "Identifier",
87 "start":49,"end":53,"loc":{"start":{"line":2,"column":23,"index":49},"end":{"line":2,"column":27,"index":53},"identifierName":"bar2"},
88 "name": "bar2"
89 }
90 }
91 ],
92 "kind": "const"
93 }
94 }
95 ],
96 "directives": []
97 }
98 }