Return the sort tier for a `CompletionItemKind`. Lower values sort first. The order is: 0 — constants and keywords (`::class`) 1 — properties 2 — methods
(kind: Option<CompletionItemKind>)
| 531 | /// 1 — properties |
| 532 | /// 2 — methods |
| 533 | fn kind_sort_tier(kind: Option<CompletionItemKind>) -> u8 { |
| 534 | match kind { |
| 535 | Some(CompletionItemKind::CONSTANT) | Some(CompletionItemKind::KEYWORD) => 0, |
| 536 | Some(CompletionItemKind::PROPERTY) => 1, |
| 537 | Some(CompletionItemKind::METHOD) => 2, |
| 538 | _ => 3, |
| 539 | } |
| 540 | } |
| 541 | |
| 542 | /// Build a `tags` vec with the `DEPRECATED` tag when the member is deprecated. |
| 543 | pub(crate) fn deprecation_tag(is_deprecated: bool) -> Option<Vec<CompletionItemTag>> { |
no outgoing calls