On 5/18/2012 4:27 PM, Ulrich Weigand wrote:

I finally got some time to look into this in detail.  The various special-
case transforms in associate_plusminus all transform a plus/minus expression
tree into either a single operand, a negated operand, or a single plus or
minus of two operands.  This is valid as long as we can prove that the
newly introduced expression can never overflow (if we're doing signed
arithmetic).

It's interesting to note that for Ada, reassociatin is allowed if there
are no overriiding parens, even if it would introduce an overflow (exception) that would not occur otherwise. However, I think I prefer
the C semantics!

Reply via email to