Debian Codegraph @

tests/fixtures/ecma-version/6/blockBindings/let-in-switchcase.result.js

raw
1 export default {
2 "type": "Program",
3 "loc": {
4 "start": {
5 "line": 1,
6 "column": 0
7 },
8 "end": {
9 "line": 1,
10 "column": 47
11 }
12 },
13 "range": [
14 0,
15 47
16 ],
17 "body": [
18 {
19 "type": "SwitchStatement",
20 "loc": {
21 "start": {
22 "line": 1,
23 "column": 0
24 },
25 "end": {
26 "line": 1,
27 "column": 47
28 }
29 },
30 "range": [
31 0,
32 47
33 ],
34 "discriminant": {
35 "type": "Identifier",
36 "loc": {
37 "start": {
38 "line": 1,
39 "column": 8
40 },
41 "end": {
42 "line": 1,
43 "column": 14
44 }
45 },
46 "range": [
47 8,
48 14
49 ],
50 "name": "answer"
51 },
52 "cases": [
53 {
54 "type": "SwitchCase",
55 "loc": {
56 "start": {
57 "line": 1,
58 "column": 18
59 },
60 "end": {
61 "line": 1,
62 "column": 45
63 }
64 },
65 "range": [
66 18,
67 45
68 ],
69 "consequent": [
70 {
71 "type": "VariableDeclaration",
72 "loc": {
73 "start": {
74 "line": 1,
75 "column": 27
76 },
77 "end": {
78 "line": 1,
79 "column": 38
80 }
81 },
82 "range": [
83 27,
84 38
85 ],
86 "declarations": [
87 {
88 "type": "VariableDeclarator",
89 "loc": {
90 "start": {
91 "line": 1,
92 "column": 31
93 },
94 "end": {
95 "line": 1,
96 "column": 37
97 }
98 },
99 "range": [
100 31,
101 37
102 ],
103 "id": {
104 "type": "Identifier",
105 "loc": {
106 "start": {
107 "line": 1,
108 "column": 31
109 },
110 "end": {
111 "line": 1,
112 "column": 32
113 }
114 },
115 "range": [
116 31,
117 32
118 ],
119 "name": "t"
120 },
121 "init": {
122 "type": "Literal",
123 "loc": {
124 "start": {
125 "line": 1,
126 "column": 35
127 },
128 "end": {
129 "line": 1,
130 "column": 37
131 }
132 },
133 "range": [
134 35,
135 37
136 ],
137 "value": 42,
138 "raw": "42"
139 }
140 }
141 ],
142 "kind": "let"
143 },
144 {
145 "type": "BreakStatement",
146 "loc": {
147 "start": {
148 "line": 1,
149 "column": 39
150 },
151 "end": {
152 "line": 1,
153 "column": 45
154 }
155 },
156 "range": [
157 39,
158 45
159 ],
160 "label": null
161 }
162 ],
163 "test": {
164 "type": "Literal",
165 "loc": {
166 "start": {
167 "line": 1,
168 "column": 23
169 },
170 "end": {
171 "line": 1,
172 "column": 25
173 }
174 },
175 "range": [
176 23,
177 25
178 ],
179 "value": 42,
180 "raw": "42"
181 }
182 }
183 ]
184 }
185 ],
186 "sourceType": "script",
187 "tokens": [
188 {
189 "type": "Keyword",
190 "value": "switch",
191 "loc": {
192 "start": {
193 "line": 1,
194 "column": 0
195 },
196 "end": {
197 "line": 1,
198 "column": 6
199 }
200 },
201 "range": [
202 0,
203 6
204 ]
205 },
206 {
207 "type": "Punctuator",
208 "value": "(",
209 "loc": {
210 "start": {
211 "line": 1,
212 "column": 7
213 },
214 "end": {
215 "line": 1,
216 "column": 8
217 }
218 },
219 "range": [
220 7,
221 8
222 ]
223 },
224 {
225 "type": "Identifier",
226 "value": "answer",
227 "loc": {
228 "start": {
229 "line": 1,
230 "column": 8
231 },
232 "end": {
233 "line": 1,
234 "column": 14
235 }
236 },
237 "range": [
238 8,
239 14
240 ]
241 },
242 {
243 "type": "Punctuator",
244 "value": ")",
245 "loc": {
246 "start": {
247 "line": 1,
248 "column": 14
249 },
250 "end": {
251 "line": 1,
252 "column": 15
253 }
254 },
255 "range": [
256 14,
257 15
258 ]
259 },
260 {
261 "type": "Punctuator",
262 "value": "{",
263 "loc": {
264 "start": {
265 "line": 1,
266 "column": 16
267 },
268 "end": {
269 "line": 1,
270 "column": 17
271 }
272 },
273 "range": [
274 16,
275 17
276 ]
277 },
278 {
279 "type": "Keyword",
280 "value": "case",
281 "loc": {
282 "start": {
283 "line": 1,
284 "column": 18
285 },
286 "end": {
287 "line": 1,
288 "column": 22
289 }
290 },
291 "range": [
292 18,
293 22
294 ]
295 },
296 {
297 "type": "Numeric",
298 "value": "42",
299 "loc": {
300 "start": {
301 "line": 1,
302 "column": 23
303 },
304 "end": {
305 "line": 1,
306 "column": 25
307 }
308 },
309 "range": [
310 23,
311 25
312 ]
313 },
314 {
315 "type": "Punctuator",
316 "value": ":",
317 "loc": {
318 "start": {
319 "line": 1,
320 "column": 25
321 },
322 "end": {
323 "line": 1,
324 "column": 26
325 }
326 },
327 "range": [
328 25,
329 26
330 ]
331 },
332 {
333 "type": "Keyword",
334 "value": "let",
335 "loc": {
336 "start": {
337 "line": 1,
338 "column": 27
339 },
340 "end": {
341 "line": 1,
342 "column": 30
343 }
344 },
345 "range": [
346 27,
347 30
348 ]
349 },
350 {
351 "type": "Identifier",
352 "value": "t",
353 "loc": {
354 "start": {
355 "line": 1,
356 "column": 31
357 },
358 "end": {
359 "line": 1,
360 "column": 32
361 }
362 },
363 "range": [
364 31,
365 32
366 ]
367 },
368 {
369 "type": "Punctuator",
370 "value": "=",
371 "loc": {
372 "start": {
373 "line": 1,
374 "column": 33
375 },
376 "end": {
377 "line": 1,
378 "column": 34
379 }
380 },
381 "range": [
382 33,
383 34
384 ]
385 },
386 {
387 "type": "Numeric",
388 "value": "42",
389 "loc": {
390 "start": {
391 "line": 1,
392 "column": 35
393 },
394 "end": {
395 "line": 1,
396 "column": 37
397 }
398 },
399 "range": [
400 35,
401 37
402 ]
403 },
404 {
405 "type": "Punctuator",
406 "value": ";",
407 "loc": {
408 "start": {
409 "line": 1,
410 "column": 37
411 },
412 "end": {
413 "line": 1,
414 "column": 38
415 }
416 },
417 "range": [
418 37,
419 38
420 ]
421 },
422 {
423 "type": "Keyword",
424 "value": "break",
425 "loc": {
426 "start": {
427 "line": 1,
428 "column": 39
429 },
430 "end": {
431 "line": 1,
432 "column": 44
433 }
434 },
435 "range": [
436 39,
437 44
438 ]
439 },
440 {
441 "type": "Punctuator",
442 "value": ";",
443 "loc": {
444 "start": {
445 "line": 1,
446 "column": 44
447 },
448 "end": {
449 "line": 1,
450 "column": 45
451 }
452 },
453 "range": [
454 44,
455 45
456 ]
457 },
458 {
459 "type": "Punctuator",
460 "value": "}",
461 "loc": {
462 "start": {
463 "line": 1,
464 "column": 46
465 },
466 "end": {
467 "line": 1,
468 "column": 47
469 }
470 },
471 "range": [
472 46,
473 47
474 ]
475 }
476 ]
477 };