]> granicus.if.org Git - clang/commitdiff
optimize out a temporary sys::Path
authorChris Lattner <sabre@nondot.org>
Thu, 13 Jan 2011 01:35:58 +0000 (01:35 +0000)
committerChris Lattner <sabre@nondot.org>
Thu, 13 Jan 2011 01:35:58 +0000 (01:35 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@123359 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Driver/ToolChains.cpp

index 10062d7414d54c88ecc0fa3faace5ea3d16a869f..537372cb0b914ea7b952bb4f57518aeb39d361e8 100644 (file)
@@ -1324,10 +1324,9 @@ Linux::Linux(const HostInfo &Host, const llvm::Triple &Triple)
     Lib32 = "lib32";
 
   std::string Lib64 = "lib";
-  llvm::sys::Path Lib64Path("/lib64");
   bool Symlink;
-  if (!llvm::sys::fs::exists(Lib64Path.str(), Exists) && Exists &&
-      (llvm::sys::fs::is_symlink(Lib64Path.str(), Symlink) || !Symlink))
+  if (!llvm::sys::fs::exists("/lib64", Exists) && Exists &&
+      (llvm::sys::fs::is_symlink("/lib64", Symlink) || !Symlink))
     Lib64 = "lib64";
 
   std::string GccTriple = "";