]> git.lizzy.rs Git - rust.git/blob - tests/ui/crashes/single-match-else.rs
Auto merge of #6298 - JohnTitor:fix-example, r=llogiq
[rust.git] / tests / ui / crashes / single-match-else.rs
1 #![warn(clippy::single_match_else)]
2
3 //! Test for https://github.com/rust-lang/rust-clippy/issues/1588
4
5 fn main() {
6     let n = match (42, 43) {
7         (42, n) => n,
8         _ => panic!("typeck error"),
9     };
10     assert_eq!(n, 43);
11 }