Debian Codegraph @

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

raw
1 {
2 "type": "File",
3 "start":0,"end":47,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":2,"column":31,"index":47}},
4 "errors": [
5 "SyntaxError: `foo` has already been exported. Exported identifiers must be unique. (2:15)"
6 ],
7 "program": {
8 "type": "Program",
9 "start":0,"end":47,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":2,"column":31,"index":47}},
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":47,"loc":{"start":{"line":2,"column":0,"index":16},"end":{"line":2,"column":31,"index":47}},
38 "specifiers": [],
39 "source": null,
40 "declaration": {
41 "type": "VariableDeclaration",
42 "start":23,"end":47,"loc":{"start":{"line":2,"column":7,"index":23},"end":{"line":2,"column":31,"index":47}},
43 "declarations": [
44 {
45 "type": "VariableDeclarator",
46 "start":29,"end":46,"loc":{"start":{"line":2,"column":13,"index":29},"end":{"line":2,"column":30,"index":46}},
47 "id": {
48 "type": "ObjectPattern",
49 "start":29,"end":40,"loc":{"start":{"line":2,"column":13,"index":29},"end":{"line":2,"column":24,"index":40}},
50 "properties": [
51 {
52 "type": "ObjectProperty",
53 "start":31,"end":38,"loc":{"start":{"line":2,"column":15,"index":31},"end":{"line":2,"column":22,"index":38}},
54 "key": {
55 "type": "Identifier",
56 "start":31,"end":34,"loc":{"start":{"line":2,"column":15,"index":31},"end":{"line":2,"column":18,"index":34},"identifierName":"foo"},
57 "name": "foo"
58 },
59 "computed": false,
60 "method": false,
61 "shorthand": true,
62 "value": {
63 "type": "AssignmentPattern",
64 "start":31,"end":38,"loc":{"start":{"line":2,"column":15,"index":31},"end":{"line":2,"column":22,"index":38}},
65 "left": {
66 "type": "Identifier",
67 "start":31,"end":34,"loc":{"start":{"line":2,"column":15,"index":31},"end":{"line":2,"column":18,"index":34},"identifierName":"foo"},
68 "name": "foo"
69 },
70 "right": {
71 "type": "NumericLiteral",
72 "start":37,"end":38,"loc":{"start":{"line":2,"column":21,"index":37},"end":{"line":2,"column":22,"index":38}},
73 "extra": {
74 "rawValue": 1,
75 "raw": "1"
76 },
77 "value": 1
78 }
79 },
80 "extra": {
81 "shorthand": true
82 }
83 }
84 ]
85 },
86 "init": {
87 "type": "Identifier",
88 "start":43,"end":46,"loc":{"start":{"line":2,"column":27,"index":43},"end":{"line":2,"column":30,"index":46},"identifierName":"bar"},
89 "name": "bar"
90 }
91 }
92 ],
93 "kind": "const"
94 }
95 }
96 ],
97 "directives": []
98 }
99 }