llvm-project icon indicating copy to clipboard operation
llvm-project copied to clipboard

Missing APPEND in ACCESS specifier of OPEN statement

Open oroppas opened this issue 5 years ago • 1 comments

Bugzilla Link 50240
Version trunk
OS Linux
CC @jeanPerier,@kiranktp,@sscalpone

Extended Description

Here's the minimal reproducer

program main lu = 60 open(lu,file='dcp.out',status='old',access='append',err=10) 10 continue end program main

flang-new -fc1 main.f90

./main.f90:3:48: error: Invalid ACCESS value 'append' open(lu,file='dcp.out',status='old',access='append',err=10) ^^^^^^^^ error: Semantic errors in main.f90

oroppas avatar May 06 '21 07:05 oroppas

Hi! ACCESS=APPEND is actually not mentioned in the standard, but some compilers implement it as an extension (as an alias for POSITION=APPEND, leaving ACCESS at the default SEQUENTIAL). This extension was implemented in flang as well, in https://reviews.llvm.org/D102350. I can run your reproducer without error. I will close this issue, but please test it on your side, and do not hesitate to reopen if this does not solve your problem.

ekieri avatar Apr 13 '22 16:04 ekieri