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

Function code

src/extraction/languages/c-cpp.ts:1796–1796  ·  view source on GitHub ↗
(i: number)

Source from the content-addressed store, hash-verified

1794 const lines = source.split('\n');
1795 const directive = (i: number) => /^[ \t]*#[ \t]*(\w+)/.exec(lines[i] ?? '')?.[1] ?? null;
1796 const code = (i: number) => (lines[i] ?? '').replace(/\/\/.*$/, '').replace(/\/\*.*?\*\//g, '').trim();
1797 let changed = false;
1798 const blank = (i: number) => {
1799 lines[i] = (lines[i] ?? '').replace(/[^\r]/g, ' ');

Calls 1

stripCrFunction · 0.85

Tested by

no test coverage detected