[Bug fortran/19543] New: formated output for logical(8) variables fails
coudert at clipper dot ens dot fr
gcc-bugzilla@gcc.gnu.org
Thu Jan 20 10:31:00 GMT 2005
When outputing a logical(8) variable, the output can be 'T' even if the variable
is set to .FALSE.! Here is a testcase!
program test
implicit none
logical(4), parameter :: l4 = .FALSE.
logical(8), parameter :: l8 = .FALSE.
print *, l4, l8
print *, 'foo', l8
if (l8) print *, 'l8 is true'
end
This produces the two lines:
F T
foo T
which is, of course, not right! What is troubling me is that removing any of the
print statements induces a correct output for the other (and, in fact, removing
the 'foo' string induces correct output).
This bug occurs on i686-linux. This reduced snippet has been worked out from a
code that fails in a similar way on i686-mingw
(http://home.comcast.net/~kmbtib/gfortran_bugs/REF_JVB_GFTN_002.html).
--
Summary: formated output for logical(8) variables fails
Product: gcc
Version: 4.0.0
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: coudert at clipper dot ens dot fr
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19543
More information about the Gcc-bugs
mailing list