mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-01 14:21:44 +00:00
Symplify by using into()
This commit is contained in:
parent
0ab5b1121a
commit
b4c0c7f79c
2 changed files with 7 additions and 7 deletions
|
@ -2,7 +2,7 @@ use std::{fmt::Write as _, io::Write as _};
|
|||
|
||||
use gen_lsp_server::ErrorCode;
|
||||
use lsp_types::{
|
||||
CodeAction, CodeActionOrCommand, CodeActionResponse, CodeLens, Command, Diagnostic,
|
||||
CodeAction, CodeActionResponse, CodeLens, Command, Diagnostic,
|
||||
DiagnosticSeverity, DocumentFormattingParams, DocumentHighlight, DocumentSymbol, FoldingRange,
|
||||
FoldingRangeKind, FoldingRangeParams, Hover, HoverContents, Location, MarkupContent,
|
||||
MarkupKind, Position, PrepareRenameResponse, Range, RenameParams, SymbolInformation,
|
||||
|
@ -689,7 +689,7 @@ pub fn handle_code_action(
|
|||
edit: None,
|
||||
command: Some(command),
|
||||
};
|
||||
res.push(CodeActionOrCommand::CodeAction(action));
|
||||
res.push(action.into());
|
||||
}
|
||||
|
||||
for assist in assists {
|
||||
|
@ -711,7 +711,7 @@ pub fn handle_code_action(
|
|||
edit: None,
|
||||
command: Some(command),
|
||||
};
|
||||
res.push(CodeActionOrCommand::CodeAction(action));
|
||||
res.push(action.into());
|
||||
}
|
||||
|
||||
Ok(Some(res))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue