From c7e70c433efc6953dc3888b9fbf9f3512d7da2b0 Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Thu, 2 Aug 2018 17:33:11 +0000 Subject: Vendor import of clang trunk r338536: https://llvm.org/svn/llvm-project/cfe/trunk@338536 --- lib/Analysis/AnalysisDeclContext.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'lib/Analysis/AnalysisDeclContext.cpp') diff --git a/lib/Analysis/AnalysisDeclContext.cpp b/lib/Analysis/AnalysisDeclContext.cpp index 486fffbe1299..9557f68452ff 100644 --- a/lib/Analysis/AnalysisDeclContext.cpp +++ b/lib/Analysis/AnalysisDeclContext.cpp @@ -56,13 +56,13 @@ using ManagedAnalysisMap = llvm::DenseMap; AnalysisDeclContext::AnalysisDeclContext(AnalysisDeclContextManager *Mgr, const Decl *d, const CFG::BuildOptions &buildOptions) - : Manager(Mgr), D(d), cfgBuildOptions(buildOptions) { + : Manager(Mgr), D(d), cfgBuildOptions(buildOptions) { cfgBuildOptions.forcedBlkExprs = &forcedBlkExprs; } AnalysisDeclContext::AnalysisDeclContext(AnalysisDeclContextManager *Mgr, const Decl *d) - : Manager(Mgr), D(d) { + : Manager(Mgr), D(d) { cfgBuildOptions.forcedBlkExprs = &forcedBlkExprs; } @@ -154,7 +154,7 @@ const ImplicitParamDecl *AnalysisDeclContext::getSelfDecl() const { const VarDecl *VD = I.getVariable(); if (isSelfDecl(VD)) return dyn_cast(VD); - } + } } auto *CXXMethod = dyn_cast(D); @@ -191,7 +191,7 @@ AnalysisDeclContext::getBlockForRegisteredExpression(const Stmt *stmt) { assert(forcedBlkExprs); if (const auto *e = dyn_cast(stmt)) stmt = e->IgnoreParens(); - CFG::BuildOptions::ForcedBlkExprs::const_iterator itr = + CFG::BuildOptions::ForcedBlkExprs::const_iterator itr = forcedBlkExprs->find(stmt); assert(itr != forcedBlkExprs->end()); return itr->second; @@ -251,7 +251,7 @@ CFG *AnalysisDeclContext::getUnoptimizedCFG() { CFGStmtMap *AnalysisDeclContext::getCFGStmtMap() { if (cfgStmtMap) return cfgStmtMap.get(); - + if (CFG *c = getCFG()) { cfgStmtMap.reset(CFGStmtMap::Build(c, &getParentMap())); return cfgStmtMap.get(); @@ -263,7 +263,7 @@ CFGStmtMap *AnalysisDeclContext::getCFGStmtMap() { CFGReverseBlockReachabilityAnalysis *AnalysisDeclContext::getCFGReachablityAnalysis() { if (CFA) return CFA.get(); - + if (CFG *c = getCFG()) { CFA.reset(new CFGReverseBlockReachabilityAnalysis(*c)); return CFA.get(); @@ -346,7 +346,7 @@ bool AnalysisDeclContext::isInStdNamespace(const Decl *D) { LocationContextManager &AnalysisDeclContext::getLocationContextManager() { assert(Manager && "Cannot create LocationContexts without an AnalysisDeclContextManager!"); - return Manager->getLocationContextManager(); + return Manager->getLocationContextManager(); } //===----------------------------------------------------------------------===// @@ -562,9 +562,9 @@ public: IgnoredContexts.insert(BR->getBlockDecl()); Visit(BR->getBlockDecl()->getBody()); } - + void VisitPseudoObjectExpr(PseudoObjectExpr *PE) { - for (PseudoObjectExpr::semantics_iterator it = PE->semantics_begin(), + for (PseudoObjectExpr::semantics_iterator it = PE->semantics_begin(), et = PE->semantics_end(); it != et; ++it) { Expr *Semantic = *it; if (auto *OVE = dyn_cast(Semantic)) -- cgit v1.2.3