Skip to content

Commit

Permalink
Rollup merge of rust-lang#22898 - edwardw:one-less-unsafe-impl, r=huonw
Browse files Browse the repository at this point in the history
 These implementations were temporary workaround. Now rust-lang#22828 has been
fixed, they can be removed.
  • Loading branch information
Manishearth committed Mar 1, 2015
2 parents 4ac53cc + 2b8207a commit 3c1f61c
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/libcore/iter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ use num::{ToPrimitive, Int};
use ops::{Add, Deref, FnMut};
use option::Option;
use option::Option::{Some, None};
use marker::{Send, Sized, Sync};
use marker::Sized;
use usize;

/// An interface for dealing with "external iterators". These types of iterators
Expand Down Expand Up @@ -1783,10 +1783,6 @@ pub struct Peekable<I: Iterator> {
peeked: Option<I::Item>,
}

// FIXME: after #22828 being fixed, the following unsafe impl should be removed
unsafe impl<I: Iterator> Sync for Peekable<I> where I: Sync, I::Item: Sync {}
unsafe impl<I: Iterator> Send for Peekable<I> where I: Send, I::Item: Send {}

impl<I: Iterator + Clone> Clone for Peekable<I> where I::Item: Clone {
fn clone(&self) -> Peekable<I> {
Peekable {
Expand Down

0 comments on commit 3c1f61c

Please sign in to comment.