Skip to content

Commit 57cf2ab

Browse files
committed
rustbuild: Deny and fix warnings
Turned out this lint uncovered an actual bug! Closes #38484
1 parent 94ae2a2 commit 57cf2ab

File tree

4 files changed

+7
-1
lines changed

4 files changed

+7
-1
lines changed

src/bootstrap/bin/rustc.rs

+2
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@
2525
//! switching compilers for the bootstrap and for build scripts will probably
2626
//! never get replaced.
2727
28+
#![deny(warnings)]
29+
2830
extern crate bootstrap;
2931

3032
use std::env;

src/bootstrap/bin/rustdoc.rs

+2
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@
1212
//!
1313
//! See comments in `src/bootstrap/rustc.rs` for more information.
1414
15+
#![deny(warnings)]
16+
1517
extern crate bootstrap;
1618

1719
use std::env;

src/bootstrap/flags.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ To learn more about a subcommand, run `./x.py <command> -h`
280280

281281
Flags {
282282
verbose: m.opt_count("v"),
283-
stage: m.opt_str("stage").map(|j| j.parse().unwrap()),
283+
stage: stage,
284284
keep_stage: m.opt_str("keep-stage").map(|j| j.parse().unwrap()),
285285
build: m.opt_str("build").unwrap_or_else(|| {
286286
env::var("BUILD").unwrap()

src/bootstrap/lib.rs

+2
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,8 @@
6464
//! More documentation can be found in each respective module below, and you can
6565
//! also check out the `src/bootstrap/README.md` file for more information.
6666
67+
#![deny(warnings)]
68+
6769
extern crate build_helper;
6870
extern crate cmake;
6971
extern crate filetime;

0 commit comments

Comments
 (0)