2022-05-05 09:12:52 -05:00
|
|
|
error: this seems like a manual implementation of the non-exhaustive pattern
|
2024-02-27 08:25:18 -06:00
|
|
|
--> tests/ui/manual_non_exhaustive_enum.rs:5:1
|
2022-05-05 09:12:52 -05:00
|
|
|
|
|
|
|
|
LL | enum E {
|
|
|
|
| ^-----
|
|
|
|
| |
|
|
|
|
| _help: add the attribute: `#[non_exhaustive] enum E`
|
|
|
|
| |
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-05-05 09:12:52 -05:00
|
|
|
LL | | A,
|
|
|
|
LL | | B,
|
|
|
|
LL | | #[doc(hidden)]
|
|
|
|
LL | | _C,
|
|
|
|
LL | | }
|
|
|
|
| |_^
|
|
|
|
|
|
|
|
|
help: remove this variant
|
2024-02-27 08:25:18 -06:00
|
|
|
--> tests/ui/manual_non_exhaustive_enum.rs:10:5
|
2022-05-05 09:12:52 -05:00
|
|
|
|
|
|
|
|
LL | _C,
|
|
|
|
| ^^
|
2022-09-22 11:04:22 -05:00
|
|
|
= note: `-D clippy::manual-non-exhaustive` implied by `-D warnings`
|
2023-08-01 07:02:21 -05:00
|
|
|
= help: to override `-D warnings` add `#[allow(clippy::manual_non_exhaustive)]`
|
2022-05-05 09:12:52 -05:00
|
|
|
|
2023-12-01 11:21:58 -06:00
|
|
|
error: this seems like a manual implementation of the non-exhaustive pattern
|
2024-02-27 08:25:18 -06:00
|
|
|
--> tests/ui/manual_non_exhaustive_enum.rs:30:1
|
2023-12-01 11:21:58 -06:00
|
|
|
|
|
|
|
|
LL | enum NoUnderscore {
|
|
|
|
| ^----------------
|
|
|
|
| |
|
|
|
|
| _help: add the attribute: `#[non_exhaustive] enum NoUnderscore`
|
|
|
|
| |
|
|
|
|
LL | | A,
|
|
|
|
LL | | B,
|
|
|
|
LL | | #[doc(hidden)]
|
|
|
|
LL | | C,
|
|
|
|
LL | | }
|
|
|
|
| |_^
|
|
|
|
|
|
|
|
|
help: remove this variant
|
2024-02-27 08:25:18 -06:00
|
|
|
--> tests/ui/manual_non_exhaustive_enum.rs:34:5
|
2023-12-01 11:21:58 -06:00
|
|
|
|
|
|
|
|
LL | C,
|
|
|
|
| ^
|
|
|
|
|
|
|
|
error: aborting due to 2 previous errors
|
2022-05-05 09:12:52 -05:00
|
|
|
|