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

Function runRefs

__tests__/go-shadowed-function-value.test.ts:129–134  ·  view source on GitHub ↗

` L ` for every function_ref ref to `run`, in source order.

(result: ExtractionResult)

Source from the content-addressed store, hash-verified

127
128/** `<function> L<line>` for every function_ref ref to `run`, in source order. */
129function runRefs(result: ExtractionResult): string[] {
130 const byId = new Map(result.nodes.map((n) => [n.id, n]));
131 return result.unresolvedReferences
132 .filter((r) => r.referenceKind === 'function_ref' && r.referenceName === 'run')
133 .map((r) => `${byId.get(r.fromNodeId)?.name} L${r.line}`);
134}
135
136const ENV_KEYS = ['CODEGRAPH_KERNEL', 'CODEGRAPH_KERNEL_LANGS'] as const;
137

Calls 2

mapMethod · 0.80
getMethod · 0.65

Tested by

no test coverage detected