File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -122,7 +122,7 @@ fn main() {
122122 check ! ( fluent_alphabetical, & compiler_path, bless) ;
123123 check ! ( fluent_period, & compiler_path) ;
124124 check ! ( fluent_lowercase, & compiler_path) ;
125- // check!(target_policy, &root_path);
125+ check ! ( target_policy, & root_path) ;
126126 // check!(gcc_submodule, &root_path, &compiler_path);
127127
128128 // Checks that only make sense for the std libs.
Original file line number Diff line number Diff line change 55use std:: collections:: HashSet ;
66use std:: path:: Path ;
77
8+ use crate :: diagnostics:: DiagCtx ;
89use crate :: walk:: { filter_not_rust, walk} ;
910
1011const TARGET_DEFINITIONS_PATH : & str = "compiler/rustc_target/src/spec/targets/" ;
@@ -23,7 +24,9 @@ const EXCEPTIONS: &[&str] = &[
2324 "xtensa_esp32s3_espidf" ,
2425] ;
2526
26- pub fn check ( root_path : & Path , bad : & mut bool ) {
27+ pub fn check ( root_path : & Path , diag_ctx : DiagCtx ) {
28+ let mut check = diag_ctx. start_check ( "target_policy" ) ;
29+
2730 let mut targets_to_find = HashSet :: new ( ) ;
2831
2932 let definitions_path = root_path. join ( TARGET_DEFINITIONS_PATH ) ;
@@ -55,7 +58,7 @@ pub fn check(root_path: &Path, bad: &mut bool) {
5558
5659 for target in targets_to_find {
5760 if !EXCEPTIONS . contains ( & target. as_str ( ) ) {
58- tidy_error ! ( bad , "{ASSEMBLY_LLVM_TEST_PATH}: missing assembly test for {target}" )
61+ check . error ( format ! ( "{ASSEMBLY_LLVM_TEST_PATH}: missing assembly test for {target}" ) ) ;
5962 }
6063 }
6164}
You can’t perform that action at this time.
0 commit comments