Struct git_repository::object::tree::diff::change::DiffPlatform
source · pub struct DiffPlatform<'old, 'new> { /* private fields */ }
Expand description
A platform to keep temporary information to perform line diffs.
Implementations
sourceimpl<'old, 'new> DiffPlatform<'old, 'new>
impl<'old, 'new> DiffPlatform<'old, 'new>
sourcepub fn lines<FnS, S>(&self, new_sink: FnS) -> S::Outwhere
FnS: for<'a> FnOnce(&InternedInput<&'a [u8]>) -> S,
S: Sink,
pub fn lines<FnS, S>(&self, new_sink: FnS) -> S::Outwhere
FnS: for<'a> FnOnce(&InternedInput<&'a [u8]>) -> S,
S: Sink,
Perform a diff on lines between the old and the new version of a blob.
The algorithm is determined by the diff.algorithm
configuration.
Note that the [Sink
][git_diff::text::imara::Sink] implementation is
what makes the diff usable and relies heavily on what the caller requires, as created by make_sink
.
Auto Trait Implementations
impl<'old, 'new> !RefUnwindSafe for DiffPlatform<'old, 'new>
impl<'old, 'new> !Send for DiffPlatform<'old, 'new>
impl<'old, 'new> !Sync for DiffPlatform<'old, 'new>
impl<'old, 'new> Unpin for DiffPlatform<'old, 'new>
impl<'old, 'new> !UnwindSafe for DiffPlatform<'old, 'new>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more