diff options
author | Paul Robinson <paul_robinson@playstation.sony.com> | 2014-11-13 00:36:34 +0000 |
---|---|---|
committer | Paul Robinson <paul_robinson@playstation.sony.com> | 2014-11-13 00:36:34 +0000 |
commit | 1b6c73474ddca35581c3b31e40eb1e0b14b0c4a0 (patch) | |
tree | a35ebb5667bd6ed7594725efdb3f103de0791b89 /llvm/unittests/Support/Path.cpp | |
parent | c4f5b046ad981990b84c96801414a764d02214b9 (diff) | |
download | llvm-1b6c73474ddca35581c3b31e40eb1e0b14b0c4a0.zip llvm-1b6c73474ddca35581c3b31e40eb1e0b14b0c4a0.tar.gz llvm-1b6c73474ddca35581c3b31e40eb1e0b14b0c4a0.tar.bz2 |
Drop a few unneeded ctor calls (missed code review comment).
llvm-svn: 221845
Diffstat (limited to 'llvm/unittests/Support/Path.cpp')
-rw-r--r-- | llvm/unittests/Support/Path.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/unittests/Support/Path.cpp b/llvm/unittests/Support/Path.cpp index d7c216a..ffd8d0c 100644 --- a/llvm/unittests/Support/Path.cpp +++ b/llvm/unittests/Support/Path.cpp @@ -397,7 +397,7 @@ TEST_F(FileSystemTest, TempFiles) { "abcdefghijklmnopqrstuvwxyz5abcdefghijklmnopqrstuvwxyz4" "abcdefghijklmnopqrstuvwxyz3abcdefghijklmnopqrstuvwxyz2" "abcdefghijklmnopqrstuvwxyz1abcdefghijklmnopqrstuvwxyz0"; - EXPECT_EQ(fs::createUniqueFile(Twine(Path270), FileDescriptor, TempPath), + EXPECT_EQ(fs::createUniqueFile(Path270, FileDescriptor, TempPath), errc::invalid_argument); // Relative path < 247 chars, no problem. const char *Path216 = @@ -405,7 +405,7 @@ TEST_F(FileSystemTest, TempFiles) { "abcdefghijklmnopqrstuvwxyz5abcdefghijklmnopqrstuvwxyz4" "abcdefghijklmnopqrstuvwxyz3abcdefghijklmnopqrstuvwxyz2" "abcdefghijklmnopqrstuvwxyz1abcdefghijklmnopqrstuvwxyz0"; - ASSERT_NO_ERROR(fs::createTemporaryFile(Twine(Path216), "", TempPath)); + ASSERT_NO_ERROR(fs::createTemporaryFile(Path216, "", TempPath)); ASSERT_NO_ERROR(fs::remove(Twine(TempPath))); #endif } @@ -456,10 +456,10 @@ TEST_F(FileSystemTest, CreateDir) { // While we're here, prove that .. and . handling works in these long paths. const char *DotDotDirs = "\\..\\.\\b"; LongDir.append(DotDotDirs); - ASSERT_NO_ERROR(fs::create_directory(Twine("b"))); + ASSERT_NO_ERROR(fs::create_directory("b")); ASSERT_EQ(fs::create_directory(Twine(LongDir), false), errc::file_exists); // And clean up. - ASSERT_NO_ERROR(fs::remove(Twine("b"))); + ASSERT_NO_ERROR(fs::remove("b")); ASSERT_NO_ERROR(fs::remove( Twine(LongDir.substr(0, LongDir.size() - strlen(DotDotDirs))))); ASSERT_NE(::SetCurrentDirectoryA(PreviousDir), 0); |