aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaTemplateInstantiateDecl.cpp
diff options
context:
space:
mode:
authorPeter Collingbourne <peter@pcc.me.uk>2011-01-21 02:08:54 +0000
committerPeter Collingbourne <peter@pcc.me.uk>2011-01-21 02:08:54 +0000
commitc80e8115278ba1537c8b517a083ecbd0a018b579 (patch)
tree6c88d65811fe129979f5be77741710e2625cd7a0 /lib/Sema/SemaTemplateInstantiateDecl.cpp
parent60700390a787471d3396f380e0679a6d08c27f1f (diff)
Sema: process non-inheritable attributes on function declarations early
This allows us to simplify the handling for the overloadable attribute, removing a number of FIXMEs. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@123961 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaTemplateInstantiateDecl.cpp')
-rw-r--r--lib/Sema/SemaTemplateInstantiateDecl.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/Sema/SemaTemplateInstantiateDecl.cpp b/lib/Sema/SemaTemplateInstantiateDecl.cpp
index 36a1900299..5238ad6dfc 100644
--- a/lib/Sema/SemaTemplateInstantiateDecl.cpp
+++ b/lib/Sema/SemaTemplateInstantiateDecl.cpp
@@ -1053,7 +1053,6 @@ Decl *TemplateDeclInstantiator::VisitFunctionDecl(FunctionDecl *D,
Function->setInvalidDecl();
bool Redeclaration = false;
- bool OverloadableAttrRequired = false;
bool isExplicitSpecialization = false;
LookupResult Previous(SemaRef, Function->getDeclName(), SourceLocation(),
@@ -1105,8 +1104,7 @@ Decl *TemplateDeclInstantiator::VisitFunctionDecl(FunctionDecl *D,
}
SemaRef.CheckFunctionDeclaration(/*Scope*/ 0, Function, Previous,
- isExplicitSpecialization, Redeclaration,
- /*FIXME:*/OverloadableAttrRequired);
+ isExplicitSpecialization, Redeclaration);
NamedDecl *PrincipalDecl = (TemplateParams
? cast<NamedDecl>(FunctionTemplate)
@@ -1386,9 +1384,7 @@ TemplateDeclInstantiator::VisitCXXMethodDecl(CXXMethodDecl *D,
}
bool Redeclaration = false;
- bool OverloadableAttrRequired = false;
- SemaRef.CheckFunctionDeclaration(0, Method, Previous, false, Redeclaration,
- /*FIXME:*/OverloadableAttrRequired);
+ SemaRef.CheckFunctionDeclaration(0, Method, Previous, false, Redeclaration);
if (D->isPure())
SemaRef.CheckPureMethod(Method, SourceRange());