]> git.lizzy.rs Git - rust.git/blob - src/test/ui/pattern/usefulness/non-exhaustive-float-range-match.rs
Add test for eval order for a+=b
[rust.git] / src / test / ui / pattern / usefulness / non-exhaustive-float-range-match.rs
1 #![allow(illegal_floating_point_literal_pattern)]
2 #![deny(unreachable_patterns)]
3
4 fn main() {
5     match 0.0 {
6       0.0..=1.0 => {}
7       _ => {} // ok
8     }
9
10     match 0.0 { //~ ERROR non-exhaustive patterns
11       0.0..=1.0 => {}
12     }
13 }