]> granicus.if.org Git - clang/commitdiff
Remove some dead code.
authorRichard Smith <richard-llvm@metafoo.co.uk>
Wed, 18 Sep 2013 21:55:14 +0000 (21:55 +0000)
committerRichard Smith <richard-llvm@metafoo.co.uk>
Wed, 18 Sep 2013 21:55:14 +0000 (21:55 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190959 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Sema/SemaTemplate.cpp

index f6863fb279967fea0edf8fa1f62fd7e280748dac..a7a6bb4f0cfe63188ecfd0eb4ea70712414ef39d 100644 (file)
@@ -7282,12 +7282,9 @@ DeclResult Sema::ActOnExplicitInstantiation(Scope *S,
     //
     // C++98 has the same restriction, just worded differently.
     //
-    // C++1y If the explicit instantiation is for a variable, the
-    // unqualified-id in the declaration shall be a template-id.
-    if (!ScopeSpecifierHasTemplateId(D.getCXXScopeSpec()) &&
-        (!PrevTemplate ||
-         (D.getName().getKind() != UnqualifiedId::IK_TemplateId &&
-          D.getCXXScopeSpec().isSet())))
+    // This does not apply to variable template specializations, where the
+    // template-id is in the unqualified-id instead.
+    if (!ScopeSpecifierHasTemplateId(D.getCXXScopeSpec()) && !PrevTemplate)
       Diag(D.getIdentifierLoc(),
            diag::ext_explicit_instantiation_without_qualified_id)
         << Prev << D.getCXXScopeSpec().getRange();