about summary refs log tree commit diff
path: root/src/compiletest/compiletest.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiletest/compiletest.rs')
-rw-r--r--src/compiletest/compiletest.rs48
1 files changed, 24 insertions, 24 deletions
diff --git a/src/compiletest/compiletest.rs b/src/compiletest/compiletest.rs
index 8ea718c7f27..701f8899fa4 100644
--- a/src/compiletest/compiletest.rs
+++ b/src/compiletest/compiletest.rs
@@ -50,7 +50,7 @@ fn start(argc: int, argv: **u8) -> int {
 pub fn main() {
     let args = os::args();
     let config = parse_config(args.move_iter()
-                                  .map(|x| x.to_strbuf())
+                                  .map(|x| x.to_string())
                                   .collect());
     log_config(&config);
     run_tests(&config);
@@ -134,15 +134,15 @@ pub fn parse_config(args: Vec<String> ) -> Config {
     Config {
         compile_lib_path: matches.opt_str("compile-lib-path")
                                  .unwrap()
-                                 .to_strbuf(),
-        run_lib_path: matches.opt_str("run-lib-path").unwrap().to_strbuf(),
+                                 .to_string(),
+        run_lib_path: matches.opt_str("run-lib-path").unwrap().to_string(),
         rustc_path: opt_path(matches, "rustc-path"),
         clang_path: matches.opt_str("clang-path").map(|s| Path::new(s)),
         llvm_bin_path: matches.opt_str("llvm-bin-path").map(|s| Path::new(s)),
         src_base: opt_path(matches, "src-base"),
         build_base: opt_path(matches, "build-base"),
         aux_base: opt_path(matches, "aux-base"),
-        stage_id: matches.opt_str("stage-id").unwrap().to_strbuf(),
+        stage_id: matches.opt_str("stage-id").unwrap().to_string(),
         mode: FromStr::from_str(matches.opt_str("mode")
                                        .unwrap()
                                        .as_slice()).expect("invalid mode"),
@@ -156,32 +156,32 @@ pub fn parse_config(args: Vec<String> ) -> Config {
         ratchet_noise_percent:
             matches.opt_str("ratchet-noise-percent")
                    .and_then(|s| from_str::<f64>(s.as_slice())),
-        runtool: matches.opt_str("runtool").map(|x| x.to_strbuf()),
+        runtool: matches.opt_str("runtool").map(|x| x.to_string()),
         host_rustcflags: matches.opt_str("host-rustcflags")
-                                .map(|x| x.to_strbuf()),
+                                .map(|x| x.to_string()),
         target_rustcflags: matches.opt_str("target-rustcflags")
-                                  .map(|x| x.to_strbuf()),
+                                  .map(|x| x.to_string()),
         jit: matches.opt_present("jit"),
-        target: opt_str2(matches.opt_str("target").map(|x| x.to_strbuf())),
-        host: opt_str2(matches.opt_str("host").map(|x| x.to_strbuf())),
+        target: opt_str2(matches.opt_str("target").map(|x| x.to_string())),
+        host: opt_str2(matches.opt_str("host").map(|x| x.to_string())),
         android_cross_path: opt_path(matches, "android-cross-path"),
         adb_path: opt_str2(matches.opt_str("adb-path")
-                                  .map(|x| x.to_strbuf())),
+                                  .map(|x| x.to_string())),
         adb_test_dir: opt_str2(matches.opt_str("adb-test-dir")
-                                      .map(|x| x.to_strbuf())),
+                                      .map(|x| x.to_string())),
         adb_device_status:
             "arm-linux-androideabi" ==
                 opt_str2(matches.opt_str("target")
-                                .map(|x| x.to_strbuf())).as_slice() &&
+                                .map(|x| x.to_string())).as_slice() &&
             "(none)" !=
                 opt_str2(matches.opt_str("adb-test-dir")
-                                .map(|x| x.to_strbuf())).as_slice() &&
+                                .map(|x| x.to_string())).as_slice() &&
             !opt_str2(matches.opt_str("adb-test-dir")
-                             .map(|x| x.to_strbuf())).is_empty(),
+                             .map(|x| x.to_string())).is_empty(),
         lldb_python_dir: matches.opt_str("lldb-python-dir")
-                                .map(|x| x.to_strbuf()),
+                                .map(|x| x.to_string()),
         test_shard: test::opt_shard(matches.opt_str("test-shard")
-                                           .map(|x| x.to_strbuf())),
+                                           .map(|x| x.to_string())),
         verbose: matches.opt_present("verbose")
     }
 }
@@ -201,7 +201,7 @@ pub fn log_config(config: &Config) {
                            opt_str(&config.filter
                                           .as_ref()
                                           .map(|re| {
-                                              re.to_str().into_strbuf()
+                                              re.to_str().into_string()
                                           }))));
     logv(c, format_strbuf!("runtool: {}", opt_str(&config.runtool)));
     logv(c, format_strbuf!("host-rustcflags: {}",
@@ -218,7 +218,7 @@ pub fn log_config(config: &Config) {
     logv(c, format_strbuf!("adb_device_status: {}",
                            config.adb_device_status));
     match config.test_shard {
-        None => logv(c, "test_shard: (all)".to_strbuf()),
+        None => logv(c, "test_shard: (all)".to_string()),
         Some((a,b)) => logv(c, format_strbuf!("test_shard: {}.{}", a, b))
     }
     logv(c, format_strbuf!("verbose: {}", config.verbose));
@@ -234,7 +234,7 @@ pub fn opt_str<'a>(maybestr: &'a Option<String>) -> &'a str {
 
 pub fn opt_str2(maybestr: Option<String>) -> String {
     match maybestr {
-        None => "(none)".to_strbuf(),
+        None => "(none)".to_string(),
         Some(s) => s,
     }
 }
@@ -314,10 +314,10 @@ pub fn is_test(config: &Config, testfile: &Path) -> bool {
     // Pretty-printer does not work with .rc files yet
     let valid_extensions =
         match config.mode {
-          Pretty => vec!(".rs".to_owned()),
-          _ => vec!(".rc".to_owned(), ".rs".to_owned())
+          Pretty => vec!(".rs".to_string()),
+          _ => vec!(".rc".to_string(), ".rs".to_string())
         };
-    let invalid_prefixes = vec!(".".to_owned(), "#".to_owned(), "~".to_owned());
+    let invalid_prefixes = vec!(".".to_string(), "#".to_string(), "~".to_string());
     let name = testfile.filename_str().unwrap();
 
     let mut valid = false;
@@ -367,7 +367,7 @@ pub fn make_test_name(config: &Config, testfile: &Path) -> test::TestName {
 pub fn make_test_closure(config: &Config, testfile: &Path) -> test::TestFn {
     let config = (*config).clone();
     // FIXME (#9639): This needs to handle non-utf8 paths
-    let testfile = testfile.as_str().unwrap().to_strbuf();
+    let testfile = testfile.as_str().unwrap().to_string();
     test::DynTestFn(proc() {
         runtest::run(config, testfile)
     })
@@ -376,7 +376,7 @@ pub fn make_test_closure(config: &Config, testfile: &Path) -> test::TestFn {
 pub fn make_metrics_test_closure(config: &Config, testfile: &Path) -> test::TestFn {
     let config = (*config).clone();
     // FIXME (#9639): This needs to handle non-utf8 paths
-    let testfile = testfile.as_str().unwrap().to_strbuf();
+    let testfile = testfile.as_str().unwrap().to_string();
     test::DynMetricFn(proc(mm) {
         runtest::run_metrics(config, testfile, mm)
     })