(j3.2006) actual arguments of intrinsic functions
Robert Corbett
Robert.Corbett at Sun.COM
Tue May 12 03:47:35 EDT 2009
Thanks to the responses of Bill Long and Michael Ingrassia,
I am convinced that the Fortran standard requires the actual
arguments in almost all references of intrinsic procedures
to be data entities. The exceptions are function references
that invoke the intrinsic functions ASSOCIATED and NULL with
actual arguments that are procedures.
As Michael noted, in the case of the inquiry function LEN,
the standard requires the actual argument corresponding to
dummy argument STRING to be a scalar or an array. A
function name does not denote a scalar or an array, it
denotes a function, and so the actual argument cannot be a
function name. The compilers that allow functions that
return values of type CHARACTER as actual arguments to LEN
are extending the language in a manner permitted by the
Fortran standard.
Bob Corbett
More information about the J3
mailing list