[Bug c/42807] constant folding at compile time limited to integers.

pinskia at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Tue Jan 19 18:13:00 GMT 2010



------- Comment #1 from pinskia at gcc dot gnu dot org  2010-01-19 18:13 -------
This is correct for C/C++.  2501*1600 is an integer.  If you want an unsigned
long, use ((unsigned long)2501)*1600 or 2501ul*1600ul.  


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |INVALID


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



More information about the Gcc-bugs mailing list