Skip to content

Commit

Permalink
skip target sanity check when it's a local-rebuild
Browse files Browse the repository at this point in the history
Running the stage0 target sanity check on the newly built compiler can result
in errors and incorrect assumptions.

Signed-off-by: onur-ozkan <work@onurozkan.dev>
  • Loading branch information
onur-ozkan committed Sep 12, 2024
1 parent f827364 commit 564fc54
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/bootstrap/src/core/sanity.rs
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,9 @@ than building it.
}

// Ignore fake targets that are only used for unit tests in bootstrap.
if cfg!(not(feature = "bootstrap-self-test")) && !skip_target_sanity {
if cfg!(not(feature = "bootstrap-self-test"))
&& (!skip_target_sanity || !build.local_rebuild)
{
let mut has_target = false;
let target_str = target.to_string();

Expand Down

0 comments on commit 564fc54

Please sign in to comment.