From 2a826e40fa51fcae4adb564d789cafe95776e0bb Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Fri, 13 Jun 2014 17:20:48 +0000 Subject: Finishing touch for the std::error_code transition. While std::error_code itself seems to work OK in all platforms, there are few annoying differences with regards to the std::errc enumeration. This patch adds a simple llvm enumeration, which will hopefully avoid build breakages in other platforms and surprises as we get more uses of std::error_code. llvm-svn: 210920 --- llvm/lib/Support/FileOutputBuffer.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'llvm/lib/Support/FileOutputBuffer.cpp') diff --git a/llvm/lib/Support/FileOutputBuffer.cpp b/llvm/lib/Support/FileOutputBuffer.cpp index 8a7b0d73f94..2e740ca0451 100644 --- a/llvm/lib/Support/FileOutputBuffer.cpp +++ b/llvm/lib/Support/FileOutputBuffer.cpp @@ -11,6 +11,7 @@ // //===----------------------------------------------------------------------===// +#include "llvm/Support/Errc.h" #include "llvm/Support/FileOutputBuffer.h" #include "llvm/ADT/SmallVector.h" #include "llvm/Support/raw_ostream.h" @@ -51,7 +52,7 @@ FileOutputBuffer::create(StringRef FilePath, size_t Size, if (EC) return EC; else - return std::make_error_code(std::errc::operation_not_permitted); + return make_error_code(errc::operation_not_permitted); } // Delete target file. -- cgit v1.2.3