- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
say I have the following data in a text file:
0.0 0.0 20.00 0. 1. 0. 0.
and that I read it with the following statement:
READ(1,40)PSL,RANGE,TRIM,LIST,RDCH,CHARTF,CHARTS
40 FORMAT(7F10.2)
I know that the text in the text file does not exactly match the format descriptor, but this was not a problem in previous versions of the intel fortran compiler, it would read the data in just fine. Now it won't read it in unless I reformat my input decks to explicitly match the format descriptor.
Is this a compiler setting that got changed?
I noticed that a lot of the debug compiler flags were changed....which was a big headache.
Eric
Link Copied
- « Previous
-
- 1
- 2
- Next »
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In retrospect, you invited trouble by using a flawed verification procedure.
In the program, you have I/O statements with ERR= and IOSTAT= clauses, but you ignore the IOSTAT value and the ERR= simply leads to RETURN. Had you used plain I/O statements without these clauses, even the FPS4 compiler would have flagged at least some of the errors that we have uncovered in this thread.
Intel Fortran gives the following error with input1.txt:
forrtl: severe (61): format/variable-type mismatch, unit 11, file T:\LANG\bowma\F90\input1.txt
Gfortran gives more detailed diagnostics:
At line 69 of file eb.f90 (unit = 11, file = 'input1.txt')
Fortran runtime error: Expected REAL for item 9 in formatted transfer, got INTEGER
(//7F10.2//7F10.2//7F10.2)
^

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- « Previous
-
- 1
- 2
- Next »