aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/IR/DebugInfoMetadata.cpp
diff options
context:
space:
mode:
authorMichael Buch <michaelbuch12@gmail.com>2023-11-15 08:49:11 +0000
committerMichael Buch <michaelbuch12@gmail.com>2023-11-15 08:50:16 +0000
commit8e8bad70e6db0b04198c025bef9acccfd06f36f0 (patch)
treeffb092be0dd1ee4016d6f1d6a92deadfea1df673 /llvm/lib/IR/DebugInfoMetadata.cpp
parent89361007aa8a44d68f2620570fd4efcc8757f3bb (diff)
downloadllvm-8e8bad70e6db0b04198c025bef9acccfd06f36f0.zip
llvm-8e8bad70e6db0b04198c025bef9acccfd06f36f0.tar.gz
llvm-8e8bad70e6db0b04198c025bef9acccfd06f36f0.tar.bz2
Revert "[llvm][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (#72234)"
This reverts commit 9a9933fae23249fbf6cf5b3c090e630f578b7f98. The OCaml bindings were using `LLVMDIBuilderCreateStaticMemberType`, causing the API change in `9a9933fae23249fbf6cf5b3c090e630f578b7f98` to break buildbots that built the bindings. Revert until we figure out whether to fixup the bindings or just not change the C-API
Diffstat (limited to 'llvm/lib/IR/DebugInfoMetadata.cpp')
-rw-r--r--llvm/lib/IR/DebugInfoMetadata.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/llvm/lib/IR/DebugInfoMetadata.cpp b/llvm/lib/IR/DebugInfoMetadata.cpp
index 943826c..0e14ec9 100644
--- a/llvm/lib/IR/DebugInfoMetadata.cpp
+++ b/llvm/lib/IR/DebugInfoMetadata.cpp
@@ -711,9 +711,7 @@ Constant *DIDerivedType::getStorageOffsetInBits() const {
}
Constant *DIDerivedType::getConstant() const {
- assert((getTag() == dwarf::DW_TAG_member ||
- getTag() == dwarf::DW_TAG_variable) &&
- isStaticMember());
+ assert(getTag() == dwarf::DW_TAG_member && isStaticMember());
if (auto *C = cast_or_null<ConstantAsMetadata>(getExtraData()))
return C->getValue();
return nullptr;