This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
The following patch is my third attempt at resolving PR middle-end/19100 which is a wrong code bug affecting both C and C++ on mainline. I still believe that the correct fix is to clean-up truthvalue_conversion, however I also agree that reducing/eliminating TREE_OVERFLOW from GCC is a good thing, so the patch below humours Mark's request to investigate a fix in the middle-end. [It did however require two fixes to int_fits_type_p :)]
* fold-const.c (fold_convert_const): Don't set TREE_OVERFLOW when converting constants from one integer type to another.
* c-common.c (convert_and_check): Avoid testing TREE_OVERFLOW to detect conversion overflow, instead use int_fits_type_p.
-- Mark Mitchell CodeSourcery, LLC mark@codesourcery.com (916) 791-8304
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |