[gfortran] Fix list directed reads of real number

Steven Bosscher stevenb@suse.de
Wed Dec 15 10:35:00 GMT 2004


On Wednesday 15 December 2004 06:22, Bud Davis wrote:
> when reading
>
> "10,20,30"
>
> as REAL values, list directed, we were not eating the comma, so the
> next value was seeing a comma as it's first character, so it was
> unchanged. problem only occurred when parsing the first part of
> a real without a decimal point, " 10.0,20.0,30.0 " was OK.
>
>
> this patch handles this situation.  i added some more tests to the file,
> including one for " 10,,20,30 " which handles the null value
> list directed read.
>
>
> both steve and myself were on the same line of code, just slightly
> different fixes.
>
>
> No additional regressions, no changes in NIST F77 test results.
> Tested i686/gnu/linux FC2.

Yay!  Thanks for the explanation, now at least we know *what* was wrong.

> --bud
>
>
> 2004-12-15  Bud Davis  <bdavis9659@comcast.net>
>             Steven G. Kargl  <kargls@comcast.net>
>
> 	* io/list_read.c (read_real): do not push back a comma when
> 	it delimits a real value without a decimal point

OK of course :-)

Gr.
Steven



More information about the Fortran mailing list