summaryrefslogtreecommitdiffstats
path: root/clang/lib/Parse/ParseDecl.cpp
diff options
context:
space:
mode:
authorDavid Blaikie <dblaikie@gmail.com>2016-01-15 23:43:25 +0000
committerDavid Blaikie <dblaikie@gmail.com>2016-01-15 23:43:25 +0000
commit0403cb11a1ed1ebbc56eb66567bbc686c755a51a (patch)
tree5962987a30a16dba216520348d716c7b2ed499b4 /clang/lib/Parse/ParseDecl.cpp
parent62d4a253f71efaec82314ab52033f2678f5d0f7b (diff)
downloadbcm5719-llvm-0403cb11a1ed1ebbc56eb66567bbc686c755a51a.tar.gz
bcm5719-llvm-0403cb11a1ed1ebbc56eb66567bbc686c755a51a.zip
OpaquePtr: Use nullptr construction for DeclGroupPtrTy OpaquePtr typedef
llvm-svn: 257956
Diffstat (limited to 'clang/lib/Parse/ParseDecl.cpp')
-rw-r--r--clang/lib/Parse/ParseDecl.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/clang/lib/Parse/ParseDecl.cpp b/clang/lib/Parse/ParseDecl.cpp
index c64b97d01b9..303e84383a6 100644
--- a/clang/lib/Parse/ParseDecl.cpp
+++ b/clang/lib/Parse/ParseDecl.cpp
@@ -1522,7 +1522,7 @@ Parser::ParseSimpleDeclaration(unsigned Context,
// may get this far before the problem becomes obvious.
if (DS.hasTagDefinition() &&
DiagnoseMissingSemiAfterTagDefinition(DS, AS_none, DSContext))
- return DeclGroupPtrTy();
+ return nullptr;
// C99 6.7.2.3p6: Handle "struct-or-union identifier;", "enum { X };"
// declaration-specifiers init-declarator-list[opt] ';'
@@ -1701,7 +1701,7 @@ Parser::DeclGroupPtrTy Parser::ParseDeclGroup(ParsingDeclSpec &DS,
// Bail out if the first declarator didn't seem well-formed.
if (!D.hasName() && !D.mayOmitIdentifier()) {
SkipMalformedDecl();
- return DeclGroupPtrTy();
+ return nullptr;
}
// Save late-parsed attributes for now; they need to be parsed in the
@@ -1766,19 +1766,19 @@ Parser::DeclGroupPtrTy Parser::ParseDeclGroup(ParsingDeclSpec &DS,
} else {
Diag(Tok, diag::err_expected_fn_body);
SkipUntil(tok::semi);
- return DeclGroupPtrTy();
+ return nullptr;
}
} else {
if (Tok.is(tok::l_brace)) {
Diag(Tok, diag::err_function_definition_not_allowed);
SkipMalformedDecl();
- return DeclGroupPtrTy();
+ return nullptr;
}
}
}
if (ParseAsmAttributesAfterDeclarator(D))
- return DeclGroupPtrTy();
+ return nullptr;
// C++0x [stmt.iter]p1: Check if we have a for-range-declarator. If so, we
// must parse and analyze the for-range-initializer before the declaration is
OpenPOWER on IntegriCloud