Debian Codegraph @

packages/babel-parser/test/fixtures/comments/basic/class-private-method/output.json

raw
1 {
2 "type": "File",
3 "start":0,"end":114,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":114,"index":114}},
4 "program": {
5 "type": "Program",
6 "start":0,"end":114,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":114,"index":114}},
7 "sourceType": "script",
8 "interpreter": null,
9 "body": [
10 {
11 "type": "ExpressionStatement",
12 "start":0,"end":114,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":114,"index":114}},
13 "expression": {
14 "type": "ClassExpression",
15 "start":9,"end":103,"loc":{"start":{"line":1,"column":9,"index":9},"end":{"line":1,"column":103,"index":103}},
16 "id": null,
17 "superClass": null,
18 "body": {
19 "type": "ClassBody",
20 "start":23,"end":103,"loc":{"start":{"line":1,"column":23,"index":23},"end":{"line":1,"column":103,"index":103}},
21 "body": [
22 {
23 "type": "ClassPrivateMethod",
24 "start":33,"end":92,"loc":{"start":{"line":1,"column":33,"index":33},"end":{"line":1,"column":92,"index":92}},
25 "static": false,
26 "key": {
27 "type": "PrivateName",
28 "start":33,"end":35,"loc":{"start":{"line":1,"column":33,"index":33},"end":{"line":1,"column":35,"index":35}},
29 "id": {
30 "type": "Identifier",
31 "start":34,"end":35,"loc":{"start":{"line":1,"column":34,"index":34},"end":{"line":1,"column":35,"index":35},"identifierName":"f"},
32 "name": "f"
33 },
34 "trailingComments": [
35 {
36 "type": "CommentBlock",
37 "value": " 4 ",
38 "start":36,"end":43,"loc":{"start":{"line":1,"column":36,"index":36},"end":{"line":1,"column":43,"index":43}}
39 }
40 ]
41 },
42 "kind": "method",
43 "id": null,
44 "generator": false,
45 "async": false,
46 "params": [
47 {
48 "type": "Identifier",
49 "start":53,"end":54,"loc":{"start":{"line":1,"column":53,"index":53},"end":{"line":1,"column":54,"index":54},"identifierName":"a"},
50 "name": "a",
51 "trailingComments": [
52 {
53 "type": "CommentBlock",
54 "value": " 6 ",
55 "start":55,"end":62,"loc":{"start":{"line":1,"column":55,"index":55},"end":{"line":1,"column":62,"index":62}}
56 },
57 {
58 "type": "CommentBlock",
59 "value": " 7 ",
60 "start":64,"end":71,"loc":{"start":{"line":1,"column":64,"index":64},"end":{"line":1,"column":71,"index":71}}
61 }
62 ],
63 "leadingComments": [
64 {
65 "type": "CommentBlock",
66 "value": " 5 ",
67 "start":45,"end":52,"loc":{"start":{"line":1,"column":45,"index":45},"end":{"line":1,"column":52,"index":52}}
68 }
69 ]
70 }
71 ],
72 "body": {
73 "type": "BlockStatement",
74 "start":81,"end":92,"loc":{"start":{"line":1,"column":81,"index":81},"end":{"line":1,"column":92,"index":92}},
75 "body": [],
76 "directives": [],
77 "innerComments": [
78 {
79 "type": "CommentBlock",
80 "value": " 9 ",
81 "start":83,"end":90,"loc":{"start":{"line":1,"column":83,"index":83},"end":{"line":1,"column":90,"index":90}}
82 }
83 ],
84 "leadingComments": [
85 {
86 "type": "CommentBlock",
87 "value": " 8 ",
88 "start":73,"end":80,"loc":{"start":{"line":1,"column":73,"index":73},"end":{"line":1,"column":80,"index":80}}
89 }
90 ]
91 },
92 "trailingComments": [
93 {
94 "type": "CommentBlock",
95 "value": " 10 ",
96 "start":93,"end":101,"loc":{"start":{"line":1,"column":93,"index":93},"end":{"line":1,"column":101,"index":101}}
97 }
98 ],
99 "leadingComments": [
100 {
101 "type": "CommentBlock",
102 "value": " 3 ",
103 "start":25,"end":32,"loc":{"start":{"line":1,"column":25,"index":25},"end":{"line":1,"column":32,"index":32}}
104 }
105 ]
106 }
107 ],
108 "leadingComments": [
109 {
110 "type": "CommentBlock",
111 "value": " 2 ",
112 "start":15,"end":22,"loc":{"start":{"line":1,"column":15,"index":15},"end":{"line":1,"column":22,"index":22}}
113 }
114 ]
115 },
116 "extra": {
117 "parenthesized": true,
118 "parenStart": 0
119 },
120 "trailingComments": [
121 {
122 "type": "CommentBlock",
123 "value": " 11 ",
124 "start":104,"end":112,"loc":{"start":{"line":1,"column":104,"index":104},"end":{"line":1,"column":112,"index":112}}
125 }
126 ],
127 "leadingComments": [
128 {
129 "type": "CommentBlock",
130 "value": " 1 ",
131 "start":1,"end":8,"loc":{"start":{"line":1,"column":1,"index":1},"end":{"line":1,"column":8,"index":8}}
132 }
133 ]
134 }
135 }
136 ],
137 "directives": []
138 },
139 "comments": [
140 {
141 "type": "CommentBlock",
142 "value": " 1 ",
143 "start":1,"end":8,"loc":{"start":{"line":1,"column":1,"index":1},"end":{"line":1,"column":8,"index":8}}
144 },
145 {
146 "type": "CommentBlock",
147 "value": " 2 ",
148 "start":15,"end":22,"loc":{"start":{"line":1,"column":15,"index":15},"end":{"line":1,"column":22,"index":22}}
149 },
150 {
151 "type": "CommentBlock",
152 "value": " 3 ",
153 "start":25,"end":32,"loc":{"start":{"line":1,"column":25,"index":25},"end":{"line":1,"column":32,"index":32}}
154 },
155 {
156 "type": "CommentBlock",
157 "value": " 4 ",
158 "start":36,"end":43,"loc":{"start":{"line":1,"column":36,"index":36},"end":{"line":1,"column":43,"index":43}}
159 },
160 {
161 "type": "CommentBlock",
162 "value": " 5 ",
163 "start":45,"end":52,"loc":{"start":{"line":1,"column":45,"index":45},"end":{"line":1,"column":52,"index":52}}
164 },
165 {
166 "type": "CommentBlock",
167 "value": " 6 ",
168 "start":55,"end":62,"loc":{"start":{"line":1,"column":55,"index":55},"end":{"line":1,"column":62,"index":62}}
169 },
170 {
171 "type": "CommentBlock",
172 "value": " 7 ",
173 "start":64,"end":71,"loc":{"start":{"line":1,"column":64,"index":64},"end":{"line":1,"column":71,"index":71}}
174 },
175 {
176 "type": "CommentBlock",
177 "value": " 8 ",
178 "start":73,"end":80,"loc":{"start":{"line":1,"column":73,"index":73},"end":{"line":1,"column":80,"index":80}}
179 },
180 {
181 "type": "CommentBlock",
182 "value": " 9 ",
183 "start":83,"end":90,"loc":{"start":{"line":1,"column":83,"index":83},"end":{"line":1,"column":90,"index":90}}
184 },
185 {
186 "type": "CommentBlock",
187 "value": " 10 ",
188 "start":93,"end":101,"loc":{"start":{"line":1,"column":93,"index":93},"end":{"line":1,"column":101,"index":101}}
189 },
190 {
191 "type": "CommentBlock",
192 "value": " 11 ",
193 "start":104,"end":112,"loc":{"start":{"line":1,"column":104,"index":104},"end":{"line":1,"column":112,"index":112}}
194 }
195 ]
196 }