public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libfortran/25425]  New: F95 and F2003 differ on list-directed output for 0.0
@ 2005-12-15  9:13 fxcoudert at gcc dot gnu dot org
  2006-01-10  4:35 ` [Bug libfortran/25425] " pinskia at gcc dot gnu dot org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2005-12-15  9:13 UTC (permalink / raw)
  To: gcc-bugs

It seems that, according to F95, list-directed formatting of zero must behave
as if formatted with the E descriptor (0.0E+00) while F2003 requires an F
format behaviour (0.0). See message
<1134632379.672465.126120@z14g2000cwz.googlegroups.com> on comp.lang.fortran
("writing formatted zeros with implicit formats", by robert.corbett@sun.com).

We currently implement the F2003 behaviour, independently of the -std flag.

$ cat a.f
      PROGRAM MAIN
        PRINT *, -2.1, -1.2, 0.0, 1.1, 2.2
      END
$ gfortran a.f && ./a.out
  -2.100000      -1.200000       0.000000       1.100000       2.200000    
$ ifort a.f && ./a.out
  -2.100000      -1.200000      0.0000000E+00   1.100000       2.200000


-- 
           Summary: F95 and F2003 differ on list-directed output for 0.0
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libfortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: fxcoudert at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25425


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libfortran/25425] F95 and F2003 differ on list-directed output for 0.0
  2005-12-15  9:13 [Bug libfortran/25425] New: F95 and F2003 differ on list-directed output for 0.0 fxcoudert at gcc dot gnu dot org
@ 2006-01-10  4:35 ` pinskia at gcc dot gnu dot org
  2006-01-29 22:06 ` jvdelisle at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-01-10  4:35 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from pinskia at gcc dot gnu dot org  2006-01-10 04:35 -------
Confirmed.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
OtherBugsDependingO|                            |20585
              nThis|                            |
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2006-01-10 04:35:27
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25425



^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libfortran/25425] F95 and F2003 differ on list-directed output for 0.0
  2005-12-15  9:13 [Bug libfortran/25425] New: F95 and F2003 differ on list-directed output for 0.0 fxcoudert at gcc dot gnu dot org
  2006-01-10  4:35 ` [Bug libfortran/25425] " pinskia at gcc dot gnu dot org
@ 2006-01-29 22:06 ` jvdelisle at gcc dot gnu dot org
  2006-02-06 21:31 ` fxcoudert at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: jvdelisle at gcc dot gnu dot org @ 2006-01-29 22:06 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from jvdelisle at gcc dot gnu dot org  2006-01-29 22:06 -------
I will start on this.


-- 

jvdelisle at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |jvdelisle at gcc dot gnu dot
                   |dot org                     |org
             Status|NEW                         |ASSIGNED
   Last reconfirmed|2006-01-10 04:35:27         |2006-01-29 22:06:15
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25425


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libfortran/25425] F95 and F2003 differ on list-directed output for 0.0
  2005-12-15  9:13 [Bug libfortran/25425] New: F95 and F2003 differ on list-directed output for 0.0 fxcoudert at gcc dot gnu dot org
  2006-01-10  4:35 ` [Bug libfortran/25425] " pinskia at gcc dot gnu dot org
  2006-01-29 22:06 ` jvdelisle at gcc dot gnu dot org
@ 2006-02-06 21:31 ` fxcoudert at gcc dot gnu dot org
  2006-02-07  5:46 ` jvdelisle at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2006-02-06 21:31 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from fxcoudert at gcc dot gnu dot org  2006-02-06 21:31 -------
Sorry to interfere, Jerry, but I had some time and decided to write that patch.
If you already had a patch for this, I'd be interested in knowing the approach
you chose.


-- 

fxcoudert at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                URL|                            |http://gcc.gnu.org/ml/fortra
                   |                            |n/2006-02/msg00110.html
           Keywords|                            |patch


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25425


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libfortran/25425] F95 and F2003 differ on list-directed output for 0.0
  2005-12-15  9:13 [Bug libfortran/25425] New: F95 and F2003 differ on list-directed output for 0.0 fxcoudert at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2006-02-06 21:31 ` fxcoudert at gcc dot gnu dot org
@ 2006-02-07  5:46 ` jvdelisle at gcc dot gnu dot org
  2006-02-08 20:54 ` fxcoudert at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: jvdelisle at gcc dot gnu dot org @ 2006-02-07  5:46 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from jvdelisle at gcc dot gnu dot org  2006-02-07 05:46 -------
(In reply to comment #3)
> Sorry to interfere, Jerry, but I had some time and decided to write that patch.
> If you already had a patch for this, I'd be interested in knowing the approach
> you chose.
> 
Not a problem, I only had a first look at this and calculate G format caught my
attention, that was as far as I got.  I was going to have to study the -std
flag stuff to see where to go there.  Glad to see you in action!


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25425


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libfortran/25425] F95 and F2003 differ on list-directed output for 0.0
  2005-12-15  9:13 [Bug libfortran/25425] New: F95 and F2003 differ on list-directed output for 0.0 fxcoudert at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2006-02-07  5:46 ` jvdelisle at gcc dot gnu dot org
@ 2006-02-08 20:54 ` fxcoudert at gcc dot gnu dot org
  2006-02-14 14:50 ` [Bug libfortran/25425] [4.1 only] " fxcoudert at gcc dot gnu dot org
  2006-02-14 14:52 ` fxcoudert at gcc dot gnu dot org
  6 siblings, 0 replies; 8+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2006-02-08 20:54 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from fxcoudert at gcc dot gnu dot org  2006-02-08 20:54 -------
Subject: Bug 25425

Author: fxcoudert
Date: Wed Feb  8 20:54:14 2006
New Revision: 110769

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=110769
Log:
        PR libfortran/25425

        * trans-decl.c (gfc_generate_function_code): Add new argument,
        pedantic, to set_std call.

        * libgfortran.h: Add pedantic field to compile_options struct.
        * io/write.c (calculate_G_format): Depending on the standard,
        choose E or F format for list-directed output of 0.0.
        * runtime/error.c (notify_std): Make warning and error dependent
        on pedanticity.
        * runtime/compile_options.c (set_std): Use new pedantic argument.

Modified:
    trunk/gcc/fortran/ChangeLog
    trunk/gcc/fortran/trans-decl.c
    trunk/libgfortran/ChangeLog
    trunk/libgfortran/io/write.c
    trunk/libgfortran/libgfortran.h
    trunk/libgfortran/runtime/compile_options.c
    trunk/libgfortran/runtime/error.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25425


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libfortran/25425] [4.1 only] F95 and F2003 differ on list-directed output for 0.0
  2005-12-15  9:13 [Bug libfortran/25425] New: F95 and F2003 differ on list-directed output for 0.0 fxcoudert at gcc dot gnu dot org
                   ` (4 preceding siblings ...)
  2006-02-08 20:54 ` fxcoudert at gcc dot gnu dot org
@ 2006-02-14 14:50 ` fxcoudert at gcc dot gnu dot org
  2006-02-14 14:52 ` fxcoudert at gcc dot gnu dot org
  6 siblings, 0 replies; 8+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2006-02-14 14:50 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from fxcoudert at gcc dot gnu dot org  2006-02-14 14:50 -------
Subject: Bug 25425

Author: fxcoudert
Date: Tue Feb 14 14:50:40 2006
New Revision: 110973

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=110973
Log:
        PR libfortran/25425

        * trans-decl.c (gfc_generate_function_code): Add new argument,
        pedantic, to set_std call.

        * libgfortran.h: Add pedantic field to compile_options struct.
        * io/write.c (calculate_G_format): Depending on the standard,
        choose E or F format for list-directed output of 0.0.
        * runtime/error.c (notify_std): Make warning and error dependent
        on pedanticity.
        * runtime/compile_options.c (set_std): Use new pedantic argument.

Modified:
    branches/gcc-4_1-branch/gcc/fortran/ChangeLog
    branches/gcc-4_1-branch/gcc/fortran/trans-decl.c
    branches/gcc-4_1-branch/libgfortran/ChangeLog
    branches/gcc-4_1-branch/libgfortran/io/write.c
    branches/gcc-4_1-branch/libgfortran/libgfortran.h
    branches/gcc-4_1-branch/libgfortran/runtime/compile_options.c
    branches/gcc-4_1-branch/libgfortran/runtime/error.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25425


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug libfortran/25425] [4.1 only] F95 and F2003 differ on list-directed output for 0.0
  2005-12-15  9:13 [Bug libfortran/25425] New: F95 and F2003 differ on list-directed output for 0.0 fxcoudert at gcc dot gnu dot org
                   ` (5 preceding siblings ...)
  2006-02-14 14:50 ` [Bug libfortran/25425] [4.1 only] " fxcoudert at gcc dot gnu dot org
@ 2006-02-14 14:52 ` fxcoudert at gcc dot gnu dot org
  6 siblings, 0 replies; 8+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2006-02-14 14:52 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from fxcoudert at gcc dot gnu dot org  2006-02-14 14:52 -------
Fixed on 4.2 and 4.1.


-- 

fxcoudert at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED
   Target Milestone|---                         |4.1.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25425


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2006-02-14 14:52 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-12-15  9:13 [Bug libfortran/25425] New: F95 and F2003 differ on list-directed output for 0.0 fxcoudert at gcc dot gnu dot org
2006-01-10  4:35 ` [Bug libfortran/25425] " pinskia at gcc dot gnu dot org
2006-01-29 22:06 ` jvdelisle at gcc dot gnu dot org
2006-02-06 21:31 ` fxcoudert at gcc dot gnu dot org
2006-02-07  5:46 ` jvdelisle at gcc dot gnu dot org
2006-02-08 20:54 ` fxcoudert at gcc dot gnu dot org
2006-02-14 14:50 ` [Bug libfortran/25425] [4.1 only] " fxcoudert at gcc dot gnu dot org
2006-02-14 14:52 ` fxcoudert at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).