From c1e295682ec23b7f9923cda07fc28d99c987f327 Mon Sep 17 00:00:00 2001 From: Florian Diebold Date: Sun, 10 Feb 2019 15:34:04 +0100 Subject: Implement glob imports from enums --- crates/ra_hir/src/code_model_api.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'crates/ra_hir/src/code_model_api.rs') diff --git a/crates/ra_hir/src/code_model_api.rs b/crates/ra_hir/src/code_model_api.rs index 19f103855..94a08aa63 100644 --- a/crates/ra_hir/src/code_model_api.rs +++ b/crates/ra_hir/src/code_model_api.rs @@ -327,7 +327,7 @@ impl Enum { db.enum_data(*self).name.clone() } - pub fn variants(&self, db: &impl HirDatabase) -> Vec { + pub fn variants(&self, db: &impl PersistentHirDatabase) -> Vec { db.enum_data(*self) .variants .iter() @@ -389,7 +389,7 @@ impl EnumVariant { self.parent } - pub fn name(&self, db: &impl HirDatabase) -> Option { + pub fn name(&self, db: &impl PersistentHirDatabase) -> Option { db.enum_data(self.parent).variants[self.id].name.clone() } -- cgit v1.2.3