mirror of
https://github.com/rust-lang/cargo.git
synced 2025-09-28 11:20:36 +00:00
profiles: improve formatting of some new error messages
This commit is contained in:
parent
c86213f141
commit
d71a172eae
@ -214,13 +214,13 @@ impl Profiles {
|
|||||||
Some(name) => {
|
Some(name) => {
|
||||||
let name = name.to_owned();
|
let name = name.to_owned();
|
||||||
if set.get(&name).is_some() {
|
if set.get(&name).is_some() {
|
||||||
failure::bail!("Inheritance loop of profiles cycles with {}", name);
|
failure::bail!("Inheritance loop of profiles cycles with profile '{}'", name);
|
||||||
}
|
}
|
||||||
|
|
||||||
set.insert(name.clone());
|
set.insert(name.clone());
|
||||||
match profiles.get(&name) {
|
match profiles.get(&name) {
|
||||||
None => {
|
None => {
|
||||||
failure::bail!("Profile {} not found in Cargo.toml", name);
|
failure::bail!("Profile '{}' not found in Cargo.toml", name);
|
||||||
}
|
}
|
||||||
Some(parent) => self.process_chain(&name, parent, set, result, profiles),
|
Some(parent) => self.process_chain(&name, parent, set, result, profiles),
|
||||||
}
|
}
|
||||||
@ -228,8 +228,8 @@ impl Profiles {
|
|||||||
None => {
|
None => {
|
||||||
failure::bail!(
|
failure::bail!(
|
||||||
"An 'inherits' directive is needed for all \
|
"An 'inherits' directive is needed for all \
|
||||||
profiles that are not 'dev' or 'release. Here \
|
profiles that are not 'dev' or 'release'. Here \
|
||||||
it is missing from {}",
|
it is missing from '{}'",
|
||||||
name
|
name
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user