import type { Anchor, HashlineEdit, HashlineApplyReport, RawHashlineEdit } from "./types"; /** * Parse a line reference string like "5#VK" into structured form. * Tolerant: strips leading >+- markers, flexible whitespace, ignores trailing content. */ export declare function parseTag(ref: string): Anchor; /** * Normalize a raw edit from the tool boundary into a typed internal edit. */ export declare function normalizeEdit(raw: RawHashlineEdit, index: number): HashlineEdit; interface HashMismatch { line: number; expected: string; } export declare class HashlineMismatchError extends Error { readonly mismatches: HashMismatch[]; readonly fileLines: string[]; readonly remaps: ReadonlyMap; constructor(mismatches: HashMismatch[], fileLines: string[]); static formatMessage(mismatches: HashMismatch[], fileLines: string[]): string; } /** * Apply an array of hashline edits to file content. * * Follows the oh-my-pi architecture: * 1. Pre-validate all references (collect all mismatches before mutating) * 2. Deduplicate identical edits * 3. Sort bottom-up (highest effective line first) * 4. Apply splices in order * * Returns the modified content and metadata. */ export declare function applyHashlineEdits(content: string, edits: HashlineEdit[]): HashlineApplyReport; /** * Convenience wrapper: normalize raw edits and apply them. */ export declare function applyRawHashlineEdits(content: string, rawEdits: RawHashlineEdit[]): HashlineApplyReport; export {};