@@ -78,7 +78,7 @@ pub(super) enum CandidateSource {
78
78
/// let _y = x.clone();
79
79
/// }
80
80
/// ```
81
- AliasBound ( usize ) ,
81
+ AliasBound ,
82
82
}
83
83
84
84
pub ( super ) trait GoalKind < ' tcx > : TypeFoldable < ' tcx > + Copy + Eq {
@@ -242,8 +242,6 @@ impl<'tcx> EvalCtxt<'_, 'tcx> {
242
242
// NOTE: Alternatively we could call `evaluate_goal` here and only have a `Normalized` candidate.
243
243
// This doesn't work as long as we use `CandidateSource` in winnowing.
244
244
let goal = goal. with ( tcx, goal. predicate . with_self_ty ( tcx, normalized_ty) ) ;
245
- // FIXME: This is broken if we care about the `usize` of `AliasBound` because the self type
246
- // could be normalized to yet another projection with different item bounds.
247
245
let normalized_candidates = self . assemble_and_evaluate_candidates ( goal) ;
248
246
for mut normalized_candidate in normalized_candidates {
249
247
normalized_candidate. result =
@@ -368,15 +366,14 @@ impl<'tcx> EvalCtxt<'_, 'tcx> {
368
366
ty:: Alias ( _, alias_ty) => alias_ty,
369
367
} ;
370
368
371
- for ( i , ( assumption, _) ) in self
369
+ for ( assumption, _) in self
372
370
. tcx ( )
373
371
. bound_explicit_item_bounds ( alias_ty. def_id )
374
372
. subst_iter_copied ( self . tcx ( ) , alias_ty. substs )
375
- . enumerate ( )
376
373
{
377
374
match G :: consider_assumption ( self , goal, assumption) {
378
375
Ok ( result) => {
379
- candidates. push ( Candidate { source : CandidateSource :: AliasBound ( i ) , result } )
376
+ candidates. push ( Candidate { source : CandidateSource :: AliasBound , result } )
380
377
}
381
378
Err ( NoSolution ) => ( ) ,
382
379
}
0 commit comments