Skip to content

Commit d6d0283

Browse files
committedMay 8, 2021
Auto merge of #83089 - Aaron1011:bootstrap-semi, r=Mark-Simulacrum
Enable `-W semicolon_in_expressions_from_macros` in bootstrap Now that stdarch has been updated, we can do this without breaking the build.
2 parents 881c1ac + 020d83d commit d6d0283

File tree

2 files changed

+2
-7
lines changed

2 files changed

+2
-7
lines changed
 

‎src/bootstrap/bootstrap.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -900,8 +900,8 @@ def build_bootstrap(self):
900900
target_linker = self.get_toml("linker", build_section)
901901
if target_linker is not None:
902902
env["RUSTFLAGS"] += " -C linker=" + target_linker
903-
# cfg(bootstrap): Add `-Wsemicolon_in_expressions_from_macros` after the next beta bump
904903
env["RUSTFLAGS"] += " -Wrust_2018_idioms -Wunused_lifetimes"
904+
env["RUSTFLAGS"] += " -Wsemicolon_in_expressions_from_macros"
905905
if self.get_toml("deny-warnings", "rust") != "false":
906906
env["RUSTFLAGS"] += " -Dwarnings"
907907

‎src/bootstrap/builder.rs

+1-6
Original file line numberDiff line numberDiff line change
@@ -1270,12 +1270,7 @@ impl<'a> Builder<'a> {
12701270
// some code doesn't go through this `rustc` wrapper.
12711271
lint_flags.push("-Wrust_2018_idioms");
12721272
lint_flags.push("-Wunused_lifetimes");
1273-
// cfg(bootstrap): unconditionally enable this warning after the next beta bump
1274-
// This is currently disabled for the stage1 libstd, since build scripts
1275-
// will end up using the bootstrap compiler (which doesn't yet support this lint)
1276-
if compiler.stage != 0 && mode != Mode::Std {
1277-
lint_flags.push("-Wsemicolon_in_expressions_from_macros");
1278-
}
1273+
lint_flags.push("-Wsemicolon_in_expressions_from_macros");
12791274

12801275
if self.config.deny_warnings {
12811276
lint_flags.push("-Dwarnings");

0 commit comments

Comments
 (0)
Please sign in to comment.