Visible to Intel only — GUID: GUID-0BE2900A-ED98-45A2-9B8C-F5736A83ECC1
Visible to Intel only — GUID: GUID-0BE2900A-ED98-45A2-9B8C-F5736A83ECC1
Defined Operations
When operators are defined for functions, the functions can then be referenced as defined operations.
The operators are defined by using a generic interface block specifying OPERATOR, followed by the defined operator (in parentheses).
A defined operation is not an intrinsic operation. However, you can use a defined operation to extend the meaning of an intrinsic operator.
For defined unary operations, the function must contain one argument. For defined binary operations, the function must contain two arguments.
Interpretation of the operation is provided by the function that defines the operation.
A Standard Fortran defined operator can contain up to 31 letters, and is enclosed in periods (.), or it may be an intrinsic operator.
An intrinsic operator can be followed by a defined unary operator.
The result of a defined operation can have any type. The type of the result (and its value) must be specified by the defining function.
Examples
The following examples show expressions containing defined operators:
.COMPLEMENT. A X .PLUS. Y .PLUS. Z M * .MINUS. N