Updated call to dead stores to use proper arguments.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@52560 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/Driver/ASTConsumers.cpp b/Driver/ASTConsumers.cpp
index 580563b..92add41 100644
--- a/Driver/ASTConsumers.cpp
+++ b/Driver/ASTConsumers.cpp
@@ -20,6 +20,7 @@
#include "clang/AST/AST.h"
#include "clang/AST/ASTConsumer.h"
#include "clang/AST/CFG.h"
+#include "clang/AST/ParentMap.h"
#include "clang/Analysis/Analyses/LiveVariables.h"
#include "clang/Analysis/LocalCheckers.h"
#include "clang/Analysis/PathSensitive/GRTransferFuncs.h"
@@ -640,7 +641,8 @@
}
virtual void VisitCFG(CFG& C, Decl& CD) {
- CheckDeadStores(C, *Ctx, Diags);
+ llvm::OwningPtr<ParentMap> PM(new ParentMap(CD.getCodeBody()));
+ CheckDeadStores(C, *Ctx, *PM, Diags);
}
virtual bool printFuncDeclStart() { return false; }