Fix hir for ast::UnionDef

This commit is contained in:
Aleksey Kladov 2019-11-25 17:30:50 +03:00
parent e1c0bdaf75
commit 5fd68b5929
22 changed files with 121 additions and 86 deletions

View file

@ -51,13 +51,13 @@ impl HasSource for StructField {
impl HasSource for Struct {
type Ast = ast::StructDef;
fn source(self, db: &impl DefDatabase) -> Source<ast::StructDef> {
self.id.0.source(db)
self.id.source(db)
}
}
impl HasSource for Union {
type Ast = ast::StructDef;
fn source(self, db: &impl DefDatabase) -> Source<ast::StructDef> {
self.id.0.source(db)
type Ast = ast::UnionDef;
fn source(self, db: &impl DefDatabase) -> Source<ast::UnionDef> {
self.id.source(db)
}
}
impl HasSource for Enum {