about summary refs log tree commit diff
path: root/src/compiletest/header.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiletest/header.rs')
-rw-r--r--src/compiletest/header.rs3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/compiletest/header.rs b/src/compiletest/header.rs
index 2413a001ee8..d7af767688e 100644
--- a/src/compiletest/header.rs
+++ b/src/compiletest/header.rs
@@ -332,8 +332,7 @@ pub fn parse_name_value_directive(line: &str, directive: &str)
     let keycolon = format!("{}:", directive);
     match line.find_str(keycolon.as_slice()) {
         Some(colon) => {
-            let value = line.slice(colon + keycolon.len(),
-                                   line.len()).to_string();
+            let value = line[(colon + keycolon.len()) .. line.len()].to_string();
             debug!("{}: {}", directive, value);
             Some(value)
         }