From 81ba51fc3cfb99b48481eb8dd5a7a60511a64205 Mon Sep 17 00:00:00 2001 From: Armin Ronacher Date: Wed, 3 Feb 2021 22:51:47 +0100 Subject: [PATCH] Added comment to TextDiff --- src/text/mod.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/text/mod.rs b/src/text/mod.rs index 8c5e6b7..6e6d5c8 100644 --- a/src/text/mod.rs +++ b/src/text/mod.rs @@ -163,6 +163,11 @@ impl TextDiffConfig { /// Captures diff op codes for textual diffs. /// +/// The exact diff behavior is depending on the underlying [`DiffableStr`]. +/// For instance diffs on bytes and strings are slightly different. You can +/// create a text diff from constructors such as [`TextDiff::from_lines`] or +/// the [`TextDiffConfig`] created by [`TextDiff::configure`]. +/// /// Requires the `text` feature. pub struct TextDiff<'old, 'new, 'bufs, T: DiffableStr + ?Sized> { old: Cow<'bufs, [&'old T]>,