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

Function stripCr

src/extraction/languages/c-cpp.ts:880–880  ·  view source on GitHub ↗
(l: string)

Source from the content-addressed store, hash-verified

878 if (source.indexOf('__cplusplus') === -1) return source;
879 const lines = source.split('\n');
880 const stripCr = (l: string): string => (l.endsWith('\r') ? l.slice(0, -1) : l);
881 let changed = false;
882 for (let i = 0; i < lines.length; i++) {
883 if (!C_CPLUSPLUS_GUARD_OPEN_RE.test(stripCr(lines[i] as string))) continue;

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected