]> git.lizzy.rs Git - rust.git/blobdiff - src/tools/clippy/clippy_lints/src/question_mark.rs
Rollup merge of #102049 - fee1-dead-contrib:derive_const, r=oli-obk
[rust.git] / src / tools / clippy / clippy_lints / src / question_mark.rs
index 328371fd602f0c517c9c48a6ff2a6585535e90ba..bb86fb3b7d42f43858db4b853f7fe3cbcb6ca8f6 100644 (file)
@@ -94,7 +94,7 @@ fn check_is_none_or_err_and_early_return<'tcx>(cx: &LateContext<'tcx>, expr: &Ex
         then {
             let mut applicability = Applicability::MachineApplicable;
             let receiver_str = snippet_with_applicability(cx, caller.span, "..", &mut applicability);
-            let by_ref = !caller_ty.is_copy_modulo_regions(cx.tcx.at(caller.span), cx.param_env) &&
+            let by_ref = !caller_ty.is_copy_modulo_regions(cx.tcx, cx.param_env) &&
                 !matches!(caller.kind, ExprKind::Call(..) | ExprKind::MethodCall(..));
             let sugg = if let Some(else_inner) = r#else {
                 if eq_expr_value(cx, caller, peel_blocks(else_inner)) {