mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-30 05:45:12 +00:00
Move things in hir_ty into submodules
- all the types that will be replaced by Chalk go to `types` - `TypeWalk` impls go to `walk`
This commit is contained in:
parent
bc8b278841
commit
508a1ecad3
11 changed files with 751 additions and 707 deletions
|
@ -452,11 +452,7 @@ impl<'a> InferenceContext<'a> {
|
|||
};
|
||||
match canonicalized.decanonicalize_ty(derefed_ty.value).kind(&Interner) {
|
||||
TyKind::Tuple(_, substs) => name.as_tuple_index().and_then(|idx| {
|
||||
substs
|
||||
.interned(&Interner)
|
||||
.get(idx)
|
||||
.map(|a| a.assert_ty_ref(&Interner))
|
||||
.cloned()
|
||||
substs.interned().get(idx).map(|a| a.assert_ty_ref(&Interner)).cloned()
|
||||
}),
|
||||
TyKind::Adt(AdtId(hir_def::AdtId::StructId(s)), parameters) => {
|
||||
let local_id = self.db.struct_data(*s).variant_data.field(name)?;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue