From: Ted Kremenek Date: Wed, 16 Jan 2008 22:20:36 +0000 (+0000) Subject: Fixed bug where we performed addition instead of subtraction during X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=95b3f6f0b5740893c97e67067450b658688badb8;p=clang Fixed bug where we performed addition instead of subtraction during constant propagation. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@46095 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/Analysis/GRConstants.cpp b/Analysis/GRConstants.cpp index 82402559f2..2173f9b671 100644 --- a/Analysis/GRConstants.cpp +++ b/Analysis/GRConstants.cpp @@ -134,7 +134,7 @@ public: ExprVariantTy operator-(const ExprVariantTy& X) const { if (!isConstant || !X.isConstant) return ExprVariantTy(); - else return ExprVariantTy(val+X.val); + else return ExprVariantTy(val-X.val); } }; } // end anonymous namespace