[llvm] r253373 - Fix -Wunused-function in a non-Win32 build

David Blaikie via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 17 12:38:54 PST 2015


Author: dblaikie
Date: Tue Nov 17 14:38:54 2015
New Revision: 253373

URL: http://llvm.org/viewvc/llvm-project?rev=253373&view=rev
Log:
Fix -Wunused-function in a non-Win32 build

Modified:
    llvm/trunk/unittests/Support/Path.cpp

Modified: llvm/trunk/unittests/Support/Path.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/unittests/Support/Path.cpp?rev=253373&r1=253372&r2=253373&view=diff
==============================================================================
--- llvm/trunk/unittests/Support/Path.cpp (original)
+++ llvm/trunk/unittests/Support/Path.cpp Tue Nov 17 14:38:54 2015
@@ -360,6 +360,7 @@ TEST(Support, TempDirectory) {
   EXPECT_TRUE(!TempDir.empty());
 }
 
+#ifdef LLVM_ON_WIN32
 static std::string path2regex(std::string Path) {
   size_t Pos = 0;
   while ((Pos = Path.find('\\', Pos)) != std::string::npos) {
@@ -381,7 +382,6 @@ static std::string path2regex(std::strin
       },                                                                       \
       ::testing::ExitedWithCode(0), path2regex(expected))
 
-#ifdef LLVM_ON_WIN32
 TEST(SupportDeathTest, TempDirectoryOnWindows) {
   // In this test we want to check how system_temp_directory responds to
   // different values of specific env vars. To prevent corrupting env vars of




More information about the llvm-commits mailing list