Introduce TypeVisitor::BreakTy

This commit is contained in:
LeSeulArtichaut 2020-11-05 17:30:39 +01:00
parent 30e49a9ead
commit e0f3119103
31 changed files with 157 additions and 128 deletions

View file

@ -1781,7 +1781,7 @@ impl<'tcx> TypeFoldable<'tcx> for ParamEnv<'tcx> {
ParamEnv::new(self.caller_bounds().fold_with(folder), self.reveal().fold_with(folder))
}
fn super_visit_with<V: TypeVisitor<'tcx>>(&self, visitor: &mut V) -> ControlFlow<()> {
fn super_visit_with<V: TypeVisitor<'tcx>>(&self, visitor: &mut V) -> ControlFlow<V::BreakTy> {
self.caller_bounds().visit_with(visitor)?;
self.reveal().visit_with(visitor)
}