pub struct Hunk<'a> {
pub old_range: Range,
pub new_range: Range,
pub range_hint: &'a str,
pub lines: Vec<Line<'a>>,
}
Expand description
One area where the files differ
Fields§
§old_range: Range
The range of lines in the old file that this hunk represents
new_range: Range
The range of lines in the new file that this hunk represents
range_hint: &'a str
Any trailing text after the hunk’s range information
lines: Vec<Line<'a>>
Each line of text in the hunk, prefixed with the type of change it represents
Implementations§
Trait Implementations§
impl<'a> Eq for Hunk<'a>
impl<'a> StructuralPartialEq for Hunk<'a>
Auto Trait Implementations§
impl<'a> Freeze for Hunk<'a>
impl<'a> RefUnwindSafe for Hunk<'a>
impl<'a> Send for Hunk<'a>
impl<'a> Sync for Hunk<'a>
impl<'a> Unpin for Hunk<'a>
impl<'a> UnwindSafe for Hunk<'a>
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