From ee1628dba051e691a4ced756ab3cb360543609fa Mon Sep 17 00:00:00 2001 From: kjeremy Date: Sun, 26 Apr 2020 18:58:15 -0400 Subject: Mark most assists as the base "refactor" type Most of them area. We will separate them out later but this gets them to show up in the "refactor" menu of vscode. --- crates/rust-analyzer/src/main_loop/handlers.rs | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) (limited to 'crates') diff --git a/crates/rust-analyzer/src/main_loop/handlers.rs b/crates/rust-analyzer/src/main_loop/handlers.rs index b4e539906..647bdc426 100644 --- a/crates/rust-analyzer/src/main_loop/handlers.rs +++ b/crates/rust-analyzer/src/main_loop/handlers.rs @@ -19,8 +19,7 @@ use lsp_types::{ TextEdit, Url, WorkspaceEdit, }; use ra_ide::{ - Assist, AssistId, FileId, FilePosition, FileRange, Query, RangeInfo, Runnable, RunnableKind, - SearchScope, + Assist, FileId, FilePosition, FileRange, Query, RangeInfo, Runnable, RunnableKind, SearchScope, }; use ra_prof::profile; use ra_syntax::{AstNode, SyntaxKind, TextRange, TextSize}; @@ -702,15 +701,9 @@ fn create_single_code_action(assist: Assist, world: &WorldSnapshot) -> Result Some("refactor.extract.variable".to_string()), - AssistId("add_custom_impl") => Some("refactor.rewrite.add_custom_impl".to_string()), - _ => None, - }; - Ok(CodeAction { title, - kind, + kind: Some("refactor".to_owned()), diagnostics: None, edit: None, command: Some(command), -- cgit v1.2.3