From db162df264a222021dbc7f1f93af94029f3948d9 Mon Sep 17 00:00:00 2001 From: Edwin Cheng Date: Fri, 27 Mar 2020 00:41:44 +0800 Subject: Remove deps on tt_mbe --- crates/ra_hir_def/src/nameres/collector.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'crates/ra_hir_def/src/nameres/collector.rs') diff --git a/crates/ra_hir_def/src/nameres/collector.rs b/crates/ra_hir_def/src/nameres/collector.rs index 9b46431cb..8fe3f8617 100644 --- a/crates/ra_hir_def/src/nameres/collector.rs +++ b/crates/ra_hir_def/src/nameres/collector.rs @@ -12,7 +12,7 @@ use hir_expand::{ }; use ra_cfg::CfgOptions; use ra_db::{CrateId, FileId, ProcMacroId}; -use ra_syntax::{ast, SmolStr}; +use ra_syntax::ast; use rustc_hash::FxHashMap; use test_utils::tested_by; @@ -59,8 +59,8 @@ pub(super) fn collect_defs(db: &dyn DefDatabase, mut def_map: CrateDefMap) -> Cr .enumerate() .map(|(idx, it)| { // FIXME: a hacky way to create a Name from string. - let name = tt::Ident { text: SmolStr::new(&it.name()), id: tt::TokenId::unspecified() }; - (name.as_name(), ProcMacroExpander::new(def_map.krate, ProcMacroId(idx))) + let name = tt::Ident { text: it.name.clone(), id: tt::TokenId::unspecified() }; + (name.as_name(), ProcMacroExpander::new(def_map.krate, ProcMacroId(idx as u32))) }) .collect(); -- cgit v1.2.3