Sun Studio 12 Update 1: Fortran User's Guide

2.3.1.1 The C Directive

The C() directive specifies that its arguments are external functions.It is equivalent to an EXTERNAL declaration except that unlike ordinary external names, the Fortran compiler will not append an underscore to these argument names. See the C-Fortran Interface chapter in the Fortran Programming Guide for more details.

The C() directive for a particular function should appear before the first reference to that function in each subprogram that contains such a reference.

Example - compiling ABC and XYZ for C:


       EXTERNAL ABC, XYZ
C$PRAGMA C(ABC, XYZ)