rust/tests/ui/uninhabited/uninhabited-patterns.stderr

32 lines
1.1 KiB
Plaintext

error: unreachable pattern
--> $DIR/uninhabited-patterns.rs:29:9
|
LL | Ok(box _) => (),
| ^^^^^^^^^ matches no values because `NotSoSecretlyEmpty` is uninhabited
|
= note: to learn more about uninhabited types, see https://doc.rust-lang.org/nomicon/exotic-sizes.html#empty-types
note: the lint level is defined here
--> $DIR/uninhabited-patterns.rs:3:9
|
LL | #![deny(unreachable_patterns)]
| ^^^^^^^^^^^^^^^^^^^^
error: unreachable pattern
--> $DIR/uninhabited-patterns.rs:38:9
|
LL | Err(Ok(_y)) => (),
| ^^^^^^^^^^^ matches no values because `NotSoSecretlyEmpty` is uninhabited
|
= note: to learn more about uninhabited types, see https://doc.rust-lang.org/nomicon/exotic-sizes.html#empty-types
error: unreachable pattern
--> $DIR/uninhabited-patterns.rs:41:15
|
LL | while let Some(_y) = foo() {
| ^^^^^^^^ matches no values because `NotSoSecretlyEmpty` is uninhabited
|
= note: to learn more about uninhabited types, see https://doc.rust-lang.org/nomicon/exotic-sizes.html#empty-types
error: aborting due to 3 previous errors