[cfe-commits] r166777 - /cfe/trunk/lib/AST/ASTImporter.cpp

Douglas Gregor dgregor at apple.com
Fri Oct 26 08:36:16 PDT 2012


Author: dgregor
Date: Fri Oct 26 10:36:15 2012
New Revision: 166777

URL: http://llvm.org/viewvc/llvm-project?rev=166777&view=rev
Log:
Eliminate some longstanding FIXMEs regarding variadic templates in the
ASTImporter.

Modified:
    cfe/trunk/lib/AST/ASTImporter.cpp

Modified: cfe/trunk/lib/AST/ASTImporter.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/ASTImporter.cpp?rev=166777&r1=166776&r2=166777&view=diff
==============================================================================
--- cfe/trunk/lib/AST/ASTImporter.cpp (original)
+++ cfe/trunk/lib/AST/ASTImporter.cpp Fri Oct 26 10:36:15 2012
@@ -1129,10 +1129,8 @@
 static bool IsStructurallyEquivalent(StructuralEquivalenceContext &Context,
                                      NonTypeTemplateParmDecl *D1,
                                      NonTypeTemplateParmDecl *D2) {
-  // FIXME: Enable once we have variadic templates.
-#if 0
   if (D1->isParameterPack() != D2->isParameterPack()) {
-    if (Context.omplain) {
+    if (Context.Complain) {
       Context.Diag2(D2->getLocation(), diag::err_odr_parameter_pack_non_pack)
         << D2->isParameterPack();
       Context.Diag1(D1->getLocation(), diag::note_odr_parameter_pack_non_pack)
@@ -1140,7 +1138,6 @@
     }
     return false;
   }
-#endif
   
   // Check types.
   if (!Context.IsStructurallyEquivalent(D1->getType(), D2->getType())) {
@@ -1160,8 +1157,6 @@
 static bool IsStructurallyEquivalent(StructuralEquivalenceContext &Context,
                                      TemplateTemplateParmDecl *D1,
                                      TemplateTemplateParmDecl *D2) {
-  // FIXME: Enable once we have variadic templates.
-#if 0
   if (D1->isParameterPack() != D2->isParameterPack()) {
     if (Context.Complain) {
       Context.Diag2(D2->getLocation(), diag::err_odr_parameter_pack_non_pack)
@@ -1171,8 +1166,7 @@
     }
     return false;
   }
-#endif
-  
+
   // Check template parameter lists.
   return IsStructurallyEquivalent(Context, D1->getTemplateParameters(),
                                   D2->getTemplateParameters());





More information about the cfe-commits mailing list