summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaDecl.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2010-02-21 22:15:06 +0000
committerDouglas Gregor <dgregor@apple.com>2010-02-21 22:15:06 +0000
commit36c569fb33842342d293388eef57fdd8e51e4d60 (patch)
tree007dcbe095ea7d3a20e8f35d7f720ad7c3b6ef52 /clang/lib/Sema/SemaDecl.cpp
parent7126183006ec694211afcf3b82b92e96afee01bc (diff)
downloadbcm5719-llvm-36c569fb33842342d293388eef57fdd8e51e4d60.tar.gz
bcm5719-llvm-36c569fb33842342d293388eef57fdd8e51e4d60.zip
Eliminate the default arguments to ASTContext::getFunctionType(),
fixing up a few callers that thought they were propagating NoReturn information but were in fact saying something about exception specifications. llvm-svn: 96766
Diffstat (limited to 'clang/lib/Sema/SemaDecl.cpp')
-rw-r--r--clang/lib/Sema/SemaDecl.cpp12
1 files changed, 9 insertions, 3 deletions
diff --git a/clang/lib/Sema/SemaDecl.cpp b/clang/lib/Sema/SemaDecl.cpp
index 3d5f9523d9a..2a9885c6a3c 100644
--- a/clang/lib/Sema/SemaDecl.cpp
+++ b/clang/lib/Sema/SemaDecl.cpp
@@ -1103,7 +1103,10 @@ bool Sema::MergeFunctionDecl(FunctionDecl *New, Decl *OldD) {
NewQType = Context.getFunctionType(NewFuncType->getResultType(),
ParamTypes.data(), ParamTypes.size(),
OldProto->isVariadic(),
- OldProto->getTypeQuals());
+ OldProto->getTypeQuals(),
+ false, false, 0, 0,
+ OldProto->getNoReturnAttr(),
+ OldProto->getCallConv());
New->setType(NewQType);
New->setHasInheritedPrototype();
@@ -1182,7 +1185,10 @@ bool Sema::MergeFunctionDecl(FunctionDecl *New, Decl *OldD) {
New->setType(Context.getFunctionType(MergedReturn, &ArgTypes[0],
ArgTypes.size(),
- OldProto->isVariadic(), 0));
+ OldProto->isVariadic(), 0,
+ false, false, 0, 0,
+ OldProto->getNoReturnAttr(),
+ OldProto->getCallConv()));
return MergeCompatibleFunctionDecls(New, Old);
}
@@ -3226,7 +3232,7 @@ void Sema::CheckFunctionDeclaration(Scope *S, FunctionDecl *NewFD,
// Turn this into a variadic function with no parameters.
QualType R = Context.getFunctionType(
NewFD->getType()->getAs<FunctionType>()->getResultType(),
- 0, 0, true, 0);
+ 0, 0, true, 0, false, false, 0, 0, false, CC_Default);
NewFD->setType(R);
return NewFD->setInvalidDecl();
}
OpenPOWER on IntegriCloud