r185702 - We don't need to check for windows' error codes in here.

Rafael Espindola rafael.espindola at gmail.com
Fri Jul 5 07:15:24 PDT 2013


Author: rafael
Date: Fri Jul  5 09:15:24 2013
New Revision: 185702

URL: http://llvm.org/viewvc/llvm-project?rev=185702&view=rev
Log:
We don't need to check for windows' error codes in here.

The operator== calls equivalent which calls default_error_condition which
handles windows to posix conversion.

Modified:
    cfe/trunk/lib/Frontend/CompilerInstance.cpp

Modified: cfe/trunk/lib/Frontend/CompilerInstance.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Frontend/CompilerInstance.cpp?rev=185702&r1=185701&r2=185702&view=diff
==============================================================================
--- cfe/trunk/lib/Frontend/CompilerInstance.cpp (original)
+++ cfe/trunk/lib/Frontend/CompilerInstance.cpp Fri Jul  5 09:15:24 2013
@@ -548,9 +548,7 @@ CompilerInstance::createOutputFile(Strin
         TempPath.str(), fd, TempPath, /*makeAbsolute=*/ false, 0664);
 
     if (CreateMissingDirectories &&
-        (EC == llvm::errc::no_such_file_or_directory ||
-         EC == llvm::windows_error::file_not_found ||
-         EC == llvm::windows_error::path_not_found)) {
+        EC == llvm::errc::no_such_file_or_directory) {
       StringRef Parent = llvm::sys::path::parent_path(OutputPath);
       EC = llvm::sys::fs::create_directories(Parent);
       if (!EC) {





More information about the cfe-commits mailing list