/** The lexical categories the {@link tokenize} pass emits. */ export type TokenKind = 'num' | 'str' | 'err' | 'word' | 'sheetq' | 'op' | 'eof'; /** One token: its {@link TokenKind} and the matched source text. */ export interface Token { readonly kind: TokenKind; readonly text: string; } /** Thrown when the source cannot be tokenized (bad character, over-long input). */ export declare class LexError extends Error { } /** * Tokenize a formula string into a flat token stream terminated by an `eof` * token. Whitespace separates tokens but is otherwise dropped. * * @param src The formula source. * @returns The token list, ending with an `eof` token. * @throws LexError when `src` exceeds the source cap or holds an unexpected * character / bad error literal. */ export declare function tokenize(src: string): Array;