Skip to content

Commit 7544563

Browse files
Only enable rustdoc --generate-macro-expansion option for stage builds higher than 1
1 parent c8c7b5b commit 7544563

File tree

1 file changed

+7
-1
lines changed
  • src/bootstrap/src/core/build_steps

1 file changed

+7
-1
lines changed

‎src/bootstrap/src/core/build_steps/doc.rs‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -932,7 +932,13 @@ impl Step for Rustc {
932932
// see https://github.com/rust-lang/rust/pull/122066#issuecomment-1983049222
933933
// If there is any bug, please comment out the next line.
934934
cargo.rustdocflag("--generate-link-to-definition");
935-
cargo.rustdocflag("--generate-macro-expansion");
935+
// FIXME: Currently, `--generate-macro-expansion` option is buggy in `beta` rustdoc. To
936+
// allow CI to pass, we only enable the option in stage 2 and higher.
937+
// cfg(bootstrap)
938+
// ^ Adding this so it's not forgotten when the new release is done.
939+
if builder.top_stage > 1 {
940+
cargo.rustdocflag("--generate-macro-expansion");
941+
}
936942

937943
compile::rustc_cargo(builder, &mut cargo, target, &build_compiler, &self.crates);
938944
cargo.arg("-Zskip-rustdoc-fingerprint");

0 commit comments

Comments
 (0)