forked from OSchip/llvm-project
Fixed bug where we performed addition instead of subtraction during
constant propagation. llvm-svn: 46095
This commit is contained in:
parent
e914bb8183
commit
493444fc19
|
@ -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
|
||||
|
|
Loading…
Reference in New Issue