http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47659
--- Comment #3 from Thomas Koenig <tkoenig at gcc dot gnu.org> 2011-08-07 21:20:36 UTC --- Created attachment 24945 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=24945 Proposed patch Here's a patch. For real a a = 2.3d0 it checks for truncation correctly and only warns if digits are lost. Unfortunately, for the case of double precision a a = 1.2 I don't see a good way of getting at the original string of numbers to see if the 1.2 would have been interpreted differently if it had been a double precision number. What should we do? Not warn for integers (like I did here) or warn unconditionally?