Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-ty/src/traits.rs')
-rw-r--r--crates/hir-ty/src/traits.rs7
1 files changed, 3 insertions, 4 deletions
diff --git a/crates/hir-ty/src/traits.rs b/crates/hir-ty/src/traits.rs
index 7414b4fc60..08b9d242e7 100644
--- a/crates/hir-ty/src/traits.rs
+++ b/crates/hir-ty/src/traits.rs
@@ -125,11 +125,10 @@ pub(crate) fn trait_solve_query(
alias: AliasTy::Projection(projection_ty),
..
}))) = &goal.value.goal.data(Interner)
+ && let TyKind::BoundVar(_) = projection_ty.self_type_parameter(db).kind(Interner)
{
- if let TyKind::BoundVar(_) = projection_ty.self_type_parameter(db).kind(Interner) {
- // Hack: don't ask Chalk to normalize with an unknown self type, it'll say that's impossible
- return Some(Solution::Ambig(Guidance::Unknown));
- }
+ // Hack: don't ask Chalk to normalize with an unknown self type, it'll say that's impossible
+ return Some(Solution::Ambig(Guidance::Unknown));
}
// Chalk see `UnevaluatedConst` as a unique concrete value, but we see it as an alias for another const. So