Language Extensions for Gnosis
To compile your program with these facilities, use the "LIB(PASGATES)" option of the "PASCALVS" command. This automaticly causes the compiler to use the maclib "PASGATES". This maclib may be found on GNOSIS 1A1. Include the statement "%INCLUDE GNOSIS;" in your program to copy in the following data:
TYPE SLOT = PACKED -32768 .. 32767;
STATIC dummy :SLOT; VALUE dummy := -2;
FUNCTION pasjmpc (CONST gate :SLOT;
CONST OutKey1,
OutKey3 :SLOT;
VAR InKey1,
InKey3,
InKey4 :SLOT;
CONST OutKey1,
OutKey3,
OutKey4 :SLOT;
CONST OutKey1,
OutKey3,
OutKey4 :SLOT;
VAR InKey1,
InKey3,
InKey4 :SLOT;
VAR InString :STRING)
For "pasjmpr" the value of the function is the value specified by the jumper the next time the domain is entered (the order code to the Pascal program).
"ReturnCode" is an integer expression whose value is passed to the gate with the "pasjmpr" function.
Values of type SLOT.
The constant "dummy" as a slot designator provides the value DK(0) when used for "OutKey1", "OutKey2", "OutKey3", or "OutKey4".
The constant "dummy" when used for "InKey1", "InKey2", "InKey3", or "InKey4" causes the received key value to be discarded.
If a variable is used for "InKey1", "InKey2", "InKey3", or "InKey4" and the variable's value is -1 then an unused slot number will be assigned to that variable and that new value will be used. If the value of an expression for "OutKey1", "OutKey2", "OutKey3", or "OutKey4" is -1 then the key DK(0) will be provided.
We may provide a call to free a slot. "pasfree (sd);" where "sd" is a an integer variable that had occurred in "InKey1", "InKey2", "InKey3", or "InKey4" sd's value will be -1 after this call.
"OutString" is a character string expression.
"DataByte" receives the value of the databyte of the start key used to enter this domain.
"OrderCode" receives the order code.
There is currently no method of reclaiming the space used to hold the keys. Thus if these variables are declared as AUTOMATIC, the storage used to hold the keys will not be reclaimed when the block where the variable is declared is exited. Thus such variables should usually be declared at the outermost nesting level or as STATIC or DEF/REF.
Auxiliary functions and suggestions: