Debian Codegraph @

packages/babel-parser/test/fixtures/es2015/yield/parameter-default-inside-generator/output.json

raw
1 {
2 "type": "File",
3 "start":0,"end":26,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":26,"index":26}},
4 "errors": [
5 "SyntaxError: Yield expression is not allowed in formal parameters. (1:17)"
6 ],
7 "program": {
8 "type": "Program",
9 "start":0,"end":26,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":26,"index":26}},
10 "sourceType": "script",
11 "interpreter": null,
12 "body": [
13 {
14 "type": "FunctionDeclaration",
15 "start":0,"end":26,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":26,"index":26}},
16 "id": {
17 "type": "Identifier",
18 "start":10,"end":12,"loc":{"start":{"line":1,"column":10,"index":10},"end":{"line":1,"column":12,"index":12},"identifierName":"fn"},
19 "name": "fn"
20 },
21 "generator": true,
22 "async": false,
23 "params": [
24 {
25 "type": "AssignmentPattern",
26 "start":13,"end":22,"loc":{"start":{"line":1,"column":13,"index":13},"end":{"line":1,"column":22,"index":22}},
27 "left": {
28 "type": "Identifier",
29 "start":13,"end":14,"loc":{"start":{"line":1,"column":13,"index":13},"end":{"line":1,"column":14,"index":14},"identifierName":"x"},
30 "name": "x"
31 },
32 "right": {
33 "type": "YieldExpression",
34 "start":17,"end":22,"loc":{"start":{"line":1,"column":17,"index":17},"end":{"line":1,"column":22,"index":22}},
35 "delegate": false,
36 "argument": null
37 }
38 }
39 ],
40 "body": {
41 "type": "BlockStatement",
42 "start":24,"end":26,"loc":{"start":{"line":1,"column":24,"index":24},"end":{"line":1,"column":26,"index":26}},
43 "body": [],
44 "directives": []
45 }
46 }
47 ],
48 "directives": []
49 }
50 }