Skip to content

Commit

Permalink
Auto merge of #7369 - jonas-schievink:the-little-c-that-Could, r=alex…
Browse files Browse the repository at this point in the history
…crichton

Uncapitalize "Could not compile" error message

"could not compile ..." matches other Cargo and rustc errors and
warnings better.
  • Loading branch information
bors committed Sep 17, 2019
2 parents 13bc9a1 + 26229cd commit 3b735c6
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion src/cargo/core/compiler/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ fn rustc<'a, 'cfg>(
&mut |line| on_stderr_line(state, line, package_id, &target, &mut output_options),
)
.map_err(internal_if_simple_exit_code)
.chain_err(|| format!("Could not compile `{}`.", name))?;
.chain_err(|| format!("could not compile `{}`.", name))?;
}

if do_rename && real_name != crate_name {
Expand Down
8 changes: 4 additions & 4 deletions tests/testsuite/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,7 @@ fn cargo_compile_with_invalid_code() {
.with_status(101)
.with_stderr_contains(
"\
[ERROR] Could not compile `foo`.
[ERROR] could not compile `foo`.
To learn more, run the command again with --verbose.\n",
)
Expand Down Expand Up @@ -551,7 +551,7 @@ fn cargo_compile_with_invalid_code_in_deps() {
p.cargo("build")
.with_status(101)
.with_stderr_contains("[..]invalid rust code[..]")
.with_stderr_contains("[ERROR] Could not compile [..]")
.with_stderr_contains("[ERROR] could not compile [..]")
.run();
}

Expand Down Expand Up @@ -4528,7 +4528,7 @@ fn signal_display() {
"\
[COMPILING] pm [..]
[COMPILING] foo [..]
[ERROR] Could not compile `foo`.
[ERROR] could not compile `foo`.
Caused by:
process didn't exit successfully: `rustc [..]` (signal: 6, SIGABRT: process abort signal)
Expand Down Expand Up @@ -4660,7 +4660,7 @@ fn pipelining_big_graph() {
foo.cargo("build -p foo")
.env("CARGO_BUILD_PIPELINING", "true")
.with_status(101)
.with_stderr_contains("[ERROR] Could not compile `a30`[..]")
.with_stderr_contains("[ERROR] could not compile `a30`[..]")
.run();
}

Expand Down
2 changes: 1 addition & 1 deletion tests/testsuite/build_script.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1072,7 +1072,7 @@ fn build_deps_not_for_normal() {
.with_stderr_contains("[..]can't find crate for `aaaaa`[..]")
.with_stderr_contains(
"\
[ERROR] Could not compile `foo`.
[ERROR] could not compile `foo`.
Caused by:
process didn't exit successfully: [..]
Expand Down
2 changes: 1 addition & 1 deletion tests/testsuite/check.rs
Original file line number Diff line number Diff line change
Expand Up @@ -684,7 +684,7 @@ fn short_message_format() {
"\
src/lib.rs:1:27: error[E0308]: mismatched types
error: aborting due to previous error
error: Could not compile `foo`.
error: could not compile `foo`.
",
)
.run();
Expand Down
2 changes: 1 addition & 1 deletion tests/testsuite/fix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ fn do_not_fix_broken_builds() {
p.cargo("fix --allow-no-vcs")
.env("__CARGO_FIX_YOLO", "1")
.with_status(101)
.with_stderr_contains("[ERROR] Could not compile `foo`.")
.with_stderr_contains("[ERROR] could not compile `foo`.")
.run();
assert!(p.read_file("src/lib.rs").contains("let mut x = 3;"));
}
Expand Down
2 changes: 1 addition & 1 deletion tests/testsuite/install.rs
Original file line number Diff line number Diff line change
Expand Up @@ -606,7 +606,7 @@ fn compile_failure() {
found at `[..]target`
Caused by:
Could not compile `foo`.
could not compile `foo`.
To learn more, run the command again with --verbose.
",
Expand Down

0 comments on commit 3b735c6

Please sign in to comment.