Skip to main content

MapDiagnostic

Type Alias MapDiagnostic 

Source
pub type MapDiagnostic<'a> = dyn Fn(&mut FileDb, &mut Diagnostic) -> bool + 'a;
Expand description

Rewrites a diagnostic before it is counted and rendered, with the program’s files at hand (spec docs/superpowers/specs/2026-10-11-phase-3-5b-doc-tests-design.md §7): it may move the diagnostic’s labels into other files of the database, adding them. false hides a warning; an error is always shown.