Differ Rust library

Find the differences between two sequences

Differ is a Rust library for finding the differences between two sequences.

The sequences can be vectors of lines, strings (e.g., words), characters, bytes, or of any custom “item” type so long as it implements the Hash and Eq traits (and uses the same data for both).

For your Cargo.toml add this to the [dependencies] section:

differ = "1.0.2"

If you want to be able to serialize or deserialize Matches, Spans, or Tags, use:

differ = { version = "1.0.2", features = ["use_serde"] }

Then, in your crate root, for Rust 2015 add extern crate differ, and for Rust 2018 or 2021 add use differ.

API documentation (with examples) — Source code: github.

Changes

Top