SENTRY - standard function entry (bumping stack).

Usage:

[NAME,NAME,...]:  sentry  inhib=>type,vararg=>type,
                          SYMDEF=>type

Where:

[NAME,NAME,...]
is a list of names to be associated with the beginning of this function.
inhib=>type
indicates whether a software inhibit should be set for this function. (A software inhibit prevents the function from being interrrupted by most events, e.g. by user interrupts.) Possible forms are:
inhib=>no
does not set a software inhibit. This is the default, if you do not specify any "inhib=>" argument.
inhib=>yes
sets a software inhibit.

If you specify any other value in the "type" position, "sentry" sets a software inhibit.

vararg=>type
indicates whether this function can take a variable number of arguments. Possible forms are:
vararg=>no
sets up the function to take a fixed number of arguments. This is the default, if you do not specify any "vararg=>" argument.
vararg=>yes
sets up the function to accept a variable number of arguments.

If you specify any other value in the "type" position, the effect is "vararg=>yes".

SYMDEF=>type
is an optional argument indicating whether you want the macro to create SYMDEFs for the names given in the label field. Possible forms are:
SYMDEF=>no
does not declare the names as SYMDEFs.
SYMDEF=>yes
declares the names as primary SYMDEFs. This is the default, if you do not specify any SYMDEF=>type argument.
SYMDEF=>secondary
declares the names as secondary SYMDEFs.

If you specify any other value in the "type" position, the names are not declared as SYMDEFs. Note that the "type" keywords are case-sensitive and must be specified in lowercase.

Description:

"sentry" is the standard function entry routine, to be used at the beginning of a function. The stack is bumped in the usual way (described in the Runtime Manual). Space for arguments should be allocated with "argdef" (before the "sentry" macro).

You may not use the "cheap" macro to obtain cheap storage in a function that uses the "sentry" entry. If you try, "cheap" displays an error message.

Examples:

 func:    sentry
 #generates
 .retrn:  .symref
          zero   FRAME_SIZE,0  #FRAME_SIZE word
 func:    .symdef
 func:    .null
 .entry:  .symref
          tra   .entry,,p.oper
 func:    sentry  inhib=>yes
 #generates
 u.retn:  .symref
          zero   FRAME_SIZE,0
 func:    .symdef
 func:    .null
 .intry:  .symref
          tra    .intry,,p.oper  #inhibit entry
 func:    sentry  vararg=>yes
 #generates
 .retrn:  .symref
          zero   FRAME_SIZE,0
 func:    .symdef
 func:    .null
 .entry:  .symref
          tra    .vntry,,p.oper    #vararg entry

See Also:

expl runtime macro aentry

expl runtime macro nentry

Copyright © 1996, Thinkage Ltd.