]> git.lizzy.rs Git - rust.git/blob - tests/ui/check-cfg/invalid-cfg-value.rs
Rollup merge of #107615 - notriddle:notriddle/nbsp, r=GuillaumeGomez
[rust.git] / tests / ui / check-cfg / invalid-cfg-value.rs
1 // Check warning for invalid configuration value
2 //
3 // edition:2018
4 // check-pass
5 // compile-flags: --check-cfg=values(feature,"serde","full") --cfg=feature="rand" -Z unstable-options
6
7 #[cfg(feature = "sedre")]
8 //~^ WARNING unexpected `cfg` condition value
9 pub fn f() {}
10
11 #[cfg(feature = "serde")]
12 pub fn g() {}
13
14 #[cfg(feature = "rand")]
15 //~^ WARNING unexpected `cfg` condition value
16 pub fn h() {}
17
18 pub fn main() {}