]> git.lizzy.rs Git - rust.git/blob - tests/ui/check-cfg/allow-top-level.rs
Rollup merge of #103236 - tspiteri:redoc-int-adc-sbb, r=m-ou-se
[rust.git] / tests / ui / check-cfg / allow-top-level.rs
1 // This test check that a top-level #![allow(unexpected_cfgs)] works
2 //
3 // check-pass
4 // compile-flags:--check-cfg=names() -Z unstable-options
5
6 #![allow(unexpected_cfgs)]
7
8 #[cfg(FALSE)]
9 fn bar() {}
10
11 fn foo() {
12     if cfg!(FALSE) {}
13 }
14
15 fn main() {}