From 64a4decec779ee0a30585a12352d20a54b722506 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Fri, 6 Feb 2015 14:47:09 -0800 Subject: [PATCH] std: Remove typarms from IteratorExt::cloned With associated types an where clauses none of the type parameters are necessary. [breaking-change] --- src/libcore/iter.rs | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/libcore/iter.rs b/src/libcore/iter.rs index 5df64cfaadaa..fcf46b81a57a 100644 --- a/src/libcore/iter.rs +++ b/src/libcore/iter.rs @@ -967,10 +967,9 @@ pub trait IteratorExt: Iterator + Sized { /// Creates an iterator that clones the elements it yields. Useful for converting an /// Iterator<&T> to an Iterator. #[unstable(feature = "core", reason = "recent addition")] - fn cloned(self) -> Cloned where - Self: Iterator, - D: Deref, - T: Clone, + fn cloned(self) -> Cloned where + Self::Item: Deref, + ::Output: Clone, { Cloned { it: self } }