Debian Codegraph @

packages/babel-parser/test/fixtures/flow/this-annotation/this-not-first/output.json

raw
1 {
2 "type": "File",
3 "start":0,"end":43,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":43,"index":43}},
4 "errors": [
5 "SyntaxError: The `this` parameter must be the first function parameter. (1:26)"
6 ],
7 "program": {
8 "type": "Program",
9 "start":0,"end":43,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":43,"index":43}},
10 "sourceType": "module",
11 "interpreter": null,
12 "body": [
13 {
14 "type": "FunctionDeclaration",
15 "start":0,"end":43,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":43,"index":43}},
16 "id": {
17 "type": "Identifier",
18 "start":9,"end":12,"loc":{"start":{"line":1,"column":9,"index":9},"end":{"line":1,"column":12,"index":12},"identifierName":"foo"},
19 "name": "foo"
20 },
21 "generator": false,
22 "async": false,
23 "params": [
24 {
25 "type": "Identifier",
26 "start":14,"end":24,"loc":{"start":{"line":1,"column":14,"index":14},"end":{"line":1,"column":24,"index":24},"identifierName":"a"},
27 "name": "a",
28 "typeAnnotation": {
29 "type": "TypeAnnotation",
30 "start":16,"end":24,"loc":{"start":{"line":1,"column":16,"index":16},"end":{"line":1,"column":24,"index":24}},
31 "typeAnnotation": {
32 "type": "StringTypeAnnotation",
33 "start":18,"end":24,"loc":{"start":{"line":1,"column":18,"index":18},"end":{"line":1,"column":24,"index":24}}
34 }
35 }
36 },
37 {
38 "type": "Identifier",
39 "start":26,"end":39,"loc":{"start":{"line":1,"column":26,"index":26},"end":{"line":1,"column":39,"index":39},"identifierName":"this"},
40 "name": "this",
41 "typeAnnotation": {
42 "type": "TypeAnnotation",
43 "start":31,"end":39,"loc":{"start":{"line":1,"column":31,"index":31},"end":{"line":1,"column":39,"index":39}},
44 "typeAnnotation": {
45 "type": "NumberTypeAnnotation",
46 "start":33,"end":39,"loc":{"start":{"line":1,"column":33,"index":33},"end":{"line":1,"column":39,"index":39}}
47 }
48 }
49 }
50 ],
51 "body": {
52 "type": "BlockStatement",
53 "start":41,"end":43,"loc":{"start":{"line":1,"column":41,"index":41},"end":{"line":1,"column":43,"index":43}},
54 "body": [],
55 "directives": []
56 }
57 }
58 ],
59 "directives": []
60 }
61 }