NET/MASTER Network Control Language (NCL) Programmer's Guide

Calling Procedures and Functions
Procedures and Functions
6–46 106160 Tandem Computers Incorporated
Procedure and Function
Name Syntax and Search
Order
You can specify the name of the procedure or function you want to call in three
different ways. The way in which you identify a procedure or function determines the
order in which NCL searches for it.
Procedure Name Syntax and Search Order
The following table summarizes how the syntax of a procedure name affects how NCL
searches for it; the table shows that the search order is affected by the use of quotes
(“ ”) and parentheses (( )) around the procedure name:
Procedure Name Syntax Comment Search Order
CALL
procedure-name
The procedure name must
be a valid symbol.
1. Internal procedure label.
2. External procedure name.
CALL "
procedure-name
" With quotes. The procedure
name must be a valid symbol
within the quotes.
External procedure name
only.
CALL (
expression
) With parentheses. The
expression is either a
procedure name (a valid
symbol) or an expression
that resolves to a procedure
name. Allows dynamic
procedure calls.
1. Internal procedure label.
2. External procedure name.
For example, the following CALL statement searches for an internal procedure label
and then, if the label is not found, for an external procedure name:
CALL abcproc /* Internal, external */
The following CALL statement searches only for an external procedure name:
CALL "procxyz" /* External only */
The following CALL statement searches for an internal procedure label and then, if the
label is not found, for an external procedure name:
CALL (proc||&number) /* Internal, external */
The name is determined by the value of the variable &NUMBER, which is
concatenated with PROC.