This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/36421] Gw.d edit descriptor for integer numbers: Wrong output
- From: "jvdelisle at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 3 Jun 2008 02:16:01 -0000
- Subject: [Bug fortran/36421] Gw.d edit descriptor for integer numbers: Wrong output
- References: <bug-36421-13404@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from jvdelisle at gcc dot gnu dot org 2008-06-03 02:16 -------
Tobias, I think it needs to go farther down to just before here:
/* Select a width if none was specified. The idea here is to always
print something. */
The standard says to ignore the w.d in the G descriptor, so I think we want to
be past after this:
if (m == 0 && n == 0)
{
if (w == 0)
w = 1;
p = write_block (dtp, w);
if (p == NULL)
return;
memset (p, ' ', w);
goto done;
}
Otherwise w will get set to 1 and not get ignored.
Also you example uses a0 which is also rejected. I have a patch for that.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36421