aboutsummaryrefslogtreecommitdiff
path: root/crates/ide/src/completion/complete_attribute.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ide/src/completion/complete_attribute.rs')
-rw-r--r--crates/ide/src/completion/complete_attribute.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/crates/ide/src/completion/complete_attribute.rs b/crates/ide/src/completion/complete_attribute.rs
index b193c6387..042c3ecef 100644
--- a/crates/ide/src/completion/complete_attribute.rs
+++ b/crates/ide/src/completion/complete_attribute.rs
@@ -9,7 +9,7 @@ use syntax::{ast, AstNode, SyntaxKind};
9use crate::completion::{ 9use crate::completion::{
10 completion_context::CompletionContext, 10 completion_context::CompletionContext,
11 completion_item::{CompletionItem, CompletionItemKind, CompletionKind, Completions}, 11 completion_item::{CompletionItem, CompletionItemKind, CompletionKind, Completions},
12 UNSTABLE_FEATURE_DESCRIPTOR, 12 generated_features::FEATURES,
13}; 13};
14 14
15pub(super) fn complete_attribute(acc: &mut Completions, ctx: &CompletionContext) -> Option<()> { 15pub(super) fn complete_attribute(acc: &mut Completions, ctx: &CompletionContext) -> Option<()> {
@@ -19,7 +19,7 @@ pub(super) fn complete_attribute(acc: &mut Completions, ctx: &CompletionContext)
19 complete_derive(acc, ctx, token_tree) 19 complete_derive(acc, ctx, token_tree)
20 } 20 }
21 (Some(path), Some(token_tree)) if path.to_string() == "feature" => { 21 (Some(path), Some(token_tree)) if path.to_string() == "feature" => {
22 complete_lint(acc, ctx, token_tree, UNSTABLE_FEATURE_DESCRIPTOR) 22 complete_lint(acc, ctx, token_tree, FEATURES)
23 } 23 }
24 (Some(path), Some(token_tree)) 24 (Some(path), Some(token_tree))
25 if ["allow", "warn", "deny", "forbid"] 25 if ["allow", "warn", "deny", "forbid"]
@@ -237,7 +237,7 @@ fn get_derive_names_in_scope(ctx: &CompletionContext) -> FxHashSet<String> {
237 result 237 result
238} 238}
239 239
240pub(crate) struct DeriveCompletion { 240struct DeriveCompletion {
241 label: &'static str, 241 label: &'static str,
242 dependencies: &'static [&'static str], 242 dependencies: &'static [&'static str],
243} 243}
@@ -257,9 +257,9 @@ const DEFAULT_DERIVE_COMPLETIONS: &[DeriveCompletion] = &[
257 DeriveCompletion { label: "Ord", dependencies: &["PartialOrd", "Eq", "PartialEq"] }, 257 DeriveCompletion { label: "Ord", dependencies: &["PartialOrd", "Eq", "PartialEq"] },
258]; 258];
259 259
260pub(crate) struct LintCompletion { 260pub(super) struct LintCompletion {
261 pub(crate) label: &'static str, 261 pub(super) label: &'static str,
262 pub(crate) description: &'static str, 262 pub(super) description: &'static str,
263} 263}
264 264
265#[rustfmt::skip] 265#[rustfmt::skip]