diff --git a/src/librustc_mir/hair/pattern/_match.rs b/src/librustc_mir/hair/pattern/_match.rs index 2e339b1eb885d..d54f6b03cdd20 100644 --- a/src/librustc_mir/hair/pattern/_match.rs +++ b/src/librustc_mir/hair/pattern/_match.rs @@ -1838,7 +1838,7 @@ fn pat_constructor<'tcx>( if slice.is_some() { VarLen(prefix, suffix) } else { FixedLen(prefix + suffix) }; Some(Slice(Slice { array_len, kind })) } - PatKind::Or { .. } => bug!("Or-pattern hould have been expanded earlier on."), + PatKind::Or { .. } => bug!("Or-pattern should have been expanded earlier on."), } } @@ -2444,7 +2444,7 @@ fn specialize_one_pattern<'p, 'a: 'p, 'q: 'p, 'tcx>( _ => span_bug!(pat.span, "unexpected ctor {:?} for slice pat", constructor), }, - PatKind::Or { .. } => bug!("Or-pattern hould have been expanded earlier on."), + PatKind::Or { .. } => bug!("Or-pattern should have been expanded earlier on."), }; debug!("specialize({:#?}, {:#?}) = {:#?}", pat, ctor_wild_subpatterns, result); diff --git a/src/test/ui/or-patterns/exhaustiveness-pass.rs b/src/test/ui/or-patterns/exhaustiveness-pass.rs index a29cc7253ad58..62a851719f96d 100644 --- a/src/test/ui/or-patterns/exhaustiveness-pass.rs +++ b/src/test/ui/or-patterns/exhaustiveness-pass.rs @@ -17,7 +17,7 @@ fn main() { } match (0u8,) { - (1 | 1,) => {} // redundancy not detected for now + (1 | 1,) => {} // FIXME(or_patterns): redundancy not detected for now. _ => {} } match (0u8, 0u8) {