@@ -285,8 +285,8 @@ fn run_pretty_test(config: &Config, props: &TestProps, testfile: &Path) {
285
285
format!( "--target={}" , config. target) ,
286
286
"-L" . to_string( ) ,
287
287
aux_dir. to_str( ) . unwrap( ) . to_string( ) ) ;
288
- args. extend ( split_maybe_args ( & config. target_rustcflags ) . into_iter ( ) ) ;
289
- args. extend ( split_maybe_args ( & props. compile_flags ) . into_iter ( ) ) ;
288
+ args. extend ( split_maybe_args ( & config. target_rustcflags ) ) ;
289
+ args. extend ( split_maybe_args ( & props. compile_flags ) ) ;
290
290
return ProcArgs {
291
291
prog : config. rustc_path . to_str ( ) . unwrap ( ) . to_string ( ) ,
292
292
args : args,
@@ -333,8 +333,8 @@ actual:\n\
333
333
config. build_base. to_str( ) . unwrap( ) . to_string( ) ,
334
334
"-L" . to_string( ) ,
335
335
aux_dir. to_str( ) . unwrap( ) . to_string( ) ) ;
336
- args. extend ( split_maybe_args ( & config. target_rustcflags ) . into_iter ( ) ) ;
337
- args. extend ( split_maybe_args ( & props. compile_flags ) . into_iter ( ) ) ;
336
+ args. extend ( split_maybe_args ( & config. target_rustcflags ) ) ;
337
+ args. extend ( split_maybe_args ( & props. compile_flags ) ) ;
338
338
// FIXME (#9639): This needs to handle non-utf8 paths
339
339
return ProcArgs {
340
340
prog : config. rustc_path . to_str ( ) . unwrap ( ) . to_string ( ) ,
@@ -380,7 +380,7 @@ fn run_debuginfo_gdb_test(config: &Config, props: &TestProps, testfile: &Path) {
380
380
script_str. push_str ( & format ! ( "set solib-search-path \
381
381
./{}/stage2/lib/rustlib/{}/lib/\n ",
382
382
config. host, config. target) ) ;
383
- for line in breakpoint_lines. iter ( ) {
383
+ for line in & breakpoint_lines {
384
384
script_str. push_str ( & format ! ( "break {:?}:{}\n " ,
385
385
testfile. file_name( ) . unwrap( )
386
386
. to_string_lossy( ) ,
@@ -1171,7 +1171,7 @@ fn document(config: &Config, props: &TestProps,
1171
1171
out_dir. to_str( ) . unwrap( ) . to_string( ) ,
1172
1172
testfile. to_str( ) . unwrap( ) . to_string( ) ] ;
1173
1173
args. extend ( extra_args. iter ( ) . cloned ( ) ) ;
1174
- args. extend ( split_maybe_args ( & props. compile_flags ) . into_iter ( ) ) ;
1174
+ args. extend ( split_maybe_args ( & props. compile_flags ) ) ;
1175
1175
let args = ProcArgs {
1176
1176
prog : config. rustdoc_path . to_str ( ) . unwrap ( ) . to_string ( ) ,
1177
1177
args : args,
@@ -1236,7 +1236,7 @@ fn compose_and_run_compiler(config: &Config, props: &TestProps,
1236
1236
vec ! ( "--crate-type=dylib" . to_string( ) )
1237
1237
}
1238
1238
} ;
1239
- crate_type. extend ( extra_link_args. clone ( ) . into_iter ( ) ) ;
1239
+ crate_type. extend ( extra_link_args. clone ( ) ) ;
1240
1240
let aux_args =
1241
1241
make_compile_args ( config,
1242
1242
& aux_props,
@@ -1334,11 +1334,11 @@ fn make_compile_args<F>(config: &Config,
1334
1334
} ;
1335
1335
args. push ( path. to_str ( ) . unwrap ( ) . to_string ( ) ) ;
1336
1336
if props. force_host {
1337
- args. extend ( split_maybe_args ( & config. host_rustcflags ) . into_iter ( ) ) ;
1337
+ args. extend ( split_maybe_args ( & config. host_rustcflags ) ) ;
1338
1338
} else {
1339
- args. extend ( split_maybe_args ( & config. target_rustcflags ) . into_iter ( ) ) ;
1339
+ args. extend ( split_maybe_args ( & config. target_rustcflags ) ) ;
1340
1340
}
1341
- args. extend ( split_maybe_args ( & props. compile_flags ) . into_iter ( ) ) ;
1341
+ args. extend ( split_maybe_args ( & props. compile_flags ) ) ;
1342
1342
return ProcArgs {
1343
1343
prog : config. rustc_path . to_str ( ) . unwrap ( ) . to_string ( ) ,
1344
1344
args : args,
@@ -1373,7 +1373,7 @@ fn make_run_args(config: &Config, props: &TestProps, testfile: &Path)
1373
1373
args. push ( exe_file. to_str ( ) . unwrap ( ) . to_string ( ) ) ;
1374
1374
1375
1375
// Add the arguments in the run_flags directive
1376
- args. extend ( split_maybe_args ( & props. run_flags ) . into_iter ( ) ) ;
1376
+ args. extend ( split_maybe_args ( & props. run_flags ) ) ;
1377
1377
1378
1378
let prog = args. remove ( 0 ) ;
1379
1379
return ProcArgs {
@@ -1683,7 +1683,7 @@ fn compile_test_and_save_ir(config: &Config, props: &TestProps,
1683
1683
aux_dir. to_str( ) . unwrap( ) . to_string( ) ) ;
1684
1684
let llvm_args = vec ! ( "--emit=llvm-ir" . to_string( ) ,
1685
1685
"--crate-type=lib" . to_string( ) ) ;
1686
- link_args. extend ( llvm_args. into_iter ( ) ) ;
1686
+ link_args. extend ( llvm_args) ;
1687
1687
let args = make_compile_args ( config,
1688
1688
props,
1689
1689
link_args,
0 commit comments