HP Fortran Programmer's Reference (September 2007)

Program units and procedures
Procedure interface
Chapter 7 181
Procedure interface
A procedure interface is the information specified in a procedure reference, including the
name of the procedure, the arguments, and (if the procedure is a function) the result. If the
interface is explicit, all of the characteristics of the arguments and the result—type, kind,
attributes, and number—are defined within the scope of the reference. If the interface is
implicit, the compiler may be able to make sufficient assumptions about the interface to
permit the procedure reference.
All procedure interfaces are implicit except for the following:
Intrinsic procedure
Internal procedure
Module procedure
Recursive function that specifies a result clause
External procedure whose interface is declared in an interface block
An explicit interface is required when:
The procedure reference uses the keyword form of an actual argument.
The procedure has OPTIONAL arguments.
Any dummy argument is an assumed-shape array or a pointer.
The result of a function is array-valued or a pointer.
The procedure is a character function, the length of which is determined dynamically.
The procedure reference is to a generic name.
The procedure reference implements a user-defined operator or assignment.
The procedure has the same name as an intrinsic procedure, but you want it to have
precedence over the intrinsic; see “Availability of intrinsics” on page 503.
You want the compiler to perform argument-checking at compile-time.
The following sections describe the interface block and its use for creating:
Generic procedures
Defined operators
Defined assignment