6 using namespace llvm::pdb;
14 const char *
name()
const noexcept
override {
return "llvm.pdb.raw"; }
16 std::string message(
int Condition)
const override {
17 switch (static_cast<raw_error_code>(Condition)) {
19 return "An unknown error has occurred.";
21 return "The feature is unsupported by the implementation.";
23 return "The record is in an unexpected format.";
25 return "The PDB file is corrupt.";
27 return "The buffer is not large enough to read the requested number of "
30 return "The specified stream could not be loaded.";
32 return "The specified item does not exist in the array.";
34 return "The specified block address is not valid.";
36 return "The entry already exists.";
38 return "The entry does not exist.";
40 return "The PDB does not support writing.";
42 return "The stream was longer than expected.";
44 return "The Type record has an invalid hash value.";
61 ErrMsg =
"Native PDB Error: ";
64 ErrMsg += EC.message() +
" ";
74 return std::error_code(static_cast<int>(Code), *
Category);
const std::string & getErrorMessage() const
Base class for errors originating when parsing raw PDB files.
static ManagedStatic< RawErrorCategory > Category
void log(raw_ostream &OS) const override
Print an error message to an output stream.
static ManagedStatic< _object_error_category > error_category
std::error_code convertToErrorCode() const override
Convert this error to a std::error_code.
llvm_unreachable("Unknown RegBank!")
RawError(raw_error_code C)
This class implements an extremely fast bulk output stream that can only output to a stream...
ManagedStatic - This transparently changes the behavior of global statics to be lazily constructed on...