From 26753f0e4931e2980f008015cbd709a77d71c0f3 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Tue, 11 Jun 2019 18:07:42 +0300 Subject: remove unneded From(..) impl --- crates/ra_hir/src/ids.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'crates/ra_hir/src/ids.rs') diff --git a/crates/ra_hir/src/ids.rs b/crates/ra_hir/src/ids.rs index a95561812..352f9ffd9 100644 --- a/crates/ra_hir/src/ids.rs +++ b/crates/ra_hir/src/ids.rs @@ -9,7 +9,7 @@ use ra_prof::profile; use mbe::MacroRules; use crate::{ - Module, DefDatabase, AstId, FileAstId, AstDatabase, + Module, DefDatabase, AstId, FileAstId, AstDatabase, Source, }; /// hir makes heavy use of ids: integer (u32) handlers to various things. You @@ -265,10 +265,10 @@ pub(crate) trait AstItemDef: salsa::InternKey + Clone { let loc = ItemLoc { module: ctx.module, ast_id: ast_id.with_file_id(ctx.file_id) }; Self::intern(ctx.db, loc) } - fn source(self, db: &(impl AstDatabase + DefDatabase)) -> (HirFileId, TreeArc) { + fn source(self, db: &(impl AstDatabase + DefDatabase)) -> Source> { let loc = self.lookup_intern(db); let ast = loc.ast_id.to_node(db); - (loc.ast_id.file_id(), ast) + Source { file_id: loc.ast_id.file_id(), ast } } fn module(self, db: &impl DefDatabase) -> Module { let loc = self.lookup_intern(db); -- cgit v1.2.3