Procedure-pointer and function-pointer relation conditions
Only EQUAL and NOT EQUAL are allowed as relational operators when specifying procedure-pointer or function-pointer data items in a relation condition.
Procedure-pointer data items are defined explicitly as USAGE PROCEDURE-POINTER. Function-pointer data items are defined explicitly as USAGE FUNCTION-POINTER.
The operands are equal if the two addresses used in the comparison would both result in the same storage location.
This relation condition is allowed in IF, PERFORM, EVALUATE, and SEARCH format-1 statements. It is not allowed in SEARCH format-2 (SEARCH ALL) statements, because there is no meaningful ordering that can be applied to procedure-pointer data items.
- identifier-1 , identifier-2
- Must be described as USAGE PROCEDURE-POINTER or USAGE FUNCTION-POINTER. identifier-1 and identifier-2 need not be described the same.
- NULL, NULLS
- Can be used only if the other operand is defined as USAGE FUNCTION-POINTER or USAGE PROCEDURE-POINTER. That is, NULL=NULL is not allowed.