From dbd65779649eb0a12e63c84c7f9d2cf9d3411a46 Mon Sep 17 00:00:00 2001 From: Larisse Voufo Date: Wed, 14 Aug 2013 20:15:02 +0000 Subject: Bug fix: note diagnosis on expression narrowing should say "variable template" instead of "static data member" when appropriate llvm-svn: 188409 --- clang/lib/Sema/SemaTemplateInstantiate.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'clang/lib') diff --git a/clang/lib/Sema/SemaTemplateInstantiate.cpp b/clang/lib/Sema/SemaTemplateInstantiate.cpp index 83c4c115fab..9f84fc665b1 100644 --- a/clang/lib/Sema/SemaTemplateInstantiate.cpp +++ b/clang/lib/Sema/SemaTemplateInstantiate.cpp @@ -524,7 +524,9 @@ void Sema::PrintInstantiationStack() { << Active->InstantiationRange; } else if (VarDecl *VD = dyn_cast(D)) { Diags.Report(Active->PointOfInstantiation, - diag::note_template_static_data_member_def_here) + VD->isStaticDataMember()? + diag::note_template_static_data_member_def_here + : diag::note_template_variable_def_here) << VD << Active->InstantiationRange; } else if (EnumDecl *ED = dyn_cast(D)) { -- cgit v1.2.3