From 9d110685e706b1fbc7602bf2b995491b1564673c Mon Sep 17 00:00:00 2001 From: Michael Woerister Date: Fri, 26 Aug 2016 16:53:19 -0400 Subject: incr.comp.: Make compiletest generate shorter cache directory names. --- src/tools/compiletest/src/runtest.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/tools') diff --git a/src/tools/compiletest/src/runtest.rs b/src/tools/compiletest/src/runtest.rs index 60a0d8f0b86..aa4510746fd 100644 --- a/src/tools/compiletest/src/runtest.rs +++ b/src/tools/compiletest/src/runtest.rs @@ -2041,7 +2041,7 @@ actual:\n\ /// Directory where incremental work products are stored. fn incremental_dir(&self) -> PathBuf { - self.output_base_name().with_extension("incremental") + self.output_base_name().with_extension("inc") } fn run_rmake_test(&self) { -- cgit 1.4.1-3-g733a5 From 50b008ae3b9d15765d829ba336856f7057c9bb0c Mon Sep 17 00:00:00 2001 From: Michael Woerister Date: Mon, 29 Aug 2016 13:38:09 -0400 Subject: compiletest: Canonicalize paths when remove incr.comp. dir, enabling longer paths --- src/tools/compiletest/src/runtest.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/tools') diff --git a/src/tools/compiletest/src/runtest.rs b/src/tools/compiletest/src/runtest.rs index aa4510746fd..228d6ada01d 100644 --- a/src/tools/compiletest/src/runtest.rs +++ b/src/tools/compiletest/src/runtest.rs @@ -1976,7 +1976,10 @@ actual:\n\ // runs. let incremental_dir = self.incremental_dir(); if incremental_dir.exists() { - fs::remove_dir_all(&incremental_dir).unwrap(); + // Canonicalizing the path will convert it to the //?/ format + // on Windows, which enables paths longer than 260 character + let canonicalized = incremental_dir.canonicalize().unwrap(); + fs::remove_dir_all(canonicalized).unwrap(); } fs::create_dir_all(&incremental_dir).unwrap(); -- cgit 1.4.1-3-g733a5