aboutsummaryrefslogtreecommitdiff
path: root/llvm/unittests/Support/Path.cpp
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2014-06-11 03:58:34 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2014-06-11 03:58:34 +0000
commita813d608a943579804eb9f12c8ede2955bb3a777 (patch)
treed77b568b616cc527538721269ccdf1aa6283798d /llvm/unittests/Support/Path.cpp
parent6a9aae77d4bc6eb644c106fc79be6f59c53c5ba1 (diff)
downloadllvm-a813d608a943579804eb9f12c8ede2955bb3a777.zip
llvm-a813d608a943579804eb9f12c8ede2955bb3a777.tar.gz
llvm-a813d608a943579804eb9f12c8ede2955bb3a777.tar.bz2
Remove windows_error.
MSVC doesn't seem to provide any is_error_code_enum enumeration for the windows errors. Fortunately very few places in llvm have to handle raw windows errors, so we can just construct the corresponding error_code directly. llvm-svn: 210631
Diffstat (limited to 'llvm/unittests/Support/Path.cpp')
-rw-r--r--llvm/unittests/Support/Path.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/llvm/unittests/Support/Path.cpp b/llvm/unittests/Support/Path.cpp
index b79d055..660ea36 100644
--- a/llvm/unittests/Support/Path.cpp
+++ b/llvm/unittests/Support/Path.cpp
@@ -14,6 +14,10 @@
#include "llvm/Support/raw_ostream.h"
#include "gtest/gtest.h"
+#ifdef LLVM_ON_WIN32
+#include <winerror.h>
+#endif
+
using namespace llvm;
using namespace llvm::sys;
@@ -393,7 +397,7 @@ TEST_F(FileSystemTest, TempFiles) {
"abcdefghijklmnopqrstuvwxyz3abcdefghijklmnopqrstuvwxyz2"
"abcdefghijklmnopqrstuvwxyz1abcdefghijklmnopqrstuvwxyz0";
EXPECT_EQ(fs::createUniqueFile(Twine(Path270), FileDescriptor, TempPath),
- windows_error::path_not_found);
+ error_code(ERROR_PATH_NOT_FOUND, system_category()));
#endif
}