From: Zhongxing Xu Date: Tue, 20 Apr 2010 04:53:09 +0000 (+0000) Subject: Use GetState() to get the possible cleaned state. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=59fea60cc3dde7a14eeafab9469cb911023fdd7f;p=clang Use GetState() to get the possible cleaned state. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@101867 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Checker/GRExprEngine.cpp b/lib/Checker/GRExprEngine.cpp index e52ce47b12..b5f8fee5a2 100644 --- a/lib/Checker/GRExprEngine.cpp +++ b/lib/Checker/GRExprEngine.cpp @@ -1953,7 +1953,7 @@ void GRExprEngine::EvalEagerlyAssume(ExplodedNodeSet &Dst, ExplodedNodeSet &Src, continue; } - const GRState* state = Pred->getState(); + const GRState* state = GetState(Pred); SVal V = state->getSVal(Ex); if (nonloc::SymExprVal *SEV = dyn_cast(&V)) { // First assume that the condition is true. @@ -2177,7 +2177,7 @@ void GRExprEngine::VisitObjCMessageExpr(ObjCMessageExpr* ME, ExplodedNode* Pred, SaveOr OldHasGen(Builder->HasGeneratedNode); if (const Expr *Receiver = ME->getReceiver()) { - const GRState *state = Pred->getState(); + const GRState *state = GetState(Pred); // Bifurcate the state into nil and non-nil ones. DefinedOrUnknownSVal receiverVal = @@ -3029,7 +3029,7 @@ void GRExprEngine::VisitBinaryOperator(BinaryOperator* B, ExplodedNodeSet Tmp3; for (ExplodedNodeSet::iterator I1=Tmp1.begin(), E1=Tmp1.end(); I1!=E1; ++I1) { - SVal LeftV = (*I1)->getState()->getSVal(LHS); + SVal LeftV = GetState(*I1)->getSVal(LHS); ExplodedNodeSet Tmp2; Visit(RHS, *I1, Tmp2);