From 51ec0cf4aa94f977b24fc9cfbb992ea4fe9889c9 Mon Sep 17 00:00:00 2001 From: Richard Smith Date: Tue, 21 Feb 2017 01:17:38 +0000 Subject: Factor out function to determine whether we're performing a template instantiation. In preparation for converting the template stack to a more general context stack (so we can include context notes for other kinds of context). llvm-svn: 295686 --- clang/lib/Sema/SemaLambda.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'clang/lib/Sema/SemaLambda.cpp') diff --git a/clang/lib/Sema/SemaLambda.cpp b/clang/lib/Sema/SemaLambda.cpp index da2768f2131..c17f9fbd07e 100644 --- a/clang/lib/Sema/SemaLambda.cpp +++ b/clang/lib/Sema/SemaLambda.cpp @@ -312,7 +312,7 @@ Sema::getCurrentMangleNumberContext(const DeclContext *DC, // In the following contexts [...] the one-definition rule requires closure // types in different translation units to "correspond": bool IsInNonspecializedTemplate = - !ActiveTemplateInstantiations.empty() || CurContext->isDependentContext(); + inTemplateInstantiation() || CurContext->isDependentContext(); switch (Kind) { case Normal: { // -- the bodies of non-exported nonspecialized template functions -- cgit v1.2.3