about summary refs log tree commit diff
path: root/src/libstd/num
diff options
context:
space:
mode:
authorFlorian Hahn <flo@fhahn.com>2013-09-05 14:17:24 +0200
committerFlorian Hahn <flo@fhahn.com>2013-09-05 14:17:24 +0200
commitde39874801761197bf10bf8d04bde1aa2bd82e15 (patch)
tree6afb87492fa6c69778066aa748b26ecae1fb5262 /src/libstd/num
parent422dcbd56d1a1888f1491d8fb14bb87a54fadbc7 (diff)
downloadrust-de39874801761197bf10bf8d04bde1aa2bd82e15.tar.gz
rust-de39874801761197bf10bf8d04bde1aa2bd82e15.zip
Rename str::from_bytes to str::from_utf8, closes #8985
Diffstat (limited to 'src/libstd/num')
-rw-r--r--src/libstd/num/int_macros.rs2
-rw-r--r--src/libstd/num/strconv.rs2
-rw-r--r--src/libstd/num/uint_macros.rs2
3 files changed, 3 insertions, 3 deletions
diff --git a/src/libstd/num/int_macros.rs b/src/libstd/num/int_macros.rs
index 0131feda830..377d0a78134 100644
--- a/src/libstd/num/int_macros.rs
+++ b/src/libstd/num/int_macros.rs
@@ -541,7 +541,7 @@ impl ToStrRadix for $T {
         }
         // We know we generated valid utf-8, so we don't need to go through that
         // check.
-        unsafe { str::raw::from_bytes_owned(buf) }
+        unsafe { str::raw::from_utf8_owned(buf) }
     }
 }
 
diff --git a/src/libstd/num/strconv.rs b/src/libstd/num/strconv.rs
index 6fba8a6dd13..edfabd339af 100644
--- a/src/libstd/num/strconv.rs
+++ b/src/libstd/num/strconv.rs
@@ -417,7 +417,7 @@ pub fn float_to_str_common<T:NumCast+Zero+One+Eq+Ord+NumStrConv+Float+Round+
         sign: SignFormat, digits: SignificantDigits) -> (~str, bool) {
     let (bytes, special) = float_to_str_bytes_common(num, radix,
                                negative_zero, sign, digits);
-    (str::from_bytes(bytes), special)
+    (str::from_utf8(bytes), special)
 }
 
 // Some constants for from_str_bytes_common's input validation,
diff --git a/src/libstd/num/uint_macros.rs b/src/libstd/num/uint_macros.rs
index 1426142d465..af991045b45 100644
--- a/src/libstd/num/uint_macros.rs
+++ b/src/libstd/num/uint_macros.rs
@@ -396,7 +396,7 @@ impl ToStrRadix for $T {
         }
         // We know we generated valid utf-8, so we don't need to go through that
         // check.
-        unsafe { str::raw::from_bytes_owned(buf) }
+        unsafe { str::raw::from_utf8_owned(buf) }
     }
 }