summaryrefslogtreecommitdiffstats
path: root/llvm/lib/IR/DebugInfo.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/IR/DebugInfo.cpp')
-rw-r--r--llvm/lib/IR/DebugInfo.cpp20
1 files changed, 2 insertions, 18 deletions
diff --git a/llvm/lib/IR/DebugInfo.cpp b/llvm/lib/IR/DebugInfo.cpp
index 91823773212..9381a5b580e 100644
--- a/llvm/lib/IR/DebugInfo.cpp
+++ b/llvm/lib/IR/DebugInfo.cpp
@@ -252,32 +252,16 @@ static bool isDescriptorRef(const Metadata *MD) {
}
#endif
-bool DIType::Verify() const {
- auto *N = dyn_cast_or_null<MDType>(DbgNode);
- if (!N)
- return false;
-
- if (isCompositeType())
- return DICompositeType(DbgNode).Verify();
- return true;
-}
-
+bool DIType::Verify() const { return isType(); }
bool DIBasicType::Verify() const { return isBasicType(); }
bool DIDerivedType::Verify() const { return isDerivedType(); }
-
-bool DICompositeType::Verify() const {
- auto *N = dyn_cast_or_null<MDCompositeTypeBase>(DbgNode);
- return N && !(isLValueReference() && isRValueReference());
-}
+bool DICompositeType::Verify() const { return isCompositeType(); }
bool DISubprogram::Verify() const {
auto *N = dyn_cast_or_null<MDSubprogram>(DbgNode);
if (!N)
return false;
- if (isLValueReference() && isRValueReference())
- return false;
-
// If a DISubprogram has an llvm::Function*, then scope chains from all
// instructions within the function should lead to this DISubprogram.
if (auto *F = getFunction()) {
OpenPOWER on IntegriCloud