* The class declaration among same-named nodes, not a forward declaration * (`TFoo = class;`, which names no members or ancestors): the longest one.
(classes: Node[])
| 717 | * (`TFoo = class;`, which names no members or ancestors): the longest one. |
| 718 | */ |
| 719 | function declarationOf(classes: Node[]): Node | null { |
| 720 | let best: Node | null = null; |
| 721 | for (const c of classes) if (!best || c.endLine - c.startLine > best.endLine - best.startLine) best = c; |
| 722 | return best; |
| 723 | } |
| 724 | |
| 725 | /** The class a method belongs to: its qualified name's owner, declared in the method's own file. */ |
| 726 | function classOfRoutine(routine: Node, context: ResolutionContext): Node | null { |
no outgoing calls
no test coverage detected