about summary refs log tree commit diff
path: root/tests/ui/cfg/both-true-false.rs
blob: 5fca8f654ad8ea0cb1fb32bbc7a34a09944b7b5d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
/// Test that placing a `cfg(true)` and `cfg(false)` on the same item result in
//. it being disabled.`

#[cfg(false)]
#[cfg(true)]
fn foo() {}

#[cfg(true)]
#[cfg(false)]
fn foo() {}

fn main() {
    foo();  //~ ERROR cannot find function `foo` in this scope
}