import type { Highlight } from './scan.js'; /** One line's pieces, with the line they are on so a caller counts nothing. */ export interface HighlightedLine { /** One-based, the same line a diagnostic's span carries. */ readonly line: number; readonly pieces: readonly Highlight[]; } /** * The pieces of a file, in order, covering every character exactly once. * * Nothing here throws and nothing here reports. A file being typed into is * malformed most of the time, and a highlighter that stopped at the first * character the language does not have would leave the rest of a trader's * script grey while they finished the word. `diagnose` is where the compiler * says what is wrong with it. */ export declare function highlight(source: string): readonly Highlight[]; /** * The same pieces, grouped by line, with every line of the file present. * * A piece that runs across a line ending is cut at it, and the line ending * itself belongs to no line: a renderer draws the text of a line and puts the * break there itself. A blank line is an entry with no pieces rather than a * missing entry, so a caller can walk lines one to `lineCount` and never index * past the end of a shorter list. */ export declare function highlightLines(source: string): readonly HighlightedLine[]; //# sourceMappingURL=highlight.d.ts.map