aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_lsp_server/src
diff options
context:
space:
mode:
authorJeremy Kolb <[email protected]>2019-07-04 19:57:14 +0100
committerJeremy Kolb <[email protected]>2019-07-04 21:57:52 +0100
commit9bfdab7089429bd6f43d1e2683598d40eb476c2a (patch)
tree0761addc409d090967c27fee599be6796a1ad36c /crates/ra_lsp_server/src
parentcf8e59ddd8762a68495443ecd0c62522c836d3d4 (diff)
Update to lsp-types 0.58.0
Diffstat (limited to 'crates/ra_lsp_server/src')
-rw-r--r--crates/ra_lsp_server/src/main_loop/handlers.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/crates/ra_lsp_server/src/main_loop/handlers.rs b/crates/ra_lsp_server/src/main_loop/handlers.rs
index bbbc93b1c..aea94ad0d 100644
--- a/crates/ra_lsp_server/src/main_loop/handlers.rs
+++ b/crates/ra_lsp_server/src/main_loop/handlers.rs
@@ -2,7 +2,7 @@ use std::{fmt::Write as _, io::Write as _};
2 2
3use gen_lsp_server::ErrorCode; 3use gen_lsp_server::ErrorCode;
4use lsp_types::{ 4use lsp_types::{
5 CodeAction, CodeActionResponse, CodeLens, Command, Diagnostic, DiagnosticSeverity, 5 CodeAction, CodeActionOrCommand, CodeActionResponse, CodeLens, Command, Diagnostic, DiagnosticSeverity,
6 DocumentFormattingParams, DocumentHighlight, DocumentSymbol, FoldingRange, FoldingRangeKind, 6 DocumentFormattingParams, DocumentHighlight, DocumentSymbol, FoldingRange, FoldingRangeKind,
7 FoldingRangeParams, Hover, HoverContents, Location, MarkupContent, MarkupKind, Position, 7 FoldingRangeParams, Hover, HoverContents, Location, MarkupContent, MarkupKind, Position,
8 PrepareRenameResponse, Range, RenameParams, SymbolInformation, TextDocumentIdentifier, 8 PrepareRenameResponse, Range, RenameParams, SymbolInformation, TextDocumentIdentifier,
@@ -665,7 +665,7 @@ pub fn handle_code_action(
665 665
666 let assists = world.analysis().assists(FileRange { file_id, range })?.into_iter(); 666 let assists = world.analysis().assists(FileRange { file_id, range })?.into_iter();
667 let diagnostics = world.analysis().diagnostics(file_id)?; 667 let diagnostics = world.analysis().diagnostics(file_id)?;
668 let mut res: Vec<CodeAction> = Vec::new(); 668 let mut res: CodeActionResponse = Default::default();
669 669
670 let fixes_from_diagnostics = diagnostics 670 let fixes_from_diagnostics = diagnostics
671 .into_iter() 671 .into_iter()
@@ -689,7 +689,7 @@ pub fn handle_code_action(
689 edit: None, 689 edit: None,
690 command: Some(command), 690 command: Some(command),
691 }; 691 };
692 res.push(action); 692 res.push(CodeActionOrCommand::CodeAction(action));
693 } 693 }
694 694
695 for assist in assists { 695 for assist in assists {
@@ -711,10 +711,10 @@ pub fn handle_code_action(
711 edit: None, 711 edit: None,
712 command: Some(command), 712 command: Some(command),
713 }; 713 };
714 res.push(action); 714 res.push(CodeActionOrCommand::CodeAction(action));
715 } 715 }
716 716
717 Ok(Some(CodeActionResponse::Actions(res))) 717 Ok(Some(res))
718} 718}
719 719
720pub fn handle_code_lens( 720pub fn handle_code_lens(