Files

84 lines
3.3 KiB
JSON

{
"type": "File",
"start":0,"end":55,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":3,"column":1,"index":55}},
"errors": [
"SyntaxError: Constructors cannot have a `this` parameter; constructors don't bind `this` like other functions. (2:16)"
],
"program": {
"type": "Program",
"start":0,"end":55,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":3,"column":1,"index":55}},
"sourceType": "module",
"interpreter": null,
"body": [
{
"type": "DeclareClass",
"start":0,"end":55,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":3,"column":1,"index":55}},
"id": {
"type": "Identifier",
"start":14,"end":15,"loc":{"start":{"line":1,"column":14,"index":14},"end":{"line":1,"column":15,"index":15},"identifierName":"A"},
"name": "A"
},
"typeParameters": null,
"extends": [],
"implements": [],
"mixins": [],
"body": {
"type": "ObjectTypeAnnotation",
"start":16,"end":55,"loc":{"start":{"line":1,"column":16,"index":16},"end":{"line":3,"column":1,"index":55}},
"callProperties": [],
"properties": [
{
"type": "ObjectTypeProperty",
"start":22,"end":52,"loc":{"start":{"line":2,"column":4,"index":22},"end":{"line":2,"column":34,"index":52}},
"key": {
"type": "Identifier",
"start":22,"end":33,"loc":{"start":{"line":2,"column":4,"index":22},"end":{"line":2,"column":15,"index":33},"identifierName":"constructor"},
"name": "constructor"
},
"static": false,
"proto": false,
"kind": "init",
"method": true,
"value": {
"type": "FunctionTypeAnnotation",
"start":22,"end":52,"loc":{"start":{"line":2,"column":4,"index":22},"end":{"line":2,"column":34,"index":52}},
"params": [],
"rest": null,
"typeParameters": null,
"this": {
"type": "FunctionTypeParam",
"start":34,"end":47,"loc":{"start":{"line":2,"column":16,"index":34},"end":{"line":2,"column":29,"index":47}},
"name": null,
"optional": false,
"typeAnnotation": {
"type": "NumberTypeAnnotation",
"start":41,"end":47,"loc":{"start":{"line":2,"column":23,"index":41},"end":{"line":2,"column":29,"index":47}}
}
},
"returnType": {
"type": "GenericTypeAnnotation",
"start":51,"end":52,"loc":{"start":{"line":2,"column":33,"index":51},"end":{"line":2,"column":34,"index":52}},
"typeParameters": null,
"id": {
"type": "Identifier",
"start":51,"end":52,"loc":{"start":{"line":2,"column":33,"index":51},"end":{"line":2,"column":34,"index":52},"identifierName":"A"},
"name": "A"
}
}
},
"optional": false
}
],
"indexers": [],
"internalSlots": [],
"exact": false
}
}
],
"directives": [],
"extra": {
"topLevelAwait": false
}
}
}