Does gfortran support ACCESS='APPEND'?

Richard E Maine Richard.Maine@nasa.gov
Fri Aug 19 17:28:00 GMT 2005


On Aug 19, 2005, at 3:41 AM, Jack Howarth wrote:

> The problem seemed to be that the ACCESS='APPEND' causes a run-time 
> error

Let me note that the standard form is POSITION='APPEND', though that 
does not directly address what I perceive to be your main question.

> Shouldn't gfortran be doing the same? That is
> generating a compile-time rather than a run-time error on 
> ACCESS='APPEND'?

Note that it is not possible to generate compile-time errors for all 
cases of invalid ACCESS= specifiers (or many other similar specifiers). 
That's because ACCESS=char-variable (or more generally char-expression) 
is allowed and the variable value is not necessarily known at compile 
time.

Thus, while I can see it as a nice feature to catch some cases at 
compile time (and that will, in practice include a large portion of the 
cases where such things will occur), such compile-time diagnosis has to 
be in addition to a run-time catch - not a replacement for it.

-- 
Richard Maine                |  Good judgment comes from experience;
Richard.Maine@nasa.gov       |  experience comes from bad judgment.
                             |        -- Mark Twain



More information about the Fortran mailing list