public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/42422] New: Error in Fortran list directed input
@ 2009-12-18 2:54 palmtag5 at yahoo dot com
2009-12-18 2:55 ` [Bug fortran/42422] " palmtag5 at yahoo dot com
` (6 more replies)
0 siblings, 7 replies; 8+ messages in thread
From: palmtag5 at yahoo dot com @ 2009-12-18 2:54 UTC (permalink / raw)
To: gcc-bugs
An error occurs when arrays are read from the input using list-directed
input that uses a repeat(*) before a record terminator (/).
The repeat is ignored.
For example, reading an integer array dimensioned 10
integer :: imatrx(10)
...
read (*,*) imatrx
will give the wrong results when the input has a repeat before the record
terminator
1 2 3 4*5 /
Will read in the values as "1 2 3 5 x x x x x x"
instead of "1 2 3 5 5 5 5 x x x"
--
Summary: Error in Fortran list directed input
Product: gcc
Version: 4.3.2
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: palmtag5 at yahoo dot com
GCC build triplet: 4.3.2
GCC host triplet: 4.3.2
GCC target triplet: 4.3.2
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42422
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/42422] Error in Fortran list directed input
2009-12-18 2:54 [Bug fortran/42422] New: Error in Fortran list directed input palmtag5 at yahoo dot com
@ 2009-12-18 2:55 ` palmtag5 at yahoo dot com
2009-12-18 10:07 ` burnus at gcc dot gnu dot org
` (5 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: palmtag5 at yahoo dot com @ 2009-12-18 2:55 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from palmtag5 at yahoo dot com 2009-12-18 02:54 -------
Full example:
program test2
implicit none
integer :: imatr(20)
imatr=0
write (*,*) 'Enter 20 integer values:'
read (*,*) imatr
write (*,*) 'results:'
write (*,*) imatr
end
With input:
1 2 3 4*5 /
--
palmtag5 at yahoo dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |palmtag5 at yahoo dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42422
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/42422] Error in Fortran list directed input
2009-12-18 2:54 [Bug fortran/42422] New: Error in Fortran list directed input palmtag5 at yahoo dot com
2009-12-18 2:55 ` [Bug fortran/42422] " palmtag5 at yahoo dot com
@ 2009-12-18 10:07 ` burnus at gcc dot gnu dot org
2009-12-20 20:17 ` tkoenig at gcc dot gnu dot org
` (4 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: burnus at gcc dot gnu dot org @ 2009-12-18 10:07 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from burnus at gcc dot gnu dot org 2009-12-18 10:07 -------
Hmm, I cannot reproduce this with newer gfortran version. Using 4.2.1 I also
get:
1 2 3 5 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
however, already with 4.3.4 [gcc-4_3-branch revision 152973] I get:
1 2 3 5 5 5 5 0 0 0 0 0 0 0 0 0 0 0 0 0
which looks OK.
Can you try a newer GCC version? Current stable version is 4.4.2; previous
stable version is 4.3.4 (which is slightly but sufficiently newer than your
4.3.2). And the current developer version is 4.5, which is currently in stage 4
(only regression fixes) and will be released beginning next year. [Personal
educated guess: end of February.]
See also http://gcc.gnu.org/wiki/GFortranBinaries for obtaining a new binary.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42422
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/42422] Error in Fortran list directed input
2009-12-18 2:54 [Bug fortran/42422] New: Error in Fortran list directed input palmtag5 at yahoo dot com
2009-12-18 2:55 ` [Bug fortran/42422] " palmtag5 at yahoo dot com
2009-12-18 10:07 ` burnus at gcc dot gnu dot org
@ 2009-12-20 20:17 ` tkoenig at gcc dot gnu dot org
2009-12-20 20:33 ` kargl at gcc dot gnu dot org
` (3 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: tkoenig at gcc dot gnu dot org @ 2009-12-20 20:17 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from tkoenig at gcc dot gnu dot org 2009-12-20 20:17 -------
I can confirm this works on all supported versions.
Should we add a test case, then close this bug?
--
tkoenig at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |tkoenig at gcc dot gnu dot
| |org
Known to fail| |4.3.2
Known to work| |4.3.4 4.4.1 4.5.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42422
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/42422] Error in Fortran list directed input
2009-12-18 2:54 [Bug fortran/42422] New: Error in Fortran list directed input palmtag5 at yahoo dot com
` (2 preceding siblings ...)
2009-12-20 20:17 ` tkoenig at gcc dot gnu dot org
@ 2009-12-20 20:33 ` kargl at gcc dot gnu dot org
2009-12-20 20:57 ` jvdelisle at gcc dot gnu dot org
` (2 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: kargl at gcc dot gnu dot org @ 2009-12-20 20:33 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from kargl at gcc dot gnu dot org 2009-12-20 20:33 -------
(In reply to comment #3)
> I can confirm this works on all supported versions.
>
> Should we add a test case, then close this bug?
>
IMHO. Yes.
A new testcase is pre-approved provided it passes a
regression test. :-)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42422
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/42422] Error in Fortran list directed input
2009-12-18 2:54 [Bug fortran/42422] New: Error in Fortran list directed input palmtag5 at yahoo dot com
` (3 preceding siblings ...)
2009-12-20 20:33 ` kargl at gcc dot gnu dot org
@ 2009-12-20 20:57 ` jvdelisle at gcc dot gnu dot org
2009-12-21 23:14 ` tkoenig at gcc dot gnu dot org
2009-12-22 17:42 ` hjl dot tools at gmail dot com
6 siblings, 0 replies; 8+ messages in thread
From: jvdelisle at gcc dot gnu dot org @ 2009-12-20 20:57 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from jvdelisle at gcc dot gnu dot org 2009-12-20 20:57 -------
Thomas, let me know if you want me to do the test case.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42422
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/42422] Error in Fortran list directed input
2009-12-18 2:54 [Bug fortran/42422] New: Error in Fortran list directed input palmtag5 at yahoo dot com
` (4 preceding siblings ...)
2009-12-20 20:57 ` jvdelisle at gcc dot gnu dot org
@ 2009-12-21 23:14 ` tkoenig at gcc dot gnu dot org
2009-12-22 17:42 ` hjl dot tools at gmail dot com
6 siblings, 0 replies; 8+ messages in thread
From: tkoenig at gcc dot gnu dot org @ 2009-12-21 23:14 UTC (permalink / raw)
To: gcc-bugs
------- Comment #6 from tkoenig at gcc dot gnu dot org 2009-12-21 23:14 -------
Test case committed to trund and 4.4 branch.
Closing.
--
tkoenig at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42422
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/42422] Error in Fortran list directed input
2009-12-18 2:54 [Bug fortran/42422] New: Error in Fortran list directed input palmtag5 at yahoo dot com
` (5 preceding siblings ...)
2009-12-21 23:14 ` tkoenig at gcc dot gnu dot org
@ 2009-12-22 17:42 ` hjl dot tools at gmail dot com
6 siblings, 0 replies; 8+ messages in thread
From: hjl dot tools at gmail dot com @ 2009-12-22 17:42 UTC (permalink / raw)
To: gcc-bugs
--
hjl dot tools at gmail dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |4.3.4
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42422
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2009-12-22 17:42 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-12-18 2:54 [Bug fortran/42422] New: Error in Fortran list directed input palmtag5 at yahoo dot com
2009-12-18 2:55 ` [Bug fortran/42422] " palmtag5 at yahoo dot com
2009-12-18 10:07 ` burnus at gcc dot gnu dot org
2009-12-20 20:17 ` tkoenig at gcc dot gnu dot org
2009-12-20 20:33 ` kargl at gcc dot gnu dot org
2009-12-20 20:57 ` jvdelisle at gcc dot gnu dot org
2009-12-21 23:14 ` tkoenig at gcc dot gnu dot org
2009-12-22 17:42 ` hjl dot tools at gmail dot com
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).