[all-commits] [llvm/llvm-project] d6b757: [flang] Fix INQUIRE(PAD=) and (POSITION=) for pred...
Peter Klausler via All-commits
all-commits at lists.llvm.org
Wed Nov 17 16:27:51 PST 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: d6b7576f210b6962de757c733c68fe8e96e9c760
https://github.com/llvm/llvm-project/commit/d6b7576f210b6962de757c733c68fe8e96e9c760
Author: Peter Klausler <pklausler at nvidia.com>
Date: 2021-11-17 (Wed, 17 Nov 2021)
Changed paths:
M flang/runtime/io-stmt.cpp
M flang/runtime/unit.cpp
Log Message:
-----------
[flang] Fix INQUIRE(PAD=) and (POSITION=) for predefined units
The predefined units were not being initialized with FORM='FORMATTED',
so INQUIRE(PAD=) was failing if no I/O had already been done.
INQUIRE(POSITION=) was returning 'REWIND' on stdin/stdout (which
is somewhat defensible from the definition, and is what Intel Fortran
does), but most implementations return 'ASIS'. Change the runtime
to return 'REWIND' only for positionable external files, but 'ASIS'
for terminals, sockets, &c.
Differential Revision: https://reviews.llvm.org/D114028
More information about the All-commits
mailing list