mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-29 05:15:04 +00:00
Show deprecated completions for deprecated traits
This commit is contained in:
parent
cc663a7b0c
commit
ca65488276
8 changed files with 69 additions and 28 deletions
|
@ -44,7 +44,9 @@ impl<'a> FunctionRender<'a> {
|
|||
CompletionItem::new(CompletionKind::Reference, self.ctx.source_range(), self.name.clone())
|
||||
.kind(self.kind())
|
||||
.set_documentation(self.ctx.docs(self.func))
|
||||
.set_deprecated(self.ctx.is_deprecated(self.func))
|
||||
.set_deprecated(
|
||||
self.ctx.is_deprecated(self.func) || self.ctx.is_deprecated_assoc_item(self.func),
|
||||
)
|
||||
.detail(self.detail())
|
||||
.add_call_parens(self.ctx.completion, self.name, params)
|
||||
.add_import(import_to_add)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue