about summary refs log tree commit diff
path: root/compiler/rustc_infer
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2020-12-24 10:16:06 +0100
committerMatthias Krüger <matthias.krueger@famsik.de>2020-12-24 12:59:22 +0100
commit6e852cc4ce3b99048d164c58456371c25669c672 (patch)
tree7c0a2e56a0fd8b3caeba59e9e72c9ce282aa931e /compiler/rustc_infer
parentc34c015fe2710caf53ba7ae9d1644f9ba65a6f74 (diff)
downloadrust-6e852cc4ce3b99048d164c58456371c25669c672.tar.gz
rust-6e852cc4ce3b99048d164c58456371c25669c672.zip
remove redundant clones (clippy::redundant_clone)
Diffstat (limited to 'compiler/rustc_infer')
-rw-r--r--compiler/rustc_infer/src/infer/mod.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_infer/src/infer/mod.rs b/compiler/rustc_infer/src/infer/mod.rs
index 069f708856e..56d9634213a 100644
--- a/compiler/rustc_infer/src/infer/mod.rs
+++ b/compiler/rustc_infer/src/infer/mod.rs
@@ -1317,7 +1317,7 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> {
         T: TypeFoldable<'tcx>,
     {
         if !value.needs_infer() {
-            return value.clone(); // Avoid duplicated subst-folding.
+            return value; // Avoid duplicated subst-folding.
         }
         let mut r = resolve::OpportunisticVarResolver::new(self);
         value.fold_with(&mut r)