diff options
author | Tobias Schlüter <tobias.schlueter@physik.uni-muenchen.de> | 2004-12-02 20:39:15 +0100 |
---|---|---|
committer | Tobias Schlüter <tobi@gcc.gnu.org> | 2004-12-02 20:39:15 +0100 |
commit | abd7fea9f9afbe42fbaad073dab52e7d78640543 (patch) | |
tree | 05580d191473440752eaeddfac5929d59504e771 /gcc | |
parent | 0396df8ac45acfbace58f00234eed18303387b7b (diff) | |
download | gcc-abd7fea9f9afbe42fbaad073dab52e7d78640543.zip gcc-abd7fea9f9afbe42fbaad073dab52e7d78640543.tar.gz gcc-abd7fea9f9afbe42fbaad073dab52e7d78640543.tar.bz2 |
re PR libfortran/18710 (img part of complex number not written to direct access file)
libgfortran/
PR fortran/18710
* io/transfer.c (unformatted_read, unformatted_write): width of
a COMPLEX is twice its kind.
gcc/testsuite/
PR fortran/18170
* gfortran.dg/direct_io_3.f90: New test.
From-SVN: r91656
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/testsuite/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/testsuite/gfortran.dg/direct_io_3.f90 | 20 |
2 files changed, 25 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 42c4c5b..7cb1ad6 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2004-12-02 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de> + + PR fortran/18170 + * gfortran.dg/direct_io_3.f90: New test. + 2004-12-02 Nathan Sidwell <nathan@codesourcery.com> PR 18758 diff --git a/gcc/testsuite/gfortran.dg/direct_io_3.f90 b/gcc/testsuite/gfortran.dg/direct_io_3.f90 new file mode 100644 index 0000000..8603a83 --- /dev/null +++ b/gcc/testsuite/gfortran.dg/direct_io_3.f90 @@ -0,0 +1,20 @@ +! { dg-do run } +! PR 18710 : We used to not read and write the imaginary part of +! complex numbers + COMPLEX C, D + DOUBLE COMPLEX E, F + + OPEN(UNIT=9,FILE='PR18710',ACCESS='DIRECT',RECL=132) + + C = (120.0,240.0) + WRITE(9,REC=1)C + READ(9,REC=1)D + if (c /= d) call abort() + + E = (120.0,240.0) + WRITE(9,REC=1)E + READ(9,REC=1)F + if (E /= F) call abort() + + CLOSE(UNIT=9,STATUS='DELETE') + END |