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

Function preParsedSource

src/extraction/kernel/index.ts:140–143  ·  view source on GitHub ↗

* The preParse hoist (checklist §arch-1): languages with an offset-preserving * `preParse` hook (c/cpp macro blanking, csharp #237, metal #1121, cuda #1172) * apply it HERE, before the kernel call, so both arms parse identical blanked * bytes and none of the blanking logic needs a Rust port. The

(filePath: string, source: string, language: Language)

Source from the content-addressed store, hash-verified

138 * blanks (`.metal` attributes; `.cu`/`.cuh` + content-gated CUDA).
139 */
140function preParsedSource(filePath: string, source: string, language: Language): string {
141 const pre = EXTRACTORS[language]?.preParse;
142 return pre ? pre(source, filePath) : source;
143}
144
145/**
146 * Whether the file's re-exports keep their statements as written while the

Callers 2

tryKernelExtractRawFunction · 0.85
tryKernelExtractFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected