MCPcopy Create free account
hub / github.com/aiscript-dev/aiscript / loadPrevChar

Method loadPrevChar

src/parser/streams/char-stream.ts:155–162  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

153 }
154
155 private loadPrevChar(): void {
156 if (this.address > 0) {
157 this._char = getLastUnicodeChar(this.pages.get(this.pageIndex)!, this.address)!;
158 } else if (!this.isFirstPage) {
159 const page = this.pages.get(this.pageIndex - 1)!;
160 this._char = getLastUnicodeChar(page)!;
161 }
162 }
163}
164
165function getUnicodeChar(string: string, position = 0): string | undefined {

Callers 1

movePrevMethod · 0.95

Calls 2

getLastUnicodeCharFunction · 0.85
getMethod · 0.65

Tested by

no test coverage detected