From: Peter Collingbourne Date: Mon, 20 Mar 2017 18:19:41 +0000 (+0000) Subject: Try using llvm::errc, should hopefully fix version mismatch problem on clang-s390x... X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3cd1f18f47bb1d0235ff82a2c9636673cbe063d7;p=llvm Try using llvm::errc, should hopefully fix version mismatch problem on clang-s390x-linux bot. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@298285 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/LTO/Caching.cpp b/lib/LTO/Caching.cpp index 00373ddd1c4..e32e46c4c3c 100644 --- a/lib/LTO/Caching.cpp +++ b/lib/LTO/Caching.cpp @@ -13,6 +13,7 @@ #include "llvm/LTO/Caching.h" #include "llvm/ADT/StringExtras.h" +#include "llvm/Support/Errc.h" #include "llvm/Support/FileSystem.h" #include "llvm/Support/MemoryBuffer.h" #include "llvm/Support/Path.h" @@ -39,10 +40,7 @@ Expected lto::localCache(StringRef CacheDirectoryPath, return AddStreamFn(); } - // FIXME: Workaround for libstdc++ version mismatch bug, see D31063 review - // thread. - if ((std::errc)MBOrErr.getError().value() != - std::errc::no_such_file_or_directory) + if (MBOrErr.getError() != errc::no_such_file_or_directory) report_fatal_error(Twine("Failed to open cache file ") + EntryPath + ": " + MBOrErr.getError().message() + "\n");