Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/ide-db/src/source_change.rs')
-rw-r--r--crates/ide-db/src/source_change.rs12
1 files changed, 0 insertions, 12 deletions
diff --git a/crates/ide-db/src/source_change.rs b/crates/ide-db/src/source_change.rs
index 1a3fc0f358..a38154420a 100644
--- a/crates/ide-db/src/source_change.rs
+++ b/crates/ide-db/src/source_change.rs
@@ -232,17 +232,10 @@ pub struct SourceChangeBuilder {
/// Keeps track of which annotations correspond to which snippets
pub snippet_annotations: Vec<(AnnotationSnippet, SyntaxAnnotation)>,
- /// Maps the original, immutable `SyntaxNode` to a `clone_for_update` twin.
- mutated_tree: Option<TreeMutator>,
/// Keeps track of where to place snippets
pub snippet_builder: Option<SnippetBuilder>,
}
-struct TreeMutator {
- immutable: SyntaxNode,
- mutable_clone: SyntaxNode,
-}
-
#[derive(Default)]
pub struct SnippetBuilder {
/// Where to place snippets at
@@ -258,7 +251,6 @@ impl SourceChangeBuilder {
command: None,
file_editors: FxHashMap::default(),
snippet_annotations: vec![],
- mutated_tree: None,
snippet_builder: None,
}
}
@@ -343,10 +335,6 @@ impl SourceChangeBuilder {
)
});
- if let Some(tm) = self.mutated_tree.take() {
- diff(&tm.immutable, &tm.mutable_clone).into_text_edit(&mut self.edit);
- }
-
let edit = mem::take(&mut self.edit).finish();
if !edit.is_empty() || snippet_edit.is_some() {
self.source_change.insert_source_and_snippet_edit(self.file_id, edit, snippet_edit);