home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Vectronix 2
/
VECTRONIX2.iso
/
FILES_01
/
X_PROLOG.LZH
/
X_PROLOG
/
SOURCES
/
GLOBAL.H
< prev
next >
Wrap
C/C++ Source or Header
|
1990-08-13
|
3KB
|
114 lines
/*
* X PROLOG Vers. 2.0
*
*
* Written by : Andreas Toenne
* CS Dept. , IRB
* University of Dortmund, W-Germany
* <at@unido.uucp>
* <....!seismo!unido!at>
* <at@unido.bitnet>
*
* Copyright : This software is copyrighted by Andreas Toenne.
* Permission is granted hereby to copy the entire
* package including this copyright notice without fee.
*
*/
/* global stack (env, backlog, frame) */
char *stack; /* pointer to the stack */
char *stacktop;
char *stackfull; /* hightide */
/* backtrack stack */
backlog *Backpoint; /* the topmost backtrack point */
/* enviroment stack */
env *Topenv; /* the topmost enviroment */
env *Preenv; /* the previous enviroment */
/* prototyp stack(area) */
char *protostack; /* the prototypes stack */
term *prototop; /* the current top element */
term *protonext; /* the next to be used element */
char *protofull; /* the highest element */
term *protofree[MAXARGS+1]; /* list of free terms */
/* copyterm stack */
char *copystack; /* the copystack */
term *copytop; /* the current top element */
term *copynext; /* the next to be used element */
char *copyfull; /* the highest element */
/* trail stack */
term **trailstack; /* the stack base */
long trailtop; /* the index of the next free element */
long trailfull; /* the highest possible index */
/* clause area */
clause *clausesp; /* room for clauses */
clause *clausefree; /* pointer to next free clause */
long clausefull; /* max. count of clauses */
clause *clausenext;
/* functor area */
char *functorsp; /* room for functors */
char *functorfull;
char *functornext; /* next functor */
functor *functors = (functor *)NULL; /* the root of the AVL tree */
/* io data */
stream streams[MAXSTREAMS]; /* list of open streams */
stream *in; /* current input stream */
stream *out; /* current output stream */
/* standard data */
functor *stdfunctor[STDFUNCTORS]; /* list of standard functors */
/* error values */
short c_errno = 0; /* the number of the last soft error */
short io_errors = 1; /* signal io errors ? */
/* enviroment data (from executing shell) */
char *shell; /* the path of the default shell */
char **enviroment; /* the program's enviroment */
/* reader data */
lookup l_table[MAXVARS]; /* the lookup table */
short tide; /* end-of-table */
char line[MAXLINE]; /* buffer for the current line */
char name[MAXNAME]; /* temp. name space */
char *p; /* pointer to current character */
char c; /* the current character */
char lastc; /* low io */
short c_type; /* the type of the current character */
char *token; /* the currently read token */
short token_type; /* it's type */
short valid_token; /* token is unused */
term *prompt; /* the prompt */
/* misc data */
short dodebug;
#ifdef ATARI
long s_time; /* timer tic at prolog's start */
#endif
long abortpoint[3]; /* save point of abort */
short booting; /* true while booting */
long lastconsult; /* last consulted clause */