@ant-yasa/uast-parser-java-js 0.1.15-beta

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (100) hide show
  1. package/.babelrc +12 -0
  2. package/.eslintignore +1 -0
  3. package/.eslintrc.js +38 -0
  4. package/.mocharc-integration.js +1 -0
  5. package/.mocharc.js +4 -0
  6. package/.prettierignore +1 -0
  7. package/.prettierrc +4 -0
  8. package/LEGAL.md +7 -0
  9. package/README.md +35 -0
  10. package/antlr/Java.g4 +1008 -0
  11. package/antlr/JavaLexer.g4 +241 -0
  12. package/antlr/JavaLexer_origin.g4 +241 -0
  13. package/antlr/JavaParser.g4 +765 -0
  14. package/antlr/JavaParser_origin.g4 +766 -0
  15. package/dist/package.json +73 -0
  16. package/dist/src/frontend/java/ASTBuilder.d.ts +171 -0
  17. package/dist/src/frontend/java/ASTBuilder.js +2369 -0
  18. package/dist/src/frontend/java/ASTBuilder.js.map +1 -0
  19. package/dist/src/frontend/java/ErrorListener.d.ts +9 -0
  20. package/dist/src/frontend/java/ErrorListener.js +24 -0
  21. package/dist/src/frontend/java/ErrorListener.js.map +1 -0
  22. package/dist/src/frontend/java/antlr/JavaLexer.d.ts +154 -0
  23. package/dist/src/frontend/java/antlr/JavaLexer.js +812 -0
  24. package/dist/src/frontend/java/antlr/JavaLexer.js.map +1 -0
  25. package/dist/src/frontend/java/antlr/JavaListener.d.ts +1393 -0
  26. package/dist/src/frontend/java/antlr/JavaListener.js +4 -0
  27. package/dist/src/frontend/java/antlr/JavaListener.js.map +1 -0
  28. package/dist/src/frontend/java/antlr/JavaParser.d.ts +2065 -0
  29. package/dist/src/frontend/java/antlr/JavaParser.js +15279 -0
  30. package/dist/src/frontend/java/antlr/JavaParser.js.map +1 -0
  31. package/dist/src/frontend/java/antlr/JavaVisitor.d.ts +892 -0
  32. package/dist/src/frontend/java/antlr/JavaVisitor.js +4 -0
  33. package/dist/src/frontend/java/antlr/JavaVisitor.js.map +1 -0
  34. package/dist/src/frontend/java/parser.d.ts +20 -0
  35. package/dist/src/frontend/java/parser.js +93 -0
  36. package/dist/src/frontend/java/parser.js.map +1 -0
  37. package/dist/src/frontend/java/testBuilder.d.ts +146 -0
  38. package/dist/src/frontend/java/testBuilder.js +464 -0
  39. package/dist/src/frontend/java/testBuilder.js.map +1 -0
  40. package/dist/src/frontend/java/types.d.ts +29 -0
  41. package/dist/src/frontend/java/types.js +3 -0
  42. package/dist/src/frontend/java/types.js.map +1 -0
  43. package/dist/src/frontend/javascript/parser.d.ts +8 -0
  44. package/dist/src/frontend/javascript/parser.js +1121 -0
  45. package/dist/src/frontend/javascript/parser.js.map +1 -0
  46. package/dist/src/index.d.ts +14 -0
  47. package/dist/src/index.js +76 -0
  48. package/dist/src/index.js.map +1 -0
  49. package/output.txt +3820 -0
  50. package/package.json +73 -0
  51. package/tests/benchmark/base/class.js +32 -0
  52. package/tests/benchmark/base/class.js.json +1809 -0
  53. package/tests/benchmark/base/class_test.js +13 -0
  54. package/tests/benchmark/base/class_test.js.json +435 -0
  55. package/tests/benchmark/base/comment.js +21 -0
  56. package/tests/benchmark/base/comment.js.json +1443 -0
  57. package/tests/benchmark/base/demo.ts +1060 -0
  58. package/tests/benchmark/base/empty.js +4 -0
  59. package/tests/benchmark/base/empty.js.json +202 -0
  60. package/tests/benchmark/base/export.js +36 -0
  61. package/tests/benchmark/base/export.js.json +6345 -0
  62. package/tests/benchmark/base/export1.js +2 -0
  63. package/tests/benchmark/base/export1.js.json +251 -0
  64. package/tests/benchmark/base/export2.js +35 -0
  65. package/tests/benchmark/base/export2.js.json +3297 -0
  66. package/tests/benchmark/base/expressions.js +25 -0
  67. package/tests/benchmark/base/expressions.js.json +1654 -0
  68. package/tests/benchmark/base/for.js +7 -0
  69. package/tests/benchmark/base/for.js.json +738 -0
  70. package/tests/benchmark/base/function.js +15 -0
  71. package/tests/benchmark/base/function.js.json +1458 -0
  72. package/tests/benchmark/base/import.js +3 -0
  73. package/tests/benchmark/base/import.js.json +416 -0
  74. package/tests/benchmark/base/literal.js +27 -0
  75. package/tests/benchmark/base/literal.js.json +1234 -0
  76. package/tests/benchmark/base/param.js +4 -0
  77. package/tests/benchmark/base/param.js.json +410 -0
  78. package/tests/benchmark/base/parseerror.js +1 -0
  79. package/tests/benchmark/base/parseerror.js.json +191 -0
  80. package/tests/benchmark/base/patternlike.js +24 -0
  81. package/tests/benchmark/base/patternlike.js.json +3720 -0
  82. package/tests/benchmark/base/react.js +8 -0
  83. package/tests/benchmark/base/react.js.json +211 -0
  84. package/tests/benchmark/base/switch.js +11 -0
  85. package/tests/benchmark/base/switch.js.json +741 -0
  86. package/tests/benchmark/base/taint.ts +61 -0
  87. package/tests/benchmark/base/temp.js +311 -0
  88. package/tests/benchmark/base/temp.js.json +22170 -0
  89. package/tests/benchmark/base/tmp.js +134 -0
  90. package/tests/benchmark/base/tmp.js.json +15409 -0
  91. package/tests/benchmark/base/vardecl.js +9 -0
  92. package/tests/benchmark/base/vardecl.js.json +491 -0
  93. package/tests/index.js +43 -0
  94. package/tests/index.ts +66 -0
  95. package/tests/test.d.ts +0 -0
  96. package/tests/test.js +38 -0
  97. package/tests/test.ts +60 -0
  98. package/tsconfig.json +24 -0
  99. package/tsconfig.test.json +13 -0
  100. package/webpack.config.js +21 -0
@@ -0,0 +1,1458 @@
1
+ {
2
+ "type": "CompileUnit",
3
+ "body": [
4
+ {
5
+ "type": "FunctionDefinition",
6
+ "id": {
7
+ "type": "Identifier",
8
+ "name": "foo",
9
+ "_meta": {
10
+ "_extra": {
11
+ "start": 9,
12
+ "end": 12
13
+ }
14
+ },
15
+ "loc": {
16
+ "start": {
17
+ "line": 1,
18
+ "column": 10
19
+ },
20
+ "end": {
21
+ "line": 1,
22
+ "column": 13
23
+ }
24
+ }
25
+ },
26
+ "parameters": [],
27
+ "returnType": {
28
+ "type": "DynamicType",
29
+ "id": null,
30
+ "_meta": {},
31
+ "loc": {
32
+ "start": {
33
+ "line": 1,
34
+ "column": 1
35
+ },
36
+ "end": {
37
+ "line": 1,
38
+ "column": 27
39
+ },
40
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
41
+ }
42
+ },
43
+ "body": {
44
+ "type": "ScopedStatement",
45
+ "body": [
46
+ {
47
+ "type": "ScopedStatement",
48
+ "body": [
49
+ {
50
+ "type": "ReturnStatement",
51
+ "argument": {
52
+ "type": "Literal",
53
+ "value": 0,
54
+ "literalType": "number",
55
+ "_meta": {
56
+ "_extra": {
57
+ "start": 23,
58
+ "end": 24
59
+ }
60
+ },
61
+ "loc": {
62
+ "start": {
63
+ "line": 1,
64
+ "column": 24
65
+ },
66
+ "end": {
67
+ "line": 1,
68
+ "column": 25
69
+ },
70
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
71
+ }
72
+ },
73
+ "isYield": false,
74
+ "_meta": {
75
+ "_extra": {
76
+ "start": 16,
77
+ "end": 25
78
+ }
79
+ },
80
+ "loc": {
81
+ "start": {
82
+ "line": 1,
83
+ "column": 17
84
+ },
85
+ "end": {
86
+ "line": 1,
87
+ "column": 26
88
+ },
89
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
90
+ }
91
+ }
92
+ ],
93
+ "id": null,
94
+ "_meta": {
95
+ "_extra": {
96
+ "start": 15,
97
+ "end": 26,
98
+ "directives": []
99
+ }
100
+ },
101
+ "loc": {
102
+ "start": {
103
+ "line": 1,
104
+ "column": 16
105
+ },
106
+ "end": {
107
+ "line": 1,
108
+ "column": 27
109
+ },
110
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
111
+ }
112
+ }
113
+ ],
114
+ "id": null,
115
+ "_meta": {},
116
+ "loc": {
117
+ "start": {
118
+ "line": 1,
119
+ "column": 1
120
+ },
121
+ "end": {
122
+ "line": 1,
123
+ "column": 27
124
+ },
125
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
126
+ }
127
+ },
128
+ "modifiers": [],
129
+ "_meta": {
130
+ "_extra": {
131
+ "end": 26
132
+ }
133
+ },
134
+ "loc": {
135
+ "start": {
136
+ "line": 1,
137
+ "column": 1
138
+ },
139
+ "end": {
140
+ "line": 1,
141
+ "column": 27
142
+ },
143
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
144
+ }
145
+ },
146
+ {
147
+ "type": "ExpressionStatement",
148
+ "expression": {
149
+ "type": "CallExpression",
150
+ "callee": {
151
+ "type": "FunctionDefinition",
152
+ "id": null,
153
+ "parameters": [],
154
+ "returnType": {
155
+ "type": "DynamicType",
156
+ "id": null,
157
+ "_meta": {},
158
+ "loc": {
159
+ "start": {
160
+ "line": 3,
161
+ "column": 2
162
+ },
163
+ "end": {
164
+ "line": 5,
165
+ "column": 2
166
+ },
167
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
168
+ }
169
+ },
170
+ "body": {
171
+ "type": "ScopedStatement",
172
+ "body": [
173
+ {
174
+ "type": "ScopedStatement",
175
+ "body": [
176
+ {
177
+ "type": "ReturnStatement",
178
+ "argument": {
179
+ "type": "Literal",
180
+ "value": 0,
181
+ "literalType": "number",
182
+ "_meta": {
183
+ "_extra": {
184
+ "start": 50,
185
+ "end": 51
186
+ }
187
+ },
188
+ "loc": {
189
+ "start": {
190
+ "line": 4,
191
+ "column": 10
192
+ },
193
+ "end": {
194
+ "line": 4,
195
+ "column": 11
196
+ },
197
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
198
+ }
199
+ },
200
+ "isYield": false,
201
+ "_meta": {
202
+ "_extra": {
203
+ "start": 43,
204
+ "end": 52
205
+ }
206
+ },
207
+ "loc": {
208
+ "start": {
209
+ "line": 4,
210
+ "column": 3
211
+ },
212
+ "end": {
213
+ "line": 4,
214
+ "column": 12
215
+ },
216
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
217
+ }
218
+ }
219
+ ],
220
+ "id": null,
221
+ "_meta": {
222
+ "_extra": {
223
+ "start": 39,
224
+ "end": 54,
225
+ "directives": []
226
+ }
227
+ },
228
+ "loc": {
229
+ "start": {
230
+ "line": 3,
231
+ "column": 12
232
+ },
233
+ "end": {
234
+ "line": 5,
235
+ "column": 2
236
+ },
237
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
238
+ }
239
+ }
240
+ ],
241
+ "id": null,
242
+ "_meta": {},
243
+ "loc": {
244
+ "start": {
245
+ "line": 3,
246
+ "column": 2
247
+ },
248
+ "end": {
249
+ "line": 5,
250
+ "column": 2
251
+ },
252
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
253
+ }
254
+ },
255
+ "modifiers": [],
256
+ "_meta": {
257
+ "_extra": {
258
+ "start": 29,
259
+ "end": 54
260
+ }
261
+ },
262
+ "loc": {
263
+ "start": {
264
+ "line": 3,
265
+ "column": 2
266
+ },
267
+ "end": {
268
+ "line": 5,
269
+ "column": 2
270
+ },
271
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
272
+ }
273
+ },
274
+ "arguments": [],
275
+ "_meta": {
276
+ "_extra": {
277
+ "start": 28,
278
+ "end": 57
279
+ }
280
+ },
281
+ "loc": {
282
+ "start": {
283
+ "line": 3,
284
+ "column": 1
285
+ },
286
+ "end": {
287
+ "line": 5,
288
+ "column": 5
289
+ },
290
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
291
+ }
292
+ },
293
+ "_meta": {
294
+ "_extra": {
295
+ "start": 28,
296
+ "end": 57
297
+ }
298
+ },
299
+ "loc": {
300
+ "start": {
301
+ "line": 3,
302
+ "column": 1
303
+ },
304
+ "end": {
305
+ "line": 5,
306
+ "column": 5
307
+ },
308
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
309
+ }
310
+ },
311
+ {
312
+ "type": "VariableDeclaration",
313
+ "id": {
314
+ "type": "Identifier",
315
+ "name": "bar",
316
+ "_meta": {
317
+ "_extra": {
318
+ "start": 65,
319
+ "end": 68
320
+ }
321
+ },
322
+ "loc": {
323
+ "start": {
324
+ "line": 7,
325
+ "column": 7
326
+ },
327
+ "end": {
328
+ "line": 7,
329
+ "column": 10
330
+ },
331
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
332
+ }
333
+ },
334
+ "init": {
335
+ "type": "FunctionDefinition",
336
+ "id": null,
337
+ "parameters": [],
338
+ "returnType": {
339
+ "type": "DynamicType",
340
+ "id": null,
341
+ "_meta": {},
342
+ "loc": {
343
+ "start": {
344
+ "line": 7,
345
+ "column": 13
346
+ },
347
+ "end": {
348
+ "line": 7,
349
+ "column": 20
350
+ },
351
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
352
+ }
353
+ },
354
+ "body": {
355
+ "type": "ScopedStatement",
356
+ "body": [
357
+ {
358
+ "type": "ScopedStatement",
359
+ "body": [
360
+ {
361
+ "type": "ReturnStatement",
362
+ "argument": {
363
+ "type": "Literal",
364
+ "value": 1,
365
+ "literalType": "number",
366
+ "_meta": {
367
+ "_extra": {
368
+ "start": 77,
369
+ "end": 78
370
+ }
371
+ },
372
+ "loc": {
373
+ "start": {
374
+ "line": 7,
375
+ "column": 19
376
+ },
377
+ "end": {
378
+ "line": 7,
379
+ "column": 20
380
+ },
381
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
382
+ }
383
+ },
384
+ "isYield": false,
385
+ "_meta": {},
386
+ "loc": {
387
+ "start": {
388
+ "line": 7,
389
+ "column": 13
390
+ },
391
+ "end": {
392
+ "line": 7,
393
+ "column": 20
394
+ },
395
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
396
+ }
397
+ }
398
+ ],
399
+ "id": null,
400
+ "_meta": {},
401
+ "loc": {
402
+ "start": {
403
+ "line": 7,
404
+ "column": 13
405
+ },
406
+ "end": {
407
+ "line": 7,
408
+ "column": 20
409
+ },
410
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
411
+ }
412
+ }
413
+ ],
414
+ "id": null,
415
+ "_meta": {},
416
+ "loc": {
417
+ "start": {
418
+ "line": 7,
419
+ "column": 13
420
+ },
421
+ "end": {
422
+ "line": 7,
423
+ "column": 20
424
+ },
425
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
426
+ }
427
+ },
428
+ "modifiers": [],
429
+ "_meta": {
430
+ "_extra": {
431
+ "start": 71,
432
+ "end": 78
433
+ }
434
+ },
435
+ "loc": {
436
+ "start": {
437
+ "line": 7,
438
+ "column": 13
439
+ },
440
+ "end": {
441
+ "line": 7,
442
+ "column": 20
443
+ },
444
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
445
+ }
446
+ },
447
+ "cloned": false,
448
+ "varType": {
449
+ "type": "DynamicType",
450
+ "id": null,
451
+ "_meta": {}
452
+ },
453
+ "_meta": {
454
+ "_extra": {
455
+ "start": 59,
456
+ "end": 79
457
+ }
458
+ },
459
+ "loc": {
460
+ "start": {
461
+ "line": 7,
462
+ "column": 7
463
+ },
464
+ "end": {
465
+ "line": 7,
466
+ "column": 20
467
+ },
468
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
469
+ }
470
+ },
471
+ {
472
+ "type": "FunctionDefinition",
473
+ "id": {
474
+ "type": "Identifier",
475
+ "name": "a1",
476
+ "_meta": {
477
+ "_extra": {
478
+ "start": 90,
479
+ "end": 92
480
+ }
481
+ },
482
+ "loc": {
483
+ "start": {
484
+ "line": 9,
485
+ "column": 10
486
+ },
487
+ "end": {
488
+ "line": 9,
489
+ "column": 12
490
+ }
491
+ }
492
+ },
493
+ "parameters": [
494
+ {
495
+ "type": "VariableDeclaration",
496
+ "id": {
497
+ "type": "Identifier",
498
+ "name": "a",
499
+ "_meta": {
500
+ "_extra": {
501
+ "start": 93,
502
+ "end": 94
503
+ }
504
+ },
505
+ "loc": {
506
+ "start": {
507
+ "line": 9,
508
+ "column": 13
509
+ },
510
+ "end": {
511
+ "line": 9,
512
+ "column": 14
513
+ },
514
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
515
+ }
516
+ },
517
+ "init": null,
518
+ "cloned": false,
519
+ "varType": {
520
+ "type": "DynamicType",
521
+ "id": null,
522
+ "_meta": {}
523
+ },
524
+ "_meta": {},
525
+ "loc": {
526
+ "start": {
527
+ "line": 9,
528
+ "column": 13
529
+ },
530
+ "end": {
531
+ "line": 9,
532
+ "column": 14
533
+ },
534
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
535
+ }
536
+ },
537
+ {
538
+ "type": "VariableDeclaration",
539
+ "id": {
540
+ "type": "Identifier",
541
+ "name": "b",
542
+ "_meta": {
543
+ "_extra": {
544
+ "start": 96,
545
+ "end": 97
546
+ }
547
+ },
548
+ "loc": {
549
+ "start": {
550
+ "line": 9,
551
+ "column": 16
552
+ },
553
+ "end": {
554
+ "line": 9,
555
+ "column": 17
556
+ },
557
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
558
+ }
559
+ },
560
+ "init": null,
561
+ "cloned": false,
562
+ "varType": {
563
+ "type": "DynamicType",
564
+ "id": null,
565
+ "_meta": {}
566
+ },
567
+ "_meta": {},
568
+ "loc": {
569
+ "start": {
570
+ "line": 9,
571
+ "column": 16
572
+ },
573
+ "end": {
574
+ "line": 9,
575
+ "column": 17
576
+ },
577
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
578
+ }
579
+ },
580
+ {
581
+ "type": "VariableDeclaration",
582
+ "id": {
583
+ "type": "Identifier",
584
+ "name": "__tmp0__",
585
+ "_meta": {},
586
+ "loc": {
587
+ "start": {
588
+ "line": 9,
589
+ "column": 19
590
+ },
591
+ "end": {
592
+ "line": 9,
593
+ "column": 23
594
+ },
595
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
596
+ }
597
+ },
598
+ "init": null,
599
+ "cloned": false,
600
+ "varType": {
601
+ "type": "DynamicType",
602
+ "id": null,
603
+ "_meta": {}
604
+ },
605
+ "_meta": {
606
+ "isRestElement": true
607
+ },
608
+ "loc": {
609
+ "start": {
610
+ "line": 9,
611
+ "column": 19
612
+ },
613
+ "end": {
614
+ "line": 9,
615
+ "column": 23
616
+ },
617
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
618
+ }
619
+ }
620
+ ],
621
+ "returnType": {
622
+ "type": "DynamicType",
623
+ "id": null,
624
+ "_meta": {},
625
+ "loc": {
626
+ "start": {
627
+ "line": 9,
628
+ "column": 1
629
+ },
630
+ "end": {
631
+ "line": 11,
632
+ "column": 2
633
+ },
634
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
635
+ }
636
+ },
637
+ "body": {
638
+ "type": "ScopedStatement",
639
+ "body": [
640
+ {
641
+ "type": "AssignmentExpression",
642
+ "left": {
643
+ "type": "Identifier",
644
+ "name": "c",
645
+ "_meta": {
646
+ "_extra": {
647
+ "start": 102,
648
+ "end": 103
649
+ }
650
+ },
651
+ "loc": {
652
+ "start": {
653
+ "line": 9,
654
+ "column": 22
655
+ },
656
+ "end": {
657
+ "line": 9,
658
+ "column": 23
659
+ },
660
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
661
+ }
662
+ },
663
+ "right": {
664
+ "type": "Identifier",
665
+ "name": "__tmp0__",
666
+ "_meta": {},
667
+ "loc": {
668
+ "start": {
669
+ "line": 9,
670
+ "column": 19
671
+ },
672
+ "end": {
673
+ "line": 9,
674
+ "column": 23
675
+ },
676
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
677
+ }
678
+ },
679
+ "operator": "=",
680
+ "cloned": null,
681
+ "_meta": {},
682
+ "loc": {
683
+ "start": {
684
+ "line": 9,
685
+ "column": 1
686
+ },
687
+ "end": {
688
+ "line": 11,
689
+ "column": 2
690
+ },
691
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
692
+ }
693
+ },
694
+ {
695
+ "type": "ScopedStatement",
696
+ "body": [
697
+ {
698
+ "type": "ReturnStatement",
699
+ "argument": {
700
+ "type": "ObjectExpression",
701
+ "properties": [
702
+ {
703
+ "type": "ObjectProperty",
704
+ "key": {
705
+ "type": "Literal",
706
+ "value": 0,
707
+ "literalType": "number",
708
+ "_meta": {},
709
+ "loc": {
710
+ "start": {
711
+ "line": 10,
712
+ "column": 10
713
+ },
714
+ "end": {
715
+ "line": 10,
716
+ "column": 19
717
+ },
718
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
719
+ }
720
+ },
721
+ "value": {
722
+ "type": "Identifier",
723
+ "name": "a",
724
+ "_meta": {
725
+ "_extra": {
726
+ "start": 117,
727
+ "end": 118
728
+ }
729
+ },
730
+ "loc": {
731
+ "start": {
732
+ "line": 10,
733
+ "column": 11
734
+ },
735
+ "end": {
736
+ "line": 10,
737
+ "column": 12
738
+ },
739
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
740
+ }
741
+ },
742
+ "_meta": {},
743
+ "loc": {
744
+ "start": {
745
+ "line": 10,
746
+ "column": 10
747
+ },
748
+ "end": {
749
+ "line": 10,
750
+ "column": 19
751
+ },
752
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
753
+ }
754
+ },
755
+ {
756
+ "type": "ObjectProperty",
757
+ "key": {
758
+ "type": "Literal",
759
+ "value": 1,
760
+ "literalType": "number",
761
+ "_meta": {},
762
+ "loc": {
763
+ "start": {
764
+ "line": 10,
765
+ "column": 10
766
+ },
767
+ "end": {
768
+ "line": 10,
769
+ "column": 19
770
+ },
771
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
772
+ }
773
+ },
774
+ "value": {
775
+ "type": "Identifier",
776
+ "name": "b",
777
+ "_meta": {
778
+ "_extra": {
779
+ "start": 120,
780
+ "end": 121
781
+ }
782
+ },
783
+ "loc": {
784
+ "start": {
785
+ "line": 10,
786
+ "column": 14
787
+ },
788
+ "end": {
789
+ "line": 10,
790
+ "column": 15
791
+ },
792
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
793
+ }
794
+ },
795
+ "_meta": {},
796
+ "loc": {
797
+ "start": {
798
+ "line": 10,
799
+ "column": 10
800
+ },
801
+ "end": {
802
+ "line": 10,
803
+ "column": 19
804
+ },
805
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
806
+ }
807
+ },
808
+ {
809
+ "type": "ObjectProperty",
810
+ "key": {
811
+ "type": "Literal",
812
+ "value": 2,
813
+ "literalType": "number",
814
+ "_meta": {},
815
+ "loc": {
816
+ "start": {
817
+ "line": 10,
818
+ "column": 10
819
+ },
820
+ "end": {
821
+ "line": 10,
822
+ "column": 19
823
+ },
824
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
825
+ }
826
+ },
827
+ "value": {
828
+ "type": "Identifier",
829
+ "name": "c",
830
+ "_meta": {
831
+ "_extra": {
832
+ "start": 123,
833
+ "end": 124
834
+ }
835
+ },
836
+ "loc": {
837
+ "start": {
838
+ "line": 10,
839
+ "column": 17
840
+ },
841
+ "end": {
842
+ "line": 10,
843
+ "column": 18
844
+ },
845
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
846
+ }
847
+ },
848
+ "_meta": {},
849
+ "loc": {
850
+ "start": {
851
+ "line": 10,
852
+ "column": 10
853
+ },
854
+ "end": {
855
+ "line": 10,
856
+ "column": 19
857
+ },
858
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
859
+ }
860
+ }
861
+ ],
862
+ "id": null,
863
+ "_meta": {
864
+ "isArray": true,
865
+ "_extra": {
866
+ "start": 116,
867
+ "end": 125
868
+ }
869
+ },
870
+ "loc": {
871
+ "start": {
872
+ "line": 10,
873
+ "column": 10
874
+ },
875
+ "end": {
876
+ "line": 10,
877
+ "column": 19
878
+ },
879
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
880
+ }
881
+ },
882
+ "isYield": false,
883
+ "_meta": {
884
+ "_extra": {
885
+ "start": 109,
886
+ "end": 126
887
+ }
888
+ },
889
+ "loc": {
890
+ "start": {
891
+ "line": 10,
892
+ "column": 3
893
+ },
894
+ "end": {
895
+ "line": 10,
896
+ "column": 20
897
+ },
898
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
899
+ }
900
+ }
901
+ ],
902
+ "id": null,
903
+ "_meta": {
904
+ "_extra": {
905
+ "start": 105,
906
+ "end": 128,
907
+ "directives": []
908
+ }
909
+ },
910
+ "loc": {
911
+ "start": {
912
+ "line": 9,
913
+ "column": 25
914
+ },
915
+ "end": {
916
+ "line": 11,
917
+ "column": 2
918
+ },
919
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
920
+ }
921
+ }
922
+ ],
923
+ "id": null,
924
+ "_meta": {},
925
+ "loc": {
926
+ "start": {
927
+ "line": 9,
928
+ "column": 1
929
+ },
930
+ "end": {
931
+ "line": 11,
932
+ "column": 2
933
+ },
934
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
935
+ }
936
+ },
937
+ "modifiers": [],
938
+ "_meta": {
939
+ "_extra": {
940
+ "start": 81,
941
+ "end": 128
942
+ }
943
+ },
944
+ "loc": {
945
+ "start": {
946
+ "line": 9,
947
+ "column": 1
948
+ },
949
+ "end": {
950
+ "line": 11,
951
+ "column": 2
952
+ },
953
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
954
+ }
955
+ },
956
+ {
957
+ "type": "FunctionDefinition",
958
+ "id": {
959
+ "type": "Identifier",
960
+ "name": "a2",
961
+ "_meta": {
962
+ "_extra": {
963
+ "start": 139,
964
+ "end": 141
965
+ }
966
+ },
967
+ "loc": {
968
+ "start": {
969
+ "line": 13,
970
+ "column": 10
971
+ },
972
+ "end": {
973
+ "line": 13,
974
+ "column": 12
975
+ }
976
+ }
977
+ },
978
+ "parameters": [
979
+ {
980
+ "type": "VariableDeclaration",
981
+ "id": {
982
+ "type": "Identifier",
983
+ "name": "__tmp1__",
984
+ "_meta": {},
985
+ "loc": {
986
+ "start": {
987
+ "line": 13,
988
+ "column": 13
989
+ },
990
+ "end": {
991
+ "line": 13,
992
+ "column": 27
993
+ },
994
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
995
+ }
996
+ },
997
+ "init": null,
998
+ "cloned": false,
999
+ "varType": {
1000
+ "type": "DynamicType",
1001
+ "id": null,
1002
+ "_meta": {}
1003
+ },
1004
+ "_meta": {},
1005
+ "loc": {
1006
+ "start": {
1007
+ "line": 13,
1008
+ "column": 13
1009
+ },
1010
+ "end": {
1011
+ "line": 13,
1012
+ "column": 27
1013
+ },
1014
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1015
+ }
1016
+ }
1017
+ ],
1018
+ "returnType": {
1019
+ "type": "DynamicType",
1020
+ "id": null,
1021
+ "_meta": {},
1022
+ "loc": {
1023
+ "start": {
1024
+ "line": 13,
1025
+ "column": 1
1026
+ },
1027
+ "end": {
1028
+ "line": 15,
1029
+ "column": 2
1030
+ },
1031
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1032
+ }
1033
+ },
1034
+ "body": {
1035
+ "type": "ScopedStatement",
1036
+ "body": [
1037
+ {
1038
+ "type": "VariableDeclaration",
1039
+ "id": {
1040
+ "type": "Identifier",
1041
+ "name": "a1",
1042
+ "_meta": {
1043
+ "_extra": {
1044
+ "start": 146,
1045
+ "end": 148
1046
+ }
1047
+ },
1048
+ "loc": {
1049
+ "start": {
1050
+ "line": 13,
1051
+ "column": 17
1052
+ },
1053
+ "end": {
1054
+ "line": 13,
1055
+ "column": 19
1056
+ },
1057
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1058
+ }
1059
+ },
1060
+ "init": {
1061
+ "type": "MemberAccess",
1062
+ "object": {
1063
+ "type": "Identifier",
1064
+ "name": "__tmp1__",
1065
+ "_meta": {},
1066
+ "loc": {
1067
+ "start": {
1068
+ "line": 13,
1069
+ "column": 13
1070
+ },
1071
+ "end": {
1072
+ "line": 13,
1073
+ "column": 27
1074
+ },
1075
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1076
+ }
1077
+ },
1078
+ "property": {
1079
+ "type": "Identifier",
1080
+ "name": "a",
1081
+ "_meta": {
1082
+ "_extra": {
1083
+ "start": 144,
1084
+ "end": 145
1085
+ }
1086
+ },
1087
+ "loc": {
1088
+ "start": {
1089
+ "line": 13,
1090
+ "column": 15
1091
+ },
1092
+ "end": {
1093
+ "line": 13,
1094
+ "column": 16
1095
+ },
1096
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1097
+ }
1098
+ },
1099
+ "computed": false,
1100
+ "_meta": {},
1101
+ "loc": {
1102
+ "start": {
1103
+ "line": 13,
1104
+ "column": 1
1105
+ },
1106
+ "end": {
1107
+ "line": 15,
1108
+ "column": 2
1109
+ },
1110
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1111
+ }
1112
+ },
1113
+ "cloned": false,
1114
+ "varType": {
1115
+ "type": "DynamicType",
1116
+ "id": null,
1117
+ "_meta": {}
1118
+ },
1119
+ "_meta": {},
1120
+ "loc": {
1121
+ "start": {
1122
+ "line": 13,
1123
+ "column": 1
1124
+ },
1125
+ "end": {
1126
+ "line": 15,
1127
+ "column": 2
1128
+ },
1129
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1130
+ }
1131
+ },
1132
+ {
1133
+ "type": "VariableDeclaration",
1134
+ "id": {
1135
+ "type": "Identifier",
1136
+ "name": "b2",
1137
+ "_meta": {
1138
+ "_extra": {
1139
+ "start": 152,
1140
+ "end": 154
1141
+ }
1142
+ },
1143
+ "loc": {
1144
+ "start": {
1145
+ "line": 13,
1146
+ "column": 23
1147
+ },
1148
+ "end": {
1149
+ "line": 13,
1150
+ "column": 25
1151
+ },
1152
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1153
+ }
1154
+ },
1155
+ "init": {
1156
+ "type": "MemberAccess",
1157
+ "object": {
1158
+ "type": "Identifier",
1159
+ "name": "__tmp1__",
1160
+ "_meta": {},
1161
+ "loc": {
1162
+ "start": {
1163
+ "line": 13,
1164
+ "column": 13
1165
+ },
1166
+ "end": {
1167
+ "line": 13,
1168
+ "column": 27
1169
+ },
1170
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1171
+ }
1172
+ },
1173
+ "property": {
1174
+ "type": "Identifier",
1175
+ "name": "b",
1176
+ "_meta": {
1177
+ "_extra": {
1178
+ "start": 150,
1179
+ "end": 151
1180
+ }
1181
+ },
1182
+ "loc": {
1183
+ "start": {
1184
+ "line": 13,
1185
+ "column": 21
1186
+ },
1187
+ "end": {
1188
+ "line": 13,
1189
+ "column": 22
1190
+ },
1191
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1192
+ }
1193
+ },
1194
+ "computed": false,
1195
+ "_meta": {},
1196
+ "loc": {
1197
+ "start": {
1198
+ "line": 13,
1199
+ "column": 1
1200
+ },
1201
+ "end": {
1202
+ "line": 15,
1203
+ "column": 2
1204
+ },
1205
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1206
+ }
1207
+ },
1208
+ "cloned": false,
1209
+ "varType": {
1210
+ "type": "DynamicType",
1211
+ "id": null,
1212
+ "_meta": {}
1213
+ },
1214
+ "_meta": {},
1215
+ "loc": {
1216
+ "start": {
1217
+ "line": 13,
1218
+ "column": 1
1219
+ },
1220
+ "end": {
1221
+ "line": 15,
1222
+ "column": 2
1223
+ },
1224
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1225
+ }
1226
+ },
1227
+ {
1228
+ "type": "ScopedStatement",
1229
+ "body": [
1230
+ {
1231
+ "type": "ReturnStatement",
1232
+ "argument": {
1233
+ "type": "ObjectExpression",
1234
+ "properties": [
1235
+ {
1236
+ "type": "ObjectProperty",
1237
+ "key": {
1238
+ "type": "Literal",
1239
+ "value": 0,
1240
+ "literalType": "number",
1241
+ "_meta": {},
1242
+ "loc": {
1243
+ "start": {
1244
+ "line": 14,
1245
+ "column": 10
1246
+ },
1247
+ "end": {
1248
+ "line": 14,
1249
+ "column": 18
1250
+ },
1251
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1252
+ }
1253
+ },
1254
+ "value": {
1255
+ "type": "Identifier",
1256
+ "name": "a1",
1257
+ "_meta": {
1258
+ "_extra": {
1259
+ "start": 170,
1260
+ "end": 172
1261
+ }
1262
+ },
1263
+ "loc": {
1264
+ "start": {
1265
+ "line": 14,
1266
+ "column": 11
1267
+ },
1268
+ "end": {
1269
+ "line": 14,
1270
+ "column": 13
1271
+ },
1272
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1273
+ }
1274
+ },
1275
+ "_meta": {},
1276
+ "loc": {
1277
+ "start": {
1278
+ "line": 14,
1279
+ "column": 10
1280
+ },
1281
+ "end": {
1282
+ "line": 14,
1283
+ "column": 18
1284
+ },
1285
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1286
+ }
1287
+ },
1288
+ {
1289
+ "type": "ObjectProperty",
1290
+ "key": {
1291
+ "type": "Literal",
1292
+ "value": 1,
1293
+ "literalType": "number",
1294
+ "_meta": {},
1295
+ "loc": {
1296
+ "start": {
1297
+ "line": 14,
1298
+ "column": 10
1299
+ },
1300
+ "end": {
1301
+ "line": 14,
1302
+ "column": 18
1303
+ },
1304
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1305
+ }
1306
+ },
1307
+ "value": {
1308
+ "type": "Identifier",
1309
+ "name": "b2",
1310
+ "_meta": {
1311
+ "_extra": {
1312
+ "start": 174,
1313
+ "end": 176
1314
+ }
1315
+ },
1316
+ "loc": {
1317
+ "start": {
1318
+ "line": 14,
1319
+ "column": 15
1320
+ },
1321
+ "end": {
1322
+ "line": 14,
1323
+ "column": 17
1324
+ },
1325
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1326
+ }
1327
+ },
1328
+ "_meta": {},
1329
+ "loc": {
1330
+ "start": {
1331
+ "line": 14,
1332
+ "column": 10
1333
+ },
1334
+ "end": {
1335
+ "line": 14,
1336
+ "column": 18
1337
+ },
1338
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1339
+ }
1340
+ }
1341
+ ],
1342
+ "id": null,
1343
+ "_meta": {
1344
+ "isArray": true,
1345
+ "_extra": {
1346
+ "start": 169,
1347
+ "end": 177
1348
+ }
1349
+ },
1350
+ "loc": {
1351
+ "start": {
1352
+ "line": 14,
1353
+ "column": 10
1354
+ },
1355
+ "end": {
1356
+ "line": 14,
1357
+ "column": 18
1358
+ },
1359
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1360
+ }
1361
+ },
1362
+ "isYield": false,
1363
+ "_meta": {
1364
+ "_extra": {
1365
+ "start": 162,
1366
+ "end": 178
1367
+ }
1368
+ },
1369
+ "loc": {
1370
+ "start": {
1371
+ "line": 14,
1372
+ "column": 3
1373
+ },
1374
+ "end": {
1375
+ "line": 14,
1376
+ "column": 19
1377
+ },
1378
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1379
+ }
1380
+ }
1381
+ ],
1382
+ "id": null,
1383
+ "_meta": {
1384
+ "_extra": {
1385
+ "start": 158,
1386
+ "end": 180,
1387
+ "directives": []
1388
+ }
1389
+ },
1390
+ "loc": {
1391
+ "start": {
1392
+ "line": 13,
1393
+ "column": 29
1394
+ },
1395
+ "end": {
1396
+ "line": 15,
1397
+ "column": 2
1398
+ },
1399
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1400
+ }
1401
+ }
1402
+ ],
1403
+ "id": null,
1404
+ "_meta": {},
1405
+ "loc": {
1406
+ "start": {
1407
+ "line": 13,
1408
+ "column": 1
1409
+ },
1410
+ "end": {
1411
+ "line": 15,
1412
+ "column": 2
1413
+ },
1414
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1415
+ }
1416
+ },
1417
+ "modifiers": [],
1418
+ "_meta": {
1419
+ "_extra": {
1420
+ "start": 130,
1421
+ "end": 180
1422
+ }
1423
+ },
1424
+ "loc": {
1425
+ "start": {
1426
+ "line": 13,
1427
+ "column": 1
1428
+ },
1429
+ "end": {
1430
+ "line": 15,
1431
+ "column": 2
1432
+ },
1433
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1434
+ }
1435
+ }
1436
+ ],
1437
+ "language": "javascript",
1438
+ "languageVersion": null,
1439
+ "uri": "",
1440
+ "version": "0.1.63",
1441
+ "_meta": {
1442
+ "_extra": {
1443
+ "end": 181,
1444
+ "directives": []
1445
+ }
1446
+ },
1447
+ "loc": {
1448
+ "start": {
1449
+ "line": 1,
1450
+ "column": 1
1451
+ },
1452
+ "end": {
1453
+ "line": 16,
1454
+ "column": 1
1455
+ },
1456
+ "sourcefile": "/Users/jiufo/yasaaaaa/uastparser_js/tests/benchmark/base/function.js"
1457
+ }
1458
+ }