about summary refs log tree commit diff
path: root/src/libstd/sys/windows
diff options
context:
space:
mode:
authorAlex Crichton <alex@alexcrichton.com>2015-01-21 11:53:49 -0800
committerAlex Crichton <alex@alexcrichton.com>2015-01-21 11:53:49 -0800
commit886c6f3534e6f03916eeff2ea8b235e85dd04b42 (patch)
tree616ec48db83b768a4be84225bed9b0c0f730072d /src/libstd/sys/windows
parent036d8c41897099b5822eafa40e3f1fd2cdc4a92a (diff)
parent537889aa78c984ee6484d16fec4a67f35778aec6 (diff)
downloadrust-886c6f3534e6f03916eeff2ea8b235e85dd04b42.tar.gz
rust-886c6f3534e6f03916eeff2ea8b235e85dd04b42.zip
rollup merge of #21258: aturon/stab-3-index
Conflicts:
	src/libcore/ops.rs
	src/librustc_typeck/astconv.rs
	src/libstd/io/mem.rs
	src/libsyntax/parse/lexer/mod.rs
Diffstat (limited to 'src/libstd/sys/windows')
-rw-r--r--src/libstd/sys/windows/fs.rs2
-rw-r--r--src/libstd/sys/windows/os.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/libstd/sys/windows/fs.rs b/src/libstd/sys/windows/fs.rs
index a7330f7c67c..cb8ef7eb66b 100644
--- a/src/libstd/sys/windows/fs.rs
+++ b/src/libstd/sys/windows/fs.rs
@@ -376,7 +376,7 @@ pub fn readlink(p: &Path) -> IoResult<Path> {
     });
     let ret = match ret {
         Some(ref s) if s.starts_with(r"\\?\") => { // "
-            Ok(Path::new(s.slice_from(4)))
+            Ok(Path::new(&s[4..]))
         }
         Some(s) => Ok(Path::new(s)),
         None => Err(super::last_error()),
diff --git a/src/libstd/sys/windows/os.rs b/src/libstd/sys/windows/os.rs
index e9490dc95c9..36dc9b2afe4 100644
--- a/src/libstd/sys/windows/os.rs
+++ b/src/libstd/sys/windows/os.rs
@@ -146,7 +146,7 @@ pub fn fill_utf16_buf_and_decode<F>(mut f: F) -> Option<String> where
                 done = true;
             }
             if k != 0 && done {
-                let sub = buf.slice(0, k as uint);
+                let sub = &buf[.. (k as uint)];
                 // We want to explicitly catch the case when the
                 // closure returned invalid UTF-16, rather than
                 // set `res` to None and continue.