Fortran provides various mechanisms by which the declarations of the dummy arguments within the called procedure can be made available to the caller while it is constructing the actual argument list. An explicit interface call is one to the following:
a module procedure
an internal procedure
an external procedure for which an interface block is provided
In this form of call the construction of the actual argument list is controlled by the declarations of the dummy arguments, rather than by the characteristics of the actual arguments. As in an implicit interface call, all arguments (apart from label arguments) are passed by address, but the form of the address is controlled by attributes of the associated dummy argument, see the table below.
Argument |
Address Passed |
scalar |
the address of the scalar |
assumed-shape array |
the address of an internal data structure which describes the actual argument |
other arrays |
the address of the first element of the actual array |
scalar pointer |
the address of the pointer |
array pointer |
the address of an internal data structure which describes the pointer's target |
procedure |
the address associated with the external name |
As in an implicit interface call, arguments of type character are passed as a character descriptor, described in Character Types.
Intel reserves the right to alter or modify the form of the internal data used to pass assumed-shape arrays and pointers to arrays. It is therefore not recommended that interfaces using these forms of argument are to be compiled with other than Intel® Fortran Compiler.
The call on an explicit interface need not associate an actual argument with a dummy argument if the dummy argument has the optional attribute. An optional argument that is not present for a particular call to a routine has a placeholder value passed instead of its address. The place-holder value for optional arguments is always -1.