aboutsummaryrefslogtreecommitdiff
path: root/lib/Parse/ParseDecl.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2012-05-07 06:16:41 +0000
committerJohn McCall <rjmccall@apple.com>2012-05-07 06:16:41 +0000
commit9257664568bf375b7790131a84d9a4fa30a5b7e3 (patch)
treeb2134311ce2830aca55c9fe352cbd7877ee72179 /lib/Parse/ParseDecl.cpp
parent667fd80de4c3b7b143ba98a3b73e9b9b200f6af0 (diff)
Refactor DelayedDiagnostics so that it keeps diagnostics in
separate pools owned by the RAII objects that keep pushing decl state. This gives us quite a bit more flexibility. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@156289 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Parse/ParseDecl.cpp')
-rw-r--r--lib/Parse/ParseDecl.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Parse/ParseDecl.cpp b/lib/Parse/ParseDecl.cpp
index 12941b09ba..dbf35b14cf 100644
--- a/lib/Parse/ParseDecl.cpp
+++ b/lib/Parse/ParseDecl.cpp
@@ -2560,7 +2560,7 @@ ParseStructDeclaration(DeclSpec &DS, FieldCallback &Fields) {
bool FirstDeclarator = true;
SourceLocation CommaLoc;
while (1) {
- ParsingDeclRAIIObject PD(*this);
+ ParsingDeclRAIIObject PD(*this, ParsingDeclRAIIObject::NoParent);
FieldDeclarator DeclaratorInfo(DS);
DeclaratorInfo.D.setCommaLoc(CommaLoc);
@@ -3067,7 +3067,7 @@ void Parser::ParseEnumBody(SourceLocation StartLoc, Decl *EnumDecl) {
SourceLocation EqualLoc;
ExprResult AssignedVal;
- ParsingDeclRAIIObject PD(*this);
+ ParsingDeclRAIIObject PD(*this, ParsingDeclRAIIObject::NoParent);
if (Tok.is(tok::equal)) {
EqualLoc = ConsumeToken();