summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaExceptionSpec.cpp
diff options
context:
space:
mode:
authorSebastian Redl <sebastian.redl@getdesigned.at>2011-03-05 22:42:26 +0000
committerSebastian Redl <sebastian.redl@getdesigned.at>2011-03-05 22:42:26 +0000
commit69d37125a98601b1d689baa6733a77129b25d386 (patch)
treeaa7aa983d9906cfe46fc581d9c0b344471828dee /clang/lib/Sema/SemaExceptionSpec.cpp
parent802a45332a98b71a0ef0ac83e12c8fea8ef3e887 (diff)
downloadbcm5719-llvm-69d37125a98601b1d689baa6733a77129b25d386.tar.gz
bcm5719-llvm-69d37125a98601b1d689baa6733a77129b25d386.zip
Propagate new-style exception spec information to ExtProtoInfo.
llvm-svn: 127112
Diffstat (limited to 'clang/lib/Sema/SemaExceptionSpec.cpp')
-rw-r--r--clang/lib/Sema/SemaExceptionSpec.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/clang/lib/Sema/SemaExceptionSpec.cpp b/clang/lib/Sema/SemaExceptionSpec.cpp
index 123e185cab3..75ae8c215ab 100644
--- a/clang/lib/Sema/SemaExceptionSpec.cpp
+++ b/clang/lib/Sema/SemaExceptionSpec.cpp
@@ -129,8 +129,7 @@ bool Sema::CheckEquivalentExceptionSpec(FunctionDecl *Old, FunctionDecl *New) {
Context.getSourceManager().isInSystemHeader(Old->getLocation())) &&
Old->isExternC()) {
FunctionProtoType::ExtProtoInfo EPI = NewProto->getExtProtoInfo();
- EPI.HasExceptionSpec = true;
- EPI.HasAnyExceptionSpec = false;
+ EPI.ExceptionSpecType = EST_Dynamic;
EPI.NumExceptions = 0;
QualType NewType = Context.getFunctionType(NewProto->getResultType(),
NewProto->arg_type_begin(),
@@ -145,8 +144,9 @@ bool Sema::CheckEquivalentExceptionSpec(FunctionDecl *Old, FunctionDecl *New) {
= Old->getType()->getAs<FunctionProtoType>();
FunctionProtoType::ExtProtoInfo EPI = NewProto->getExtProtoInfo();
- EPI.HasExceptionSpec = OldProto->hasExceptionSpec();
- EPI.HasAnyExceptionSpec = OldProto->hasAnyExceptionSpec();
+ EPI.ExceptionSpecType = OldProto->hasExceptionSpec() ?
+ (OldProto->hasAnyExceptionSpec() ? EST_DynamicAny : EST_Dynamic) :
+ EST_None;
EPI.NumExceptions = OldProto->getNumExceptions();
EPI.Exceptions = OldProto->exception_begin();
OpenPOWER on IntegriCloud