Skip to content

Commit 00d30f3

Browse files
committed
---
yaml --- r: 13782 b: refs/heads/try c: 57717fa h: refs/heads/master v: v3
1 parent 34ee767 commit 00d30f3

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22
refs/heads/master: 61b1875c16de39c166b0f4d54bba19f9c6777d1a
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 4a81779abd786ff22d71434c6d9a5917ea4cdfff
5-
refs/heads/try: 87320a9f2768e5e011a6c8edaceb3d3b7ddc2747
5+
refs/heads/try: 57717fa4d8f27a05e16cbc4de0d55728aaf32e73
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105

branches/try/src/libstd/io.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ impl reader_util for reader {
109109
if ch == -1 || ch == 10 { break; }
110110
buf += [ch as u8];
111111
}
112-
str::unsafe_from_bytes(buf)
112+
str::from_bytes(buf)
113113
}
114114

115115
fn read_c_str() -> str {
@@ -118,7 +118,7 @@ impl reader_util for reader {
118118
let ch = self.read_byte();
119119
if ch < 1 { break; } else { buf += [ch as u8]; }
120120
}
121-
str::unsafe_from_bytes(buf)
121+
str::from_bytes(buf)
122122
}
123123

124124
// FIXME deal with eof?
@@ -479,7 +479,7 @@ fn seek_in_buf(offset: int, pos: uint, len: uint, whence: seek_style) ->
479479

480480
fn read_whole_file_str(file: str) -> result::t<str, str> {
481481
result::chain(read_whole_file(file), { |bytes|
482-
result::ok(str::unsafe_from_bytes(bytes))
482+
result::ok(str::from_bytes(bytes))
483483
})
484484
}
485485

0 commit comments

Comments
 (0)