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: "burnus at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 2 Jun 2008 14:43:14 -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 #1 from burnus at gcc dot gnu dot org 2008-06-02 14:43 -------
Jerry, is this patch inserted at the right place or is there a better place?
Where do you think one should modify in order to get g0 working (PR36420 /
F2008)?
Index: libgfortran/io/write.c
===================================================================
--- libgfortran/io/write.c (Revision 136271)
+++ libgfortran/io/write.c (Arbeitskopie)
@@ -340,7 +340,11 @@ write_decimal (st_parameter_dt *dtp, con
char itoa_buf[GFC_BTOA_BUF_SIZE];
w = f->u.integer.w;
- m = f->u.integer.m;
+
+ if (f->format == FMT_G)
+ m = 0;
+ else
+ m = f->u.integer.m;
n = extract_int (source, len);
--
burnus at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jvdelisle at gcc dot gnu dot
| |org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36421