Debian Codegraph @

packages/babel-parser/test/fixtures/flow/internal-slot/interface-method/output.json

raw
1 {
2 "type": "File",
3 "start":0,"end":28,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":28,"index":28}},
4 "program": {
5 "type": "Program",
6 "start":0,"end":28,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":28,"index":28}},
7 "sourceType": "module",
8 "interpreter": null,
9 "body": [
10 {
11 "type": "InterfaceDeclaration",
12 "start":0,"end":28,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":28,"index":28}},
13 "id": {
14 "type": "Identifier",
15 "start":10,"end":11,"loc":{"start":{"line":1,"column":10,"index":10},"end":{"line":1,"column":11,"index":11},"identifierName":"T"},
16 "name": "T"
17 },
18 "typeParameters": null,
19 "extends": [],
20 "implements": [],
21 "mixins": [],
22 "body": {
23 "type": "ObjectTypeAnnotation",
24 "start":12,"end":28,"loc":{"start":{"line":1,"column":12,"index":12},"end":{"line":1,"column":28,"index":28}},
25 "callProperties": [],
26 "properties": [],
27 "indexers": [],
28 "internalSlots": [
29 {
30 "type": "ObjectTypeInternalSlot",
31 "start":14,"end":26,"loc":{"start":{"line":1,"column":14,"index":14},"end":{"line":1,"column":26,"index":26}},
32 "static": false,
33 "id": {
34 "type": "Identifier",
35 "start":16,"end":19,"loc":{"start":{"line":1,"column":16,"index":16},"end":{"line":1,"column":19,"index":19},"identifierName":"foo"},
36 "name": "foo"
37 },
38 "method": true,
39 "optional": false,
40 "value": {
41 "type": "FunctionTypeAnnotation",
42 "start":14,"end":26,"loc":{"start":{"line":1,"column":14,"index":14},"end":{"line":1,"column":26,"index":26}},
43 "params": [],
44 "rest": null,
45 "typeParameters": null,
46 "this": null,
47 "returnType": {
48 "type": "GenericTypeAnnotation",
49 "start":25,"end":26,"loc":{"start":{"line":1,"column":25,"index":25},"end":{"line":1,"column":26,"index":26}},
50 "typeParameters": null,
51 "id": {
52 "type": "Identifier",
53 "start":25,"end":26,"loc":{"start":{"line":1,"column":25,"index":25},"end":{"line":1,"column":26,"index":26},"identifierName":"X"},
54 "name": "X"
55 }
56 }
57 }
58 }
59 ],
60 "exact": false
61 }
62 }
63 ],
64 "directives": []
65 }
66 }