r247447 - Remove a redundant check from CGDebugInfo::shouldOmitDefinition() (NFC).

Adrian Prantl via cfe-commits cfe-commits at lists.llvm.org
Fri Sep 11 11:54:29 PDT 2015


Author: adrian
Date: Fri Sep 11 13:54:28 2015
New Revision: 247447

URL: http://llvm.org/viewvc/llvm-project?rev=247447&view=rev
Log:
Remove a redundant check from CGDebugInfo::shouldOmitDefinition() (NFC).

Modified:
    cfe/trunk/lib/CodeGen/CGDebugInfo.cpp

Modified: cfe/trunk/lib/CodeGen/CGDebugInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGDebugInfo.cpp?rev=247447&r1=247446&r2=247447&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/CGDebugInfo.cpp (original)
+++ cfe/trunk/lib/CodeGen/CGDebugInfo.cpp Fri Sep 11 13:54:28 2015
@@ -1480,14 +1480,8 @@ static bool shouldOmitDefinition(CodeGen
                                  const RecordDecl *RD,
                                  const LangOptions &LangOpts) {
   // Does the type exist in an imported clang module?
-  if (DebugTypeExtRefs && RD->isFromASTFile()) {
-    if (auto *CTSD = dyn_cast<ClassTemplateSpecializationDecl>(RD))
-      if (CTSD->isExplicitInstantiationOrSpecialization())
-        // We may not assume that this type made it into the module.
-        return true;
-    if (RD->getDefinition())
+  if (DebugTypeExtRefs && RD->isFromASTFile() && RD->getDefinition())
       return true;
-  }
 
   if (DebugKind > CodeGenOptions::LimitedDebugInfo)
     return false;




More information about the cfe-commits mailing list