Skip to content

Renamed ClonableIterator to CloneableIterator #11160

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 28, 2013
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/etc/vim/syntax/rust.vim
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ syn keyword rustTrait Default
syn keyword rustTrait Hash
syn keyword rustTrait FromStr
syn keyword rustTrait FromIterator Extendable
syn keyword rustTrait Iterator DoubleEndedIterator RandomAccessIterator ClonableIterator
syn keyword rustTrait Iterator DoubleEndedIterator RandomAccessIterator CloneableIterator
syn keyword rustTrait OrdIterator MutableDoubleEndedIterator ExactSize
syn keyword rustTrait Times

Expand Down
8 changes: 4 additions & 4 deletions src/libstd/iter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -906,14 +906,14 @@ impl<A: Ord, T: Iterator<A>> OrdIterator<A> for T {
}
}

/// A trait for iterators that are clonable.
pub trait ClonableIterator {
/// A trait for iterators that are cloneable.
pub trait CloneableIterator {
/// Repeats an iterator endlessly
///
/// # Example
///
/// ```rust
/// use std::iter::{ClonableIterator, count};
/// use std::iter::{CloneableIterator, count};
///
/// let a = count(1,1).take(1);
/// let mut cy = a.cycle();
Expand All @@ -923,7 +923,7 @@ pub trait ClonableIterator {
fn cycle(self) -> Cycle<Self>;
}

impl<A, T: Clone + Iterator<A>> ClonableIterator for T {
impl<A, T: Clone + Iterator<A>> CloneableIterator for T {
#[inline]
fn cycle(self) -> Cycle<T> {
Cycle{orig: self.clone(), iter: self}
Expand Down
2 changes: 1 addition & 1 deletion src/libstd/prelude.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ pub use default::Default;
pub use from_str::FromStr;
pub use hash::Hash;
pub use iter::{FromIterator, Extendable};
pub use iter::{Iterator, DoubleEndedIterator, RandomAccessIterator, ClonableIterator};
pub use iter::{Iterator, DoubleEndedIterator, RandomAccessIterator, CloneableIterator};
pub use iter::{OrdIterator, MutableDoubleEndedIterator, ExactSize};
pub use num::Times;
pub use num::{Algebraic, Trigonometric, Exponential, Hyperbolic};
Expand Down