diff options
Diffstat (limited to 'crates/rust-analyzer/src/config.rs')
-rw-r--r-- | crates/rust-analyzer/src/config.rs | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/crates/rust-analyzer/src/config.rs b/crates/rust-analyzer/src/config.rs index e012b4452..f809667e9 100644 --- a/crates/rust-analyzer/src/config.rs +++ b/crates/rust-analyzer/src/config.rs | |||
@@ -656,6 +656,19 @@ impl Config { | |||
656 | pub fn code_lens_refresh(&self) -> bool { | 656 | pub fn code_lens_refresh(&self) -> bool { |
657 | try_or!(self.caps.workspace.as_ref()?.code_lens.as_ref()?.refresh_support?, false) | 657 | try_or!(self.caps.workspace.as_ref()?.code_lens.as_ref()?.refresh_support?, false) |
658 | } | 658 | } |
659 | pub fn insert_replace_support(&self) -> bool { | ||
660 | try_or!( | ||
661 | self.caps | ||
662 | .text_document | ||
663 | .as_ref()? | ||
664 | .completion | ||
665 | .as_ref()? | ||
666 | .completion_item | ||
667 | .as_ref()? | ||
668 | .insert_replace_support?, | ||
669 | false | ||
670 | ) | ||
671 | } | ||
659 | } | 672 | } |
660 | 673 | ||
661 | #[derive(Deserialize, Debug, Clone)] | 674 | #[derive(Deserialize, Debug, Clone)] |