pub struct Hunk<'a, T: ?Sized> { /* private fields */ }
Expand description
Represents a group of differing lines between two files
Implementations§
source§impl<'a, T: ?Sized> Hunk<'a, T>
impl<'a, T: ?Sized> Hunk<'a, T>
sourcepub fn old_range(&self) -> HunkRange
pub fn old_range(&self) -> HunkRange
Returns the corresponding range for the old file in the hunk
sourcepub fn new_range(&self) -> HunkRange
pub fn new_range(&self) -> HunkRange
Returns the corresponding range for the new file in the hunk
sourcepub fn function_context(&self) -> Option<&T>
pub fn function_context(&self) -> Option<&T>
Returns the function context (if any) for the hunk
Trait Implementations§
source§impl<'a, T: PartialEq + ?Sized> PartialEq for Hunk<'a, T>
impl<'a, T: PartialEq + ?Sized> PartialEq for Hunk<'a, T>
impl<'a, T: Eq + ?Sized> Eq for Hunk<'a, T>
impl<'a, T: ?Sized> StructuralEq for Hunk<'a, T>
impl<'a, T: ?Sized> StructuralPartialEq for Hunk<'a, T>
Auto Trait Implementations§
impl<'a, T: ?Sized> RefUnwindSafe for Hunk<'a, T>where T: RefUnwindSafe,
impl<'a, T: ?Sized> Send for Hunk<'a, T>where T: Sync,
impl<'a, T: ?Sized> Sync for Hunk<'a, T>where T: Sync,
impl<'a, T: ?Sized> Unpin for Hunk<'a, T>
impl<'a, T: ?Sized> UnwindSafe for Hunk<'a, T>where T: RefUnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more