r290780 - Remove redundant assertion.

Richard Smith via cfe-commits cfe-commits at lists.llvm.org
Fri Dec 30 19:33:43 PST 2016


Author: rsmith
Date: Fri Dec 30 21:33:42 2016
New Revision: 290780

URL: http://llvm.org/viewvc/llvm-project?rev=290780&view=rev
Log:
Remove redundant assertion.

Modified:
    cfe/trunk/lib/Sema/SemaTemplateDeduction.cpp

Modified: cfe/trunk/lib/Sema/SemaTemplateDeduction.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaTemplateDeduction.cpp?rev=290780&r1=290779&r2=290780&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaTemplateDeduction.cpp (original)
+++ cfe/trunk/lib/Sema/SemaTemplateDeduction.cpp Fri Dec 30 21:33:42 2016
@@ -3244,11 +3244,8 @@ DeduceFromInitializerList(Sema &S, Templ
             getDeducedParameterFromExpr(Info, ArrTy->getSizeExpr())) {
       // We can perform template argument deduction for the given non-type
       // template parameter.
-      assert(NTTP->getDepth() == 0 &&
-             "Cannot deduce non-type template argument at depth > 0");
       llvm::APInt Size(S.Context.getIntWidth(NTTP->getType()),
                        ILE->getNumInits());
-
       Result = DeduceNonTypeTemplateArgument(
           S, TemplateParams, NTTP, llvm::APSInt(Size), NTTP->getType(),
           /*ArrayBound=*/true, Info, Deduced);




More information about the cfe-commits mailing list