aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2012-04-24 05:48:42 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2012-04-24 05:48:42 +0000
commit2b2a0876c9d3a92c5216a578373817974fe159a0 (patch)
treedba3d7d906c994485876edad84c1b1e0ca28326d /lib
parent577535156425fa67ed2f1dad321e807f0f67649b (diff)
Don't try to delay parsing the exception specification for a data member of a
class; we would never actually parse it and attach it to the type. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@155426 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/Parse/ParseDecl.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/Parse/ParseDecl.cpp b/lib/Parse/ParseDecl.cpp
index 932ffb440f..4775798d62 100644
--- a/lib/Parse/ParseDecl.cpp
+++ b/lib/Parse/ParseDecl.cpp
@@ -4270,6 +4270,8 @@ void Parser::ParseFunctionDeclarator(Declarator &D,
D.getDeclSpec().getStorageClassSpec()
!= DeclSpec::SCS_typedef &&
!D.getDeclSpec().isFriendSpecified());
+ for (unsigned i = 0, e = D.getNumTypeObjects(); Delayed && i != e; ++i)
+ Delayed &= D.getTypeObject(i).Kind == DeclaratorChunk::Paren;
ESpecType = tryParseExceptionSpecification(Delayed,
ESpecRange,
DynamicExceptions,