When Format 5 of the SET statement is executed, the current value of the receiving field is replaced by the address value contained in the sending field.
SET Statement - Format 5 .------------------------------. V | >>-SET----+-identifier-4-------------+-+------------------------> '-ADDRESS OF--identifier-5-' >--TO--+-identifier-6-------------+---------------------------->< +-ADDRESS OF--identifier-7-+ +-NULL---------------------+ '-NULLS--------------------'
Must be described as USAGE IS POINTER.
This is the ADDRESS OF special register.
Must be a level-01 or level-77 item defined in the Linkage Section. It is set to the value of the operand specified in the TO phrase. It cannot be subscripted or reference modified.
Must be described as USAGE IS POINTER.
Must not contain an address within the program's own Working-Storage, Local-Storage or File sections.
Must be an item in the data division section of any level except 66 or 88.
ADDRESS OF identifier-7 contains the address of the identifier, rather than its contents. Identifier-7 can be subscripted, reference modified, or both.
Sets the receiving field to contain the value of an invalid address.