@@ -113,38 +113,35 @@ impl Step for Std {
113
113
// since we initialize with an empty sysroot.
114
114
//
115
115
// Currently only the "libtest" tree of crates does this.
116
+ let mut cargo = builder. cargo (
117
+ compiler,
118
+ Mode :: Std ,
119
+ SourceType :: InTree ,
120
+ target,
121
+ cargo_subcommand ( builder. kind ) ,
122
+ ) ;
123
+ cargo. arg ( "--all-targets" ) ;
124
+ std_cargo ( builder, target, compiler. stage , & mut cargo) ;
116
125
117
- if let Subcommand :: Check { all_targets : true , .. } = builder. config . cmd {
118
- let mut cargo = builder. cargo (
119
- compiler,
120
- Mode :: Std ,
121
- SourceType :: InTree ,
122
- target,
123
- cargo_subcommand ( builder. kind ) ,
124
- ) ;
125
- std_cargo ( builder, target, compiler. stage , & mut cargo) ;
126
- cargo. arg ( "--all-targets" ) ;
127
-
128
- // Explicitly pass -p for all dependencies krates -- this will force cargo
129
- // to also check the tests/benches/examples for these crates, rather
130
- // than just the leaf crate.
131
- for krate in builder. in_tree_crates ( "test" , Some ( target) ) {
132
- cargo. arg ( "-p" ) . arg ( krate. name ) ;
133
- }
134
-
135
- builder. info ( & format ! (
136
- "Checking stage{} std test/bench/example targets ({} -> {})" ,
137
- builder. top_stage, & compiler. host, target
138
- ) ) ;
139
- run_cargo (
140
- builder,
141
- cargo,
142
- args ( builder) ,
143
- & libstd_test_stamp ( builder, compiler, target) ,
144
- vec ! [ ] ,
145
- true ,
146
- ) ;
126
+ // Explicitly pass -p for all dependencies krates -- this will force cargo
127
+ // to also check the tests/benches/examples for these crates, rather
128
+ // than just the leaf crate.
129
+ for krate in builder. in_tree_crates ( "test" , Some ( target) ) {
130
+ cargo. arg ( "-p" ) . arg ( krate. name ) ;
147
131
}
132
+
133
+ builder. info ( & format ! (
134
+ "Checking stage{} std test/bench/example targets ({} -> {})" ,
135
+ builder. top_stage, & compiler. host, target
136
+ ) ) ;
137
+ run_cargo (
138
+ builder,
139
+ cargo,
140
+ args ( builder) ,
141
+ & libstd_test_stamp ( builder, compiler, target) ,
142
+ vec ! [ ] ,
143
+ true ,
144
+ ) ;
148
145
}
149
146
}
150
147
@@ -195,9 +192,7 @@ impl Step for Rustc {
195
192
cargo_subcommand ( builder. kind ) ,
196
193
) ;
197
194
rustc_cargo ( builder, & mut cargo, target) ;
198
- if let Subcommand :: Check { all_targets : true , .. } = builder. config . cmd {
199
- cargo. arg ( "--all-targets" ) ;
200
- }
195
+ cargo. arg ( "--all-targets" ) ;
201
196
202
197
// Explicitly pass -p for all compiler krates -- this will force cargo
203
198
// to also check the tests/benches/examples for these crates, rather
@@ -318,10 +313,7 @@ macro_rules! tool_check_step {
318
313
$source_type,
319
314
& [ ] ,
320
315
) ;
321
-
322
- if let Subcommand :: Check { all_targets: true , .. } = builder. config. cmd {
323
- cargo. arg( "--all-targets" ) ;
324
- }
316
+ cargo. arg( "--all-targets" ) ;
325
317
326
318
// Enable internal lints for clippy and rustdoc
327
319
// NOTE: this doesn't enable lints for any other tools unless they explicitly add `#![warn(rustc::internal)]`
0 commit comments