インテル® Fortran コンパイラー XE 13.1 ユーザー・リファレンス・ガイド
Statement: Rewrites the current record.
Formatted:
REWRITE (eunit, format[, iostat] [, err]) [io-list]
Unformatted:
REWRITE (eunit[, iostat][ , err]) [io-list]
eunit |
Is an external unit specifier ([UNIT=]io-unit). |
format |
Is a format specifier ([FMT=]format). |
iostat |
Is a status specifier (IOSTAT=i-var). |
err |
Is a branch specifier (ERR=label) if an error condition occurs. |
io-list |
Is an I/O list. |
In the REWRITE statement, data (translated if formatted; untranslated if unformatted) is written to the current (existing) record in a file with direct access.
The current record is the last record accessed by a preceding, successful sequential or direct-access READ statement.
Between a READ and REWRITE statement, you should not specify any other I/O statement (except INQUIRE) on that logical unit. Execution of any other I/O statement on the logical unit destroys the current-record context and causes the current record to become undefined.
Only one record can be rewritten in a single REWRITE statement operation.
The output list (and format specification, if any) must not specify more characters for a record than the record size. (Record size is specified by RECLin an OPEN statement.)
If the number of characters specified by the I/O list (and format, if any) do not fill a record, blank characters are added to fill the record.