Skip to main content

apply_fixes

Function apply_fixes 

Source
pub fn apply_fixes(input: &str, safety: FixSafety) -> FixOutcome
Expand description

Apply every auto-fix at or below the requested safety tier, re-running check after each pass until no applicable fix remains (fixpoint) or MAX_FIX_ITERATIONS passes were applied.

CRLF input is normalised to LF first (the same normalisation parse applies, so edit offsets line up); all other untouched bytes are preserved exactly. Guarantees enforced by property tests: idempotent, converging (an applied fix’s diagnostic is gone on re-check), non-destructive, and deterministic.