about summary refs log tree commit diff
path: root/src/libstd
diff options
context:
space:
mode:
authorPatrick Walton <pcwalton@mimiga.net>2013-06-14 19:40:11 -0700
committerCorey Richardson <corey@octayn.net>2013-06-28 10:44:16 -0400
commit89eb9951958dc2cd652645cea5badf4bb9edc6f9 (patch)
treedc234db5e74b23cec4080026d8c316d88849e638 /src/libstd
parent03ab6351ccc7b0e2b6102f88eddc0bbe84f2abc0 (diff)
downloadrust-89eb9951958dc2cd652645cea5badf4bb9edc6f9.tar.gz
rust-89eb9951958dc2cd652645cea5badf4bb9edc6f9.zip
librustc: Fix merge fallout.
Diffstat (limited to 'src/libstd')
-rw-r--r--src/libstd/path.rs2
-rw-r--r--src/libstd/str.rs6
2 files changed, 5 insertions, 3 deletions
diff --git a/src/libstd/path.rs b/src/libstd/path.rs
index b3b696a9a60..9b4a3270f28 100644
--- a/src/libstd/path.rs
+++ b/src/libstd/path.rs
@@ -21,7 +21,7 @@ use cmp::Eq;
 use iterator::IteratorUtil;
 use libc;
 use option::{None, Option, Some};
-use str::{Str, StrSlice, StrVector};
+use str::{OwnedStr, Str, StrSlice, StrVector};
 use str;
 use to_str::ToStr;
 use ascii::{AsciiCast, AsciiStr};
diff --git a/src/libstd/str.rs b/src/libstd/str.rs
index 9c94f36fba3..3c512d9bfd2 100644
--- a/src/libstd/str.rs
+++ b/src/libstd/str.rs
@@ -1427,7 +1427,8 @@ impl<'self> StrSlice<'self> for &'self str {
     fn slice_chars(&self, begin: uint, end: uint) -> &'self str {
         assert!(begin <= end);
         // not sure how to use the iterators for this nicely.
-        let mut (position, count) = (0, 0);
+        let mut position = 0;
+        let mut count = 0;
         let l = self.len();
         while count < begin && position < l {
             position = self.char_range_at(position).next;
@@ -1575,7 +1576,8 @@ impl<'self> StrSlice<'self> for &'self str {
      * The original string with all occurances of `from` replaced with `to`
      */
     pub fn replace(&self, from: &str, to: &str) -> ~str {
-        let mut (result, last_end) = (~"", 0);
+        let mut result = ~"";
+        let mut last_end = 0;
         for self.matches_index_iter(from).advance |(start, end)| {
             result.push_str(unsafe{raw::slice_bytes(*self, last_end, start)});
             result.push_str(to);