------- Comment #9 from dominiq at lps dot ens dot fr 2010-03-07 17:24 ------- I just noticed that using -Warray-temporaries gives the warning twice. For the test in comment #8, I get
[macbook] f90/bug% gfc -Warray-temporaries -fcheck=all pr40850_3.f90 pr40850_3.f90:11.13: CALL test ((/ lines /)) 1 Warning: Creating array temporary at (1) pr40850_3.f90:11.13: CALL test ((/ lines /)) 1 Warning: Creating array temporary at (1) [macbook] f90/bug% a.out a.out(35149) malloc: *** error for object 0x100201010: pointer being freed was not allocated *** set a breakpoint in malloc_error_break to debug Abort -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40850