diff --git a/Analysis/GRExprEngine.cpp b/Analysis/GRExprEngine.cpp index 80de395c58..6635b0b6a6 100644 --- a/Analysis/GRExprEngine.cpp +++ b/Analysis/GRExprEngine.cpp @@ -747,7 +747,8 @@ void GRExprEngine::VisitUnaryOperator(UnaryOperator* U, NodeTy* Pred, St = SetRVal(St, U, Result); } else { - nonlval::ConcreteInt V(ValMgr.getZeroWithPtrWidth()); + Expr* Ex = U->getSubExpr(); + nonlval::ConcreteInt V(ValMgr.getValue(0, Ex->getType())); RVal Result = EvalBinOp(BinaryOperator::EQ, cast(SubV), V); St = SetRVal(St, U, Result); }