diff options
author | Stephen Kelly <steveire@gmail.com> | 2019-01-18 22:15:05 +0000 |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2019-01-18 22:15:05 +0000 |
commit | 4e35baa842df5cd169456fe3ba0f25a48317b8c9 (patch) | |
tree | 380c734daf1c35b61a9c6e53fd14eb6819729edd /clang/lib/AST/ASTDumper.cpp | |
parent | f4129fd58b1d859f3e1f3a5b1155e0d82f2f80bd (diff) | |
download | bcm5719-llvm-4e35baa842df5cd169456fe3ba0f25a48317b8c9.tar.gz bcm5719-llvm-4e35baa842df5cd169456fe3ba0f25a48317b8c9.zip |
[ASTDump] NFC: Remove redundant condition
These conditions are duplicated from the dumpDeclContext function called
within the if(). This is presumably an attempt to avoid calling the
function in the case it will do nothing.
That may have made sense in the past if the code was different, but it
doesn't make sense now.
llvm-svn: 351604
Diffstat (limited to 'clang/lib/AST/ASTDumper.cpp')
-rw-r--r-- | clang/lib/AST/ASTDumper.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/clang/lib/AST/ASTDumper.cpp b/clang/lib/AST/ASTDumper.cpp index 678a6b5fc85..2b9b132eea7 100644 --- a/clang/lib/AST/ASTDumper.cpp +++ b/clang/lib/AST/ASTDumper.cpp @@ -514,10 +514,7 @@ void ASTDumper::dumpDecl(const Decl *D) { // Decls within functions are visited by the body. if (!isa<FunctionDecl>(*D) && !isa<ObjCMethodDecl>(*D)) { auto DC = dyn_cast<DeclContext>(D); - if (DC && - (DC->hasExternalLexicalStorage() || - (Deserialize ? DC->decls_begin() != DC->decls_end() - : DC->noload_decls_begin() != DC->noload_decls_end()))) + if (DC) dumpDeclContext(DC); } }); |