Skip to content

Commit

Permalink
core: derive Clone for result::IntoIter
Browse files Browse the repository at this point in the history
It appears to be a simple oversight that `result::IntoIter<T>` doesn't
implement `Clone` (where `T: Clone`).  We do already have `Clone` for
`result::Iter`, as well as the similar `option::IntoIter` and `Iter`.
  • Loading branch information
cuviper committed Oct 10, 2017
1 parent ec016f8 commit 9e8b33e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/libcore/result.rs
Expand Up @@ -1060,7 +1060,7 @@ unsafe impl<'a, A> TrustedLen for IterMut<'a, A> {}
/// [`Result`]: enum.Result.html
/// [`into_iter`]: ../iter/trait.IntoIterator.html#tymethod.into_iter
/// [`IntoIterator`]: ../iter/trait.IntoIterator.html
#[derive(Debug)]
#[derive(Clone, Debug)]
#[stable(feature = "rust1", since = "1.0.0")]
pub struct IntoIter<T> { inner: Option<T> }

Expand Down

0 comments on commit 9e8b33e

Please sign in to comment.