]> git.lizzy.rs Git - rust.git/blob - tests/ui/match/issue-11319.rs
Rollup merge of #106605 - notriddle:notriddle/outdated-rustbook, r=GuillaumeGomez
[rust.git] / tests / ui / match / issue-11319.rs
1 fn main() {
2     match Some(10) {
3     //~^ NOTE `match` arms have incompatible types
4         Some(5) => false,
5         //~^ NOTE this is found to be of type `bool`
6         Some(2) => true,
7         //~^ NOTE this is found to be of type `bool`
8         None    => (),
9         //~^ ERROR `match` arms have incompatible types
10         //~| NOTE expected `bool`, found `()`
11         _       => true
12     }
13 }