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

Method constructor

src/resolution/ruby-parameter-flow.ts:55–62  ·  view source on GitHub ↗
(private readonly source: string)

Source from the content-addressed store, hash-verified

53 readonly length: number;
54
55 constructor(private readonly source: string) {
56 scratch ??= new Int32Array(MAX_SOURCE_FILE_SIZE_BYTES + 2);
57 let count = 1;
58 for (let at = source.indexOf('\n'); at >= 0; at = source.indexOf('\n', at + 1)) scratch[count++] = at + 1;
59 scratch[count] = source.length + 1;
60 this.starts = scratch.slice(0, count + 1);
61 this.length = count;
62 }
63
64 /** Line `index`, 0-based, without its newline; undefined past the last. */
65 at(index: number): string | undefined {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected