File tree Expand file tree Collapse file tree 5 files changed +22
-2
lines changed Expand file tree Collapse file tree 5 files changed +22
-2
lines changed Original file line number Diff line number Diff line change 467
467
# Whether to use the precompiled stage0 libtest with compiletest.
468
468
# build.compiletest-use-stage0-libtest = true
469
469
470
+ # Default value for the `--extra-checks` flag of tidy.
471
+ #
472
+ # See `./x test tidy --help` for details.
473
+ #
474
+ # Note that if any value is manually given to bootstrap such as
475
+ # `./x test tidy --extra-checks=js`, this value is ignored.
476
+ # Use `--extra-checks=''` to temporarily disable all extra checks.
477
+ # build.tidy-extra-checks = ""
478
+
470
479
# Indicates whether ccache is used when building certain artifacts (e.g. LLVM).
471
480
# Set to `true` to use the first `ccache` in PATH, or set an absolute path to use
472
481
# a specific version.
Original file line number Diff line number Diff line change @@ -1108,7 +1108,9 @@ impl Step for Tidy {
1108
1108
if builder. config . cmd . bless ( ) {
1109
1109
cmd. arg ( "--bless" ) ;
1110
1110
}
1111
- if let Some ( s) = builder. config . cmd . extra_checks ( ) {
1111
+ if let Some ( s) =
1112
+ builder. config . cmd . extra_checks ( ) . or ( builder. config . tidy_extra_checks . as_deref ( ) )
1113
+ {
1112
1114
cmd. arg ( format ! ( "--extra-checks={s}" ) ) ;
1113
1115
}
1114
1116
let mut args = std:: env:: args_os ( ) ;
Original file line number Diff line number Diff line change @@ -297,7 +297,8 @@ pub struct Config {
297
297
298
298
/// Whether to use the precompiled stage0 libtest with compiletest.
299
299
pub compiletest_use_stage0_libtest : bool ,
300
-
300
+ /// Default value for `--extra-checks`
301
+ pub tidy_extra_checks : Option < String > ,
301
302
pub is_running_on_ci : bool ,
302
303
303
304
/// Cache for determining path modifications
@@ -744,6 +745,7 @@ impl Config {
744
745
jobs,
745
746
compiletest_diff_tool,
746
747
compiletest_use_stage0_libtest,
748
+ tidy_extra_checks,
747
749
mut ccache,
748
750
exclude,
749
751
} = toml. build . unwrap_or_default ( ) ;
@@ -1010,6 +1012,7 @@ impl Config {
1010
1012
optimized_compiler_builtins. unwrap_or ( config. channel != "dev" ) ;
1011
1013
config. compiletest_diff_tool = compiletest_diff_tool;
1012
1014
config. compiletest_use_stage0_libtest = compiletest_use_stage0_libtest. unwrap_or ( true ) ;
1015
+ config. tidy_extra_checks = tidy_extra_checks;
1013
1016
1014
1017
let download_rustc = config. download_rustc_commit . is_some ( ) ;
1015
1018
config. explicit_stage_from_cli = flags_stage. is_some ( ) ;
Original file line number Diff line number Diff line change @@ -69,6 +69,7 @@ define_config! {
69
69
jobs: Option <u32 > = "jobs" ,
70
70
compiletest_diff_tool: Option <String > = "compiletest-diff-tool" ,
71
71
compiletest_use_stage0_libtest: Option <bool > = "compiletest-use-stage0-libtest" ,
72
+ tidy_extra_checks: Option <String > = "tidy-extra-checks" ,
72
73
ccache: Option <StringOrBool > = "ccache" ,
73
74
exclude: Option <Vec <PathBuf >> = "exclude" ,
74
75
}
Original file line number Diff line number Diff line change @@ -441,4 +441,9 @@ pub const CONFIG_CHANGE_HISTORY: &[ChangeInfo] = &[
441
441
severity : ChangeSeverity :: Warning ,
442
442
summary : "`llvm.lld` is no longer enabled by default for the dist profile." ,
443
443
} ,
444
+ ChangeInfo {
445
+ change_id : 143251 ,
446
+ severity : ChangeSeverity :: Info ,
447
+ summary : "Added new option `build.tidy-extra-checks` to specify a default value for the --extra-checks cli flag." ,
448
+ } ,
444
449
] ;
You can’t perform that action at this time.
0 commit comments