os-rust/tests/ui/pattern/usefulness/floats.stderr
Trevor Gross 6fb6c19c96 Replace f16 and f128 pattern matching stubs with real implementations
This section of code depends on `rustc_apfloat` rather than our internal
types, so this is one potential ICE that we should be able to melt now.

This also fixes some missing range and match handling in `rustc_middle`.
2024-06-23 04:28:42 -05:00

106 lines
2.1 KiB
Text

error[E0004]: non-exhaustive patterns: `_` not covered
--> $DIR/floats.rs:11:11
|
LL | match 0.0 {
| ^^^ pattern `_` not covered
|
= note: the matched value is of type `f64`
help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern or an explicit pattern as shown
|
LL ~ 0.0..=1.0 => {},
LL + _ => todo!()
|
error: unreachable pattern
--> $DIR/floats.rs:18:9
|
LL | 0.01f16 => {}
| ^^^^^^^
|
note: the lint level is defined here
--> $DIR/floats.rs:1:9
|
LL | #![deny(unreachable_patterns)]
| ^^^^^^^^^^^^^^^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:19:9
|
LL | 0.02f16 => {}
| ^^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:20:9
|
LL | 6.5f16 => {}
| ^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:31:9
|
LL | 0.01f32 => {}
| ^^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:32:9
|
LL | 0.02f32 => {}
| ^^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:33:9
|
LL | 6.5f32 => {}
| ^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:45:9
|
LL | 0.01f64 => {}
| ^^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:46:9
|
LL | 0.02f64 => {}
| ^^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:47:9
|
LL | 6.5f64 => {}
| ^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:49:9
|
LL | 1.0f64..=4.0f64 => {}
| ^^^^^^^^^^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:62:9
|
LL | 0.01f128 => {}
| ^^^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:63:9
|
LL | 0.02f128 => {}
| ^^^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:64:9
|
LL | 6.5f128 => {}
| ^^^^^^^
error: unreachable pattern
--> $DIR/floats.rs:66:9
|
LL | 1.0f128..=4.0f128 => {}
| ^^^^^^^^^^^^^^^^^
error: aborting due to 15 previous errors
For more information about this error, try `rustc --explain E0004`.