mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-27 02:06:57 +00:00
Add a test for field default value body as defining usage of TAIT
This commit is contained in:
parent
ce9da90630
commit
4fe18a6fb5
3 changed files with 141 additions and 27 deletions
|
|
@ -1399,11 +1399,7 @@ impl HasModule for DefWithBodyId {
|
|||
DefWithBodyId::ConstId(it) => it.module(db),
|
||||
DefWithBodyId::VariantId(it) => it.module(db),
|
||||
DefWithBodyId::InTypeConstId(it) => it.lookup(db).owner.module(db),
|
||||
DefWithBodyId::FieldId(it) => match it.parent {
|
||||
VariantId::EnumVariantId(it) => it.module(db),
|
||||
VariantId::StructId(it) => it.module(db),
|
||||
VariantId::UnionId(it) => it.module(db),
|
||||
},
|
||||
DefWithBodyId::FieldId(it) => it.module(db),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue