about summary refs log tree commit diff
path: root/src/compiletest
diff options
context:
space:
mode:
authorKevin Ballard <kevin@sb.org>2014-02-07 19:45:48 -0800
committerKevin Ballard <kevin@sb.org>2014-02-07 22:31:52 -0800
commit1d17c2129ec696d81e6c6caee8b1740dd9509090 (patch)
tree82db5e94279972bd3d12d4fa5fc765b7c0bc891e /src/compiletest
parent086c0dd33febb752b036fba62dcfb8aa22a51642 (diff)
downloadrust-1d17c2129ec696d81e6c6caee8b1740dd9509090.tar.gz
rust-1d17c2129ec696d81e6c6caee8b1740dd9509090.zip
Rewrite path::Display to reduce unnecessary allocation
Diffstat (limited to 'src/compiletest')
-rw-r--r--src/compiletest/runtest.rs4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/compiletest/runtest.rs b/src/compiletest/runtest.rs
index adb81803ab0..8edd923390a 100644
--- a/src/compiletest/runtest.rs
+++ b/src/compiletest/runtest.rs
@@ -442,9 +442,7 @@ fn check_error_patterns(props: &TestProps,
                         testfile: &Path,
                         ProcRes: &ProcRes) {
     if props.error_patterns.is_empty() {
-        testfile.display().with_str(|s| {
-            fatal(~"no error pattern specified in " + s);
-        })
+        fatal(~"no error pattern specified in " + testfile.display().as_maybe_owned().as_slice());
     }
 
     if ProcRes.status.success() {