aboutsummaryrefslogtreecommitdiff
path: root/crates/rust-analyzer/src/to_proto.rs
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2021-05-31 13:42:32 +0100
committerGitHub <[email protected]>2021-05-31 13:42:32 +0100
commite9a797748daa7e25cde66927b8907b2d976201a5 (patch)
tree438bb6e1a2c5e422ee18994d2e045480b429d549 /crates/rust-analyzer/src/to_proto.rs
parentb8d269990c57634e77f4702afc91041bacb4816a (diff)
parentacb5c227ed2d2d52d67ab56a61e6944cd4d5de88 (diff)
Merge #8866
8866: Update salsa r=matklad a=jonas-schievink This updates salsa to include https://github.com/salsa-rs/salsa/pull/265, and removes all cancellation-related code from rust-analyzer Co-authored-by: Jonas Schievink <[email protected]>
Diffstat (limited to 'crates/rust-analyzer/src/to_proto.rs')
-rw-r--r--crates/rust-analyzer/src/to_proto.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/rust-analyzer/src/to_proto.rs b/crates/rust-analyzer/src/to_proto.rs
index f5c8535a2..85898f495 100644
--- a/crates/rust-analyzer/src/to_proto.rs
+++ b/crates/rust-analyzer/src/to_proto.rs
@@ -6,7 +6,7 @@ use std::{
6}; 6};
7 7
8use ide::{ 8use ide::{
9 Annotation, AnnotationKind, Assist, AssistKind, CallInfo, Cancelable, CompletionItem, 9 Annotation, AnnotationKind, Assist, AssistKind, CallInfo, Cancellable, CompletionItem,
10 CompletionItemKind, CompletionRelevance, Documentation, FileId, FileRange, FileSystemEdit, 10 CompletionItemKind, CompletionRelevance, Documentation, FileId, FileRange, FileSystemEdit,
11 Fold, FoldKind, Highlight, HlMod, HlOperator, HlPunct, HlRange, HlTag, Indel, InlayHint, 11 Fold, FoldKind, Highlight, HlMod, HlOperator, HlPunct, HlRange, HlTag, Indel, InlayHint,
12 InlayKind, InsertTextFormat, Markup, NavigationTarget, ReferenceAccess, RenameError, Runnable, 12 InlayKind, InsertTextFormat, Markup, NavigationTarget, ReferenceAccess, RenameError, Runnable,
@@ -727,7 +727,7 @@ pub(crate) fn snippet_text_document_edit(
727pub(crate) fn snippet_text_document_ops( 727pub(crate) fn snippet_text_document_ops(
728 snap: &GlobalStateSnapshot, 728 snap: &GlobalStateSnapshot,
729 file_system_edit: FileSystemEdit, 729 file_system_edit: FileSystemEdit,
730) -> Cancelable<Vec<lsp_ext::SnippetDocumentChangeOperation>> { 730) -> Cancellable<Vec<lsp_ext::SnippetDocumentChangeOperation>> {
731 let mut ops = Vec::new(); 731 let mut ops = Vec::new();
732 match file_system_edit { 732 match file_system_edit {
733 FileSystemEdit::CreateFile { dst, initial_contents } => { 733 FileSystemEdit::CreateFile { dst, initial_contents } => {
@@ -757,7 +757,7 @@ pub(crate) fn snippet_text_document_ops(
757 let new_uri = snap.anchored_path(&dst); 757 let new_uri = snap.anchored_path(&dst);
758 let mut rename_file = 758 let mut rename_file =
759 lsp_types::RenameFile { old_uri, new_uri, options: None, annotation_id: None }; 759 lsp_types::RenameFile { old_uri, new_uri, options: None, annotation_id: None };
760 if snap.analysis.is_library_file(src) == Ok(true) 760 if snap.analysis.is_library_file(src).ok() == Some(true)
761 && snap.config.change_annotation_support() 761 && snap.config.change_annotation_support()
762 { 762 {
763 rename_file.annotation_id = Some(outside_workspace_annotation_id()) 763 rename_file.annotation_id = Some(outside_workspace_annotation_id())