This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libfortran/37753] New: [4.4 Regression] Convert="BIG_ENDIAN" reverses character
- From: "tkoenig at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 6 Oct 2008 19:32:43 -0000
- Subject: [Bug libfortran/37753] New: [4.4 Regression] Convert="BIG_ENDIAN" reverses character
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
>From http://gcc.gnu.org/ml/fortran/2008-10/msg00045.html :
$ cat foo.f90
character(len=16) :: string, string2
string='BIG_ENDIAN'
open(unit=13,form='unformatted',file='gftest.dat',convert='big_endian',status='UNKNOWN')
write(13) string
close(13)
end
$ gfortran foo.f90
$ ./a.out
$ od -t x1 -t a gftest.dat
0000000 00 00 00 10 20 20 20 20 20 20 4e 41 49 44 4e 45
nul nul nul dle sp sp sp sp sp sp N A I D N E
0000020 5f 47 49 42 00 00 00 10
_ G I B nul nul nul dle
0000030
--
Summary: [4.4 Regression] Convert="BIG_ENDIAN" reverses character
Product: gcc
Version: 4.4.0
Status: UNCONFIRMED
Keywords: wrong-code
Severity: major
Priority: P3
Component: libfortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: tkoenig at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37753