diff --git a/include/clang/Parse/Parser.h b/include/clang/Parse/Parser.h index 49554422bb..a11cd7d78d 100644 --- a/include/clang/Parse/Parser.h +++ b/include/clang/Parse/Parser.h @@ -553,7 +553,6 @@ private: bool isDeclarationAfterDeclarator(); bool isStartOfFunctionDefinition(); DeclGroupPtrTy ParseDeclarationOrFunctionDefinition( - TemplateParameterLists *TemplateParams = 0, AccessSpecifier AS = AS_none); DeclPtrTy ParseFunctionDefinition(Declarator &D); diff --git a/lib/Parse/Parser.cpp b/lib/Parse/Parser.cpp index e886bd43ca..d07d52e58c 100644 --- a/lib/Parse/Parser.cpp +++ b/lib/Parse/Parser.cpp @@ -477,12 +477,10 @@ bool Parser::isStartOfFunctionDefinition() { /// [OMP] threadprivate-directive [TODO] /// Parser::DeclGroupPtrTy -Parser::ParseDeclarationOrFunctionDefinition( - TemplateParameterLists *TemplateParams, - AccessSpecifier AS) { +Parser::ParseDeclarationOrFunctionDefinition(AccessSpecifier AS) { // Parse the common declaration-specifiers piece. DeclSpec DS; - ParseDeclarationSpecifiers(DS, TemplateParams, AS); + ParseDeclarationSpecifiers(DS, 0, AS); // C99 6.7.2.3p6: Handle "struct-or-union identifier;", "enum { X };" // declaration-specifiers init-declarator-list[opt] ';' diff --git a/test/SemaTemplate/temp.cpp b/test/SemaTemplate/temp.cpp index bd37cc668b..8be4739a74 100644 --- a/test/SemaTemplate/temp.cpp +++ b/test/SemaTemplate/temp.cpp @@ -1,2 +1,5 @@ // RUN: clang-cc -fsyntax-only -verify %s + + +// p3 template int foo(T), bar(T, T); // expected-error{{single entity}}