Lint
This commit is contained in:
parent
8b8733c1e3
commit
3391d2c0ec
2 changed files with 4 additions and 5 deletions
|
|
@ -37,13 +37,13 @@ where
|
|||
pub fn extend(self, other: RawOperation<T>) -> Option<RawOperation<T>> {
|
||||
match (self, other) {
|
||||
(RawOperation::Insert(tokens1), RawOperation::Insert(tokens2)) => Some(
|
||||
RawOperation::Insert(tokens1.into_iter().chain(tokens2.into_iter()).collect()),
|
||||
RawOperation::Insert(tokens1.into_iter().chain(tokens2).collect()),
|
||||
),
|
||||
(RawOperation::Delete(tokens1), RawOperation::Delete(tokens2)) => Some(
|
||||
RawOperation::Delete(tokens1.into_iter().chain(tokens2.into_iter()).collect()),
|
||||
RawOperation::Delete(tokens1.into_iter().chain(tokens2).collect()),
|
||||
),
|
||||
(RawOperation::Equal(tokens1), RawOperation::Equal(tokens2)) => Some(
|
||||
RawOperation::Equal(tokens1.into_iter().chain(tokens2.into_iter()).collect()),
|
||||
RawOperation::Equal(tokens1.into_iter().chain(tokens2).collect()),
|
||||
),
|
||||
_ => None,
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@ use crate::{diffs::myers::diff, utils::merge_iters::MergeSorted};
|
|||
use ropey::Rope;
|
||||
use std::hash::Hash;
|
||||
use std::iter;
|
||||
use std::path::Iter;
|
||||
|
||||
#[cfg(feature = "serde")]
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
|
@ -59,7 +58,7 @@ impl<'a> EditedText<'a> {
|
|||
Self::new(
|
||||
original,
|
||||
// Self::cook_operations(diff),
|
||||
Self::cook_operations(Self::elongate_operations(diff.into_iter())).collect(),
|
||||
Self::cook_operations(Self::elongate_operations(diff)).collect(),
|
||||
)
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue