Skip to content

Commit

Permalink
Merge pull request #4281 from Dretch/io-explicit-self
Browse files Browse the repository at this point in the history
Convert core::io to use explicit self (for issue #4118 and issue #2004)
  • Loading branch information
catamorphism committed Dec 24, 2012
2 parents cd6960e + feff3a9 commit 2bb2536
Show file tree
Hide file tree
Showing 4 changed files with 184 additions and 190 deletions.
12 changes: 6 additions & 6 deletions src/libcore/hash.rs
Original file line number Diff line number Diff line change
Expand Up @@ -188,11 +188,11 @@ fn SipState(key0: u64, key1: u64) -> SipState {
}


impl &SipState : io::Writer {
impl SipState : io::Writer {

// Methods for io::writer
#[inline(always)]
fn write(msg: &[const u8]) {
fn write(&self, msg: &[const u8]) {

macro_rules! u8to64_le (
($buf:expr, $i:expr) =>
Expand Down Expand Up @@ -282,16 +282,16 @@ impl &SipState : io::Writer {
self.ntail = left;
}

fn seek(_x: int, _s: io::SeekStyle) {
fn seek(&self, _x: int, _s: io::SeekStyle) {
fail;
}
fn tell() -> uint {
fn tell(&self) -> uint {
self.length
}
fn flush() -> int {
fn flush(&self) -> int {
0
}
fn get_type() -> io::WriterType {
fn get_type(&self) -> io::WriterType {
io::File
}
}
Expand Down
Loading

0 comments on commit 2bb2536

Please sign in to comment.