[cfe-dev] bug in Expr::isIntegerConstantExpr() in LNot handling
Chris Lattner
clattner at apple.com
Fri Jan 25 11:16:28 PST 2008
On Jan 25, 2008, at 10:57 AM, Nuno Lopes wrote:
> Hi,
>
> I think I didn't send this patch yet. The patch fixes a bug in
> Expr::isIntegerConstantExpr() handling the LNot Operator.
Applied, thanks!
-Chris
>
> Nuno
>
>
> Index: Expr.cpp
> ===================================================================
> --- Expr.cpp (revision 46352)
> +++ Expr.cpp (working copy)
> @@ -703,7 +703,7 @@
> }
> break;
> case UnaryOperator::LNot: {
> - bool Val = Result != 0;
> + bool Val = Result == 0;
> Result.zextOrTrunc(
> static_cast<uint32_t>(Ctx.getTypeSize(getType(),
> Exp-
> >getOperatorLoc())));
>
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
More information about the cfe-dev
mailing list