MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / calls

Function calls

__tests__/cpp-undeclared-qualifier.test.ts:54–60  ·  view source on GitHub ↗

`calls` callees of a function or method, as `qualifiedName`.

(cg: CodeGraph, caller: string)

Source from the content-addressed store, hash-verified

52
53/** `calls` callees of a function or method, as `qualifiedName`. */
54function calls(cg: CodeGraph, caller: string): string[] {
55 return cg
56 .getCallees(callable(cg, caller).id)
57 .filter((r) => r.edge.kind === 'calls')
58 .map((r) => r.node.qualifiedName)
59 .sort();
60}
61
62/** Where the `calls` edges written in `file` lead, as `name @ file:line` of each target. */
63function callsFrom(cg: CodeGraph, file: string): string[] {

Calls 3

mapMethod · 0.80
callableFunction · 0.70
getCalleesMethod · 0.45

Tested by

no test coverage detected