]> granicus.if.org Git - clang/commitdiff
Remove a redundant check from CGDebugInfo::shouldOmitDefinition() (NFC).
authorAdrian Prantl <aprantl@apple.com>
Fri, 11 Sep 2015 18:54:28 +0000 (18:54 +0000)
committerAdrian Prantl <aprantl@apple.com>
Fri, 11 Sep 2015 18:54:28 +0000 (18:54 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@247447 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/CGDebugInfo.cpp

index a24934e6240e88b9e631d2a8c62808798d716b69..50a8ffb4953d2648ec92c30f919fb69f10ddeb7e 100644 (file)
@@ -1480,14 +1480,8 @@ static bool shouldOmitDefinition(CodeGenOptions::DebugInfoKind DebugKind,
                                  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;