summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
authorFaisal Vali <faisalv@yahoo.com>2016-03-26 20:46:45 +0000
committerFaisal Vali <faisalv@yahoo.com>2016-03-26 20:46:45 +0000
commitb8b04f8526375676d6d51f4f01acb69eada1d02c (patch)
tree06d2cf04e061e4b526acfd11e05351946b09066c /clang/lib
parentf6d61afc146441d1f1b3ae564da54e0d40882368 (diff)
downloadbcm5719-llvm-b8b04f8526375676d6d51f4f01acb69eada1d02c.tar.gz
bcm5719-llvm-b8b04f8526375676d6d51f4f01acb69eada1d02c.zip
[NFC] Tweak diagnostic for template template arguments, to include template aliases.
The prior diagnostic (err_template_arg_not_class_template) would state that the template argument to a template template parameter can only be a class template, when it can also be a template alias. The newly renamed diagnostic (err_template_arg_not_valid_template) mentions template aliases. llvm-svn: 264522
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/Sema/SemaTemplate.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/Sema/SemaTemplate.cpp b/clang/lib/Sema/SemaTemplate.cpp
index 0b4b083ffbd..18b739df7f5 100644
--- a/clang/lib/Sema/SemaTemplate.cpp
+++ b/clang/lib/Sema/SemaTemplate.cpp
@@ -800,7 +800,7 @@ Decl *Sema::ActOnTemplateTemplateParameter(Scope* S,
// However, it isn't worth doing.
TemplateArgumentLoc DefaultArg = translateTemplateArgument(*this, Default);
if (DefaultArg.getArgument().getAsTemplate().isNull()) {
- Diag(DefaultArg.getLocation(), diag::err_template_arg_not_class_template)
+ Diag(DefaultArg.getLocation(), diag::err_template_arg_not_valid_template)
<< DefaultArg.getSourceRange();
return Param;
}
@@ -5352,7 +5352,7 @@ bool Sema::CheckTemplateArgument(TemplateTemplateParmDecl *Param,
!isa<TypeAliasTemplateDecl>(Template)) {
assert(isa<FunctionTemplateDecl>(Template) &&
"Only function templates are possible here");
- Diag(Arg.getLocation(), diag::err_template_arg_not_class_template);
+ Diag(Arg.getLocation(), diag::err_template_arg_not_valid_template);
Diag(Template->getLocation(), diag::note_template_arg_refers_here_func)
<< Template;
}
OpenPOWER on IntegriCloud