aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_ide_db/src
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2020-07-30 17:07:32 +0100
committerGitHub <[email protected]>2020-07-30 17:07:32 +0100
commit8de0eb904baf1fa261a7825402bb3adf0c23b843 (patch)
tree34296539101d8db4a484c472a45a1e30503791ef /crates/ra_ide_db/src
parent97df465391f50521c5102474d7e0ee2ea61ef48e (diff)
parent609680ef97dbf82c07b6b06e21aa366423892304 (diff)
Merge #5603
5603: Rename EnumDef -> Enum r=matklad a=matklad bors r+ 🤖 Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'crates/ra_ide_db/src')
-rw-r--r--crates/ra_ide_db/src/defs.rs2
-rw-r--r--crates/ra_ide_db/src/symbol_index.rs4
2 files changed, 3 insertions, 3 deletions
diff --git a/crates/ra_ide_db/src/defs.rs b/crates/ra_ide_db/src/defs.rs
index 6a2180f6c..586b3d750 100644
--- a/crates/ra_ide_db/src/defs.rs
+++ b/crates/ra_ide_db/src/defs.rs
@@ -158,7 +158,7 @@ pub fn classify_name(sema: &Semantics<RootDatabase>, name: &ast::Name) -> Option
158 let def: hir::Union = sema.to_def(&it)?; 158 let def: hir::Union = sema.to_def(&it)?;
159 Some(NameClass::Definition(Definition::ModuleDef(def.into()))) 159 Some(NameClass::Definition(Definition::ModuleDef(def.into())))
160 }, 160 },
161 ast::EnumDef(it) => { 161 ast::Enum(it) => {
162 let def: hir::Enum = sema.to_def(&it)?; 162 let def: hir::Enum = sema.to_def(&it)?;
163 Some(NameClass::Definition(Definition::ModuleDef(def.into()))) 163 Some(NameClass::Definition(Definition::ModuleDef(def.into())))
164 }, 164 },
diff --git a/crates/ra_ide_db/src/symbol_index.rs b/crates/ra_ide_db/src/symbol_index.rs
index da19f0f33..646d338ae 100644
--- a/crates/ra_ide_db/src/symbol_index.rs
+++ b/crates/ra_ide_db/src/symbol_index.rs
@@ -344,7 +344,7 @@ impl Query {
344} 344}
345 345
346fn is_type(kind: SyntaxKind) -> bool { 346fn is_type(kind: SyntaxKind) -> bool {
347 matches!(kind, STRUCT | ENUM_DEF | TRAIT_DEF | TYPE_ALIAS) 347 matches!(kind, STRUCT | ENUM | TRAIT_DEF | TYPE_ALIAS)
348} 348}
349 349
350/// The actual data that is stored in the index. It should be as compact as 350/// The actual data that is stored in the index. It should be as compact as
@@ -399,7 +399,7 @@ fn to_symbol(node: &SyntaxNode) -> Option<(SmolStr, SyntaxNodePtr, TextRange)> {
399 match node { 399 match node {
400 ast::Fn(it) => decl(it), 400 ast::Fn(it) => decl(it),
401 ast::Struct(it) => decl(it), 401 ast::Struct(it) => decl(it),
402 ast::EnumDef(it) => decl(it), 402 ast::Enum(it) => decl(it),
403 ast::TraitDef(it) => decl(it), 403 ast::TraitDef(it) => decl(it),
404 ast::Module(it) => decl(it), 404 ast::Module(it) => decl(it),
405 ast::TypeAlias(it) => decl(it), 405 ast::TypeAlias(it) => decl(it),