Skip to content

Commit cf3d178

Browse files
Rollup merge of #122378 - clubby789:rustbook-rebuild, r=onur-ozkan
Properly rebuild rustbooks Fixes #122367 If the book was out of date but the tool was up to date, this would evaluate to `!(false || true)` == `!true` == `false` and not rebuild.
2 parents bca8c62 + e8cef43 commit cf3d178

File tree

1 file changed

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

1 file changed

+2
-1
lines changed

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

+2-1
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,8 @@ impl<P: Step> Step for RustbookSrc<P> {
145145
let rustbook = builder.tool_exe(Tool::Rustbook);
146146
let mut rustbook_cmd = builder.tool_cmd(Tool::Rustbook);
147147

148-
if !builder.config.dry_run() && !(up_to_date(&src, &index) || up_to_date(&rustbook, &index))
148+
if !builder.config.dry_run()
149+
&& (!up_to_date(&src, &index) || !up_to_date(&rustbook, &index))
149150
{
150151
builder.info(&format!("Rustbook ({target}) - {name}"));
151152
let _ = fs::remove_dir_all(&out);

0 commit comments

Comments
 (0)