about summary refs log tree commit diff
path: root/src/tools/compiletest
diff options
context:
space:
mode:
authorAndrew Pollack <andrewpkq@gmail.com>2022-10-24 08:48:13 -0700
committerGitHub <noreply@github.com>2022-10-24 08:48:13 -0700
commitf01608cbc41783710dd1909707d74d720c2b6cf8 (patch)
tree5b45a1eb2fb134769bb39de2f1d35e02445be36a /src/tools/compiletest
parent47703d3f3daaa84b0d8e2c66ddd3835402da0884 (diff)
downloadrust-f01608cbc41783710dd1909707d74d720c2b6cf8.tar.gz
rust-f01608cbc41783710dd1909707d74d720c2b6cf8.zip
Update src/tools/compiletest/src/runtest.rs
Co-authored-by: Mark Rousskov <mark.simulacrum@gmail.com>
Diffstat (limited to 'src/tools/compiletest')
-rw-r--r--src/tools/compiletest/src/runtest.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tools/compiletest/src/runtest.rs b/src/tools/compiletest/src/runtest.rs
index 3068f3c5b0b..8af5f1da694 100644
--- a/src/tools/compiletest/src/runtest.rs
+++ b/src/tools/compiletest/src/runtest.rs
@@ -1184,7 +1184,7 @@ impl<'test> TestCx<'test> {
         // Remove options that are either unwanted (-O) or may lead to duplicates due to RUSTFLAGS.
         let options_to_remove = ["-O".to_owned(), "-g".to_owned(), "--debuginfo".to_owned()];
 
-        options.to_vec().into_iter().filter(|x| !options_to_remove.contains(x)).collect()
+        options.iter().filter(|x| !options_to_remove.contains(x)).map(|x| x.clone()).collect()
     }
 
     fn maybe_add_external_args(&self, cmd: &mut Command, args: &Vec<String>) {