Ch 8. Procedure Options [ HP Pascal/iX Programmer's Guide ] MPE/iX 5.0 Documentation
HP Pascal/iX Programmer's Guide
Chapter 8 Procedure Options
Procedure options, which immediately follow a routine head, can specify:
* That the routine has an extensible parameter list--that is, one or
more optional parameters (EXTENSIBLE option).
* Default values for formal parameters, allowing their actual
parameters to be left out of actual parameter lists (DEFAULT_PARMS
option).
* That formal ANYVAR parameters do not have the usual hidden
parameters that specify their sizes (UNCHECKABLE_ANYVAR option).
* That the loader does not resolve the routine until run time
(UNRESOLVED option).
* That the routine is duplicated in-line wherever the program calls
it (INLINE option).
A routine heading can specify any combination of procedure options.
Example
PROCEDURE alpha (a,b,c : integer)
OPTION EXTENSIBLE 2;
FUNCTION beta (x : integer; y : real) : boolean
OPTION DEFAULT_PARMS (x:=0, y:=0);
FUNCTION delta (i,j,k : integer) : integer
OPTION EXTENSIBLE 1
DEFAULT_PARMS (i:=0, j:=1, k:=1)
UNRESOLVED;
PROCEDURE gamma (ANYVAR r,s : char)
OPTION UNCHECKABLE_ANYVAR;
PROCEDURE epsilon (ANYVAR t : real)
OPTION UNRESOLVED
UNCHECKABLE_ANYVAR;
FUNCTION zeta (ANYVAR u : real) : integer
OPTION UNCHECKABLE_ANYVAR
DEFAULT_PARMS (u:=nil)
UNRESOLVED;
MPE/iX 5.0 Documentation