Visit mir::Constant::user_ty for completeness.

It's not necessary yet, but it may become necessary with things like lazy normalization.
This commit is contained in:
Oli Scherer
2021-03-12 12:59:37 +00:00
parent 20f737966e
commit 6ca1d87194
@@ -342,8 +342,8 @@ fn super_fold_with<F: TypeFolder<'tcx>>(self, folder: &mut F) -> Self {
}
}
fn super_visit_with<V: TypeVisitor<'tcx>>(&self, visitor: &mut V) -> ControlFlow<V::BreakTy> {
self.literal.visit_with(visitor)
// FIXME: should this be visiting the `user_ty`, too?
self.literal.visit_with(visitor)?;
self.user_ty.visit_with(visitor)
}
}