Slight updates to match API drift in io, lib-io.rs passes.
This commit is contained in:
parent
01b1d4110d
commit
80a4b1ba53
2 changed files with 5 additions and 5 deletions
|
@ -115,7 +115,7 @@ state obj new_reader(buf_reader rdr) {
|
||||||
// See _str.char_at
|
// See _str.char_at
|
||||||
val += ((b0 << ((w + 1u) as u8)) as uint) << ((w - 1u) * 6u - w - 1u);
|
val += ((b0 << ((w + 1u) as u8)) as uint) << ((w - 1u) * 6u - w - 1u);
|
||||||
ret val as char;
|
ret val as char;
|
||||||
}
|
}
|
||||||
impure fn eof() -> bool {
|
impure fn eof() -> bool {
|
||||||
ret rdr.eof();
|
ret rdr.eof();
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,12 +13,12 @@ fn test_simple(str tmpfilebase) {
|
||||||
log frood;
|
log frood;
|
||||||
|
|
||||||
{
|
{
|
||||||
let io.buf_writer out = io.new_buf_writer(tmpfile, vec(io.create));
|
let io.writer out = io.file_writer(tmpfile, vec(io.create));
|
||||||
out.write(_str.bytes(frood));
|
out.write_str(frood);
|
||||||
}
|
}
|
||||||
|
|
||||||
let io.buf_reader inp = io.new_buf_reader(tmpfile);
|
let io.reader inp = io.file_reader(tmpfile);
|
||||||
let str frood2 = _str.from_bytes(inp.read());
|
let str frood2 = inp.read_c_str();
|
||||||
log frood2;
|
log frood2;
|
||||||
check (_str.eq(frood, frood2));
|
check (_str.eq(frood, frood2));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue