Order of Referencing

Assume two procedures, PROC_ONE and PROC_TWO, make references to each other, and PROC_ONE appears before PROC_TWO in the source code. Before PROC_ONE is declared, the following FORWARD REFERENCE declaration must appear:

PROCEDURE PROC_TWO; FORWARD

When PROC_ONE calls PROC_TWO, the compiler recognizes the second procedure. Later in the program, the second procedure, PROC_TWO, is declared in full.

Similar methods are used for mutually referencing interrupts, switch labels, structure block types, and connection block types.