diff options
author | Jerry DeLisle <jvdelisle@gcc.gnu.org> | 2018-01-14 17:36:29 +0000 |
---|---|---|
committer | Jerry DeLisle <jvdelisle@gcc.gnu.org> | 2018-01-14 17:36:29 +0000 |
commit | 33b2b069c16e53592936095575852e3fe7b43ec3 (patch) | |
tree | 56e6600d935c8537f8408bd9db589bd479cc5a07 /gcc | |
parent | a61bac1ea9a971fa76a7c3770da13638e3839592 (diff) | |
download | gcc-33b2b069c16e53592936095575852e3fe7b43ec3.zip gcc-33b2b069c16e53592936095575852e3fe7b43ec3.tar.gz gcc-33b2b069c16e53592936095575852e3fe7b43ec3.tar.bz2 |
re PR libfortran/83811 (fortran 'e' format broken for single digit exponents)
2018-01-18 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR libgfortran/83811
* write.c (select_buffer): Adjust buffer size up by 1.
* gfortran.dg/fmt_e.f90: New test.
From-SVN: r256669
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/testsuite/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/testsuite/gfortran.dg/fmt_e.f90 | 10 |
2 files changed, 15 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 143d59c..dfc1345 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2018-01-18 Jerry DeLisle <jvdelisle@gcc.gnu.org> + + PR libgfortran/83811 + * gfortran.dg/fmt_e.f90: New test. + 2018-01-14 H.J. Lu <hongjiu.lu@intel.com> * gcc.target/i386/indirect-thunk-10.c: New test. diff --git a/gcc/testsuite/gfortran.dg/fmt_e.f90 b/gcc/testsuite/gfortran.dg/fmt_e.f90 new file mode 100644 index 0000000..a85506b --- /dev/null +++ b/gcc/testsuite/gfortran.dg/fmt_e.f90 @@ -0,0 +1,10 @@ +! { dg-do run } +! PR83811 fortran 'e' format broken for single digit exponents +program test + character(25) :: s + write(s, '(1pe5.0e1)') 1.e-4 + if (s.ne."1.E-4") call abort + write(s, '(e5.1e1)') 1.e12 + if (s.ne."*****") call abort +end + |