diff options
author | Aleksey Kladov <[email protected]> | 2019-11-24 18:03:24 +0000 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2019-11-24 18:17:37 +0000 |
commit | 191b1d238fd1594ab74b1ab6a17dbe0430fc6b1a (patch) | |
tree | 047d256c33567aa3dfb59e7986f7059bf99ffb6b /crates/ra_hir/src/code_model | |
parent | d87c16bea60f4972b0adf4dd69bbb9abcfca12d6 (diff) |
Remove impl_block module
Diffstat (limited to 'crates/ra_hir/src/code_model')
-rw-r--r-- | crates/ra_hir/src/code_model/src.rs | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/crates/ra_hir/src/code_model/src.rs b/crates/ra_hir/src/code_model/src.rs index a0e605603..a4e317c20 100644 --- a/crates/ra_hir/src/code_model/src.rs +++ b/crates/ra_hir/src/code_model/src.rs | |||
@@ -5,8 +5,8 @@ use hir_expand::either::Either; | |||
5 | use ra_syntax::ast; | 5 | use ra_syntax::ast; |
6 | 6 | ||
7 | use crate::{ | 7 | use crate::{ |
8 | db::DefDatabase, Const, Enum, EnumVariant, FieldSource, Function, Import, MacroDef, Module, | 8 | db::DefDatabase, Const, Enum, EnumVariant, FieldSource, Function, ImplBlock, Import, MacroDef, |
9 | ModuleSource, Static, Struct, StructField, Trait, TypeAlias, Union, | 9 | Module, ModuleSource, Static, Struct, StructField, Trait, TypeAlias, Union, |
10 | }; | 10 | }; |
11 | 11 | ||
12 | pub use hir_expand::Source; | 12 | pub use hir_expand::Source; |
@@ -108,6 +108,12 @@ impl HasSource for MacroDef { | |||
108 | Source { file_id: self.id.ast_id.file_id(), value: self.id.ast_id.to_node(db) } | 108 | Source { file_id: self.id.ast_id.file_id(), value: self.id.ast_id.to_node(db) } |
109 | } | 109 | } |
110 | } | 110 | } |
111 | impl HasSource for ImplBlock { | ||
112 | type Ast = ast::ImplBlock; | ||
113 | fn source(self, db: &impl DefDatabase) -> Source<ast::ImplBlock> { | ||
114 | self.id.source(db) | ||
115 | } | ||
116 | } | ||
111 | impl HasSource for Import { | 117 | impl HasSource for Import { |
112 | type Ast = Either<ast::UseTree, ast::ExternCrateItem>; | 118 | type Ast = Either<ast::UseTree, ast::ExternCrateItem>; |
113 | 119 | ||