Intel® Fortran Compiler 16.0 User and Reference Guide

Interoperability of Procedures and Procedure Interfaces

A Fortran procedure is interoperable if it has the BIND attribute.

A Fortran procedure interface is interoperable with a C function prototype if the following is true:

In an invocation of an interoperable procedure whose Fortran interface has an assumed-shape or assumed-rank dummy argument with the CONTIGUOUS attribute, the associated effective argument can be an array that is not contiguous or it can be the address of a C descriptor for such an array.

If the procedure is invoked from Fortran or the procedure is a Fortran procedure, the Fortran processor will handle the difference in contiguity.

If the procedure is invoked from C or the procedure is a C procedure, the C code within the procedure must be able to handle the situation of receiving a discontiguous argument.

An actual argument that is absent in a reference to an interoperable procedure is indicated by a corresponding formal parameter with the value of a null pointer. An optional dummy argument that is absent in a reference to an interoperable procedure from a C function is indicated by a corresponding argument with the value of a null pointer.

The following rules also apply: