Use BottomUpFolder

This commit is contained in:
Esteban Küber 2023-01-03 20:49:47 -08:00
parent 4ac7d1c3ab
commit ad82eedfa1
2 changed files with 19 additions and 40 deletions

View file

@ -61,7 +61,7 @@ impl<'tcx> InferCtxt<'tcx> {
.as_local()
.map_or(false, |def_id| self.opaque_type_origin(def_id, span).is_some())
};
let value = value.fold_with(&mut ty::fold::BottomUpFolder {
let value = value.fold_with(&mut BottomUpFolder {
tcx: self.tcx,
lt_op: |lt| lt,
ct_op: |ct| ct,