https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119222
--- Comment #15 from Jonathan Wakely <redi at gcc dot gnu.org> --- (In reply to Gwen Fu from comment #13) > warning_at(loc, OPT_Wfloat_conversion, > "conversion from %qT to %qT changes infinity to maximum or minimum integer > value", expr_type , type) ; The message could be improved, the conversion has undefined behaviour, so according to the C++ standard it could convert to any value, or crash the program, or anything else.