Debian Codegraph @

packages/babel-parser/test/fixtures/es2022/class-static-block/invalid-yield/output.json

raw
1 {
2 "type": "File",
3 "start":0,"end":90,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":8,"column":1,"index":90}},
4 "errors": [
5 "SyntaxError: Unexpected reserved word 'yield'. (5:6)",
6 "SyntaxError: Missing semicolon. (5:11)"
7 ],
8 "program": {
9 "type": "Program",
10 "start":0,"end":90,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":8,"column":1,"index":90}},
11 "sourceType": "script",
12 "interpreter": null,
13 "body": [
14 {
15 "type": "FunctionDeclaration",
16 "start":0,"end":90,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":8,"column":1,"index":90}},
17 "id": {
18 "type": "Identifier",
19 "start":10,"end":13,"loc":{"start":{"line":1,"column":10,"index":10},"end":{"line":1,"column":13,"index":13},"identifierName":"foo"},
20 "name": "foo"
21 },
22 "generator": true,
23 "async": false,
24 "params": [],
25 "body": {
26 "type": "BlockStatement",
27 "start":16,"end":90,"loc":{"start":{"line":1,"column":16,"index":16},"end":{"line":8,"column":1,"index":90}},
28 "body": [
29 {
30 "type": "ClassDeclaration",
31 "start":20,"end":88,"loc":{"start":{"line":2,"column":2,"index":20},"end":{"line":7,"column":3,"index":88}},
32 "id": {
33 "type": "Identifier",
34 "start":26,"end":27,"loc":{"start":{"line":2,"column":8,"index":26},"end":{"line":2,"column":9,"index":27},"identifierName":"C"},
35 "name": "C"
36 },
37 "superClass": null,
38 "body": {
39 "type": "ClassBody",
40 "start":28,"end":88,"loc":{"start":{"line":2,"column":10,"index":28},"end":{"line":7,"column":3,"index":88}},
41 "body": [
42 {
43 "type": "ClassMethod",
44 "start":34,"end":49,"loc":{"start":{"line":3,"column":4,"index":34},"end":{"line":3,"column":19,"index":49}},
45 "static": true,
46 "key": {
47 "type": "Identifier",
48 "start":41,"end":44,"loc":{"start":{"line":3,"column":11,"index":41},"end":{"line":3,"column":14,"index":44},"identifierName":"foo"},
49 "name": "foo"
50 },
51 "computed": false,
52 "kind": "method",
53 "id": null,
54 "generator": false,
55 "async": false,
56 "params": [],
57 "body": {
58 "type": "BlockStatement",
59 "start":47,"end":49,"loc":{"start":{"line":3,"column":17,"index":47},"end":{"line":3,"column":19,"index":49}},
60 "body": [],
61 "directives": []
62 }
63 },
64 {
65 "type": "StaticBlock",
66 "start":54,"end":84,"loc":{"start":{"line":4,"column":4,"index":54},"end":{"line":6,"column":5,"index":84}},
67 "body": [
68 {
69 "type": "ExpressionStatement",
70 "start":69,"end":74,"loc":{"start":{"line":5,"column":6,"index":69},"end":{"line":5,"column":11,"index":74}},
71 "expression": {
72 "type": "Identifier",
73 "start":69,"end":74,"loc":{"start":{"line":5,"column":6,"index":69},"end":{"line":5,"column":11,"index":74},"identifierName":"yield"},
74 "name": "yield"
75 }
76 },
77 {
78 "type": "ExpressionStatement",
79 "start":75,"end":78,"loc":{"start":{"line":5,"column":12,"index":75},"end":{"line":5,"column":15,"index":78}},
80 "expression": {
81 "type": "NumericLiteral",
82 "start":75,"end":77,"loc":{"start":{"line":5,"column":12,"index":75},"end":{"line":5,"column":14,"index":77}},
83 "extra": {
84 "rawValue": 42,
85 "raw": "42"
86 },
87 "value": 42
88 }
89 }
90 ]
91 }
92 ]
93 }
94 }
95 ],
96 "directives": []
97 }
98 }
99 ],
100 "directives": []
101 }
102 }