HP Fortran Programmer's Reference (September 2007)

Program units and procedures
Arguments
Chapter 7172
Arrays
Derived types
Pointers
Procedure names
Scalar dummy argument
If the dummy argument is a scalar, the corresponding actual argument must be a scalar or a
scalar expression, of the same kind and type. If the dummy argument is a character variable
and has assumed length, it inherits the length of the actual argument. Otherwise, the length
of the actual argument must be at least that of the dummy argument, and only the characters
within the range of the dummy argument can be accessed by the subprogram. Lengths may
differ for default character types only.
Array dummy argument
If the dummy argument is an assumed-shape array, the corresponding actual argument must
match in kind, type, and rank; the dummy argument takes its shape from the actual
argument, resulting in an element-by-element association between the actual and dummy
arguments.
If the dummy argument is an explicit-shape or assumed-size array, the kind and type of the
actual argument must match but the rank need not. The elements are sequence
associated—that is, the actual and dummy arguments are each considered to be a linear
sequence of elements in storage without regard to rank or shape, and corresponding elements
in each sequence are associated with each other in array element order.
A consequence of sequence association is that the overall size of the actual argument must be
at least that of the dummy argument, and only elements within the overall size of the dummy
argument can be accessed by referenced procedure.
For example, if an actual argument has this declaration:
REAL a(0:3,0:2)
and the corresponding dummy argument has this declaration:
REAL d(2,3,2)
then the correspondence between elements of the actual and dummy arguments is as follows:
Dummy <=> Actual
-------------------
d(1,1,1) <=> a(0,0)
d(2,1,1) <=> a(1,0)
d(1,2,1) <=> a(2,0)