This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [gfortran] PR libfortran/21376


Well, we can't test for the same error, but we can verify that the output is
indeed correct.  This is what I meantt the testcase should be for.

Commited the attached testcase.


FX
! { dg-do run }
! PR 21376
! we used to take the logarithm of zero in this special case
  character*10 c
  write (c,'(e10.4)') 1.0
  if(c /= "0.1000E+01") call abort
  write (c,'(e10.4)') 0.0
  if(c /= "0.0000E+00") call abort
  write (c,'(e10.4)') 1.0d100
  if(c /= "0.1000+101") call abort
  write (c,'(e10.4)') 1.0d-102
  if(c /= "0.1000-101") call abort
end

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]