[Bug fortran/70235] New: Incorrect output with PF format
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70235 Bug ID: 70235 Summary: Incorrect output with PF format Product: gcc Version: 4.8.2 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: agardeux.ge at gmail dot com Target Milestone: --- Consider the following formatted output using PF format: program fmt implicit none real*8 y y = 1.0e4 print '(a, -6PF8.3)', '-6PF8.3 y = ', y end program fmt gfortran 4.8.2 and 4.9.3 give an incorrect result: -6PF8.3 y = Tested with: GNU Fortran (Ubuntu 4.8.2-19ubuntu1) 4.8.2 GNU Fortran (GCC) 4.9.3 The output is correct with gfortran 4.4.7: -6PF8.3 y =0.010 Tested with: GNU Fortran (GCC) 4.4.7 20120313 (Red Hat 4.4.7-11)
[Bug fortran/70237] New: Incorrect 0.0 output with PF format
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70237 Bug ID: 70237 Summary: Incorrect 0.0 output with PF format Product: gcc Version: 4.9.3 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: agardeux.ge at gmail dot com Target Milestone: --- Consider the following formatted output using PF format: program zero_pf_fmt print '(a, -6PF8.3)', '-6PF8.3 0.0 = ', 0.0 end program zero_pf_fmt gfortran 4.9.3 gives an incorrect result (wrong number of digits): -6PF8.3 0.0 = .000 Tested with: GNU Fortran (GCC) 4.9.3 The output is correct with gfortran 4.4.7: -6PF8.3 0.0 =0.000 Tested with: GNU Fortran (GCC) 4.4.7 20120313 (Red Hat 4.4.7-11)
[Bug fortran/70235] [4.9/5/6 Regression] Incorrect output with PF format
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70235 --- Comment #3 from Antoine Gardeux --- Thanks for the quick confirmation. Since this kind of format is widely used in our code base, it would be very tedious to change all the occurrences. Is there any other way to work around this issue ? Thanks again for your help.