Make LateCtxt be a type info delegate for EUV for clippy

This commit is contained in:
Michael Goulet 2024-05-08 14:08:18 -04:00
parent dfc9c9132b
commit db193c1c9d
9 changed files with 21 additions and 60 deletions

View file

@ -69,14 +69,11 @@ pub(super) fn check<'tcx>(
let mut delegate = MoveDelegate {
used_move: HirIdSet::default(),
};
let infcx = cx.tcx.infer_ctxt().build();
ExprUseVisitor::new(
ExprUseVisitor::for_clippy(
cx,
closure.def_id,
&mut delegate,
&infcx,
closure.body.hir_id.owner.def_id,
cx.param_env,
cx.typeck_results(),
)
.consume_body(body);