From 328d123f5baeab8ff9a1f63a6744f6eec89818ab Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Sat, 22 Dec 2018 01:37:11 +0300 Subject: specify completion item kind --- crates/ra_analysis/src/completion/complete_snippet.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'crates/ra_analysis/src/completion/complete_snippet.rs') diff --git a/crates/ra_analysis/src/completion/complete_snippet.rs b/crates/ra_analysis/src/completion/complete_snippet.rs index 1feb332b9..91de8ca37 100644 --- a/crates/ra_analysis/src/completion/complete_snippet.rs +++ b/crates/ra_analysis/src/completion/complete_snippet.rs @@ -1,7 +1,9 @@ -use crate::completion::{CompletionItem, Completions, CompletionKind, CompletionContext, completion_item::Builder}; +use crate::completion::{CompletionItem, Completions, CompletionKind, CompletionItemKind, CompletionContext, completion_item::Builder}; fn snippet(label: &str, snippet: &str) -> Builder { - CompletionItem::new(CompletionKind::Snippet, label).snippet(snippet) + CompletionItem::new(CompletionKind::Snippet, label) + .snippet(snippet) + .kind(CompletionItemKind::Keyword) } pub(super) fn complete_expr_snippet(acc: &mut Completions, ctx: &CompletionContext) { -- cgit v1.2.3