Skip to content

Commit 7bffe94

Browse files
committed
add delay_span_bug
1 parent 8126ccb commit 7bffe94

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

compiler/rustc_hir_typeck/src/upvar.rs

+7-1
Original file line numberDiff line numberDiff line change
@@ -712,7 +712,13 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
712712
}
713713
}
714714

715-
// return Equal for two identical projections
715+
self.tcx.sess.delay_span_bug(
716+
closure_span,
717+
&format!(
718+
"two identical projections: ({:?}, {:?})",
719+
capture1.place.projections, capture2.place.projections
720+
),
721+
);
716722
std::cmp::Ordering::Equal
717723
});
718724
}

0 commit comments

Comments
 (0)