Debian Codegraph @

packages/babel-parser/test/fixtures/comments/basic/call-expression-trailing-comma-object-shorthand/output.json

raw
1 {
2 "type": "File",
3 "start":0,"end":46,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":46,"index":46}},
4 "program": {
5 "type": "Program",
6 "start":0,"end":46,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":46,"index":46}},
7 "sourceType": "script",
8 "interpreter": null,
9 "body": [
10 {
11 "type": "ExpressionStatement",
12 "start":0,"end":46,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":46,"index":46}},
13 "expression": {
14 "type": "CallExpression",
15 "start":0,"end":29,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":29,"index":29}},
16 "callee": {
17 "type": "Identifier",
18 "start":0,"end":2,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":2,"index":2},"identifierName":"fn"},
19 "name": "fn"
20 },
21 "extra": {
22 "trailingComma": 11
23 },
24 "arguments": [
25 {
26 "type": "Identifier",
27 "start":3,"end":4,"loc":{"start":{"line":1,"column":3,"index":3},"end":{"line":1,"column":4,"index":4},"identifierName":"a"},
28 "name": "a"
29 },
30 {
31 "type": "ObjectExpression",
32 "start":6,"end":11,"loc":{"start":{"line":1,"column":6,"index":6},"end":{"line":1,"column":11,"index":11}},
33 "properties": [
34 {
35 "type": "ObjectProperty",
36 "start":8,"end":9,"loc":{"start":{"line":1,"column":8,"index":8},"end":{"line":1,"column":9,"index":9}},
37 "method": false,
38 "key": {
39 "type": "Identifier",
40 "start":8,"end":9,"loc":{"start":{"line":1,"column":8,"index":8},"end":{"line":1,"column":9,"index":9},"identifierName":"b"},
41 "name": "b"
42 },
43 "computed": false,
44 "shorthand": true,
45 "value": {
46 "type": "Identifier",
47 "start":8,"end":9,"loc":{"start":{"line":1,"column":8,"index":8},"end":{"line":1,"column":9,"index":9},"identifierName":"b"},
48 "name": "b"
49 },
50 "extra": {
51 "shorthand": true
52 }
53 }
54 ],
55 "trailingComments": [
56 {
57 "type": "CommentBlock",
58 "value": " comment 1 ",
59 "start":13,"end":28,"loc":{"start":{"line":1,"column":13,"index":13},"end":{"line":1,"column":28,"index":28}}
60 }
61 ]
62 }
63 ],
64 "trailingComments": [
65 {
66 "type": "CommentBlock",
67 "value": " comment 2 ",
68 "start":30,"end":45,"loc":{"start":{"line":1,"column":30,"index":30},"end":{"line":1,"column":45,"index":45}}
69 }
70 ]
71 }
72 }
73 ],
74 "directives": []
75 },
76 "comments": [
77 {
78 "type": "CommentBlock",
79 "value": " comment 1 ",
80 "start":13,"end":28,"loc":{"start":{"line":1,"column":13,"index":13},"end":{"line":1,"column":28,"index":28}}
81 },
82 {
83 "type": "CommentBlock",
84 "value": " comment 2 ",
85 "start":30,"end":45,"loc":{"start":{"line":1,"column":30,"index":30},"end":{"line":1,"column":45,"index":45}}
86 }
87 ]
88 }