diff options
author | Pirama Arumuga Nainar <pirama@google.com> | 2015-04-08 08:55:49 -0700 |
---|---|---|
committer | Pirama Arumuga Nainar <pirama@google.com> | 2015-04-09 15:04:38 -0700 |
commit | 4c5e43da7792f75567b693105cc53e3f1992ad98 (patch) | |
tree | 1b2c9792582e12f5af0b1512e3094425f0dc0df9 /include/llvm/DebugInfo/PDB/PDBTypes.h | |
parent | c75239e6119d0f9a74c57099d91cbc9bde56bf33 (diff) | |
download | external_llvm-4c5e43da7792f75567b693105cc53e3f1992ad98.zip external_llvm-4c5e43da7792f75567b693105cc53e3f1992ad98.tar.gz external_llvm-4c5e43da7792f75567b693105cc53e3f1992ad98.tar.bz2 |
Update aosp/master llvm for rebase to r233350
Change-Id: I07d935f8793ee8ec6b7da003f6483046594bca49
Diffstat (limited to 'include/llvm/DebugInfo/PDB/PDBTypes.h')
-rw-r--r-- | include/llvm/DebugInfo/PDB/PDBTypes.h | 36 |
1 files changed, 35 insertions, 1 deletions
diff --git a/include/llvm/DebugInfo/PDB/PDBTypes.h b/include/llvm/DebugInfo/PDB/PDBTypes.h index 75b6475..686e08f 100644 --- a/include/llvm/DebugInfo/PDB/PDBTypes.h +++ b/include/llvm/DebugInfo/PDB/PDBTypes.h @@ -418,6 +418,17 @@ enum class PDB_RegisterId { enum class PDB_MemberAccess { Private = 1, Protected = 2, Public = 3 }; +enum class PDB_ErrorCode { + Success, + NoPdbImpl, + InvalidPath, + InvalidFileFormat, + InvalidParameter, + AlreadyLoaded, + UnknownError, + NoMemory +}; + struct VersionInfo { uint32_t Major; uint32_t Minor; @@ -459,8 +470,31 @@ struct Variant { uint16_t UInt16; uint32_t UInt32; uint64_t UInt64; - void* Pointer; }; +#define VARIANT_EQUAL_CASE(Enum) \ + case PDB_VariantType::Enum: \ + return Enum == Other.Enum; + bool operator==(const Variant &Other) const { + if (Type != Other.Type) + return false; + switch (Type) { + VARIANT_EQUAL_CASE(Bool) + VARIANT_EQUAL_CASE(Int8) + VARIANT_EQUAL_CASE(Int16) + VARIANT_EQUAL_CASE(Int32) + VARIANT_EQUAL_CASE(Int64) + VARIANT_EQUAL_CASE(Single) + VARIANT_EQUAL_CASE(Double) + VARIANT_EQUAL_CASE(UInt8) + VARIANT_EQUAL_CASE(UInt16) + VARIANT_EQUAL_CASE(UInt32) + VARIANT_EQUAL_CASE(UInt64) + default: + return true; + } + } +#undef VARIANT_EQUAL_CASE + bool operator!=(const Variant &Other) const { return !(*this == Other); } }; } // namespace llvm |