summaryrefslogtreecommitdiffstats
path: root/compiler/rustc_middle/src/thir
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/rustc_middle/src/thir')
-rw-r--r--compiler/rustc_middle/src/thir/visit.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler/rustc_middle/src/thir/visit.rs b/compiler/rustc_middle/src/thir/visit.rs
index 8feefb4c0..4943c1184 100644
--- a/compiler/rustc_middle/src/thir/visit.rs
+++ b/compiler/rustc_middle/src/thir/visit.rs
@@ -226,8 +226,8 @@ pub fn walk_pat<'a, 'tcx: 'a, V: Visitor<'a, 'tcx>>(visitor: &mut V, pat: &Pat<'
ty: _,
is_primary: _,
name: _,
- } => visitor.visit_pat(&subpattern),
- Binding { .. } | Wild | Error(_) => {}
+ } => visitor.visit_pat(subpattern),
+ Binding { .. } | Wild | Never | Error(_) => {}
Variant { subpatterns, adt_def: _, args: _, variant_index: _ } | Leaf { subpatterns } => {
for subpattern in subpatterns {
visitor.visit_pat(&subpattern.pattern);
@@ -249,7 +249,7 @@ pub fn walk_pat<'a, 'tcx: 'a, V: Visitor<'a, 'tcx>>(visitor: &mut V, pat: &Pat<'
}
Or { pats } => {
for pat in pats.iter() {
- visitor.visit_pat(&pat);
+ visitor.visit_pat(pat);
}
}
};