about summary refs log tree commit diff
path: root/src/bootstrap/builder.rs
diff options
context:
space:
mode:
authorJoshua Nelson <jyn514@gmail.com>2020-09-15 00:08:37 -0400
committerJoshua Nelson <jyn514@gmail.com>2020-09-16 08:51:42 -0400
commitd04ca008e1c8ade73ec22976ff6a2a6a13ceabec (patch)
tree6479dc44883bc4b5dd02cd4290871f713f5d7a8c /src/bootstrap/builder.rs
parent5fae56971d8487088c0099c82c0a5ce1638b5f62 (diff)
downloadrust-d04ca008e1c8ade73ec22976ff6a2a6a13ceabec.tar.gz
rust-d04ca008e1c8ade73ec22976ff6a2a6a13ceabec.zip
Remove unnecessary `clone()`s in bootstrap
The performance difference is negligible, but it makes me feel better.

Note that this does not remove some clones in `config`, because it would
require changing the logic around (and performance doesn't matter
for bootstrap).
Diffstat (limited to 'src/bootstrap/builder.rs')
-rw-r--r--src/bootstrap/builder.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/bootstrap/builder.rs b/src/bootstrap/builder.rs
index 34756af21e4..319f81c4ebb 100644
--- a/src/bootstrap/builder.rs
+++ b/src/bootstrap/builder.rs
@@ -1209,7 +1209,7 @@ impl<'a> Builder<'a> {
             cargo.env(format!("CC_{}", target.triple), &cc);
 
             let cflags = self.cflags(target, GitRepo::Rustc).join(" ");
-            cargo.env(format!("CFLAGS_{}", target.triple), cflags.clone());
+            cargo.env(format!("CFLAGS_{}", target.triple), &cflags);
 
             if let Some(ar) = self.ar(target) {
                 let ranlib = format!("{} s", ar.display());