Skip to main content

file_diff

Function file_diff 

Source
pub fn file_diff(
    a: Option<&str>,
    b: Option<&str>,
    a_path: Option<&str>,
    b_path: Option<&str>,
    context_lines: usize,
) -> FileDiff
Expand description

Convenience: diff two text strings, treating absent strings as empty (file added/deleted). Provided for tests and for callers that already hold UTF-8 strings.