ExpressProc.mesa
This interface is intended for use by the Express package. Other clients beware!
Created July 11, 1984 12:49:48 pm PDT
Last edited by Eric Nickell, July 18, 1984 1:59:34 am PDT
DIRECTORY
ExpressTree;
ExpressProc: CEDAR DEFINITIONS ~ {
XTree: TYPE ~ ExpressTree.XTree;
Token: TYPE ~ ATOM;   --Maybe enumerated later...see ExpressProcDoc.tioga for list of currently usable tokens.
NoProcedureAvailable: ERROR;
IllegalToken: ERROR;
ANYPROC: TYPE ~ PROC ANY RETURNS ANY;
GetProc: PROC [fcn: XTree, oldProc: ANYPROCNIL] RETURNS [proc: ANYPROC];
! NoProcedureAvailable, if internal storage fills up. See the maintainer if this happens.
! IllegalToken, if passed a non-declared token. Note that these are declared in the implementation so that we retain flexibility without having to recompile the world.
There should be exactly one item in constants for each token=$Constant. The tokens $Constant will be converted into the corresponding immediate push.
There should be exactly one item in procsToCall for each token=$Proc. The tokens $Proc will be converted into the corresponding procedure call.
oldProc is a proc to be recycled. NOTE: Even if it is given, it might not be the one returned by GetProc.
FreeProcedure: PROC [proc: ANYPROC];
It's not absolutely necessary to call this procedure. Be careful!!! It is up to the client to keep track of the dangling pointer problem.
GetProc calls this if it is given an oldProc.
}.