The following patch has been tested on i686-pc-linux-gnu with a
full "make bootstrap", all default languages including Ada, and
regression tested with a top-level "make -k check" with no new
failures.
Committed to mainline as revision 115742. I'll backport this to
the release branches after a few days without problems. My apologies
and gratitude again to Richard; I didn't realise he was investigating
a solution when Andrew Pinski asked that I look into this PR.
2006-07-25 Roger Sayle <roger@eyesopen.com>
PR middle-end/28473
* convert.c (convert_to_integer): When transforming (T)foo(x) into
bar(x) check that bar's result type can represent all the values of T.
* gcc.dg/fold-convround-1.c: New test case.