aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaTemplateInstantiateDecl.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2011-07-05 18:30:26 +0000
committerDouglas Gregor <dgregor@apple.com>2011-07-05 18:30:26 +0000
commit5cbe101b502e06d16bc77df45a27ce8bc13f33c8 (patch)
tree27addc3ae3bec3596b0ad8cbf406d8f9755ce2d3 /lib/Sema/SemaTemplateInstantiateDecl.cpp
parent94c9ce54bf69768166deb2a716863c64b12f77a6 (diff)
Look through parenthesized declarators when determining whether an
instantiated function template was written with a prototype or via some kind of typedef. Fixes PR10273 / <rdar://problem/9723679>. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@134426 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaTemplateInstantiateDecl.cpp')
-rw-r--r--lib/Sema/SemaTemplateInstantiateDecl.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/SemaTemplateInstantiateDecl.cpp b/lib/Sema/SemaTemplateInstantiateDecl.cpp
index b6d5abfcc8..0a05d0e304 100644
--- a/lib/Sema/SemaTemplateInstantiateDecl.cpp
+++ b/lib/Sema/SemaTemplateInstantiateDecl.cpp
@@ -1090,7 +1090,7 @@ Decl *TemplateDeclInstantiator::VisitFunctionDecl(FunctionDecl *D,
Function->setLexicalDeclContext(LexicalDC);
// Attach the parameters
- if (isa<FunctionProtoType>(Function->getType())) {
+ if (isa<FunctionProtoType>(Function->getType().IgnoreParens())) {
// Adopt the already-instantiated parameters into our own context.
for (unsigned P = 0; P < Params.size(); ++P)
if (Params[P])