next up previous contents
Next: Specification of Data Type Up: C Language Bindings Previous: C Language Bindings

Specification of Interfaces to Procedures Defined in C

If a user wishes to specify that a procedure is defined by a C procedure, this is specified with an extrinsic-spec-arg of LANGUAGE = "0DC"0D, or an extrinsic-kind-keyword of C, as specified in Section 6.

For C subprograms for which EXTRINSIC (LANGUAGE = "0DC"0D) has been specified, the constraints associated with the syntax for attr-spec-extended (H1102) are extended as follows:

The value of the scalar-char-initialization-expr in the EXTERNAL_NAME specifier gives the name of the procedure as defined in C. This value need not be the same as the procedure name specified by the function-stmt or subroutine-stmt. If EXTERNAL_NAME is not specified, it is as if it were specified with a value that is the same as the procedure name in lower case letters.

The extrinsic-spec-arg of LANGUAGE = "0DC"0D helps a compiler identify a procedure that is defined in C so that it can take appropriate steps to ensure that the procedure is invoked in the manner required by the C compiler.


next up previous contents
Next: Specification of Data Type Up: C Language Bindings Previous: C Language Bindings