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

Function onOneLine

src/extraction/languages/pascal-preparse.ts:782–788  ·  view source on GitHub ↗

Whether `[at, at + length)` holds no line break, so a word written there keeps every line where it is.

(s: string, at: number, length: number)

Source from the content-addressed store, hash-verified

780
781/** Whether `[at, at + length)` holds no line break, so a word written there keeps every line where it is. */
782function onOneLine(s: string, at: number, length: number): boolean {
783 for (let i = at; i < at + length; i++) {
784 const c = s.charCodeAt(i);
785 if (c === CH_LF || c === CH_CR) return false;
786 }
787 return true;
788}
789
790/**
791 * Read as one statement each conditional whose branches are alternative statements where the grammar takes just

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected