1 #ifndef LLVM_DWP_DWPERROR_H 2 #define LLVM_DWP_DWPERROR_H 3 4 #include "llvm/Support/Compiler.h" 5 #include "llvm/Support/Error.h" 6 #include "llvm/Support/ErrorHandling.h" 7 #include <string> 8 9 namespace llvm { 10 class DWPError : public ErrorInfo<DWPError> { 11 public: DWPError(std::string Info)12 DWPError(std::string Info) : Info(std::move(Info)) {} log(raw_ostream & OS)13 void log(raw_ostream &OS) const override { OS << Info; } convertToErrorCode()14 std::error_code convertToErrorCode() const override { 15 llvm_unreachable("Not implemented"); 16 } 17 LLVM_ABI static char ID; 18 19 private: 20 std::string Info; 21 }; 22 } // namespace llvm 23 24 #endif // LLVM_DWP_DWPERROR_H 25