On Thu, Nov 13, 2008 at 6:43 PM, Zhongxing Xu <[EMAIL PROTECTED]> wrote:
> Is this the rule:
>  - if the bitwidth of E2 is the same as the pointer, do the arithmetic.
>  - if the bitwidth of E2 is different from the pointer, trunc or ext it to
> the same width of the pointer. Signed-ness affects the ext operation. Then
> do the arithmetic.

The rule is conceptually the following: "Do the arithmetic exactly; if
there's overflow, the result is undefined."

Your rules are equivalent for the defined cases, though.

-Eli
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to