Fixed compilation for rust master.

This commit is contained in:
Aaron Weiss 2015-01-04 14:22:24 -05:00
parent 4e41d5a80d
commit 01b2e218cd
3 changed files with 5 additions and 3 deletions

View file

@ -189,7 +189,8 @@ impl<'a> AccessLevelIterator<'a> {
} }
} }
impl<'a> Iterator<AccessLevel> for AccessLevelIterator<'a> { impl<'a> Iterator for AccessLevelIterator<'a> {
type Item = AccessLevel;
fn next(&mut self) -> Option<AccessLevel> { fn next(&mut self) -> Option<AccessLevel> {
let ret = self.value.parse(); let ret = self.value.parse();
if self.value.len() > 0 { if self.value.len() > 0 {

View file

@ -4,7 +4,7 @@
#![unstable] #![unstable]
#![warn(missing_docs)] #![warn(missing_docs)]
#![feature(slicing_syntax, old_orphan_check)] #![feature(associated_types, slicing_syntax, old_orphan_check)]
#[cfg(feature = "ctcp")] extern crate time; #[cfg(feature = "ctcp")] extern crate time;
#[cfg(feature = "encode")] extern crate encoding; #[cfg(feature = "encode")] extern crate encoding;
extern crate "rustc-serialize" as rustc_serialize; extern crate "rustc-serialize" as rustc_serialize;

View file

@ -260,7 +260,8 @@ impl<'a, T: IrcReader, U: IrcWriter> ServerIterator<'a, T, U> {
} }
} }
impl<'a, T: IrcReader, U: IrcWriter> Iterator<IoResult<Message>> for ServerIterator<'a, T, U> { impl<'a, T: IrcReader, U: IrcWriter> Iterator for ServerIterator<'a, T, U> {
type Item = IoResult<Message>;
fn next(&mut self) -> Option<IoResult<Message>> { fn next(&mut self) -> Option<IoResult<Message>> {
let res = self.get_next_line().and_then(|msg| let res = self.get_next_line().and_then(|msg|
match msg.parse() { match msg.parse() {