pub struct CloneInstance {
pub file: PathBuf,
pub start_line: usize,
pub end_line: usize,
pub start_col: usize,
pub end_col: usize,
pub fragment: String,
}Expand description
A single instance of duplicated code at a specific location.
Fields§
§file: PathBufPath to the file containing this clone instance.
start_line: usize1-based start line of the clone.
end_line: usize1-based end line of the clone.
start_col: usize0-based start column.
end_col: usize0-based end column.
fragment: StringThe actual source code fragment.
Omitted from JSON when the caller asked for a location-only payload
(fallow dupes --no-fragments, and the MCP find_dupes default). The
five location fields above address the same text, so a consumer that
wants the source reads it from the file.
Trait Implementations§
Source§impl Clone for CloneInstance
impl Clone for CloneInstance
Source§impl Debug for CloneInstance
impl Debug for CloneInstance
Source§impl<'de> Deserialize<'de> for CloneInstance
impl<'de> Deserialize<'de> for CloneInstance
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
Auto Trait Implementations§
impl Freeze for CloneInstance
impl RefUnwindSafe for CloneInstance
impl Send for CloneInstance
impl Sync for CloneInstance
impl Unpin for CloneInstance
impl UnsafeUnpin for CloneInstance
impl UnwindSafe for CloneInstance
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