2023-07-02 12:35:19 +00:00
|
|
|
#![warn(clippy::maybe_misused_cfg)]
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
#[cfg(features = "not-really-a-feature")]
|
2023-08-24 19:32:12 +00:00
|
|
|
//~^ ERROR: feature may misspelled as features
|
|
|
|
//~| NOTE: `-D clippy::maybe-misused-cfg` implied by `-D warnings`
|
2023-07-02 12:35:19 +00:00
|
|
|
let _ = 1 + 2;
|
|
|
|
|
|
|
|
#[cfg(all(feature = "right", features = "wrong"))]
|
2023-08-24 19:32:12 +00:00
|
|
|
//~^ ERROR: feature may misspelled as features
|
2023-07-02 12:35:19 +00:00
|
|
|
let _ = 1 + 2;
|
|
|
|
|
|
|
|
#[cfg(all(features = "wrong1", any(feature = "right", features = "wrong2", feature, features)))]
|
2023-08-24 19:32:12 +00:00
|
|
|
//~^ ERROR: feature may misspelled as features
|
|
|
|
//~| ERROR: feature may misspelled as features
|
2023-07-02 12:35:19 +00:00
|
|
|
let _ = 1 + 2;
|
|
|
|
}
|