treat the dev channel as nightly in compiletest

This commit is contained in:
Pietro Albini 2023-04-17 11:00:10 +02:00 committed by Pietro Albini
parent 1151ea6006
commit 2bf5f77696
No known key found for this signature in database
GPG key ID: 3E06ABE80BAAF19C

View file

@ -165,11 +165,15 @@ pub(super) fn parse_cfg_name_directive<'a>(
message: "when the architecture is part of the Thumb family"
}
// Technically the locally built compiler uses the "dev" channel rather than the "nightly"
// channel, even though most people don't know or won't care about it. To avoid confusion, we
// treat the "dev" channel as the "nightly" channel when processing the directive.
condition! {
name: &config.channel,
name: if config.channel == "dev" { "nightly" } else { &config.channel },
allowed_names: &["stable", "beta", "nightly"],
message: "when the release channel is {name}",
}
condition! {
name: "cross-compile",
condition: config.target != config.host,