llvm.org GIT mirror llvm / d5132f9
Remove system_error.h. This is a minimal change to remove the header. I will remove the occurrences of "using std::error_code" in a followup patch. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210803 91177308-0d34-0410-b5e6-96231b3b80d8 Rafael Espindola 5 years ago
58 changed file(s) with 73 addition(s) and 91 deletion(s). Raw diff Collapse all Expand all
1717 #ifndef LLVM_IR_GVMATERIALIZER_H
1818 #define LLVM_IR_GVMATERIALIZER_H
1919
20 #include "llvm/Support/system_error.h"
20 #include
2121
2222 namespace llvm {
23
23 using std::error_code;
2424 class Function;
2525 class GlobalValue;
2626 class Module;
2222 #include "llvm/IR/Metadata.h"
2323 #include "llvm/Support/CBindingWrapping.h"
2424 #include "llvm/Support/DataTypes.h"
25 #include "llvm/Support/system_error.h"
25 #include
2626
2727 namespace llvm {
2828
1313 #ifndef LLVM_OBJECT_ERROR_H
1414 #define LLVM_OBJECT_ERROR_H
1515
16 #include "llvm/Support/system_error.h"
16 #include
1717
1818 namespace llvm {
19 using std::error_code;
1920 namespace object {
2021
2122 const std::error_category &object_category();
1515 #ifndef LLVM_PROFILEDATA_INSTRPROF_H_
1616 #define LLVM_PROFILEDATA_INSTRPROF_H_
1717
18 #include "llvm/Support/system_error.h"
18 #include
1919
2020 namespace llvm {
21
21 using std::error_code;
2222 const std::error_category &instrprof_category();
2323
2424 enum class instrprof_error {
1717
1818 #include "llvm/ADT/PointerIntPair.h"
1919 #include "llvm/Support/AlignOf.h"
20 #include "llvm/Support/system_error.h"
2120 #include
21 #include
2222 #include
2323
2424 namespace llvm {
25 using std::error_code;
2526 template
2627 typename std::enable_if< std::is_constructible::value
2728 , typename std::remove_reference::type>::type &&
3232 #include "llvm/Support/DataTypes.h"
3333 #include "llvm/Support/ErrorHandling.h"
3434 #include "llvm/Support/TimeValue.h"
35 #include "llvm/Support/system_error.h"
3635 #include
3736 #include
3837 #include
3938 #include
39 #include
4040 #include
4141 #include
4242
4545 #endif
4646
4747 namespace llvm {
48 using std::error_code;
4849 namespace sys {
4950 namespace fs {
5051
1111 #include "llvm/ADT/Optional.h"
1212 #include "llvm/ADT/SmallString.h"
1313 #include "llvm/ADT/StringRef.h"
14 #include "llvm/Support/system_error.h"
14 #include
1515 #include // for std::pair
1616
1717 namespace llvm {
18
18 using std::error_code;
1919 /// \brief Class that manages the creation of a lock file to aid
2020 /// implicit coordination between different processes.
2121 ///
1414 #define LLVM_SUPPORT_MEMORY_H
1515
1616 #include "llvm/Support/DataTypes.h"
17 #include "llvm/Support/system_error.h"
1817 #include
18 #include
1919
2020 namespace llvm {
21 using std::error_code;
2122 namespace sys {
2223
2324 /// This class encapsulates the notion of a memory block which has an address
1818 #include "llvm/Support/CBindingWrapping.h"
1919 #include "llvm/Support/Compiler.h"
2020 #include "llvm/Support/DataTypes.h"
21 #include "llvm/Support/system_error.h"
2221 #include
22 #include
2323
2424 namespace llvm {
25 using std::error_code;
2526 /// MemoryBuffer - This interface provides simple read-only access to a block
2627 /// of memory, and provides simple methods for reading files and standard input
2728 /// into a memory buffer. In addition to basic access to the characters in the
3030 #include "llvm/Support/Allocator.h"
3131 #include "llvm/Support/DataTypes.h"
3232 #include "llvm/Support/TimeValue.h"
33 #include "llvm/Support/system_error.h"
33 #include
3434
3535 namespace llvm {
3636 class StringRef;
1515
1616 #include "llvm/ADT/ArrayRef.h"
1717 #include "llvm/Support/Path.h"
18 #include "llvm/Support/system_error.h"
18 #include
1919
2020 namespace llvm {
21 using std::error_code;
2122 namespace sys {
2223
2324 /// This is the OS-specific separator for PATH like environment variables:
2323 #include "llvm/Support/SourceMgr.h"
2424 #include "llvm/Support/YAMLParser.h"
2525 #include "llvm/Support/raw_ostream.h"
26 #include "llvm/Support/system_error.h"
26 #include
2727
2828 namespace llvm {
2929 namespace yaml {
+0
-23
include/llvm/Support/system_error.h less more
None //===---------------------------- system_error ------------------*- C++ -*-===//
1 //
2 // The LLVM Compiler Infrastructure
3 //
4 // This file is distributed under the University of Illinois Open Source
5 // License. See LICENSE.TXT for details.
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 // This is a temporary file to help with the transition to std::error_code.
10 //
11 //===----------------------------------------------------------------------===//
12
13 #ifndef LLVM_SUPPORT_SYSTEM_ERROR_H
14 #define LLVM_SUPPORT_SYSTEM_ERROR_H
15
16 #include
17
18 namespace llvm {
19 using std::error_code;
20 }
21
22 #endif
1616 #include "llvm/Support/MemoryBuffer.h"
1717 #include "llvm/Support/SourceMgr.h"
1818 #include "llvm/Support/raw_ostream.h"
19 #include "llvm/Support/system_error.h"
2019 #include
20 #include
2121 using namespace llvm;
2222
2323 Module *llvm::ParseAssembly(MemoryBuffer *F,
2121 #include "llvm/IR/OperandTraits.h"
2222 #include "llvm/IR/Type.h"
2323 #include "llvm/IR/ValueHandle.h"
24 #include "llvm/Support/system_error.h"
24 #include
2525 #include
2626
2727 namespace llvm {
2727 #include "llvm/Support/Mutex.h"
2828 #include "llvm/Support/SwapByteOrder.h"
2929 #include "llvm/Support/raw_ostream.h"
30 #include "llvm/Support/system_error.h"
3130 #include
31 #include
3232
3333 using namespace llvm;
3434 using namespace llvm::object;
1616 #include "llvm/IR/Attributes.h"
1717 #include "llvm/IR/CallSite.h"
1818 #include "llvm/IR/Constants.h"
19 #include "llvm/IR/DerivedTypes.h"
1920 #include "llvm/IR/DiagnosticInfo.h"
2021 #include "llvm/IR/DiagnosticPrinter.h"
21 #include "llvm/IR/DerivedTypes.h"
2222 #include "llvm/IR/GlobalAlias.h"
2323 #include "llvm/IR/GlobalVariable.h"
2424 #include "llvm/IR/IRBuilder.h"
3434 #include "llvm/Support/MemoryBuffer.h"
3535 #include "llvm/Support/Threading.h"
3636 #include "llvm/Support/raw_ostream.h"
37 #include "llvm/Support/system_error.h"
3837 #include
3938 #include
4039 #include
40 #include
4141
4242 using namespace llvm;
4343
1818 #include "llvm/Support/Format.h"
1919 #include "llvm/Support/MemoryObject.h"
2020 #include "llvm/Support/Path.h"
21 #include "llvm/Support/system_error.h"
2221 #include
22 #include
2323 using namespace llvm;
2424
2525 //===----------------------------------------------------------------------===//
1717 #include "llvm/Support/SourceMgr.h"
1818 #include "llvm/Support/Timer.h"
1919 #include "llvm/Support/raw_ostream.h"
20 #include "llvm/Support/system_error.h"
20 #include
2121
2222 using namespace llvm;
2323
4343 #include "llvm/Support/TargetSelect.h"
4444 #include "llvm/Support/ToolOutputFile.h"
4545 #include "llvm/Support/raw_ostream.h"
46 #include "llvm/Support/system_error.h"
4746 #include "llvm/Target/TargetLibraryInfo.h"
4847 #include "llvm/Target/TargetLowering.h"
4948 #include "llvm/Target/TargetOptions.h"
5150 #include "llvm/Transforms/IPO.h"
5251 #include "llvm/Transforms/IPO/PassManagerBuilder.h"
5352 #include "llvm/Transforms/ObjCARC.h"
53 #include
5454 using namespace llvm;
5555
5656 const char* LTOCodeGenerator::getVersionString() {
3636 #include "llvm/Support/SourceMgr.h"
3737 #include "llvm/Support/TargetRegistry.h"
3838 #include "llvm/Support/TargetSelect.h"
39 #include "llvm/Support/system_error.h"
4039 #include "llvm/Target/TargetLowering.h"
4140 #include "llvm/Target/TargetLoweringObjectFile.h"
4241 #include "llvm/Target/TargetRegisterInfo.h"
4342 #include "llvm/Transforms/Utils/GlobalStatus.h"
43 #include
4444 using namespace llvm;
4545
4646 LTOModule::LTOModule(llvm::Module *m, llvm::TargetMachine *t)
1515 #include "llvm/Support/FileSystem.h"
1616 #include "llvm/Support/MemoryBuffer.h"
1717 #include "llvm/Support/raw_ostream.h"
18 #include "llvm/Support/system_error.h"
18 #include
1919
2020 using namespace llvm;
2121 using namespace object;
3030 #include "llvm/Support/MemoryBuffer.h"
3131 #include "llvm/Support/Path.h"
3232 #include "llvm/Support/raw_ostream.h"
33 #include "llvm/Support/system_error.h"
3433 #include
3534 #include
3635 #include
36 #include
3737 using namespace llvm;
3838 using namespace cl;
3939
1717 #include "llvm/ADT/Statistic.h"
1818 #include "llvm/Support/FileSystem.h"
1919 #include "llvm/Support/Program.h"
20 #include "llvm/Support/system_error.h"
2120 #include
2221 #include
2322 #include
23 #include
2424 #if !defined(_MSC_VER) && !defined(__MINGW32__)
2525 #include
2626 #else
1313 #include "llvm/Support/FileOutputBuffer.h"
1414 #include "llvm/ADT/SmallVector.h"
1515 #include "llvm/Support/raw_ostream.h"
16 #include "llvm/Support/system_error.h"
16 #include
1717
1818 using llvm::sys::fs::mapped_file_region;
1919
1616 #include "llvm/Support/MemoryBuffer.h"
1717 #include "llvm/Support/Path.h"
1818 #include "llvm/Support/raw_ostream.h"
19 #include "llvm/Support/system_error.h"
2019 #include
2120 #include
2221 #include
22 #include
2323 using namespace llvm;
2424
2525 static bool isSignedChar(char C) {
1919 #include "llvm/Support/Path.h"
2020 #include "llvm/Support/Process.h"
2121 #include "llvm/Support/Program.h"
22 #include "llvm/Support/system_error.h"
2322 #include
2423 #include
2524 #include
2625 #include
2726 #include
2827 #include
28 #include
2929 #if !defined(_MSC_VER) && !defined(__MINGW32__)
3030 #include
3131 #else
1212
1313 #include "llvm/Support/Program.h"
1414 #include "llvm/Config/config.h"
15 #include "llvm/Support/system_error.h"
15 #include
1616 using namespace llvm;
1717 using namespace sys;
1818
1919 #include "llvm/Support/MemoryBuffer.h"
2020 #include "llvm/Support/Path.h"
2121 #include "llvm/Support/raw_ostream.h"
22 #include "llvm/Support/system_error.h"
22 #include
2323 using namespace llvm;
2424
2525 static const size_t TabStop = 8;
3131 #include "llvm/ADT/StringRef.h"
3232 #include "llvm/Config/config.h" // Get build system configuration settings
3333 #include "llvm/Support/Compiler.h"
34 #include "llvm/Support/system_error.h"
34 #include
3535 #include
3636 #include
3737 #include
2121 #include "llvm/Support/Format.h"
2222 #include "llvm/Support/Process.h"
2323 #include "llvm/Support/Program.h"
24 #include "llvm/Support/system_error.h"
2524 #include
2625 #include
2726 #include
27 #include
2828
2929 // may provide O_BINARY.
3030 #if defined(HAVE_FCNTL_H)
1919 #include "llvm/Support/FileSystem.h"
2020 #include "llvm/Support/MemoryBuffer.h"
2121 #include "llvm/Support/ToolOutputFile.h"
22 #include "llvm/Support/system_error.h"
2322 #include "llvm/TableGen/Error.h"
2423 #include "llvm/TableGen/Main.h"
2524 #include "llvm/TableGen/Record.h"
2625 #include
2726 #include
27 #include
2828 using namespace llvm;
2929
3030 namespace {
3838 #include "llvm/Support/DataTypes.h"
3939 #include "llvm/Support/Debug.h"
4040 #include "llvm/Support/Endian.h"
41 #include "llvm/Support/system_error.h"
4241 #include "llvm/Transforms/Utils/ASanStackFrameLayout.h"
4342 #include "llvm/Transforms/Utils/BasicBlockUtils.h"
4443 #include "llvm/Transforms/Utils/Cloning.h"
4746 #include "llvm/Transforms/Utils/SpecialCaseList.h"
4847 #include
4948 #include
49 #include
5050
5151 using namespace llvm;
5252
2525 #include "llvm/Support/MemoryBuffer.h"
2626 #include "llvm/Support/Regex.h"
2727 #include "llvm/Support/raw_ostream.h"
28 #include "llvm/Support/system_error.h"
2928 #include
29 #include
3030 #include
3131
3232 namespace llvm {
2020 #include "llvm/Support/Path.h"
2121 #include "llvm/Support/Program.h"
2222 #include "llvm/Support/ToolOutputFile.h"
23 #include "llvm/Support/system_error.h"
2423 #include
2524 #include
2625 #include
2726 #include
2827 #include
2928 #include
29 #include
3030 #include
3131
3232 // Support Windows/MinGW crazyness.
3737 #include "llvm/Support/PrettyStackTrace.h"
3838 #include "llvm/Support/Signals.h"
3939 #include "llvm/Support/raw_ostream.h"
40 #include "llvm/Support/system_error.h"
4140 #include
4241 #include
4342 #include
43 #include
4444 using namespace llvm;
4545
4646 static cl::opt
1919 #include "llvm/Support/Path.h"
2020 #include "llvm/Support/PrettyStackTrace.h"
2121 #include "llvm/Support/Signals.h"
22 #include "llvm/Support/system_error.h"
22 #include
2323 using namespace llvm;
2424
2525 static cl::opt SourceFile(cl::Positional, cl::Required,
3131 #include "llvm/Support/PrettyStackTrace.h"
3232 #include "llvm/Support/Signals.h"
3333 #include "llvm/Support/ToolOutputFile.h"
34 #include "llvm/Support/system_error.h"
34 #include
3535 using namespace llvm;
3636
3737 static cl::opt
2424 #include "llvm/Support/PrettyStackTrace.h"
2525 #include "llvm/Support/Signals.h"
2626 #include "llvm/Support/raw_ostream.h"
27 #include "llvm/Support/system_error.h"
2827 #include
2928 #include
3029 #include
3130 #include
31 #include
3232
3333 using namespace llvm;
3434 using namespace object;
1818 #include "llvm/Support/Signals.h"
1919 #include "llvm/Support/SourceMgr.h"
2020 #include "llvm/Support/raw_ostream.h"
21 #include "llvm/Support/system_error.h"
21 #include
2222 using namespace llvm;
2323
2424 static cl::list
3636 #include "llvm/Support/Program.h"
3737 #include "llvm/Support/Signals.h"
3838 #include "llvm/Support/raw_ostream.h"
39 #include "llvm/Support/system_error.h"
4039 #include
4140 #include
4241 #include
4342 #include
43 #include
4444 #include
4545 using namespace llvm;
4646 using namespace object;
2121 #include "llvm/Support/SourceMgr.h"
2222 #include "llvm/Support/Win64EH.h"
2323 #include "llvm/Support/raw_ostream.h"
24 #include "llvm/Support/system_error.h"
2524 #include
2625 #include
26 #include
2727
2828 using namespace llvm;
2929 using namespace object;
3636 #include "llvm/Support/TargetRegistry.h"
3737 #include "llvm/Support/TargetSelect.h"
3838 #include "llvm/Support/raw_ostream.h"
39 #include "llvm/Support/system_error.h"
4039 #include
4140 #include
41 #include
4242 using namespace llvm;
4343 using namespace object;
4444
5656 #include "llvm/Support/TargetRegistry.h"
5757 #include "llvm/Support/TargetSelect.h"
5858 #include "llvm/Support/raw_ostream.h"
59 #include "llvm/Support/system_error.h"
6059 #include
6160 #include
6261 #include
62 #include
6363
6464 using namespace llvm;
6565 using namespace object;
1212 //===----------------------------------------------------------------------===//
1313
1414 #include "llvm-readobj.h"
15 #include "ARMWinEHPrinter.h"
1516 #include "Error.h"
1617 #include "ObjDumper.h"
1718 #include "StreamWriter.h"
18 #include "ARMWinEHPrinter.h"
1919 #include "Win64EHDumper.h"
2020 #include "llvm/ADT/DenseMap.h"
2121 #include "llvm/ADT/SmallString.h"
2929 #include "llvm/Support/SourceMgr.h"
3030 #include "llvm/Support/Win64EH.h"
3131 #include "llvm/Support/raw_ostream.h"
32 #include "llvm/Support/system_error.h"
3332 #include
3433 #include
34 #include
3535 #include
3636
3737 using namespace llvm;
1313 #ifndef LLVM_READOBJ_ERROR_H
1414 #define LLVM_READOBJ_ERROR_H
1515
16 #include "llvm/Support/system_error.h"
16 #include
1717
1818 namespace llvm {
19
19 using std::error_code;
2020 const std::error_category &readobj_category();
2121
2222 enum class readobj_error {
99 #ifndef LLVM_READOBJ_OBJDUMPER_H
1010 #define LLVM_READOBJ_OBJDUMPER_H
1111
12 #include "llvm/Support/system_error.h"
13
1412 #include
13 #include
1514
1615 namespace llvm {
17
16 using std::error_code;
1817 namespace object {
1918 class ObjectFile;
2019 }
3434 #include "llvm/Support/Signals.h"
3535 #include "llvm/Support/TargetRegistry.h"
3636 #include "llvm/Support/TargetSelect.h"
37 #include "llvm/Support/system_error.h"
3837 #include
38 #include
3939
4040
4141 using namespace llvm;
2424 #include "llvm/Support/PrettyStackTrace.h"
2525 #include "llvm/Support/Signals.h"
2626 #include "llvm/Support/raw_ostream.h"
27 #include "llvm/Support/system_error.h"
27 #include
2828 using namespace llvm;
2929 using namespace llvm::object;
3030
2424 #include "llvm/Support/PrettyStackTrace.h"
2525 #include "llvm/Support/Signals.h"
2626 #include "llvm/Support/raw_ostream.h"
27 #include "llvm/Support/system_error.h"
2827 #include
2928 #include
29 #include
3030 using namespace llvm;
3131 using namespace object;
3232
1919 #include "llvm/Support/ManagedStatic.h"
2020 #include "llvm/Support/MemoryBuffer.h"
2121 #include "llvm/Support/raw_ostream.h"
22 #include "llvm/Support/system_error.h"
22 #include
2323 using namespace llvm;
2424 using namespace llvm::object;
2525
99 #ifndef LLVM_TOOLS_ERROR_H
1010 #define LLVM_TOOLS_ERROR_H
1111
12 #include "llvm/Support/system_error.h"
12 #include
1313
1414 namespace llvm {
15
15 using std::error_code;
1616 const std::error_category &obj2yaml_category();
1717
1818 enum class obj2yaml_error {
1414
1515 #include "llvm/Object/COFF.h"
1616 #include "llvm/Support/raw_ostream.h"
17 #include "llvm/Support/system_error.h"
17 #include
1818
1919 std::error_code coff2yaml(llvm::raw_ostream &Out,
2020 const llvm::object::COFFObjectFile &Obj);
2121 #include "llvm/Support/MemoryBuffer.h"
2222 #include "llvm/Support/PrettyStackTrace.h"
2323 #include "llvm/Support/Signals.h"
24 #include "llvm/Support/raw_ostream.h"
25 #include "llvm/Support/system_error.h"
2624 #include "llvm/Support/ToolOutputFile.h"
2725 #include "llvm/Support/YAMLTraits.h"
26 #include "llvm/Support/raw_ostream.h"
27 #include
2828
2929 using namespace llvm;
3030
2626 #include "llvm/Support/Signals.h"
2727 #include "llvm/Support/SourceMgr.h"
2828 #include "llvm/Support/raw_ostream.h"
29 #include "llvm/Support/system_error.h"
3029 #include
3130 #include
3231 #include
3332 #include
33 #include
3434 #include
3535 using namespace llvm;
3636
1818 #include "llvm/Support/PrettyStackTrace.h"
1919 #include "llvm/Support/Signals.h"
2020 #include "llvm/Support/ToolOutputFile.h"
21 #include "llvm/Support/system_error.h"
21 #include
2222 using namespace llvm;
2323
2424 static cl::opt
3939 #include "llvm/Support/ManagedStatic.h"
4040 #include "llvm/Support/PrettyStackTrace.h"
4141 #include "llvm/Support/Signals.h"
42 #include "llvm/Support/WindowsError.h"
4243 #include "llvm/Support/raw_ostream.h"
43 #include "llvm/Support/system_error.h"
4444 #include "llvm/Support/type_traits.h"
45 #include "llvm/Support/WindowsError.h"
4645 #include
4746 #include
4847 #include
4948 #include
5049 #include
50 #include
5151
5252 // These includes must be last.
5353 #include
2020 #include "llvm/Support/Timer.h"
2121 #include "llvm/Support/YAMLParser.h"
2222 #include "llvm/Support/raw_ostream.h"
23 #include "llvm/Support/system_error.h"
23 #include
2424
2525 using namespace llvm;
2626