about summary refs log tree commit diff
path: root/src/libstd/rt
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2014-04-06 23:36:38 -0700
committerbors <bors@rust-lang.org>2014-04-06 23:36:38 -0700
commite4779b505092cf1a394c187eb77ab2738be6f280 (patch)
tree9a0199b15bd0b4e7b352b58e3c123e89d70af5d2 /src/libstd/rt
parent31e8f2448c8cdd913566d5cb9a5cb9f0c014dcbc (diff)
parentfcf9b30f426fcf8fd0b6e0a044825fdfa4a1bfdb (diff)
downloadrust-e4779b505092cf1a394c187eb77ab2738be6f280.tar.gz
rust-e4779b505092cf1a394c187eb77ab2738be6f280.zip
auto merge of #13165 : sfackler/rust/io-vec, r=alexcrichton
`Reader`, `Writer`, `MemReader`, `MemWriter`, and `MultiWriter` now work with `Vec<u8>` instead of `~[u8]`. This does introduce some extra copies since `from_utf8_owned` isn't usable anymore, but I think that can't be helped until `~str`'s representation changes.
Diffstat (limited to 'src/libstd/rt')
-rw-r--r--src/libstd/rt/backtrace.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstd/rt/backtrace.rs b/src/libstd/rt/backtrace.rs
index 96f95622b92..bf8c15c20ab 100644
--- a/src/libstd/rt/backtrace.rs
+++ b/src/libstd/rt/backtrace.rs
@@ -756,7 +756,7 @@ mod test {
     macro_rules! t( ($a:expr, $b:expr) => ({
         let mut m = MemWriter::new();
         super::demangle(&mut m, $a).unwrap();
-        assert_eq!(str::from_utf8_owned(m.unwrap()).unwrap(), $b.to_owned());
+        assert_eq!(str::from_utf8(m.unwrap().as_slice()).unwrap().to_owned(), $b.to_owned());
     }) )
 
     #[test]