Skip to content

Commit ab45660

Browse files
committed
Auto merge of rust-lang#125775 - compiler-errors:uplift-closure-args, r=lcnr
Uplift `{Closure,Coroutine,CoroutineClosure}Args` and friends to `rustc_type_ir` Part of converting the new solver's `structural_traits.rs` to be interner-agnostic. I decided against aliasing `ClosureArgs<TyCtxt<'tcx>>` to `ClosureArgs<'tcx>` because it seemed so rare. I could do so if desired, though. r? lcnr
2 parents 2334264 + 5a44877 commit ab45660

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

clippy_lints/src/eta_reduction.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ use rustc_infer::infer::TyCtxtInferExt;
1010
use rustc_lint::{LateContext, LateLintPass};
1111
use rustc_middle::ty::{
1212
self, Binder, ClosureArgs, ClosureKind, FnSig, GenericArg, GenericArgKind, List, Region, RegionKind, Ty,
13-
TypeVisitableExt, TypeckResults,
13+
TypeVisitableExt, TypeckResults, TyCtxt,
1414
};
1515
use rustc_session::declare_lint_pass;
1616
use rustc_span::symbol::sym;
@@ -240,7 +240,7 @@ fn check_inputs(
240240
})
241241
}
242242

243-
fn check_sig<'tcx>(cx: &LateContext<'tcx>, closure: ClosureArgs<'tcx>, call_sig: FnSig<'_>) -> bool {
243+
fn check_sig<'tcx>(cx: &LateContext<'tcx>, closure: ClosureArgs<TyCtxt<'tcx>>, call_sig: FnSig<'_>) -> bool {
244244
call_sig.safety == Safety::Safe
245245
&& !has_late_bound_to_non_late_bound_regions(
246246
cx.tcx.signature_unclosure(closure.sig(), Safety::Safe).skip_binder(),

0 commit comments

Comments
 (0)