Skip to content

Commit 0dc4978

Browse files
committed
compiletest: prevent rmake.rs from using any nightly/unstable features
1 parent da69926 commit 0dc4978

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/tools/compiletest/src/runtest/run_make.rs

+5
Original file line numberDiff line numberDiff line change
@@ -272,6 +272,11 @@ impl TestCx<'_> {
272272
};
273273
let mut rustc = Command::new(bootstrap_rustc);
274274
rustc
275+
// `rmake.rs` **must** be buildable by a stable compiler, it may not use *any* unstable
276+
// library or compiler features. Here, we force the stage 0 rustc to consider itself as
277+
// a stable-channel compiler via `RUSTC_BOOTSTRAP=-1` to prevent *any* unstable
278+
// library/compiler usages, even if stage 0 rustc is *actually* a nightly rustc.
279+
.env("RUSTC_BOOTSTRAP", "-1")
275280
.arg("-o")
276281
.arg(&recipe_bin)
277282
// Specify library search paths for `run_make_support`.

0 commit comments

Comments
 (0)