File indexing completed on 2026-05-10 08:36:28
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014 #ifndef LLVM_CLANG_AST_ASTIMPORTERROR_H
0015 #define LLVM_CLANG_AST_ASTIMPORTERROR_H
0016
0017 #include "llvm/Support/Error.h"
0018
0019 namespace clang {
0020
0021 class ASTImportError : public llvm::ErrorInfo<ASTImportError> {
0022 public:
0023
0024 enum ErrorKind {
0025 NameConflict,
0026 UnsupportedConstruct,
0027 Unknown
0028 };
0029
0030 ErrorKind Error;
0031
0032 static char ID;
0033
0034 ASTImportError() : Error(Unknown) {}
0035 ASTImportError(const ASTImportError &Other) : Error(Other.Error) {}
0036 ASTImportError &operator=(const ASTImportError &Other) {
0037 Error = Other.Error;
0038 return *this;
0039 }
0040 ASTImportError(ErrorKind Error) : Error(Error) {}
0041
0042 std::string toString() const;
0043
0044 void log(llvm::raw_ostream &OS) const override;
0045 std::error_code convertToErrorCode() const override;
0046 };
0047
0048 }
0049
0050 #endif