mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-02 22:54:58 +00:00
Bump chalk to 0.86
Two breaking changes: - `TypeFolder` has been split into `TypeFolder` and `FallibleTypeFolder` - `ProjectionTy::self_type_parameter()` has been removed
This commit is contained in:
parent
a0ab61fb6c
commit
310a72bf47
9 changed files with 103 additions and 102 deletions
|
@ -262,7 +262,7 @@ impl TyExt for Ty {
|
|||
WhereClause::AliasEq(AliasEq {
|
||||
alias: AliasTy::Projection(proj),
|
||||
ty: _,
|
||||
}) => &proj.self_type_parameter(Interner) == self,
|
||||
}) => &proj.self_type_parameter(db) == self,
|
||||
_ => false,
|
||||
})
|
||||
.collect::<Vec<_>>();
|
||||
|
@ -333,6 +333,7 @@ impl TyExt for Ty {
|
|||
pub trait ProjectionTyExt {
|
||||
fn trait_ref(&self, db: &dyn HirDatabase) -> TraitRef;
|
||||
fn trait_(&self, db: &dyn HirDatabase) -> TraitId;
|
||||
fn self_type_parameter(&self, db: &dyn HirDatabase) -> Ty;
|
||||
}
|
||||
|
||||
impl ProjectionTyExt for ProjectionTy {
|
||||
|
@ -349,6 +350,10 @@ impl ProjectionTyExt for ProjectionTy {
|
|||
_ => panic!("projection ty without parent trait"),
|
||||
}
|
||||
}
|
||||
|
||||
fn self_type_parameter(&self, db: &dyn HirDatabase) -> Ty {
|
||||
self.trait_ref(db).self_type_parameter(Interner)
|
||||
}
|
||||
}
|
||||
|
||||
pub trait TraitRefExt {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue