mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-23 23:34:48 +00:00
18 lines
305 B
Rust
18 lines
305 B
Rust
//@ 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);
|
|
}
|