Skip to main content

to_human

Function to_human 

Source
pub fn to_human(
    file_path: &str,
    src: &str,
    diagnostics: &[Diagnostic],
) -> String
Expand description

Render each diagnostic as its own snippet group.

The primary label’s line is shown first; every other label’s line follows in label order. Lines are folded to what each snippet annotates, and the group keeps one error:/warning: title, so a two-location diagnostic (a conflict, say) reads as one problem with two underlines.