MCPcopy Create free account
hub / github.com/cortex-js/compute-engine / error

Function error

src/common/parser.ts:74–85  ·  view source on GitHub ↗
(message: string)

Source from the content-addressed store, hash-verified

72 }
73
74 error(message: string): never {
75 const { line, col } = this.lineCol;
76 // message = message.replace(/\n/g, ' ');
77 // message = message.replace(/\s+/g, ' '); // Normalize whitespace
78 // message = message.trim();
79 // if (message.endsWith('.')) message = message.slice(0, -1); // Remove trailing period
80 message = `|${this.getLine(line)}\n|${' '.repeat(
81 col - 1
82 )}^\n| ${line}:${col}: ${message}`;
83
84 throw new Error(message);
85 }
86
87 // @todo: atString()?, or just at()?
88 match(pattern: string): boolean {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected