]> granicus.if.org Git - llvm/commitdiff
Remove redundant check for nullptr.
authorAdrian Prantl <aprantl@apple.com>
Mon, 27 Mar 2017 17:36:31 +0000 (17:36 +0000)
committerAdrian Prantl <aprantl@apple.com>
Mon, 27 Mar 2017 17:36:31 +0000 (17:36 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@298866 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/AsmPrinter/CodeViewDebug.cpp

index 5d117fdbd5daafc7fb447df6451602b3c6987a0e..383b8cddb1a06384fafe131ebf077f9b7302f7cd 100644 (file)
@@ -947,10 +947,10 @@ void CodeViewDebug::collectVariableInfo(const DISubprogram *SP) {
 
       // Handle fragments.
       auto Fragment = DIExpr->getFragmentInfo();
-      if (DIExpr && Fragment) {
+      if (Fragment) {
         IsSubfield = true;
         StructOffset = Fragment->OffsetInBits / 8;
-      } else if (DIExpr && DIExpr->getNumElements() > 0) {
+      } else if (DIExpr->getNumElements() > 0) {
         continue; // Ignore unrecognized exprs.
       }