aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
Diffstat (limited to 'crates')
-rw-r--r--crates/ra_analysis/src/imp.rs4
-rw-r--r--crates/ra_analysis/src/lib.rs4
-rw-r--r--crates/ra_lsp_server/src/conv.rs4
3 files changed, 6 insertions, 6 deletions
diff --git a/crates/ra_analysis/src/imp.rs b/crates/ra_analysis/src/imp.rs
index b44d9297a..cefe5a748 100644
--- a/crates/ra_analysis/src/imp.rs
+++ b/crates/ra_analysis/src/imp.rs
@@ -25,7 +25,7 @@ use crate::{
25 db, 25 db,
26 symbol_index::{SymbolIndex, SymbolsDatabase, LibrarySymbolsQuery}, 26 symbol_index::{SymbolIndex, SymbolsDatabase, LibrarySymbolsQuery},
27 AnalysisChange, RootChange, Cancelable, CrateId, Diagnostic, FileId, 27 AnalysisChange, RootChange, Cancelable, CrateId, Diagnostic, FileId,
28 FileSystemEdit, FilePosition, Query, SourceChange, SourceFileNodeEdit, 28 FileSystemEdit, FilePosition, Query, SourceChange, SourceFileEdit,
29 ReferenceResolution, 29 ReferenceResolution,
30}; 30};
31 31
@@ -518,7 +518,7 @@ impl AnalysisImpl {
518 518
519impl SourceChange { 519impl SourceChange {
520 pub(crate) fn from_local_edit(file_id: FileId, label: &str, edit: LocalEdit) -> SourceChange { 520 pub(crate) fn from_local_edit(file_id: FileId, label: &str, edit: LocalEdit) -> SourceChange {
521 let file_edit = SourceFileNodeEdit { 521 let file_edit = SourceFileEdit {
522 file_id, 522 file_id,
523 edits: edit.edit.into_atoms(), 523 edits: edit.edit.into_atoms(),
524 }; 524 };
diff --git a/crates/ra_analysis/src/lib.rs b/crates/ra_analysis/src/lib.rs
index a1d462528..d5725ef2e 100644
--- a/crates/ra_analysis/src/lib.rs
+++ b/crates/ra_analysis/src/lib.rs
@@ -159,13 +159,13 @@ impl AnalysisHost {
159#[derive(Debug)] 159#[derive(Debug)]
160pub struct SourceChange { 160pub struct SourceChange {
161 pub label: String, 161 pub label: String,
162 pub source_file_edits: Vec<SourceFileNodeEdit>, 162 pub source_file_edits: Vec<SourceFileEdit>,
163 pub file_system_edits: Vec<FileSystemEdit>, 163 pub file_system_edits: Vec<FileSystemEdit>,
164 pub cursor_position: Option<FilePosition>, 164 pub cursor_position: Option<FilePosition>,
165} 165}
166 166
167#[derive(Debug)] 167#[derive(Debug)]
168pub struct SourceFileNodeEdit { 168pub struct SourceFileEdit {
169 pub file_id: FileId, 169 pub file_id: FileId,
170 pub edits: Vec<AtomTextEdit>, 170 pub edits: Vec<AtomTextEdit>,
171} 171}
diff --git a/crates/ra_lsp_server/src/conv.rs b/crates/ra_lsp_server/src/conv.rs
index 7467f472c..198dbfc49 100644
--- a/crates/ra_lsp_server/src/conv.rs
+++ b/crates/ra_lsp_server/src/conv.rs
@@ -2,7 +2,7 @@ use languageserver_types::{
2 self, Location, Position, Range, SymbolKind, TextDocumentEdit, TextDocumentIdentifier, 2 self, Location, Position, Range, SymbolKind, TextDocumentEdit, TextDocumentIdentifier,
3 TextDocumentItem, TextDocumentPositionParams, Url, VersionedTextDocumentIdentifier, 3 TextDocumentItem, TextDocumentPositionParams, Url, VersionedTextDocumentIdentifier,
4}; 4};
5use ra_analysis::{FileId, FileSystemEdit, SourceChange, SourceFileNodeEdit, FilePosition}; 5use ra_analysis::{FileId, FileSystemEdit, SourceChange, SourceFileEdit, FilePosition};
6use ra_editor::{LineCol, LineIndex}; 6use ra_editor::{LineCol, LineIndex};
7use ra_text_edit::{AtomTextEdit, TextEdit}; 7use ra_text_edit::{AtomTextEdit, TextEdit};
8use ra_syntax::{SyntaxKind, TextRange, TextUnit}; 8use ra_syntax::{SyntaxKind, TextRange, TextUnit};
@@ -256,7 +256,7 @@ fn translate_offset_with_edit(
256 } 256 }
257} 257}
258 258
259impl TryConvWith for SourceFileNodeEdit { 259impl TryConvWith for SourceFileEdit {
260 type Ctx = ServerWorld; 260 type Ctx = ServerWorld;
261 type Output = TextDocumentEdit; 261 type Output = TextDocumentEdit;
262 fn try_conv_with(self, world: &ServerWorld) -> Result<TextDocumentEdit> { 262 fn try_conv_with(self, world: &ServerWorld) -> Result<TextDocumentEdit> {