[Bug middle-end/36300] Incorrect type used for inlined expression

acarmeli at mathworks dot com gcc-bugzilla@gcc.gnu.org
Tue May 27 12:51:00 GMT 2008



------- Comment #8 from acarmeli at mathworks dot com  2008-05-27 12:50 -------
Richard,

I truly appreciate your effort on this bug.

Can you please elaborate on your plan? Will this be fixed for -fwrapv only, or
also for -fwrapv-free compilations?

I understand that downcasting an out-of-range value to a signed integer is not
defined in the standard. However, many compilers offer an "expected" modulo-2^n
behavior. This behavior helps avoid writing extra cumbersome "safe downcast"
code. Having GCC offer it for non -fwrapv compilations is an important
interoperability and readability feature.

Thank you for looking into it.

Alex.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36300



More information about the Gcc-bugs mailing list