diff options
| author | Matthias Krüger <476013+matthiaskrgr@users.noreply.github.com> | 2025-06-04 19:50:25 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-06-04 19:50:25 +0200 |
| commit | 87969ff151184466ffceeb15e539e60bde3dce02 (patch) | |
| tree | 3a3d6d99bc030831bd115d4c1ff0cc7ff7acdd0d | |
| parent | 23ba088502f4e05a9f79cfa6e6a3494161d5f09e (diff) | |
| parent | f9c2a454fd1d632ea90718306f7250e2b0db2514 (diff) | |
Rollup merge of #141999 - nnethercote:precise-ident, r=compiler-errors
Visit the ident in `PreciseCapturingNonLifetimeArg`. It's currently skipped, presumably by accident. r? `@BoxyUwU`
| -rw-r--r-- | compiler/rustc_hir/src/intravisit.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/compiler/rustc_hir/src/intravisit.rs b/compiler/rustc_hir/src/intravisit.rs index b9932a7334e..d12050ea4bb 100644 --- a/compiler/rustc_hir/src/intravisit.rs +++ b/compiler/rustc_hir/src/intravisit.rs @@ -1333,8 +1333,9 @@ pub fn walk_precise_capturing_arg<'v, V: Visitor<'v>>( match *arg { PreciseCapturingArg::Lifetime(lt) => visitor.visit_lifetime(lt), PreciseCapturingArg::Param(param) => { - let PreciseCapturingNonLifetimeArg { hir_id, ident: _, res: _ } = param; - visitor.visit_id(hir_id) + let PreciseCapturingNonLifetimeArg { hir_id, ident, res: _ } = param; + try_visit!(visitor.visit_id(hir_id)); + visitor.visit_ident(ident) } } } |
