From 80386ca5be78d8ea65483df3edeec1a89b09a5a3 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Wed, 1 Jul 2020 10:03:07 +0200 Subject: Use Strings for display names --- crates/ra_hir/src/code_model.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'crates/ra_hir/src') diff --git a/crates/ra_hir/src/code_model.rs b/crates/ra_hir/src/code_model.rs index e86077dd6..e09eb77c2 100644 --- a/crates/ra_hir/src/code_model.rs +++ b/crates/ra_hir/src/code_model.rs @@ -31,7 +31,7 @@ use hir_ty::{ ApplicationTy, Canonical, GenericPredicate, InEnvironment, Substs, TraitEnvironment, Ty, TyDefId, TypeCtor, }; -use ra_db::{CrateId, CrateName, Edition, FileId}; +use ra_db::{CrateId, Edition, FileId}; use ra_prof::profile; use ra_syntax::ast::{self, AttrsOwner, NameOwner}; use rustc_hash::FxHashSet; @@ -94,8 +94,8 @@ impl Crate { db.crate_graph()[self.id].edition } - pub fn display_name(self, db: &dyn HirDatabase) -> Option { - db.crate_graph()[self.id].display_name.as_ref().cloned() + pub fn display_name(self, db: &dyn HirDatabase) -> Option { + db.crate_graph()[self.id].display_name.clone() } pub fn query_external_importables( -- cgit v1.2.3