aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir/src/has_source.rs
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2019-12-12 14:20:02 +0000
committerGitHub <[email protected]>2019-12-12 14:20:02 +0000
commitc213c3b36b7987504c6c3703b76a637dd0d01355 (patch)
tree36f9066ab25826f9401216d6ff371954eb9f447c /crates/ra_hir/src/has_source.rs
parentd8dba7fbe587ba5fb6cfe939083ccd92c61f5827 (diff)
parent7a255a2f9381ba5886cacc48c1dd0420a739a55c (diff)
Merge #2539
2539: Remove old location infra r=matklad a=matklad Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'crates/ra_hir/src/has_source.rs')
-rw-r--r--crates/ra_hir/src/has_source.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/crates/ra_hir/src/has_source.rs b/crates/ra_hir/src/has_source.rs
index a888fe995..72afecf26 100644
--- a/crates/ra_hir/src/has_source.rs
+++ b/crates/ra_hir/src/has_source.rs
@@ -4,7 +4,7 @@ use either::Either;
4use hir_def::{ 4use hir_def::{
5 nameres::ModuleSource, 5 nameres::ModuleSource,
6 src::{HasChildSource, HasSource as _}, 6 src::{HasChildSource, HasSource as _},
7 AstItemDef, Lookup, VariantId, 7 Lookup, VariantId,
8}; 8};
9use ra_syntax::ast; 9use ra_syntax::ast;
10 10
@@ -51,19 +51,19 @@ impl HasSource for StructField {
51impl HasSource for Struct { 51impl HasSource for Struct {
52 type Ast = ast::StructDef; 52 type Ast = ast::StructDef;
53 fn source(self, db: &impl DefDatabase) -> InFile<ast::StructDef> { 53 fn source(self, db: &impl DefDatabase) -> InFile<ast::StructDef> {
54 self.id.source(db) 54 self.id.lookup(db).source(db)
55 } 55 }
56} 56}
57impl HasSource for Union { 57impl HasSource for Union {
58 type Ast = ast::UnionDef; 58 type Ast = ast::UnionDef;
59 fn source(self, db: &impl DefDatabase) -> InFile<ast::UnionDef> { 59 fn source(self, db: &impl DefDatabase) -> InFile<ast::UnionDef> {
60 self.id.source(db) 60 self.id.lookup(db).source(db)
61 } 61 }
62} 62}
63impl HasSource for Enum { 63impl HasSource for Enum {
64 type Ast = ast::EnumDef; 64 type Ast = ast::EnumDef;
65 fn source(self, db: &impl DefDatabase) -> InFile<ast::EnumDef> { 65 fn source(self, db: &impl DefDatabase) -> InFile<ast::EnumDef> {
66 self.id.source(db) 66 self.id.lookup(db).source(db)
67 } 67 }
68} 68}
69impl HasSource for EnumVariant { 69impl HasSource for EnumVariant {
@@ -93,7 +93,7 @@ impl HasSource for Static {
93impl HasSource for Trait { 93impl HasSource for Trait {
94 type Ast = ast::TraitDef; 94 type Ast = ast::TraitDef;
95 fn source(self, db: &impl DefDatabase) -> InFile<ast::TraitDef> { 95 fn source(self, db: &impl DefDatabase) -> InFile<ast::TraitDef> {
96 self.id.source(db) 96 self.id.lookup(db).source(db)
97 } 97 }
98} 98}
99impl HasSource for TypeAlias { 99impl HasSource for TypeAlias {