mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-05 05:04:24 +00:00
Merge pull request #2235 from topecongiro/option_env
Inspect CFG_RELEASE_CHANNEL env var at compile time
This commit is contained in:
commit
77524632f3
@ -24,9 +24,9 @@ use Summary;
|
||||
|
||||
macro_rules! is_nightly_channel {
|
||||
() => {
|
||||
env::var("CFG_RELEASE_CHANNEL")
|
||||
.map(|c| c == "nightly")
|
||||
.unwrap_or(false)
|
||||
option_env!("CFG_RELEASE_CHANNEL")
|
||||
.map(|c| c == "nightly")
|
||||
.unwrap_or(false)
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user