mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-08 09:38:26 +03:00
Trim MSVC output even if it doesn't start with whitespace
I copied this from Chromium and I think Chromium was just wrong.
This commit is contained in:
@@ -729,9 +729,10 @@ fn for_each(bytes: &[u8], mut f: impl FnMut(&str, &mut String)) -> String {
|
||||
escaped_stdout = for_each(&stdout, |line, output| {
|
||||
// Hide some progress messages from link.exe that we don't care about.
|
||||
// See https://github.com/chromium/chromium/blob/bfa41e41145ffc85f041384280caf2949bb7bd72/build/toolchain/win/tool_wrapper.py#L144-L146
|
||||
if line.starts_with(" Creating library")
|
||||
|| line.starts_with("Generating code")
|
||||
|| line.starts_with("Finished generating code")
|
||||
let trimmed = line.trim_start();
|
||||
if trimmed.starts_with("Creating library")
|
||||
|| trimmed.starts_with("Generating code")
|
||||
|| trimmed.starts_with("Finished generating code")
|
||||
{
|
||||
linker_info += line;
|
||||
linker_info += "\r\n";
|
||||
|
||||
Reference in New Issue
Block a user