diff options
| author | Patrick Walton <pcwalton@mimiga.net> | 2013-11-22 15:45:12 -0800 |
|---|---|---|
| committer | Patrick Walton <pcwalton@mimiga.net> | 2013-11-29 10:55:13 -0800 |
| commit | c54427ddfbbab41a39d14f2b1dc4f080cbc2d41b (patch) | |
| tree | 7b4e7af9dfe4342f3fd474f1010d4839281edd87 /src/compiletest | |
| parent | 6c672ee094a1a8e72c100100f43c73a9741f08a7 (diff) | |
| download | rust-c54427ddfbbab41a39d14f2b1dc4f080cbc2d41b.tar.gz rust-c54427ddfbbab41a39d14f2b1dc4f080cbc2d41b.zip | |
libstd: Change `Path::new` to `Path::init`.
Diffstat (limited to 'src/compiletest')
| -rw-r--r-- | src/compiletest/compiletest.rs | 12 | ||||
| -rw-r--r-- | src/compiletest/header.rs | 4 | ||||
| -rw-r--r-- | src/compiletest/runtest.rs | 4 |
3 files changed, 10 insertions, 10 deletions
diff --git a/src/compiletest/compiletest.rs b/src/compiletest/compiletest.rs index 0f39b29c60a..1f06b9700c2 100644 --- a/src/compiletest/compiletest.rs +++ b/src/compiletest/compiletest.rs @@ -103,15 +103,15 @@ pub fn parse_config(args: ~[~str]) -> config { } fn opt_path(m: &getopts::Matches, nm: &str) -> Path { - Path::new(m.opt_str(nm).unwrap()) + Path::init(m.opt_str(nm).unwrap()) } config { compile_lib_path: matches.opt_str("compile-lib-path").unwrap(), run_lib_path: matches.opt_str("run-lib-path").unwrap(), 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)), + clang_path: matches.opt_str("clang-path").map(|s| Path::init(s)), + llvm_bin_path: matches.opt_str("llvm-bin-path").map(|s| Path::init(s)), src_base: opt_path(matches, "src-base"), build_base: opt_path(matches, "build-base"), aux_base: opt_path(matches, "aux-base"), @@ -124,10 +124,10 @@ pub fn parse_config(args: ~[~str]) -> config { } else { None }, - logfile: matches.opt_str("logfile").map(|s| Path::new(s)), - save_metrics: matches.opt_str("save-metrics").map(|s| Path::new(s)), + logfile: matches.opt_str("logfile").map(|s| Path::init(s)), + save_metrics: matches.opt_str("save-metrics").map(|s| Path::init(s)), ratchet_metrics: - matches.opt_str("ratchet-metrics").map(|s| Path::new(s)), + matches.opt_str("ratchet-metrics").map(|s| Path::init(s)), ratchet_noise_percent: matches.opt_str("ratchet-noise-percent").and_then(|s| from_str::<f64>(s)), runtool: matches.opt_str("runtool"), diff --git a/src/compiletest/header.rs b/src/compiletest/header.rs index 1966701dbde..09e20415ebf 100644 --- a/src/compiletest/header.rs +++ b/src/compiletest/header.rs @@ -160,10 +160,10 @@ fn parse_exec_env(line: &str) -> Option<(~str, ~str)> { fn parse_pp_exact(line: &str, testfile: &Path) -> Option<Path> { match parse_name_value_directive(line, ~"pp-exact") { - Some(s) => Some(Path::new(s)), + Some(s) => Some(Path::init(s)), None => { if parse_name_directive(line, "pp-exact") { - testfile.filename().map(|s| Path::new(s)) + testfile.filename().map(|s| Path::init(s)) } else { None } diff --git a/src/compiletest/runtest.rs b/src/compiletest/runtest.rs index 1bf6542903a..5f113d2950a 100644 --- a/src/compiletest/runtest.rs +++ b/src/compiletest/runtest.rs @@ -45,7 +45,7 @@ pub fn run_metrics(config: config, testfile: ~str, mm: &mut MetricMap) { // We're going to be dumping a lot of info. Start on a new line. print!("\n\n"); } - let testfile = Path::new(testfile); + let testfile = Path::init(testfile); debug!("running {}", testfile.display()); let props = load_props(&testfile); debug!("loaded props"); @@ -852,7 +852,7 @@ fn aux_output_dir_name(config: &config, testfile: &Path) -> Path { } fn output_testname(testfile: &Path) -> Path { - Path::new(testfile.filestem().unwrap()) + Path::init(testfile.filestem().unwrap()) } fn output_base_name(config: &config, testfile: &Path) -> Path { |
