pub struct Fix {
pub start: usize,
pub end: usize,
pub replacement: String,
pub safe: bool,
}Expand description
A replacement for a range of a file’s bytes.
Fields§
§start: usizeByte offset the replacement starts at.
end: usizeByte offset it ends at, exclusive.
replacement: StringWhat to put there.
safe: boolWhether applying it preserves behavior.
false — a suggestion — is the default a rule gets by not saying, because the
cautious mistake costs a manual edit and the other one rewrites code silently.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Fix
impl<'de> Deserialize<'de> for Fix
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Fix
impl StructuralPartialEq for Fix
Auto Trait Implementations§
impl Freeze for Fix
impl RefUnwindSafe for Fix
impl Send for Fix
impl Sync for Fix
impl Unpin for Fix
impl UnsafeUnpin for Fix
impl UnwindSafe for Fix
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