Rename str::unsafe to str::raw

This commit is contained in:
Brian Anderson 2012-09-12 19:55:05 -07:00
parent 59c3c6c147
commit 308ca06012
10 changed files with 50 additions and 50 deletions

View file

@ -59,7 +59,7 @@ fn make_repeat_fasta(wr: io::Writer, id: ~str, desc: ~str, s: ~str, n: int) unsa
let mut op: ~str = ~"";
let sl: uint = str::len(s);
for uint::range(0u, n as uint) |i| {
str::unsafe::push_byte(op, s[i % sl]);
str::raw::push_byte(op, s[i % sl]);
if str::len(op) >= LINE_LENGTH() {
wr.write_line(op);
op = ~"";

View file

@ -49,7 +49,7 @@ fn sort_and_fmt(mm: HashMap<~[u8], uint>, total: uint) -> ~str {
pairs_sorted.each(fn&(kv: (~[u8], float)) -> bool unsafe {
let (k,v) = kv;
buffer += (fmt!("%s %0.3f\n", str::to_upper(str::unsafe::from_bytes(k)), v));
buffer += (fmt!("%s %0.3f\n", str::to_upper(str::raw::from_bytes(k)), v));
return true;
});

View file

@ -48,7 +48,7 @@ fn sort_and_fmt(mm: HashMap<~[u8], uint>, total: uint) -> ~str {
pairs_sorted.each(fn&(kv: (~[u8], float)) -> bool unsafe {
let (k,v) = kv;
buffer += (fmt!("%s %0.3f\n", str::to_upper(str::unsafe::from_bytes(k)), v));
buffer += (fmt!("%s %0.3f\n", str::to_upper(str::raw::from_bytes(k)), v));
return true;
});