Skip to content
Closed
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: 2 additions & 0 deletions src/libcore/fmt/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,7 @@ pub trait Show {
#[lang = "debug_trait"]
pub trait Debug {
/// Formats the value using the given formatter.
#[stable(feature = "rust1", since = "1.0.0")]
fn fmt(&self, &mut Formatter) -> Result;
}

Expand All @@ -324,6 +325,7 @@ pub trait String {
#[stable(feature = "rust1", since = "1.0.0")]
pub trait Display {
/// Formats the value using the given formatter.
#[stable(feature = "rust1", since = "1.0.0")]
fn fmt(&self, &mut Formatter) -> Result;
}

Expand Down
5 changes: 5 additions & 0 deletions src/libcore/iter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -119,14 +119,18 @@ impl<'a, T> Iterator for &'a mut (Iterator<Item=T> + 'a) {
built from an iterator over elements of type `{A}`"]
pub trait FromIterator<A> {
/// Build a container with elements from an external iterator.
#[stable(feature = "rust1", since = "1.0.0")]
fn from_iter<T: Iterator<Item=A>>(iterator: T) -> Self;
}

/// Conversion into an `Iterator`
#[stable(feature = "rust1", since = "1.0.0")]
pub trait IntoIterator {
#[stable(feature = "rust1", since = "1.0.0")]
type Iter: Iterator;

/// Consumes `Self` and returns an iterator over it
#[stable(feature = "rust1", since = "1.0.0")]
fn into_iter(self) -> Self::Iter;
}

Expand Down Expand Up @@ -1866,6 +1870,7 @@ impl<T, I> Peekable<T, I> where I: Iterator<Item=T> {
/// Return a reference to the next element of the iterator with out advancing it,
/// or None if the iterator is exhausted.
#[inline]
#[stable(feature = "rust1", since = "1.0.0")]
pub fn peek(&mut self) -> Option<&T> {
if self.peeked.is_none() {
self.peeked = self.iter.next();
Expand Down