Rollup merge of #140214 - compiler-errors:remove-hack, r=lcnr
Remove comment about handling non-global where bounds with corresponding projection This comment is no longer relevant since we only assemble rigid projections if no param-env candidates hold. Also remove a stray comment from the old solver. r? lcnr
This commit is contained in:
@@ -1308,18 +1308,6 @@ where
|
||||
return true;
|
||||
}
|
||||
|
||||
// We don't consider a trait-bound global if it has a projection bound.
|
||||
//
|
||||
// See ui/traits/next-solver/normalization-shadowing/global-trait-with-project.rs
|
||||
// for an example where this is necessary.
|
||||
for p in goal.param_env.caller_bounds().iter() {
|
||||
if let ty::ClauseKind::Projection(proj) = p.kind().skip_binder() {
|
||||
if proj.projection_term.trait_ref(self.cx()) == trait_pred.trait_ref {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
false
|
||||
}
|
||||
_ => false,
|
||||
|
||||
Reference in New Issue
Block a user