about summary refs log tree commit diff
path: root/tests/ui/cfg/cfg-macros-notfoo.rs
blob: c25cf1c39bf542c41742ac11021114e06fca9a34 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
//@ run-pass

// check that cfg correctly chooses between the macro impls (see also
// cfg-macros-foo.rs)

#[cfg(false)]
#[macro_use]
mod foo {
    macro_rules! bar {
        () => { true }
    }
}

#[cfg(not(FALSE))]
#[macro_use]
mod foo {
    macro_rules! bar {
        () => { false }
    }
}

pub fn main() {
    assert!(!bar!())
}