$ cat cio.f program cio complex a a = cmplx(1.0, 2.0) print '(1P,E13.5)',a end $ gfortran cio.f $ ./a.out 1.00000E+00 2.00000E+00 $ g77 cio.f $ ./a.out 1.00000E+00 2.00000E+00 $ gfortran -v Reading specs from /home/ig25/lib/gcc/i686-pc-linux-gnu/4.0.0/specs Configured with: ../gcc/configure --prefix=/home/ig25 --enable-languages=c,c++,f95 Thread model: posix gcc version 4.0.0 20041218 (experimental) Possibly related to PR 10964.
What I meant was that the bug is possibly related to PR 19064.
patch here http://gcc.gnu.org/ml/fortran/2004-12/msg00224.html
Subject: Bug 19071 CVSROOT: /cvs/gcc Module name: gcc Changes by: bdavis@gcc.gnu.org 2004-12-24 00:29:08 Modified files: gcc/testsuite : ChangeLog libgfortran : ChangeLog libgfortran/io : transfer.c Added files: gcc/testsuite/gfortran.dg: complex_write.f90 Log message: 2004-12-23 Bud Davis <bdavis9659@comcast.net> PR fortran/19071 * io/tranfer.c (formatted_transfer): moved check for format reversion inside the processing loop. * gfortran.dg/complex_write.f90: New test. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gfortran.dg/complex_write.f90.diff?cvsroot=gcc&r1=NONE&r2=1.1 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.4813&r2=1.4814 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/ChangeLog.diff?cvsroot=gcc&r1=1.140&r2=1.141 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/io/transfer.c.diff?cvsroot=gcc&r1=1.22&r2=1.23
Fixed.