summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/Sema')
-rw-r--r--clang/lib/Sema/SemaTemplateDeduction.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/clang/lib/Sema/SemaTemplateDeduction.cpp b/clang/lib/Sema/SemaTemplateDeduction.cpp
index af8d309267c..6f676ad7c55 100644
--- a/clang/lib/Sema/SemaTemplateDeduction.cpp
+++ b/clang/lib/Sema/SemaTemplateDeduction.cpp
@@ -3656,8 +3656,10 @@ SpecializeCorrespondingLambdaCallOperatorAndInvoker(
FunctionTemplateDecl *InvokerTemplate = LambdaClass->
getLambdaStaticInvoker()->getDescribedFunctionTemplate();
- Sema::TemplateDeductionResult LLVM_ATTRIBUTE_UNUSED Result
- = S.FinishTemplateArgumentDeduction(InvokerTemplate, DeducedArguments, 0,
+#ifndef NDEBUG
+ Sema::TemplateDeductionResult LLVM_ATTRIBUTE_UNUSED Result =
+#endif
+ S.FinishTemplateArgumentDeduction(InvokerTemplate, DeducedArguments, 0,
InvokerSpecialized, TDInfo);
assert(Result == Sema::TDK_Success &&
"If the call operator succeeded so should the invoker!");
OpenPOWER on IntegriCloud