The following code compiled on 4.4.x works without problems, but by using gcc 4.5 it produces for -O0 wrong code, and for -O >= 1 correct code but the strange warning (with -Wall option enabled) 'modf.c:9:1: warning: statement with no effect.'.
#include <stdio.h> #include <math.h> int main( void ) { double d = 10.5; double i = 100.0; modf( d, &i ); printf( "%f %f\n", d, i ); return 0; } -- Summary: Wrong code and misleading warning "statement with no effect" Product: gcc Version: 4.5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: regression AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: ktietz at gcc dot gnu dot org GCC target triplet: x86_64-*-mingw* http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43356