mirror of
https://github.com/rust-lang/rust-analyzer
synced 2025-01-12 05:08:52 +00:00
Merge #6523
6523: Be more pedantic when checking codeAction/resolve support r=matklad a=matklad
bors r+
🤖
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
This commit is contained in:
commit
111cc34c8f
1 changed files with 6 additions and 3 deletions
|
@ -385,11 +385,14 @@ impl Config {
|
||||||
}
|
}
|
||||||
|
|
||||||
if let Some(code_action) = &doc_caps.code_action {
|
if let Some(code_action) = &doc_caps.code_action {
|
||||||
if let Some(resolve_support) = &code_action.resolve_support {
|
match (code_action.data_support, &code_action.resolve_support) {
|
||||||
|
(Some(true), Some(resolve_support)) => {
|
||||||
if resolve_support.properties.iter().any(|it| it == "edit") {
|
if resolve_support.properties.iter().any(|it| it == "edit") {
|
||||||
self.client_caps.code_action_resolve = true;
|
self.client_caps.code_action_resolve = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
_ => (),
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue