aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2020-11-10 19:39:27 +0000
committerGitHub <[email protected]>2020-11-10 19:39:27 +0000
commit111cc34c8f181315f4dcfa85c616d54d47eff0b9 (patch)
tree550000df7814916070ccc056bdfea81a67958a10 /crates
parent5c06e820fa02b47a1550576f2a7071ff94fb0c64 (diff)
parent0caa4918932cd70b8eef58279a1a5e783ac19fb1 (diff)
Merge #6523
6523: Be more pedantic when checking codeAction/resolve support r=matklad a=matklad bors r+ 🤖 Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'crates')
-rw-r--r--crates/rust-analyzer/src/config.rs9
1 files changed, 6 insertions, 3 deletions
diff --git a/crates/rust-analyzer/src/config.rs b/crates/rust-analyzer/src/config.rs
index 9cc14fe82..b4c738272 100644
--- a/crates/rust-analyzer/src/config.rs
+++ b/crates/rust-analyzer/src/config.rs
@@ -385,10 +385,13 @@ impl Config {
385 } 385 }
386 386
387 if let Some(code_action) = &doc_caps.code_action { 387 if let Some(code_action) = &doc_caps.code_action {
388 if let Some(resolve_support) = &code_action.resolve_support { 388 match (code_action.data_support, &code_action.resolve_support) {
389 if resolve_support.properties.iter().any(|it| it == "edit") { 389 (Some(true), Some(resolve_support)) => {
390 self.client_caps.code_action_resolve = true; 390 if resolve_support.properties.iter().any(|it| it == "edit") {
391 self.client_caps.code_action_resolve = true;
392 }
391 } 393 }
394 _ => (),
392 } 395 }
393 } 396 }
394 } 397 }