]> git.lizzy.rs Git - rust.git/blob - src/tools/clippy/tests/ui/crashes/single-match-else.rs
Rollup merge of #71581 - GuillaumeGomez:unify-lints-handling, r=kinnison
[rust.git] / src / tools / clippy / tests / ui / crashes / single-match-else.rs
1 // run-pass
2
3 #![warn(clippy::single_match_else)]
4
5 //! Test for https://github.com/rust-lang/rust-clippy/issues/1588
6
7 fn main() {
8     let n = match (42, 43) {
9         (42, n) => n,
10         _ => panic!("typeck error"),
11     };
12     assert_eq!(n, 43);
13 }