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

Function instNames

__tests__/extraction.test.ts:5094–5097  ·  view source on GitHub ↗
(code: string)

Source from the content-addressed store, hash-verified

5092 // they emitted no constructor reference, unlike heap `new Calculator(0)`. An
5093 // `instantiates` ref to the constructed type is now emitted for both.
5094 const instNames = (code: string) =>
5095 extractFromSource('f.cpp', `void run() {\n${code}\n}`)
5096 .unresolvedReferences.filter((r) => r.referenceKind === 'instantiates')
5097 .map((r) => r.referenceName);
5098
5099 it('emits an instantiates ref for direct-init and brace-init', () => {
5100 expect(instNames('Calculator calc(0);')).toEqual(['Calculator']);

Callers 1

extraction.test.tsFile · 0.85

Calls 2

extractFromSourceFunction · 0.90
mapMethod · 0.80

Tested by

no test coverage detected