From e4a9f1b6e78f2af36f87d587a99909b7ad3c77c0 Mon Sep 17 00:00:00 2001 From: "Duncan P. N. Exon Smith" Date: Fri, 24 Jul 2015 18:58:32 +0000 Subject: [PATCH] DI: Strengthen block-byref cast to DIDerivedType, NFC This code is visiting the members of a block-byref, and we know those are all `DIDerivedType`. Strengthen the cast. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@243138 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/AsmPrinter/DwarfDebug.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/CodeGen/AsmPrinter/DwarfDebug.cpp b/lib/CodeGen/AsmPrinter/DwarfDebug.cpp index d05df017d7a..5611ae6fcd8 100644 --- a/lib/CodeGen/AsmPrinter/DwarfDebug.cpp +++ b/lib/CodeGen/AsmPrinter/DwarfDebug.cpp @@ -189,7 +189,7 @@ const DIType *DbgVariable::getType() const { auto Elements = cast(subType)->getElements(); for (unsigned i = 0, N = Elements.size(); i < N; ++i) { - auto *DT = cast(Elements[i]); + auto *DT = cast(Elements[i]); if (getName() == DT->getName()) return resolve(DT->getBaseType()); } -- 2.34.1