=== tests/cases/conformance/parser/ecmascript5/parserRealSource14.ts === // Copyright (c) Microsoft. All rights reserved. Licensed under the Apache License, Version 2.0. // See LICENSE.txt in the project root for complete license information. /// module TypeScript { >TypeScript : typeof TypeScript export function lastOf(items: any[]): any { >lastOf : (items: any[]) => any >items : any[] return (items === null || items.length === 0) ? null : items[items.length - 1]; >(items === null || items.length === 0) ? null : items[items.length - 1] : any >(items === null || items.length === 0) : boolean >items === null || items.length === 0 : boolean >items === null : boolean >items : any[] >null : null >items.length === 0 : boolean >items.length : number >items : any[] >length : number >0 : 0 >null : null >items[items.length - 1] : any >items : any[] >items.length - 1 : number >items.length : number >items : any[] >length : number >1 : 1 } export function max(a: number, b: number): number { >max : (a: number, b: number) => number >a : number >b : number return a >= b ? a : b; >a >= b ? a : b : number >a >= b : boolean >a : number >b : number >a : number >b : number } export function min(a: number, b: number): number { >min : (a: number, b: number) => number >a : number >b : number return a <= b ? a : b; >a <= b ? a : b : number >a <= b : boolean >a : number >b : number >a : number >b : number } // // Helper class representing a path from a root ast node to a (grand)child ast node. // This is helpful as our tree don't have parents. // export class AstPath { >AstPath : AstPath public asts: TypeScript.AST[] = []; >asts : TypeScript.AST[] >TypeScript : any >[] : undefined[] public top: number = -1; >top : number >-1 : -1 >1 : 1 static reverseIndexOf(items: any[], index: number): any { >reverseIndexOf : (items: any[], index: number) => any >items : any[] >index : number return (items === null || items.length <= index) ? null : items[items.length - index - 1]; >(items === null || items.length <= index) ? null : items[items.length - index - 1] : any >(items === null || items.length <= index) : boolean >items === null || items.length <= index : boolean >items === null : boolean >items : any[] >null : null >items.length <= index : boolean >items.length : number >items : any[] >length : number >index : number >null : null >items[items.length - index - 1] : any >items : any[] >items.length - index - 1 : number >items.length - index : number >items.length : number >items : any[] >length : number >index : number >1 : 1 } public clone(): AstPath { >clone : () => AstPath var clone = new AstPath(); >clone : AstPath >new AstPath() : AstPath >AstPath : typeof AstPath clone.asts = this.asts.map((value) => { return value; }); >clone.asts = this.asts.map((value) => { return value; }) : TypeScript.AST[] >clone.asts : TypeScript.AST[] >clone : AstPath >asts : TypeScript.AST[] >this.asts.map((value) => { return value; }) : TypeScript.AST[] >this.asts.map : (callbackfn: (value: TypeScript.AST, index: number, array: TypeScript.AST[]) => U, thisArg?: any) => U[] >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >map : (callbackfn: (value: TypeScript.AST, index: number, array: TypeScript.AST[]) => U, thisArg?: any) => U[] >(value) => { return value; } : (value: TypeScript.AST) => TypeScript.AST >value : TypeScript.AST >value : TypeScript.AST clone.top = this.top; >clone.top = this.top : number >clone.top : number >clone : AstPath >top : number >this.top : number >this : this >top : number return clone; >clone : AstPath } public pop(): TypeScript.AST { >pop : () => TypeScript.AST >TypeScript : any var head = this.ast(); >head : TypeScript.AST >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST this.up(); >this.up() : void >this.up : () => void >this : this >up : () => void while (this.asts.length > this.count()) { >this.asts.length > this.count() : boolean >this.asts.length : number >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >length : number >this.count() : number >this.count : () => number >this : this >count : () => number this.asts.pop(); >this.asts.pop() : TypeScript.AST >this.asts.pop : () => TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >pop : () => TypeScript.AST } return head; >head : TypeScript.AST } public push(ast: TypeScript.AST) { >push : (ast: TypeScript.AST) => void >ast : TypeScript.AST >TypeScript : any while (this.asts.length > this.count()) { >this.asts.length > this.count() : boolean >this.asts.length : number >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >length : number >this.count() : number >this.count : () => number >this : this >count : () => number this.asts.pop(); >this.asts.pop() : TypeScript.AST >this.asts.pop : () => TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >pop : () => TypeScript.AST } this.top = this.asts.length; >this.top = this.asts.length : number >this.top : number >this : this >top : number >this.asts.length : number >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >length : number this.asts.push(ast); >this.asts.push(ast) : number >this.asts.push : (...items: TypeScript.AST[]) => number >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >push : (...items: TypeScript.AST[]) => number >ast : TypeScript.AST } public up() { >up : () => void if (this.top <= -1) >this.top <= -1 : boolean >this.top : number >this : this >top : number >-1 : -1 >1 : 1 throw new Error("Invalid call to 'up'"); >new Error("Invalid call to 'up'") : Error >Error : ErrorConstructor >"Invalid call to 'up'" : "Invalid call to 'up'" this.top--; >this.top-- : number >this.top : number >this : this >top : number } public down() { >down : () => void if (this.top == this.ast.length - 1) >this.top == this.ast.length - 1 : boolean >this.top : number >this : this >top : number >this.ast.length - 1 : number >this.ast.length : number >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >length : number >1 : 1 throw new Error("Invalid call to 'down'"); >new Error("Invalid call to 'down'") : Error >Error : ErrorConstructor >"Invalid call to 'down'" : "Invalid call to 'down'" this.top++; >this.top++ : number >this.top : number >this : this >top : number } public nodeType(): TypeScript.NodeType { >nodeType : () => TypeScript.NodeType >TypeScript : any if (this.ast() == null) >this.ast() == null : boolean >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >null : null return TypeScript.NodeType.None; >TypeScript.NodeType.None : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >None : any return this.ast().nodeType; >this.ast().nodeType : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >nodeType : any } public ast() { >ast : () => TypeScript.AST return AstPath.reverseIndexOf(this.asts, this.asts.length - (this.top + 1)); >AstPath.reverseIndexOf(this.asts, this.asts.length - (this.top + 1)) : TypeScript.AST >TypeScript : any >AstPath.reverseIndexOf(this.asts, this.asts.length - (this.top + 1)) : any >AstPath.reverseIndexOf : (items: any[], index: number) => any >AstPath : typeof AstPath >reverseIndexOf : (items: any[], index: number) => any >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.asts.length - (this.top + 1) : number >this.asts.length : number >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >length : number >(this.top + 1) : number >this.top + 1 : number >this.top : number >this : this >top : number >1 : 1 } public parent() { >parent : () => TypeScript.AST return AstPath.reverseIndexOf(this.asts, this.asts.length - this.top); >AstPath.reverseIndexOf(this.asts, this.asts.length - this.top) : TypeScript.AST >TypeScript : any >AstPath.reverseIndexOf(this.asts, this.asts.length - this.top) : any >AstPath.reverseIndexOf : (items: any[], index: number) => any >AstPath : typeof AstPath >reverseIndexOf : (items: any[], index: number) => any >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.asts.length - this.top : number >this.asts.length : number >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >length : number >this.top : number >this : this >top : number } public count() { >count : () => number return this.top + 1; >this.top + 1 : number >this.top : number >this : this >top : number >1 : 1 } public get(index: number): TypeScript.AST { >get : (index: number) => TypeScript.AST >index : number >TypeScript : any return this.asts[index]; >this.asts[index] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >index : number } public isNameOfClass(): boolean { >isNameOfClass : () => boolean if (this.ast() === null || this.parent() === null) >this.ast() === null || this.parent() === null : boolean >this.ast() === null : boolean >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >null : null >this.parent() === null : boolean >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >null : null return false; >false : false return (this.ast().nodeType === TypeScript.NodeType.Name) && >(this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.ClassDeclaration) && ((this.parent()).name === this.ast()) : boolean >(this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.ClassDeclaration) : boolean >(this.ast().nodeType === TypeScript.NodeType.Name) : boolean >this.ast().nodeType === TypeScript.NodeType.Name : boolean >this.ast().nodeType : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >nodeType : any >TypeScript.NodeType.Name : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Name : any (this.parent().nodeType === TypeScript.NodeType.ClassDeclaration) && >(this.parent().nodeType === TypeScript.NodeType.ClassDeclaration) : boolean >this.parent().nodeType === TypeScript.NodeType.ClassDeclaration : boolean >this.parent().nodeType : any >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >nodeType : any >TypeScript.NodeType.ClassDeclaration : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ClassDeclaration : any ((this.parent()).name === this.ast()); >((this.parent()).name === this.ast()) : boolean >(this.parent()).name === this.ast() : boolean >(this.parent()).name : any >(this.parent()) : TypeScript.InterfaceDeclaration >this.parent() : TypeScript.InterfaceDeclaration >TypeScript : any >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >name : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST } public isNameOfInterface(): boolean { >isNameOfInterface : () => boolean if (this.ast() === null || this.parent() === null) >this.ast() === null || this.parent() === null : boolean >this.ast() === null : boolean >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >null : null >this.parent() === null : boolean >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >null : null return false; >false : false return (this.ast().nodeType === TypeScript.NodeType.Name) && >(this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.InterfaceDeclaration) && ((this.parent()).name === this.ast()) : boolean >(this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.InterfaceDeclaration) : boolean >(this.ast().nodeType === TypeScript.NodeType.Name) : boolean >this.ast().nodeType === TypeScript.NodeType.Name : boolean >this.ast().nodeType : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >nodeType : any >TypeScript.NodeType.Name : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Name : any (this.parent().nodeType === TypeScript.NodeType.InterfaceDeclaration) && >(this.parent().nodeType === TypeScript.NodeType.InterfaceDeclaration) : boolean >this.parent().nodeType === TypeScript.NodeType.InterfaceDeclaration : boolean >this.parent().nodeType : any >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >nodeType : any >TypeScript.NodeType.InterfaceDeclaration : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >InterfaceDeclaration : any ((this.parent()).name === this.ast()); >((this.parent()).name === this.ast()) : boolean >(this.parent()).name === this.ast() : boolean >(this.parent()).name : any >(this.parent()) : TypeScript.InterfaceDeclaration >this.parent() : TypeScript.InterfaceDeclaration >TypeScript : any >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >name : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST } public isNameOfArgument(): boolean { >isNameOfArgument : () => boolean if (this.ast() === null || this.parent() === null) >this.ast() === null || this.parent() === null : boolean >this.ast() === null : boolean >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >null : null >this.parent() === null : boolean >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >null : null return false; >false : false return (this.ast().nodeType === TypeScript.NodeType.Name) && >(this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.ArgDecl) && ((this.parent()).id === this.ast()) : boolean >(this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.ArgDecl) : boolean >(this.ast().nodeType === TypeScript.NodeType.Name) : boolean >this.ast().nodeType === TypeScript.NodeType.Name : boolean >this.ast().nodeType : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >nodeType : any >TypeScript.NodeType.Name : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Name : any (this.parent().nodeType === TypeScript.NodeType.ArgDecl) && >(this.parent().nodeType === TypeScript.NodeType.ArgDecl) : boolean >this.parent().nodeType === TypeScript.NodeType.ArgDecl : boolean >this.parent().nodeType : any >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >nodeType : any >TypeScript.NodeType.ArgDecl : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ArgDecl : any ((this.parent()).id === this.ast()); >((this.parent()).id === this.ast()) : boolean >(this.parent()).id === this.ast() : boolean >(this.parent()).id : any >(this.parent()) : TypeScript.ArgDecl >this.parent() : TypeScript.ArgDecl >TypeScript : any >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >id : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST } public isNameOfVariable(): boolean { >isNameOfVariable : () => boolean if (this.ast() === null || this.parent() === null) >this.ast() === null || this.parent() === null : boolean >this.ast() === null : boolean >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >null : null >this.parent() === null : boolean >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >null : null return false; >false : false return (this.ast().nodeType === TypeScript.NodeType.Name) && >(this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.VarDecl) && ((this.parent()).id === this.ast()) : boolean >(this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.VarDecl) : boolean >(this.ast().nodeType === TypeScript.NodeType.Name) : boolean >this.ast().nodeType === TypeScript.NodeType.Name : boolean >this.ast().nodeType : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >nodeType : any >TypeScript.NodeType.Name : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Name : any (this.parent().nodeType === TypeScript.NodeType.VarDecl) && >(this.parent().nodeType === TypeScript.NodeType.VarDecl) : boolean >this.parent().nodeType === TypeScript.NodeType.VarDecl : boolean >this.parent().nodeType : any >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >nodeType : any >TypeScript.NodeType.VarDecl : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >VarDecl : any ((this.parent()).id === this.ast()); >((this.parent()).id === this.ast()) : boolean >(this.parent()).id === this.ast() : boolean >(this.parent()).id : any >(this.parent()) : TypeScript.VarDecl >this.parent() : TypeScript.VarDecl >TypeScript : any >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >id : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST } public isNameOfModule(): boolean { >isNameOfModule : () => boolean if (this.ast() === null || this.parent() === null) >this.ast() === null || this.parent() === null : boolean >this.ast() === null : boolean >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >null : null >this.parent() === null : boolean >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >null : null return false; >false : false return (this.ast().nodeType === TypeScript.NodeType.Name) && >(this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.ModuleDeclaration) && ((this.parent()).name === this.ast()) : boolean >(this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.ModuleDeclaration) : boolean >(this.ast().nodeType === TypeScript.NodeType.Name) : boolean >this.ast().nodeType === TypeScript.NodeType.Name : boolean >this.ast().nodeType : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >nodeType : any >TypeScript.NodeType.Name : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Name : any (this.parent().nodeType === TypeScript.NodeType.ModuleDeclaration) && >(this.parent().nodeType === TypeScript.NodeType.ModuleDeclaration) : boolean >this.parent().nodeType === TypeScript.NodeType.ModuleDeclaration : boolean >this.parent().nodeType : any >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >nodeType : any >TypeScript.NodeType.ModuleDeclaration : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ModuleDeclaration : any ((this.parent()).name === this.ast()); >((this.parent()).name === this.ast()) : boolean >(this.parent()).name === this.ast() : boolean >(this.parent()).name : any >(this.parent()) : TypeScript.ModuleDeclaration >this.parent() : TypeScript.ModuleDeclaration >TypeScript : any >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >name : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST } public isNameOfFunction(): boolean { >isNameOfFunction : () => boolean if (this.ast() === null || this.parent() === null) >this.ast() === null || this.parent() === null : boolean >this.ast() === null : boolean >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >null : null >this.parent() === null : boolean >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >null : null return false; >false : false return (this.ast().nodeType === TypeScript.NodeType.Name) && >(this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.FuncDecl) && ((this.parent()).name === this.ast()) : boolean >(this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.FuncDecl) : boolean >(this.ast().nodeType === TypeScript.NodeType.Name) : boolean >this.ast().nodeType === TypeScript.NodeType.Name : boolean >this.ast().nodeType : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST >nodeType : any >TypeScript.NodeType.Name : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Name : any (this.parent().nodeType === TypeScript.NodeType.FuncDecl) && >(this.parent().nodeType === TypeScript.NodeType.FuncDecl) : boolean >this.parent().nodeType === TypeScript.NodeType.FuncDecl : boolean >this.parent().nodeType : any >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >nodeType : any >TypeScript.NodeType.FuncDecl : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >FuncDecl : any ((this.parent()).name === this.ast()); >((this.parent()).name === this.ast()) : boolean >(this.parent()).name === this.ast() : boolean >(this.parent()).name : any >(this.parent()) : TypeScript.FuncDecl >this.parent() : TypeScript.FuncDecl >TypeScript : any >this.parent() : TypeScript.AST >this.parent : () => TypeScript.AST >this : this >parent : () => TypeScript.AST >name : any >this.ast() : TypeScript.AST >this.ast : () => TypeScript.AST >this : this >ast : () => TypeScript.AST } public isChildOfScript(): boolean { >isChildOfScript : () => boolean var ast = lastOf(this.asts); >ast : any >lastOf(this.asts) : any >lastOf : (items: any[]) => any >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] return this.count() >= 3 && >this.count() >= 3 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.Script : boolean >this.count() >= 3 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 3 && this.asts[this.top] === ast : boolean >this.count() >= 3 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >3 : 3 this.asts[this.top] === ast && >this.asts[this.top] === ast : boolean >this.asts[this.top] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top : number >this : this >top : number >ast : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 2].nodeType === TypeScript.NodeType.Script; >this.asts[this.top - 2].nodeType === TypeScript.NodeType.Script : boolean >this.asts[this.top - 2].nodeType : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >nodeType : any >TypeScript.NodeType.Script : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Script : any } public isChildOfModule(): boolean { >isChildOfModule : () => boolean var ast = lastOf(this.asts); >ast : any >lastOf(this.asts) : any >lastOf : (items: any[]) => any >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] return this.count() >= 3 && >this.count() >= 3 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.ModuleDeclaration : boolean >this.count() >= 3 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 3 && this.asts[this.top] === ast : boolean >this.count() >= 3 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >3 : 3 this.asts[this.top] === ast && >this.asts[this.top] === ast : boolean >this.asts[this.top] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top : number >this : this >top : number >ast : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 2].nodeType === TypeScript.NodeType.ModuleDeclaration; >this.asts[this.top - 2].nodeType === TypeScript.NodeType.ModuleDeclaration : boolean >this.asts[this.top - 2].nodeType : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >nodeType : any >TypeScript.NodeType.ModuleDeclaration : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ModuleDeclaration : any } public isChildOfClass(): boolean { >isChildOfClass : () => boolean var ast = lastOf(this.asts); >ast : any >lastOf(this.asts) : any >lastOf : (items: any[]) => any >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] return this.count() >= 3 && >this.count() >= 3 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.ClassDeclaration : boolean >this.count() >= 3 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 3 && this.asts[this.top] === ast : boolean >this.count() >= 3 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >3 : 3 this.asts[this.top] === ast && >this.asts[this.top] === ast : boolean >this.asts[this.top] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top : number >this : this >top : number >ast : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 2].nodeType === TypeScript.NodeType.ClassDeclaration; >this.asts[this.top - 2].nodeType === TypeScript.NodeType.ClassDeclaration : boolean >this.asts[this.top - 2].nodeType : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >nodeType : any >TypeScript.NodeType.ClassDeclaration : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ClassDeclaration : any } public isArgumentOfClassConstructor(): boolean { >isArgumentOfClassConstructor : () => boolean var ast = lastOf(this.asts); >ast : any >lastOf(this.asts) : any >lastOf : (items: any[]) => any >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] return this.count() >= 5 && >this.count() >= 5 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl && this.asts[this.top - 3].nodeType === TypeScript.NodeType.List && this.asts[this.top - 4].nodeType === TypeScript.NodeType.ClassDeclaration && ((this.asts[this.top - 2]).isConstructor) && ((this.asts[this.top - 2]).arguments === this.asts[this.top - 1]) && ((this.asts[this.top - 4]).constructorDecl === this.asts[this.top - 2]) : boolean >this.count() >= 5 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl && this.asts[this.top - 3].nodeType === TypeScript.NodeType.List && this.asts[this.top - 4].nodeType === TypeScript.NodeType.ClassDeclaration && ((this.asts[this.top - 2]).isConstructor) && ((this.asts[this.top - 2]).arguments === this.asts[this.top - 1]) : boolean >this.count() >= 5 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl && this.asts[this.top - 3].nodeType === TypeScript.NodeType.List && this.asts[this.top - 4].nodeType === TypeScript.NodeType.ClassDeclaration && ((this.asts[this.top - 2]).isConstructor) : any >this.count() >= 5 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl && this.asts[this.top - 3].nodeType === TypeScript.NodeType.List && this.asts[this.top - 4].nodeType === TypeScript.NodeType.ClassDeclaration : boolean >this.count() >= 5 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl && this.asts[this.top - 3].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 5 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl : boolean >this.count() >= 5 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 5 && this.asts[this.top] === ast : boolean >this.count() >= 5 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >5 : 5 this.asts[this.top] === ast && >this.asts[this.top] === ast : boolean >this.asts[this.top] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top : number >this : this >top : number >ast : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl && >this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl : boolean >this.asts[this.top - 2].nodeType : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >nodeType : any >TypeScript.NodeType.FuncDecl : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >FuncDecl : any this.asts[this.top - 3].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 3].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 3].nodeType : any >this.asts[this.top - 3] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 3 : number >this.top : number >this : this >top : number >3 : 3 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 4].nodeType === TypeScript.NodeType.ClassDeclaration && >this.asts[this.top - 4].nodeType === TypeScript.NodeType.ClassDeclaration : boolean >this.asts[this.top - 4].nodeType : any >this.asts[this.top - 4] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 4 : number >this.top : number >this : this >top : number >4 : 4 >nodeType : any >TypeScript.NodeType.ClassDeclaration : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ClassDeclaration : any ((this.asts[this.top - 2]).isConstructor) && >((this.asts[this.top - 2]).isConstructor) : any >(this.asts[this.top - 2]).isConstructor : any >(this.asts[this.top - 2]) : TypeScript.FuncDecl >this.asts[this.top - 2] : TypeScript.FuncDecl >TypeScript : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >isConstructor : any ((this.asts[this.top - 2]).arguments === this.asts[this.top - 1]) && >((this.asts[this.top - 2]).arguments === this.asts[this.top - 1]) : boolean >(this.asts[this.top - 2]).arguments === this.asts[this.top - 1] : boolean >(this.asts[this.top - 2]).arguments : any >(this.asts[this.top - 2]) : TypeScript.FuncDecl >this.asts[this.top - 2] : TypeScript.FuncDecl >TypeScript : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >arguments : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 ((this.asts[this.top - 4]).constructorDecl === this.asts[this.top - 2]); >((this.asts[this.top - 4]).constructorDecl === this.asts[this.top - 2]) : boolean >(this.asts[this.top - 4]).constructorDecl === this.asts[this.top - 2] : boolean >(this.asts[this.top - 4]).constructorDecl : any >(this.asts[this.top - 4]) : TypeScript.ClassDeclaration >this.asts[this.top - 4] : TypeScript.ClassDeclaration >TypeScript : any >this.asts[this.top - 4] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 4 : number >this.top : number >this : this >top : number >4 : 4 >constructorDecl : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 } public isChildOfInterface(): boolean { >isChildOfInterface : () => boolean var ast = lastOf(this.asts); >ast : any >lastOf(this.asts) : any >lastOf : (items: any[]) => any >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] return this.count() >= 3 && >this.count() >= 3 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.InterfaceDeclaration : boolean >this.count() >= 3 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 3 && this.asts[this.top] === ast : boolean >this.count() >= 3 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >3 : 3 this.asts[this.top] === ast && >this.asts[this.top] === ast : boolean >this.asts[this.top] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top : number >this : this >top : number >ast : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 2].nodeType === TypeScript.NodeType.InterfaceDeclaration; >this.asts[this.top - 2].nodeType === TypeScript.NodeType.InterfaceDeclaration : boolean >this.asts[this.top - 2].nodeType : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >nodeType : any >TypeScript.NodeType.InterfaceDeclaration : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >InterfaceDeclaration : any } public isTopLevelImplicitModule() { >isTopLevelImplicitModule : () => any return this.count() >= 1 && >this.count() >= 1 && this.asts[this.top].nodeType === TypeScript.NodeType.ModuleDeclaration && TypeScript.hasFlag((this.asts[this.top]).modFlags, TypeScript.ModuleFlags.IsWholeFile) : any >this.count() >= 1 && this.asts[this.top].nodeType === TypeScript.NodeType.ModuleDeclaration : boolean >this.count() >= 1 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >1 : 1 this.asts[this.top].nodeType === TypeScript.NodeType.ModuleDeclaration && >this.asts[this.top].nodeType === TypeScript.NodeType.ModuleDeclaration : boolean >this.asts[this.top].nodeType : any >this.asts[this.top] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top : number >this : this >top : number >nodeType : any >TypeScript.NodeType.ModuleDeclaration : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ModuleDeclaration : any TypeScript.hasFlag((this.asts[this.top]).modFlags, TypeScript.ModuleFlags.IsWholeFile); >TypeScript.hasFlag((this.asts[this.top]).modFlags, TypeScript.ModuleFlags.IsWholeFile) : any >TypeScript.hasFlag : any >TypeScript : typeof TypeScript >hasFlag : any >(this.asts[this.top]).modFlags : any >(this.asts[this.top]) : TypeScript.ModuleDeclaration >this.asts[this.top] : TypeScript.ModuleDeclaration >TypeScript : any >this.asts[this.top] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top : number >this : this >top : number >modFlags : any >TypeScript.ModuleFlags.IsWholeFile : any >TypeScript.ModuleFlags : any >TypeScript : typeof TypeScript >ModuleFlags : any >IsWholeFile : any } public isBodyOfTopLevelImplicitModule() { >isBodyOfTopLevelImplicitModule : () => any return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration && (this.asts[this.top - 1]).members == this.asts[this.top - 0] && TypeScript.hasFlag((this.asts[this.top - 1]).modFlags, TypeScript.ModuleFlags.IsWholeFile) : any >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration && (this.asts[this.top - 1]).members == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration : boolean >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 0].nodeType : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.ModuleDeclaration : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ModuleDeclaration : any (this.asts[this.top - 1]).members == this.asts[this.top - 0] && >(this.asts[this.top - 1]).members == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).members : any >(this.asts[this.top - 1]) : TypeScript.ModuleDeclaration >this.asts[this.top - 1] : TypeScript.ModuleDeclaration >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >members : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 TypeScript.hasFlag((this.asts[this.top - 1]).modFlags, TypeScript.ModuleFlags.IsWholeFile); >TypeScript.hasFlag((this.asts[this.top - 1]).modFlags, TypeScript.ModuleFlags.IsWholeFile) : any >TypeScript.hasFlag : any >TypeScript : typeof TypeScript >hasFlag : any >(this.asts[this.top - 1]).modFlags : any >(this.asts[this.top - 1]) : TypeScript.ModuleDeclaration >this.asts[this.top - 1] : TypeScript.ModuleDeclaration >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >modFlags : any >TypeScript.ModuleFlags.IsWholeFile : any >TypeScript.ModuleFlags : any >TypeScript : typeof TypeScript >ModuleFlags : any >IsWholeFile : any } public isBodyOfScript(): boolean { >isBodyOfScript : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Script && (this.asts[this.top - 1]).bod == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Script : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.Script && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.Script : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.Script : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Script : any (this.asts[this.top - 1]).bod == this.asts[this.top - 0]; >(this.asts[this.top - 1]).bod == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).bod : any >(this.asts[this.top - 1]) : TypeScript.Script >this.asts[this.top - 1] : TypeScript.Script >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >bod : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfSwitch(): boolean { >isBodyOfSwitch : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Switch && (this.asts[this.top - 1]).caseList == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Switch : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.Switch && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.Switch : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.Switch : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Switch : any (this.asts[this.top - 1]).caseList == this.asts[this.top - 0]; >(this.asts[this.top - 1]).caseList == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).caseList : any >(this.asts[this.top - 1]) : TypeScript.SwitchStatement >this.asts[this.top - 1] : TypeScript.SwitchStatement >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >caseList : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfModule(): boolean { >isBodyOfModule : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration && (this.asts[this.top - 1]).members == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.ModuleDeclaration : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ModuleDeclaration : any (this.asts[this.top - 1]).members == this.asts[this.top - 0]; >(this.asts[this.top - 1]).members == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).members : any >(this.asts[this.top - 1]) : TypeScript.ModuleDeclaration >this.asts[this.top - 1] : TypeScript.ModuleDeclaration >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >members : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfClass(): boolean { >isBodyOfClass : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ClassDeclaration && (this.asts[this.top - 1]).members == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ClassDeclaration : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.ClassDeclaration && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.ClassDeclaration : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.ClassDeclaration : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ClassDeclaration : any (this.asts[this.top - 1]).members == this.asts[this.top - 0]; >(this.asts[this.top - 1]).members == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).members : any >(this.asts[this.top - 1]) : TypeScript.ClassDeclaration >this.asts[this.top - 1] : TypeScript.ClassDeclaration >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >members : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfFunction(): boolean { >isBodyOfFunction : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.FuncDecl && (this.asts[this.top - 1]).bod == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.FuncDecl : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.FuncDecl && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.FuncDecl : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.FuncDecl : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >FuncDecl : any (this.asts[this.top - 1]).bod == this.asts[this.top - 0]; >(this.asts[this.top - 1]).bod == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).bod : any >(this.asts[this.top - 1]) : TypeScript.FuncDecl >this.asts[this.top - 1] : TypeScript.FuncDecl >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >bod : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfInterface(): boolean { >isBodyOfInterface : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.InterfaceDeclaration && (this.asts[this.top - 1]).members == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.InterfaceDeclaration : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.InterfaceDeclaration && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.InterfaceDeclaration : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.InterfaceDeclaration : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >InterfaceDeclaration : any (this.asts[this.top - 1]).members == this.asts[this.top - 0]; >(this.asts[this.top - 1]).members == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).members : any >(this.asts[this.top - 1]) : TypeScript.InterfaceDeclaration >this.asts[this.top - 1] : TypeScript.InterfaceDeclaration >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >members : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfBlock(): boolean { >isBodyOfBlock : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Block && (this.asts[this.top - 1]).statements == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Block : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.Block && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.Block : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.Block : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Block : any (this.asts[this.top - 1]).statements == this.asts[this.top - 0]; >(this.asts[this.top - 1]).statements == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).statements : any >(this.asts[this.top - 1]) : TypeScript.Block >this.asts[this.top - 1] : TypeScript.Block >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >statements : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfFor(): boolean { >isBodyOfFor : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.For && (this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.For : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.For && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.For : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.For : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >For : any (this.asts[this.top - 1]).body == this.asts[this.top - 0]; >(this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).body : any >(this.asts[this.top - 1]) : TypeScript.ForStatement >this.asts[this.top - 1] : TypeScript.ForStatement >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >body : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfCase(): boolean { >isBodyOfCase : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Case && (this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Case : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.Case && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.Case : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.Case : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Case : any (this.asts[this.top - 1]).body == this.asts[this.top - 0]; >(this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).body : any >(this.asts[this.top - 1]) : TypeScript.CaseStatement >this.asts[this.top - 1] : TypeScript.CaseStatement >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >body : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfTry(): boolean { >isBodyOfTry : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Try && (this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Try : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.Try && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.Try : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.Try : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Try : any (this.asts[this.top - 1]).body == this.asts[this.top - 0]; >(this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).body : any >(this.asts[this.top - 1]) : TypeScript.Try >this.asts[this.top - 1] : TypeScript.Try >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >body : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfCatch(): boolean { >isBodyOfCatch : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Catch && (this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Catch : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.Catch && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.Catch : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.Catch : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Catch : any (this.asts[this.top - 1]).body == this.asts[this.top - 0]; >(this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).body : any >(this.asts[this.top - 1]) : TypeScript.Catch >this.asts[this.top - 1] : TypeScript.Catch >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >body : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfDoWhile(): boolean { >isBodyOfDoWhile : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.DoWhile && (this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.DoWhile : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.DoWhile && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.DoWhile : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.DoWhile : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >DoWhile : any (this.asts[this.top - 1]).body == this.asts[this.top - 0]; >(this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).body : any >(this.asts[this.top - 1]) : TypeScript.DoWhileStatement >this.asts[this.top - 1] : TypeScript.DoWhileStatement >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >body : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfWhile(): boolean { >isBodyOfWhile : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.While && (this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.While : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.While && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.While : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.While : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >While : any (this.asts[this.top - 1]).body == this.asts[this.top - 0]; >(this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).body : any >(this.asts[this.top - 1]) : TypeScript.WhileStatement >this.asts[this.top - 1] : TypeScript.WhileStatement >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >body : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfForIn(): boolean { >isBodyOfForIn : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ForIn && (this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ForIn : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.ForIn && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.ForIn : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.ForIn : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ForIn : any (this.asts[this.top - 1]).body == this.asts[this.top - 0]; >(this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).body : any >(this.asts[this.top - 1]) : TypeScript.ForInStatement >this.asts[this.top - 1] : TypeScript.ForInStatement >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >body : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfWith(): boolean { >isBodyOfWith : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.With && (this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.With : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.With && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.With : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.With : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >With : any (this.asts[this.top - 1]).body == this.asts[this.top - 0]; >(this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).body : any >(this.asts[this.top - 1]) : TypeScript.WithStatement >this.asts[this.top - 1] : TypeScript.WithStatement >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >body : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfFinally(): boolean { >isBodyOfFinally : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Finally && (this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Finally : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.Finally && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.Finally : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.Finally : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Finally : any (this.asts[this.top - 1]).body == this.asts[this.top - 0]; >(this.asts[this.top - 1]).body == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).body : any >(this.asts[this.top - 1]) : TypeScript.Finally >this.asts[this.top - 1] : TypeScript.Finally >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >body : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isCaseOfSwitch(): boolean { >isCaseOfSwitch : () => boolean return this.count() >= 3 && >this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && (this.asts[this.top - 2]).caseList == this.asts[this.top - 1] : boolean >this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch : boolean >this.count() >= 3 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >3 : 3 this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch && >this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch : boolean >this.asts[this.top - 2].nodeType : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >nodeType : any >TypeScript.NodeType.Switch : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Switch : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any (this.asts[this.top - 2]).caseList == this.asts[this.top - 1]; >(this.asts[this.top - 2]).caseList == this.asts[this.top - 1] : boolean >(this.asts[this.top - 2]).caseList : any >(this.asts[this.top - 2]) : TypeScript.SwitchStatement >this.asts[this.top - 2] : TypeScript.SwitchStatement >TypeScript : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >caseList : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 } public isDefaultCaseOfSwitch(): boolean { >isDefaultCaseOfSwitch : () => boolean return this.count() >= 3 && >this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && (this.asts[this.top - 2]).caseList == this.asts[this.top - 1] && (this.asts[this.top - 2]).defaultCase == this.asts[this.top - 0] : boolean >this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && (this.asts[this.top - 2]).caseList == this.asts[this.top - 1] : boolean >this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch : boolean >this.count() >= 3 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >3 : 3 this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch && >this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch : boolean >this.asts[this.top - 2].nodeType : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >nodeType : any >TypeScript.NodeType.Switch : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Switch : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any (this.asts[this.top - 2]).caseList == this.asts[this.top - 1] && >(this.asts[this.top - 2]).caseList == this.asts[this.top - 1] : boolean >(this.asts[this.top - 2]).caseList : any >(this.asts[this.top - 2]) : TypeScript.SwitchStatement >this.asts[this.top - 2] : TypeScript.SwitchStatement >TypeScript : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >caseList : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 (this.asts[this.top - 2]).defaultCase == this.asts[this.top - 0]; >(this.asts[this.top - 2]).defaultCase == this.asts[this.top - 0] : boolean >(this.asts[this.top - 2]).defaultCase : any >(this.asts[this.top - 2]) : TypeScript.SwitchStatement >this.asts[this.top - 2] : TypeScript.SwitchStatement >TypeScript : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >defaultCase : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isListOfObjectLit(): boolean { >isListOfObjectLit : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && (this.asts[this.top - 1]).operand == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.ObjectLit : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ObjectLit : any this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 0].nodeType : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any (this.asts[this.top - 1]).operand == this.asts[this.top - 0]; >(this.asts[this.top - 1]).operand == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).operand : any >(this.asts[this.top - 1]) : TypeScript.UnaryExpression >this.asts[this.top - 1] : TypeScript.UnaryExpression >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >operand : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfObjectLit(): boolean { >isBodyOfObjectLit : () => boolean return this.isListOfObjectLit(); >this.isListOfObjectLit() : boolean >this.isListOfObjectLit : () => boolean >this : this >isListOfObjectLit : () => boolean } public isEmptyListOfObjectLit(): boolean { >isEmptyListOfObjectLit : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && (this.asts[this.top - 1]).operand == this.asts[this.top - 0] && (this.asts[this.top - 0]).members.length == 0 : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && (this.asts[this.top - 1]).operand == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.ObjectLit : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ObjectLit : any this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 0].nodeType : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any (this.asts[this.top - 1]).operand == this.asts[this.top - 0] && >(this.asts[this.top - 1]).operand == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).operand : any >(this.asts[this.top - 1]) : TypeScript.UnaryExpression >this.asts[this.top - 1] : TypeScript.UnaryExpression >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >operand : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 (this.asts[this.top - 0]).members.length == 0; >(this.asts[this.top - 0]).members.length == 0 : boolean >(this.asts[this.top - 0]).members.length : any >(this.asts[this.top - 0]).members : any >(this.asts[this.top - 0]) : TypeScript.ASTList >this.asts[this.top - 0] : TypeScript.ASTList >TypeScript : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 >members : any >length : any >0 : 0 } public isMemberOfObjectLit(): boolean { >isMemberOfObjectLit : () => boolean return this.count() >= 3 && >this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 0].nodeType === TypeScript.NodeType.Member && (this.asts[this.top - 2]).operand == this.asts[this.top - 1] : boolean >this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 0].nodeType === TypeScript.NodeType.Member : boolean >this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.ObjectLit : boolean >this.count() >= 3 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >3 : 3 this.asts[this.top - 2].nodeType === TypeScript.NodeType.ObjectLit && >this.asts[this.top - 2].nodeType === TypeScript.NodeType.ObjectLit : boolean >this.asts[this.top - 2].nodeType : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >nodeType : any >TypeScript.NodeType.ObjectLit : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ObjectLit : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 0].nodeType === TypeScript.NodeType.Member && >this.asts[this.top - 0].nodeType === TypeScript.NodeType.Member : boolean >this.asts[this.top - 0].nodeType : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 >nodeType : any >TypeScript.NodeType.Member : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Member : any (this.asts[this.top - 2]).operand == this.asts[this.top - 1]; >(this.asts[this.top - 2]).operand == this.asts[this.top - 1] : boolean >(this.asts[this.top - 2]).operand : any >(this.asts[this.top - 2]) : TypeScript.UnaryExpression >this.asts[this.top - 2] : TypeScript.UnaryExpression >TypeScript : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >operand : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 } public isNameOfMemberOfObjectLit(): boolean { >isNameOfMemberOfObjectLit : () => boolean return this.count() >= 4 && >this.count() >= 4 && this.asts[this.top - 3].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 2].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && this.asts[this.top - 0].nodeType === TypeScript.NodeType.Name && (this.asts[this.top - 3]).operand == this.asts[this.top - 2] : boolean >this.count() >= 4 && this.asts[this.top - 3].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 2].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && this.asts[this.top - 0].nodeType === TypeScript.NodeType.Name : boolean >this.count() >= 4 && this.asts[this.top - 3].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 2].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member : boolean >this.count() >= 4 && this.asts[this.top - 3].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 2].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 4 && this.asts[this.top - 3].nodeType === TypeScript.NodeType.ObjectLit : boolean >this.count() >= 4 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >4 : 4 this.asts[this.top - 3].nodeType === TypeScript.NodeType.ObjectLit && >this.asts[this.top - 3].nodeType === TypeScript.NodeType.ObjectLit : boolean >this.asts[this.top - 3].nodeType : any >this.asts[this.top - 3] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 3 : number >this.top : number >this : this >top : number >3 : 3 >nodeType : any >TypeScript.NodeType.ObjectLit : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ObjectLit : any this.asts[this.top - 2].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 2].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 2].nodeType : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.Member : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Member : any this.asts[this.top - 0].nodeType === TypeScript.NodeType.Name && >this.asts[this.top - 0].nodeType === TypeScript.NodeType.Name : boolean >this.asts[this.top - 0].nodeType : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 >nodeType : any >TypeScript.NodeType.Name : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Name : any (this.asts[this.top - 3]).operand == this.asts[this.top - 2]; >(this.asts[this.top - 3]).operand == this.asts[this.top - 2] : boolean >(this.asts[this.top - 3]).operand : any >(this.asts[this.top - 3]) : TypeScript.UnaryExpression >this.asts[this.top - 3] : TypeScript.UnaryExpression >TypeScript : any >this.asts[this.top - 3] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 3 : number >this.top : number >this : this >top : number >3 : 3 >operand : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 } public isListOfArrayLit(): boolean { >isListOfArrayLit : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ArrayLit && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && (this.asts[this.top - 1]).operand == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ArrayLit && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ArrayLit : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.ArrayLit && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.ArrayLit : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.ArrayLit : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >ArrayLit : any this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 0].nodeType : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any (this.asts[this.top - 1]).operand == this.asts[this.top - 0]; >(this.asts[this.top - 1]).operand == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).operand : any >(this.asts[this.top - 1]) : TypeScript.UnaryExpression >this.asts[this.top - 1] : TypeScript.UnaryExpression >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >operand : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isTargetOfMember(): boolean { >isTargetOfMember : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && (this.asts[this.top - 1]).operand1 === this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.Member : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Member : any (this.asts[this.top - 1]).operand1 === this.asts[this.top - 0]; >(this.asts[this.top - 1]).operand1 === this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).operand1 : any >(this.asts[this.top - 1]) : TypeScript.BinaryExpression >this.asts[this.top - 1] : TypeScript.BinaryExpression >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >operand1 : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isMemberOfMember(): boolean { >isMemberOfMember : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && (this.asts[this.top - 1]).operand2 === this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.Member : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Member : any (this.asts[this.top - 1]).operand2 === this.asts[this.top - 0]; >(this.asts[this.top - 1]).operand2 === this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).operand2 : any >(this.asts[this.top - 1]) : TypeScript.BinaryExpression >this.asts[this.top - 1] : TypeScript.BinaryExpression >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >operand2 : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isItemOfList(): boolean { >isItemOfList : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.List; >this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any //(this.asts[this.top - 1]).operand2 === this.asts[this.top - 0]; } public isThenOfIf(): boolean { >isThenOfIf : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.If && (this.asts[this.top - 1]).thenBod == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.If : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.If && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.If : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.If : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >If : any (this.asts[this.top - 1]).thenBod == this.asts[this.top - 0]; >(this.asts[this.top - 1]).thenBod == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).thenBod : any >(this.asts[this.top - 1]) : TypeScript.IfStatement >this.asts[this.top - 1] : TypeScript.IfStatement >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >thenBod : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isElseOfIf(): boolean { >isElseOfIf : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.If && (this.asts[this.top - 1]).elseBod == this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.If : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 1].nodeType === TypeScript.NodeType.If && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.If : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.If : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >If : any (this.asts[this.top - 1]).elseBod == this.asts[this.top - 0]; >(this.asts[this.top - 1]).elseBod == this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).elseBod : any >(this.asts[this.top - 1]) : TypeScript.IfStatement >this.asts[this.top - 1] : TypeScript.IfStatement >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >elseBod : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isBodyOfDefaultCase(): boolean { >isBodyOfDefaultCase : () => boolean return this.isBodyOfCase(); >this.isBodyOfCase() : boolean >this.isBodyOfCase : () => boolean >this : this >isBodyOfCase : () => boolean } public isSingleStatementList(): boolean { >isSingleStatementList : () => boolean return this.count() >= 1 && >this.count() >= 1 && this.asts[this.top].nodeType === TypeScript.NodeType.List && (this.asts[this.top]).members.length === 1 : boolean >this.count() >= 1 && this.asts[this.top].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 1 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >1 : 1 this.asts[this.top].nodeType === TypeScript.NodeType.List && >this.asts[this.top].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top].nodeType : any >this.asts[this.top] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top : number >this : this >top : number >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any (this.asts[this.top]).members.length === 1; >(this.asts[this.top]).members.length === 1 : boolean >(this.asts[this.top]).members.length : any >(this.asts[this.top]).members : any >(this.asts[this.top]) : TypeScript.ASTList >this.asts[this.top] : TypeScript.ASTList >TypeScript : any >this.asts[this.top] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top : number >this : this >top : number >members : any >length : any >1 : 1 } public isArgumentListOfFunction(): boolean { >isArgumentListOfFunction : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.FuncDecl && (this.asts[this.top - 1]).arguments === this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.FuncDecl : boolean >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 0].nodeType : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.FuncDecl && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.FuncDecl : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.FuncDecl : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >FuncDecl : any (this.asts[this.top - 1]).arguments === this.asts[this.top - 0]; >(this.asts[this.top - 1]).arguments === this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).arguments : any >(this.asts[this.top - 1]) : TypeScript.FuncDecl >this.asts[this.top - 1] : TypeScript.FuncDecl >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >arguments : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isArgumentOfFunction(): boolean { >isArgumentOfFunction : () => boolean return this.count() >= 3 && >this.count() >= 3 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl && (this.asts[this.top - 2]).arguments === this.asts[this.top - 1] : boolean >this.count() >= 3 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl : boolean >this.count() >= 3 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 3 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >3 : 3 this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl && >this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl : boolean >this.asts[this.top - 2].nodeType : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >nodeType : any >TypeScript.NodeType.FuncDecl : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >FuncDecl : any (this.asts[this.top - 2]).arguments === this.asts[this.top - 1]; >(this.asts[this.top - 2]).arguments === this.asts[this.top - 1] : boolean >(this.asts[this.top - 2]).arguments : any >(this.asts[this.top - 2]) : TypeScript.FuncDecl >this.asts[this.top - 2] : TypeScript.FuncDecl >TypeScript : any >this.asts[this.top - 2] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 2 : number >this.top : number >this : this >top : number >2 : 2 >arguments : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 } public isArgumentListOfCall(): boolean { >isArgumentListOfCall : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Call && (this.asts[this.top - 1]).arguments === this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Call : boolean >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 0].nodeType : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.Call && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.Call : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.Call : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Call : any (this.asts[this.top - 1]).arguments === this.asts[this.top - 0]; >(this.asts[this.top - 1]).arguments === this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).arguments : any >(this.asts[this.top - 1]) : TypeScript.CallExpression >this.asts[this.top - 1] : TypeScript.CallExpression >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >arguments : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isArgumentListOfNew(): boolean { >isArgumentListOfNew : () => boolean return this.count() >= 2 && >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.New && (this.asts[this.top - 1]).arguments === this.asts[this.top - 0] : boolean >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.New : boolean >this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.count() >= 2 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >2 : 2 this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && >this.asts[this.top - 0].nodeType === TypeScript.NodeType.List : boolean >this.asts[this.top - 0].nodeType : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 >nodeType : any >TypeScript.NodeType.List : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >List : any this.asts[this.top - 1].nodeType === TypeScript.NodeType.New && >this.asts[this.top - 1].nodeType === TypeScript.NodeType.New : boolean >this.asts[this.top - 1].nodeType : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >nodeType : any >TypeScript.NodeType.New : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >New : any (this.asts[this.top - 1]).arguments === this.asts[this.top - 0]; >(this.asts[this.top - 1]).arguments === this.asts[this.top - 0] : boolean >(this.asts[this.top - 1]).arguments : any >(this.asts[this.top - 1]) : TypeScript.CallExpression >this.asts[this.top - 1] : TypeScript.CallExpression >TypeScript : any >this.asts[this.top - 1] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 1 : number >this.top : number >this : this >top : number >1 : 1 >arguments : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 } public isSynthesizedBlock(): boolean { >isSynthesizedBlock : () => boolean return this.count() >= 1 && >this.count() >= 1 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.Block && (this.asts[this.top - 0]).isStatementBlock === false : boolean >this.count() >= 1 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.Block : boolean >this.count() >= 1 : boolean >this.count() : number >this.count : () => number >this : this >count : () => number >1 : 1 this.asts[this.top - 0].nodeType === TypeScript.NodeType.Block && >this.asts[this.top - 0].nodeType === TypeScript.NodeType.Block : boolean >this.asts[this.top - 0].nodeType : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 >nodeType : any >TypeScript.NodeType.Block : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Block : any (this.asts[this.top - 0]).isStatementBlock === false; >(this.asts[this.top - 0]).isStatementBlock === false : boolean >(this.asts[this.top - 0]).isStatementBlock : any >(this.asts[this.top - 0]) : TypeScript.Block >this.asts[this.top - 0] : TypeScript.Block >TypeScript : any >this.asts[this.top - 0] : TypeScript.AST >this.asts : TypeScript.AST[] >this : this >asts : TypeScript.AST[] >this.top - 0 : number >this.top : number >this : this >top : number >0 : 0 >isStatementBlock : any >false : false } } export function isValidAstNode(ast: TypeScript.ASTSpan): boolean { >isValidAstNode : (ast: TypeScript.ASTSpan) => boolean >ast : TypeScript.ASTSpan >TypeScript : any if (ast === null) >ast === null : boolean >ast : TypeScript.ASTSpan >null : null return false; >false : false if (ast.minChar === -1 || ast.limChar === -1) >ast.minChar === -1 || ast.limChar === -1 : boolean >ast.minChar === -1 : boolean >ast.minChar : any >ast : TypeScript.ASTSpan >minChar : any >-1 : -1 >1 : 1 >ast.limChar === -1 : boolean >ast.limChar : any >ast : TypeScript.ASTSpan >limChar : any >-1 : -1 >1 : 1 return false; >false : false return true; >true : true } export class AstPathContext { >AstPathContext : AstPathContext public path = new TypeScript.AstPath(); >path : AstPath >new TypeScript.AstPath() : AstPath >TypeScript.AstPath : typeof AstPath >TypeScript : typeof TypeScript >AstPath : typeof AstPath } export enum GetAstPathOptions { >GetAstPathOptions : GetAstPathOptions Default = 0, >Default : GetAstPathOptions >0 : 0 EdgeInclusive = 1, >EdgeInclusive : GetAstPathOptions >1 : 1 //We need this options dealing with an AST coming from an incomplete AST. For example: // class foo { // r // If we ask for the AST at the position after the "r" character, we won't see we are // inside a comment, because the "class" AST node has a limChar corresponding to the position of // the "{" character, meaning we don't traverse the tree down to the stmt list of the class, meaning // we don't find the "precomment" attached to the errorneous empty stmt. //TODO: It would be nice to be able to get rid of this. DontPruneSearchBasedOnPosition = 1 << 1, >DontPruneSearchBasedOnPosition : GetAstPathOptions >1 << 1 : number >1 : 1 >1 : 1 } /// /// Return the stack of AST nodes containing "position" /// export function getAstPathToPosition(script: TypeScript.AST, pos: number, options = GetAstPathOptions.Default): TypeScript.AstPath { >getAstPathToPosition : (script: TypeScript.AST, pos: number, options?: GetAstPathOptions) => TypeScript.AstPath >script : TypeScript.AST >TypeScript : any >pos : number >options : GetAstPathOptions >GetAstPathOptions.Default : GetAstPathOptions >GetAstPathOptions : typeof GetAstPathOptions >Default : GetAstPathOptions >TypeScript : any var lookInComments = (comments: TypeScript.Comment[]) => { >lookInComments : (comments: TypeScript.Comment[]) => void >(comments: TypeScript.Comment[]) => { if (comments && comments.length > 0) { for (var i = 0; i < comments.length; i++) { var minChar = comments[i].minChar; var limChar = comments[i].limChar; if (!comments[i].isBlockComment) { limChar++; // For single line comments, include 1 more character (for the newline) } if (pos >= minChar && pos < limChar) { ctx.path.push(comments[i]); } } } } : (comments: TypeScript.Comment[]) => void >comments : TypeScript.Comment[] >TypeScript : any if (comments && comments.length > 0) { >comments && comments.length > 0 : boolean >comments : TypeScript.Comment[] >comments.length > 0 : boolean >comments.length : number >comments : TypeScript.Comment[] >length : number >0 : 0 for (var i = 0; i < comments.length; i++) { >i : number >0 : 0 >i < comments.length : boolean >i : number >comments.length : number >comments : TypeScript.Comment[] >length : number >i++ : number >i : number var minChar = comments[i].minChar; >minChar : any >comments[i].minChar : any >comments[i] : TypeScript.Comment >comments : TypeScript.Comment[] >i : number >minChar : any var limChar = comments[i].limChar; >limChar : any >comments[i].limChar : any >comments[i] : TypeScript.Comment >comments : TypeScript.Comment[] >i : number >limChar : any if (!comments[i].isBlockComment) { >!comments[i].isBlockComment : boolean >comments[i].isBlockComment : any >comments[i] : TypeScript.Comment >comments : TypeScript.Comment[] >i : number >isBlockComment : any limChar++; // For single line comments, include 1 more character (for the newline) >limChar++ : number >limChar : any } if (pos >= minChar && pos < limChar) { >pos >= minChar && pos < limChar : boolean >pos >= minChar : boolean >pos : number >minChar : any >pos < limChar : boolean >pos : number >limChar : any ctx.path.push(comments[i]); >ctx.path.push(comments[i]) : void >ctx.path.push : (ast: TypeScript.AST) => void >ctx.path : AstPath >ctx : AstPathContext >path : AstPath >push : (ast: TypeScript.AST) => void >comments[i] : TypeScript.Comment >comments : TypeScript.Comment[] >i : number } } } } var pre = function (cur: TypeScript.AST, parent: TypeScript.AST, walker: IAstWalker) { >pre : (cur: TypeScript.AST, parent: TypeScript.AST, walker: IAstWalker) => TypeScript.AST >function (cur: TypeScript.AST, parent: TypeScript.AST, walker: IAstWalker) { if (isValidAstNode(cur)) { // Add "cur" to the stack if it contains our position // For "identifier" nodes, we need a special case: A position equal to "limChar" is // valid, since the position corresponds to a caret position (in between characters) // For example: // bar // 0123 // If "position == 3", the caret is at the "right" of the "r" character, which should be considered valid var inclusive = hasFlag(options, GetAstPathOptions.EdgeInclusive) || cur.nodeType === TypeScript.NodeType.Name || pos === script.limChar; // Special "EOF" case var minChar = cur.minChar; var limChar = cur.limChar + (inclusive ? 1 : 0) if (pos >= minChar && pos < limChar) { // TODO: Since AST is sometimes not correct wrt to position, only add "cur" if it's better // than top of the stack. var previous = ctx.path.ast(); if (previous == null || (cur.minChar >= previous.minChar && cur.limChar <= previous.limChar)) { ctx.path.push(cur); } else { //logger.log("TODO: Ignoring node because minChar, limChar not better than previous node in stack"); } } // The AST walker skips comments, but we might be in one, so check the pre/post comments for this node manually if (pos < limChar) { lookInComments(cur.preComments); } if (pos >= minChar) { lookInComments(cur.postComments); } if (!hasFlag(options, GetAstPathOptions.DontPruneSearchBasedOnPosition)) { // Don't go further down the tree if pos is outside of [minChar, limChar] walker.options.goChildren = (minChar <= pos && pos <= limChar); } } return cur; } : (cur: TypeScript.AST, parent: TypeScript.AST, walker: IAstWalker) => TypeScript.AST >cur : TypeScript.AST >TypeScript : any >parent : TypeScript.AST >TypeScript : any >walker : IAstWalker if (isValidAstNode(cur)) { >isValidAstNode(cur) : boolean >isValidAstNode : (ast: TypeScript.ASTSpan) => boolean >cur : TypeScript.AST // Add "cur" to the stack if it contains our position // For "identifier" nodes, we need a special case: A position equal to "limChar" is // valid, since the position corresponds to a caret position (in between characters) // For example: // bar // 0123 // If "position == 3", the caret is at the "right" of the "r" character, which should be considered valid var inclusive = >inclusive : any hasFlag(options, GetAstPathOptions.EdgeInclusive) || >hasFlag(options, GetAstPathOptions.EdgeInclusive) || cur.nodeType === TypeScript.NodeType.Name || pos === script.limChar : any >hasFlag(options, GetAstPathOptions.EdgeInclusive) || cur.nodeType === TypeScript.NodeType.Name : any >hasFlag(options, GetAstPathOptions.EdgeInclusive) : any >hasFlag : any >options : GetAstPathOptions >GetAstPathOptions.EdgeInclusive : GetAstPathOptions >GetAstPathOptions : typeof GetAstPathOptions >EdgeInclusive : GetAstPathOptions cur.nodeType === TypeScript.NodeType.Name || >cur.nodeType === TypeScript.NodeType.Name : boolean >cur.nodeType : any >cur : TypeScript.AST >nodeType : any >TypeScript.NodeType.Name : any >TypeScript.NodeType : any >TypeScript : typeof TypeScript >NodeType : any >Name : any pos === script.limChar; // Special "EOF" case >pos === script.limChar : boolean >pos : number >script.limChar : any >script : TypeScript.AST >limChar : any var minChar = cur.minChar; >minChar : any >cur.minChar : any >cur : TypeScript.AST >minChar : any var limChar = cur.limChar + (inclusive ? 1 : 0) >limChar : any >cur.limChar + (inclusive ? 1 : 0) : any >cur.limChar : any >cur : TypeScript.AST >limChar : any >(inclusive ? 1 : 0) : 0 | 1 >inclusive ? 1 : 0 : 0 | 1 >inclusive : any >1 : 1 >0 : 0 if (pos >= minChar && pos < limChar) { >pos >= minChar && pos < limChar : boolean >pos >= minChar : boolean >pos : number >minChar : any >pos < limChar : boolean >pos : number >limChar : any // TODO: Since AST is sometimes not correct wrt to position, only add "cur" if it's better // than top of the stack. var previous = ctx.path.ast(); >previous : TypeScript.AST >ctx.path.ast() : TypeScript.AST >ctx.path.ast : () => TypeScript.AST >ctx.path : AstPath >ctx : AstPathContext >path : AstPath >ast : () => TypeScript.AST if (previous == null || (cur.minChar >= previous.minChar && cur.limChar <= previous.limChar)) { >previous == null || (cur.minChar >= previous.minChar && cur.limChar <= previous.limChar) : boolean >previous == null : boolean >previous : TypeScript.AST >null : null >(cur.minChar >= previous.minChar && cur.limChar <= previous.limChar) : boolean >cur.minChar >= previous.minChar && cur.limChar <= previous.limChar : boolean >cur.minChar >= previous.minChar : boolean >cur.minChar : any >cur : TypeScript.AST >minChar : any >previous.minChar : any >previous : TypeScript.AST >minChar : any >cur.limChar <= previous.limChar : boolean >cur.limChar : any >cur : TypeScript.AST >limChar : any >previous.limChar : any >previous : TypeScript.AST >limChar : any ctx.path.push(cur); >ctx.path.push(cur) : void >ctx.path.push : (ast: TypeScript.AST) => void >ctx.path : AstPath >ctx : AstPathContext >path : AstPath >push : (ast: TypeScript.AST) => void >cur : TypeScript.AST } else { //logger.log("TODO: Ignoring node because minChar, limChar not better than previous node in stack"); } } // The AST walker skips comments, but we might be in one, so check the pre/post comments for this node manually if (pos < limChar) { >pos < limChar : boolean >pos : number >limChar : any lookInComments(cur.preComments); >lookInComments(cur.preComments) : void >lookInComments : (comments: TypeScript.Comment[]) => void >cur.preComments : any >cur : TypeScript.AST >preComments : any } if (pos >= minChar) { >pos >= minChar : boolean >pos : number >minChar : any lookInComments(cur.postComments); >lookInComments(cur.postComments) : void >lookInComments : (comments: TypeScript.Comment[]) => void >cur.postComments : any >cur : TypeScript.AST >postComments : any } if (!hasFlag(options, GetAstPathOptions.DontPruneSearchBasedOnPosition)) { >!hasFlag(options, GetAstPathOptions.DontPruneSearchBasedOnPosition) : boolean >hasFlag(options, GetAstPathOptions.DontPruneSearchBasedOnPosition) : any >hasFlag : any >options : GetAstPathOptions >GetAstPathOptions.DontPruneSearchBasedOnPosition : GetAstPathOptions >GetAstPathOptions : typeof GetAstPathOptions >DontPruneSearchBasedOnPosition : GetAstPathOptions // Don't go further down the tree if pos is outside of [minChar, limChar] walker.options.goChildren = (minChar <= pos && pos <= limChar); >walker.options.goChildren = (minChar <= pos && pos <= limChar) : boolean >walker.options.goChildren : any >walker.options : any >walker : IAstWalker >options : any >goChildren : any >(minChar <= pos && pos <= limChar) : boolean >minChar <= pos && pos <= limChar : boolean >minChar <= pos : boolean >minChar : any >pos : number >pos <= limChar : boolean >pos : number >limChar : any } } return cur; >cur : TypeScript.AST } var ctx = new AstPathContext(); >ctx : AstPathContext >new AstPathContext() : AstPathContext >AstPathContext : typeof AstPathContext TypeScript.getAstWalkerFactory().walk(script, pre, null, null, ctx); >TypeScript.getAstWalkerFactory().walk(script, pre, null, null, ctx) : any >TypeScript.getAstWalkerFactory().walk : any >TypeScript.getAstWalkerFactory() : any >TypeScript.getAstWalkerFactory : any >TypeScript : typeof TypeScript >getAstWalkerFactory : any >walk : any >script : TypeScript.AST >pre : (cur: TypeScript.AST, parent: TypeScript.AST, walker: IAstWalker) => TypeScript.AST >null : null >null : null >ctx : AstPathContext return ctx.path; >ctx.path : AstPath >ctx : AstPathContext >path : AstPath } // // Find a source text offset that is safe for lexing tokens at the given position. // This is used when "position" might be inside a comment or string, etc. // export function getTokenizationOffset(script: TypeScript.Script, position: number): number { >getTokenizationOffset : (script: TypeScript.Script, position: number) => number >script : TypeScript.Script >TypeScript : any >position : number var bestOffset = 0; >bestOffset : number >0 : 0 var pre = (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker): TypeScript.AST => { >pre : (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) => TypeScript.AST >(cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker): TypeScript.AST => { if (TypeScript.isValidAstNode(cur)) { // Did we find a closer offset? if (cur.minChar <= position) { bestOffset = max(bestOffset, cur.minChar); } // Stop the walk if this node is not related to "minChar" if (cur.minChar > position || cur.limChar < bestOffset) { walker.options.goChildren = false; } } return cur; } : (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) => TypeScript.AST >cur : TypeScript.AST >TypeScript : any >parent : TypeScript.AST >TypeScript : any >walker : TypeScript.IAstWalker >TypeScript : any >TypeScript : any if (TypeScript.isValidAstNode(cur)) { >TypeScript.isValidAstNode(cur) : boolean >TypeScript.isValidAstNode : (ast: TypeScript.ASTSpan) => boolean >TypeScript : typeof TypeScript >isValidAstNode : (ast: TypeScript.ASTSpan) => boolean >cur : TypeScript.AST // Did we find a closer offset? if (cur.minChar <= position) { >cur.minChar <= position : boolean >cur.minChar : any >cur : TypeScript.AST >minChar : any >position : number bestOffset = max(bestOffset, cur.minChar); >bestOffset = max(bestOffset, cur.minChar) : number >bestOffset : number >max(bestOffset, cur.minChar) : number >max : (a: number, b: number) => number >bestOffset : number >cur.minChar : any >cur : TypeScript.AST >minChar : any } // Stop the walk if this node is not related to "minChar" if (cur.minChar > position || cur.limChar < bestOffset) { >cur.minChar > position || cur.limChar < bestOffset : boolean >cur.minChar > position : boolean >cur.minChar : any >cur : TypeScript.AST >minChar : any >position : number >cur.limChar < bestOffset : boolean >cur.limChar : any >cur : TypeScript.AST >limChar : any >bestOffset : number walker.options.goChildren = false; >walker.options.goChildren = false : false >walker.options.goChildren : any >walker.options : any >walker : TypeScript.IAstWalker >options : any >goChildren : any >false : false } } return cur; >cur : TypeScript.AST } TypeScript.getAstWalkerFactory().walk(script, pre); >TypeScript.getAstWalkerFactory().walk(script, pre) : any >TypeScript.getAstWalkerFactory().walk : any >TypeScript.getAstWalkerFactory() : any >TypeScript.getAstWalkerFactory : any >TypeScript : typeof TypeScript >getAstWalkerFactory : any >walk : any >script : TypeScript.Script >pre : (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) => TypeScript.AST return bestOffset; >bestOffset : number } /// /// Simple function to Walk an AST using a simple callback function. /// export function walkAST(ast: TypeScript.AST, callback: (path: AstPath, walker: TypeScript.IAstWalker) => void ): void { >walkAST : (ast: TypeScript.AST, callback: (path: AstPath, walker: TypeScript.IAstWalker) => void) => void >ast : TypeScript.AST >TypeScript : any >callback : (path: AstPath, walker: TypeScript.IAstWalker) => void >path : AstPath >walker : TypeScript.IAstWalker >TypeScript : any var pre = function (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) { >pre : (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) => TypeScript.AST >function (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) { var path: TypeScript.AstPath = walker.state; path.push(cur); callback(path, walker); return cur; } : (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) => TypeScript.AST >cur : TypeScript.AST >TypeScript : any >parent : TypeScript.AST >TypeScript : any >walker : TypeScript.IAstWalker >TypeScript : any var path: TypeScript.AstPath = walker.state; >path : AstPath >TypeScript : any >walker.state : any >walker : TypeScript.IAstWalker >state : any path.push(cur); >path.push(cur) : void >path.push : (ast: TypeScript.AST) => void >path : AstPath >push : (ast: TypeScript.AST) => void >cur : TypeScript.AST callback(path, walker); >callback(path, walker) : void >callback : (path: AstPath, walker: TypeScript.IAstWalker) => void >path : AstPath >walker : TypeScript.IAstWalker return cur; >cur : TypeScript.AST } var post = function (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) { >post : (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) => TypeScript.AST >function (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) { var path: TypeScript.AstPath = walker.state; path.pop(); return cur; } : (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) => TypeScript.AST >cur : TypeScript.AST >TypeScript : any >parent : TypeScript.AST >TypeScript : any >walker : TypeScript.IAstWalker >TypeScript : any var path: TypeScript.AstPath = walker.state; >path : AstPath >TypeScript : any >walker.state : any >walker : TypeScript.IAstWalker >state : any path.pop(); >path.pop() : TypeScript.AST >path.pop : () => TypeScript.AST >path : AstPath >pop : () => TypeScript.AST return cur; >cur : TypeScript.AST } var path = new AstPath(); >path : AstPath >new AstPath() : AstPath >AstPath : typeof AstPath TypeScript.getAstWalkerFactory().walk(ast, pre, post, null, path); >TypeScript.getAstWalkerFactory().walk(ast, pre, post, null, path) : any >TypeScript.getAstWalkerFactory().walk : any >TypeScript.getAstWalkerFactory() : any >TypeScript.getAstWalkerFactory : any >TypeScript : typeof TypeScript >getAstWalkerFactory : any >walk : any >ast : TypeScript.AST >pre : (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) => TypeScript.AST >post : (cur: TypeScript.AST, parent: TypeScript.AST, walker: TypeScript.IAstWalker) => TypeScript.AST >null : null >path : AstPath } }