@@ -58,15 +58,15 @@ pub(super) trait GoalKind<'tcx>:
58
58
/// goal by equating it with the assumption.
59
59
fn probe_and_consider_implied_clause (
60
60
ecx : & mut EvalCtxt < ' _ , ' tcx > ,
61
- source : CandidateSource ,
61
+ parent_source : CandidateSource ,
62
62
goal : Goal < ' tcx , Self > ,
63
63
assumption : ty:: Clause < ' tcx > ,
64
- requirements : impl IntoIterator < Item = Goal < ' tcx , ty:: Predicate < ' tcx > > > ,
64
+ requirements : impl IntoIterator < Item = ( GoalSource , Goal < ' tcx , ty:: Predicate < ' tcx > > ) > ,
65
65
) -> Result < Candidate < ' tcx > , NoSolution > {
66
- Self :: probe_and_match_goal_against_assumption ( ecx, source , goal, assumption, |ecx| {
67
- // FIXME(-Znext-solver=coinductive): check whether this should be
68
- // `GoalSource::ImplWhereBound` for any caller.
69
- ecx . add_goals ( GoalSource :: Misc , requirements ) ;
66
+ Self :: probe_and_match_goal_against_assumption ( ecx, parent_source , goal, assumption, |ecx| {
67
+ for ( nested_source , goal ) in requirements {
68
+ ecx . add_goal ( nested_source , goal ) ;
69
+ }
70
70
ecx. evaluate_added_goals_and_make_canonical_response ( Certainty :: Yes )
71
71
} )
72
72
}
@@ -85,9 +85,8 @@ pub(super) trait GoalKind<'tcx>:
85
85
let ty:: Dynamic ( bounds, _, _) = * goal. predicate . self_ty ( ) . kind ( ) else {
86
86
bug ! ( "expected object type in `probe_and_consider_object_bound_candidate`" ) ;
87
87
} ;
88
- // FIXME(-Znext-solver=coinductive): Should this be `GoalSource::ImplWhereBound`?
89
88
ecx. add_goals (
90
- GoalSource :: Misc ,
89
+ GoalSource :: ImplWhereBound ,
91
90
structural_traits:: predicates_for_object_candidate (
92
91
ecx,
93
92
goal. param_env ,
0 commit comments