(cg: CodeGraph, qualifiedName: string)
| 37 | } |
| 38 | |
| 39 | function callable(cg: CodeGraph, qualifiedName: string): Node { |
| 40 | const node = [...cg.getNodesByKind('method'), ...cg.getNodesByKind('function')].find((n) => n.qualifiedName === qualifiedName); |
| 41 | if (!node) throw new Error(`no function or method ${qualifiedName}`); |
| 42 | return node; |
| 43 | } |
| 44 | |
| 45 | /** `calls` callees of a function or method, as `qualifiedName`. */ |
| 46 | function calls(cg: CodeGraph, caller: string): string[] { |