{ "type": "Program", "statements": [ { "type": "TSDeclareFunction", "function": { "type": "ScriptFunction", "id": { "type": "Identifier", "name": "someCondition", "loc": { "start": { "line": 17, "column": 18 }, "end": { "line": 17, "column": 31 } } }, "generator": false, "async": false, "expression": false, "params": [ { "type": "Identifier", "name": "num", "typeAnnotation": { "type": "TSNumberKeyword", "loc": { "start": { "line": 17, "column": 37 }, "end": { "line": 17, "column": 43 } } }, "loc": { "start": { "line": 17, "column": 32 }, "end": { "line": 17, "column": 35 } } } ], "returnType": { "type": "TSBooleanKeyword", "loc": { "start": { "line": 17, "column": 46 }, "end": { "line": 17, "column": 53 } } }, "declare": true, "loc": { "start": { "line": 17, "column": 9 }, "end": { "line": 17, "column": 54 } } }, "loc": { "start": { "line": 17, "column": 9 }, "end": { "line": 17, "column": 54 } } }, { "type": "ClassDeclaration", "definition": { "id": { "type": "Identifier", "name": "Foo", "loc": { "start": { "line": 19, "column": 7 }, "end": { "line": 19, "column": 10 } } }, "superClass": null, "implements": [], "constructor": { "type": "MethodDefinition", "key": { "type": "Identifier", "name": "constructor", "loc": { "start": { "line": 1, "column": 1 }, "end": { "line": 1, "column": 1 } } }, "kind": "constructor", "static": false, "optional": false, "computed": false, "value": { "type": "FunctionExpression", "function": { "type": "ScriptFunction", "id": null, "generator": false, "async": false, "expression": false, "params": [], "body": { "type": "BlockStatement", "statements": [], "loc": { "start": { "line": 1, "column": 1 }, "end": { "line": 1, "column": 1 } } }, "loc": { "start": { "line": 1, "column": 1 }, "end": { "line": 1, "column": 1 } } }, "loc": { "start": { "line": 1, "column": 1 }, "end": { "line": 1, "column": 1 } } }, "overloads": [], "decorators": [], "annotations": [], "loc": { "start": { "line": 19, "column": 1 }, "end": { "line": 28, "column": 2 } } }, "body": [ { "type": "ClassProperty", "key": { "type": "Identifier", "name": "count", "loc": { "start": { "line": 20, "column": 10 }, "end": { "line": 20, "column": 15 } } }, "value": { "type": "NumberLiteral", "value": 0, "loc": { "start": { "line": 20, "column": 18 }, "end": { "line": 20, "column": 19 } } }, "static": true, "readonly": false, "declare": false, "optional": false, "computed": false, "decorators": [], "loc": { "start": { "line": 20, "column": 3 }, "end": { "line": 20, "column": 19 } } }, { "type": "ClassStaticBlock", "body": { "type": "BlockStatement", "statements": [ { "type": "IfStatement", "test": { "type": "CallExpression", "callee": { "type": "Identifier", "name": "someCondition", "loc": { "start": { "line": 22, "column": 9 }, "end": { "line": 22, "column": 22 } } }, "arguments": [ { "type": "NumberLiteral", "value": 5, "loc": { "start": { "line": 22, "column": 23 }, "end": { "line": 22, "column": 24 } } } ], "optional": false, "loc": { "start": { "line": 22, "column": 9 }, "end": { "line": 22, "column": 25 } } }, "consequent": { "type": "BlockStatement", "statements": [ { "type": "ExpressionStatement", "expression": { "type": "UpdateExpression", "operator": "++", "prefix": false, "argument": { "type": "MemberExpression", "object": { "type": "Identifier", "name": "Foo", "loc": { "start": { "line": 23, "column": 7 }, "end": { "line": 23, "column": 10 } } }, "property": { "type": "Identifier", "name": "count", "loc": { "start": { "line": 23, "column": 11 }, "end": { "line": 23, "column": 16 } } }, "computed": false, "optional": false, "loc": { "start": { "line": 23, "column": 7 }, "end": { "line": 23, "column": 16 } } }, "loc": { "start": { "line": 23, "column": 7 }, "end": { "line": 23, "column": 18 } } }, "loc": { "start": { "line": 23, "column": 7 }, "end": { "line": 23, "column": 19 } } } ], "loc": { "start": { "line": 22, "column": 27 }, "end": { "line": 24, "column": 6 } } }, "alternate": { "type": "BlockStatement", "statements": [ { "type": "ExpressionStatement", "expression": { "type": "UpdateExpression", "operator": "--", "prefix": false, "argument": { "type": "MemberExpression", "object": { "type": "Identifier", "name": "Foo", "loc": { "start": { "line": 25, "column": 7 }, "end": { "line": 25, "column": 10 } } }, "property": { "type": "Identifier", "name": "count", "loc": { "start": { "line": 25, "column": 11 }, "end": { "line": 25, "column": 16 } } }, "computed": false, "optional": false, "loc": { "start": { "line": 25, "column": 7 }, "end": { "line": 25, "column": 16 } } }, "loc": { "start": { "line": 25, "column": 7 }, "end": { "line": 25, "column": 18 } } }, "loc": { "start": { "line": 25, "column": 7 }, "end": { "line": 25, "column": 19 } } } ], "loc": { "start": { "line": 24, "column": 12 }, "end": { "line": 26, "column": 6 } } }, "loc": { "start": { "line": 22, "column": 5 }, "end": { "line": 26, "column": 6 } } } ], "loc": { "start": { "line": 21, "column": 10 }, "end": { "line": 27, "column": 4 } } }, "loc": { "start": { "line": 21, "column": 3 }, "end": { "line": 27, "column": 4 } } } ], "indexSignatures": [], "loc": { "start": { "line": 19, "column": 11 }, "end": { "line": 28, "column": 2 } } }, "decorators": [], "isAnnotationDeclaration": false, "loc": { "start": { "line": 19, "column": 1 }, "end": { "line": 28, "column": 2 } } } ], "loc": { "start": { "line": 1, "column": 1 }, "end": { "line": 28, "column": 2 } } }