/** Original-source range returned from a masked-source pattern match. */ export interface SourceRange { end: number; start: number; } /** * Detects the dominant newline sequence, preferring the repository LF default * when a source contains equal numbers of CRLF and bare LF line endings. */ export declare function detectSourceLineEnding(source: string): '\n' | '\r\n'; /** * Masks TypeScript comments with spaces while preserving newlines and offsets. */ export declare function maskTypeScriptComments(source: string): string; /** * Masks TypeScript comments and quoted/template literals with spaces while * preserving source offsets. This is a lightweight lexer for runtime checks, * not a full TypeScript parser, so template interpolation and regex/division * ambiguity are intentionally left to callers that need deeper syntax analysis. */ export declare function maskTypeScriptCommentsAndLiterals(source: string): string; /** * Tests for a pattern after hiding comments and quoted/template literals. */ export declare function hasExecutablePattern(source: string, pattern: RegExp): boolean; /** * Tests for a pattern after hiding comments while leaving literals intact. */ export declare function hasUncommentedPattern(source: string, pattern: RegExp): boolean; /** * Finds the first masked-source match that maps back to the original source. */ export declare function findExecutablePatternMatch(source: string, patterns: readonly RegExp[]): SourceRange | undefined; /** * Finds the first comment-masked match while retaining string literal content. * * This is useful for imports and path declarations whose patterns need to * inspect literal values without accepting a commented-out declaration. */ export declare function findUncommentedPatternMatch(source: string, patterns: readonly RegExp[]): SourceRange | undefined;