diff options
Diffstat (limited to 'lib/Analysis/GRExprEngine.cpp')
-rw-r--r-- | lib/Analysis/GRExprEngine.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/lib/Analysis/GRExprEngine.cpp b/lib/Analysis/GRExprEngine.cpp index 6d360ed503..1f47bc7f33 100644 --- a/lib/Analysis/GRExprEngine.cpp +++ b/lib/Analysis/GRExprEngine.cpp @@ -394,9 +394,17 @@ void GRExprEngine::Visit(Stmt* S, NodeTy* Pred, NodeSet& Dst) { VisitLValue(cast<StringLiteral>(S), Pred, Dst); break; - case Stmt::UnaryOperatorClass: - VisitUnaryOperator(cast<UnaryOperator>(S), Pred, Dst, false); + case Stmt::UnaryOperatorClass: { + UnaryOperator *U = cast<UnaryOperator>(S); + if (EagerlyAssume && (U->getOpcode() == UnaryOperator::LNot)) { + NodeSet Tmp; + VisitUnaryOperator(U, Pred, Tmp, false); + EvalEagerlyAssume(Dst, Tmp, U); + } + else + VisitUnaryOperator(U, Pred, Dst, false); break; + } } } |