HP Fortran Programmer's Reference (September 2007)

HP Fortran statements
READ
Chapter 10442
specifies the label of the executable statement to which control passes if an
end-of-record condition is encountered. This specifier may appear in
io-specifier-list
only if ADVANCE='NO' also appears in the list.
IOSTAT=
integer-variable
returns the I/O status after the statement executes. If the statement
successfully executes,
integer-variable
is set to zero. If an end-of-file
record is encountered without an error condition, it is set to a negative
integer. If an error occurs,
integer-variable
is set to a positive integer
that indicates which error occurred.
REC=
integer-expression
specifies the number of the record to be read from a file connected for direct
access. This specifier cannot appear in
io-specifier-list
with the NML=,
ADVANCE=, SIZE=, and EOR= specifiers, nor with FMT=* (for list-directed I/O).
SIZE=
integer-variable
returns the number of characters that have been read by this READ
statement. This specifier may appear in
io-specifier-list
only if
ADVANCE='NO' also appears in the list.
input-list
is a comma-separated list of data items for input. The data items can
include variables and implied-DO lists.
format
is one of the following:
An asterisk (*), specifying list-directed I/O.
The label of a FORMAT statement containing the format specification.
An integer variable that has been assigned the label of a FORMAT
statement.
An embedded format specification.
name
is the name of a namelist group, as previously defined by a NAMELIST
statement. Using the namelist-directed syntax, the READ statement takes its
input from standard input. To read from a connected file, you must use the
NML= specifier with the full syntax form, as described below.