Skip to content

Commit 9c076f3

Browse files
committed
Add more commments
1 parent 91846fe commit 9c076f3

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

compiler/rustc_trait_selection/src/traits/coherence.rs

+2
Original file line numberDiff line numberDiff line change
@@ -353,6 +353,7 @@ fn negative_impl<'cx, 'tcx>(
353353
})
354354
}
355355

356+
/// Try to prove that a negative impl exist for the given obligation and their super predicates.
356357
#[instrument(level = "debug", skip(selcx))]
357358
fn negative_impl_exists<'cx, 'tcx>(
358359
selcx: &SelectionContext<'cx, 'tcx>,
@@ -366,6 +367,7 @@ fn negative_impl_exists<'cx, 'tcx>(
366367
return true;
367368
}
368369

370+
// Try to prove a negative obligation exist for super predicates
369371
// FIXME we should implement an `assemble_neg_candidates` fn
370372
for o in util::elaborate_predicates(infcx.tcx, iter::once(o.predicate)) {
371373
if resolve_negative_obligation(infcx, param_env, region_context, &o) {

0 commit comments

Comments
 (0)