Auto merge of #57184 - varkor:deny-warnings-lib, r=Mark-Simulacrum

Deny warnings in libcore and libstd

This probably fixes https://github.com/rust-lang/rust/issues/57178 (though there may still be some crates that need warnings denied). At least after this change, rustc currently produces no warnings during compilation.

r? @oli-obk
This commit is contained in:
bors 2019-02-09 03:54:31 +00:00
commit 312f3827fa

View file

@ -1018,8 +1018,7 @@ impl<'a> Builder<'a> {
cargo.env("RUSTC_VERBOSE", self.verbosity.to_string()); cargo.env("RUSTC_VERBOSE", self.verbosity.to_string());
// in std, we want to avoid denying warnings for stage 0 as that makes cfg's painful. if self.config.deny_warnings {
if self.config.deny_warnings && !(mode == Mode::Std && stage == 0) {
cargo.env("RUSTC_DENY_WARNINGS", "1"); cargo.env("RUSTC_DENY_WARNINGS", "1");
} }