std: move str::as_buf into StrSlice

This commit is contained in:
Erick Tryzelaar 2013-07-10 17:33:11 -07:00
parent cfd89c4075
commit 9fdec67a67
6 changed files with 62 additions and 62 deletions

View file

@ -20,11 +20,11 @@ mod libc {
}
fn atol(s: ~str) -> int {
return str::as_buf(s, { |x, _len| unsafe { libc::atol(x) } });
s.as_buf(|x, _len| unsafe { libc::atol(x) })
}
fn atoll(s: ~str) -> i64 {
return str::as_buf(s, { |x, _len| unsafe { libc::atoll(x) } });
s.as_buf(|x, _len| unsafe { libc::atoll(x) })
}
pub fn main() {