pub struct FileEolState {
pub old_has_final_newline: bool,
pub new_has_final_newline: bool,
pub old_line_count: usize,
pub new_line_count: usize,
}Expand description
Trailing-newline state for both sides of a file change, plus the
total line count per side. The patch renderer reads these to decide
whether to emit \ No newline at end of file and where.
Fields§
§old_has_final_newline: bool§new_has_final_newline: bool§old_line_count: usize§new_line_count: usizeTrait Implementations§
Source§impl Clone for FileEolState
impl Clone for FileEolState
Source§fn clone(&self) -> FileEolState
fn clone(&self) -> FileEolState
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for FileEolState
Source§impl Debug for FileEolState
impl Debug for FileEolState
Auto Trait Implementations§
impl Freeze for FileEolState
impl RefUnwindSafe for FileEolState
impl Send for FileEolState
impl Sync for FileEolState
impl Unpin for FileEolState
impl UnsafeUnpin for FileEolState
impl UnwindSafe for FileEolState
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