about summary refs log tree commit diff
path: root/tests/ui/proc-macro/env.rs
blob: c0edda4f7df23679c222293c2a7ba5d6af99be90 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// aux-build:env.rs
// run-pass
// rustc-env: THE_CONST=1
// compile-flags: -Zunstable-options --env-set THE_CONST=12 --env-set ANOTHER=4

#![crate_name = "foo"]

extern crate env;

use env::generate_const;

generate_const!();

fn main() {
    assert_eq!(THE_CONST, 12);
    assert_eq!(ANOTHER, 1);
}