mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-03 07:04:49 +00:00
Introduce Label
This commit is contained in:
parent
eb81731600
commit
aa1a7a5414
8 changed files with 68 additions and 30 deletions
|
@ -782,10 +782,9 @@ fn handle_fixes(
|
|||
.filter_map(|d| d.fix)
|
||||
.filter(|fix| fix.fix_trigger_range.intersect(range).is_some())
|
||||
{
|
||||
let title = fix.label;
|
||||
let edit = to_proto::snippet_workspace_edit(&snap, fix.source_change)?;
|
||||
let action = lsp_ext::CodeAction {
|
||||
title,
|
||||
title: fix.label.to_string(),
|
||||
id: None,
|
||||
group: None,
|
||||
kind: Some(CodeActionKind::QUICKFIX),
|
||||
|
|
|
@ -704,7 +704,7 @@ pub(crate) fn unresolved_code_action(
|
|||
index: usize,
|
||||
) -> Result<lsp_ext::CodeAction> {
|
||||
let res = lsp_ext::CodeAction {
|
||||
title: assist.label().to_string(),
|
||||
title: assist.label.to_string(),
|
||||
id: Some(format!("{}:{}", assist.id.0, index.to_string())),
|
||||
group: assist.group.filter(|_| snap.config.client_caps.code_action_group).map(|gr| gr.0),
|
||||
kind: Some(code_action_kind(assist.id.1)),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue