Skip to content

Commit 31283a1

Browse files
committed
Auto merge of #108145 - matthiaskrgr:rollup-bgadak1, r=matthiaskrgr
Rollup of 8 pull requests Successful merges: - #104068 (rustdoc: Add PartialOrd trait to doc comment explanation) - #107489 (Implement partial support for non-lifetime binders) - #107905 (Pass arguments to `x` subcommands with `--`) - #108009 (Move some tests) - #108086 (wasm: Register the `relaxed-simd` target feature) - #108104 (don't into self) - #108133 (Small cleanups around `EarlyBinder`) - #108136 (Do not ICE on unmet trait alias impl bounds) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2 parents 29fa684 + 9d39b5f commit 31283a1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

clippy_lints/src/ptr.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -505,13 +505,13 @@ fn check_mut_from_ref<'tcx>(cx: &LateContext<'tcx>, sig: &FnSig<'_>, body: Optio
505505
if let FnRetTy::Return(ty) = sig.decl.output
506506
&& let Some((out, Mutability::Mut, _)) = get_ref_lm(ty)
507507
{
508-
let out_region = cx.tcx.named_region(out.hir_id);
508+
let out_region = cx.tcx.named_bound_var(out.hir_id);
509509
let args: Option<Vec<_>> = sig
510510
.decl
511511
.inputs
512512
.iter()
513513
.filter_map(get_ref_lm)
514-
.filter(|&(lt, _, _)| cx.tcx.named_region(lt.hir_id) == out_region)
514+
.filter(|&(lt, _, _)| cx.tcx.named_bound_var(lt.hir_id) == out_region)
515515
.map(|(_, mutability, span)| (mutability == Mutability::Not).then_some(span))
516516
.collect();
517517
if let Some(args) = args

0 commit comments

Comments
 (0)