3 * (C) Copyright May 7 1995, Edmond J. Breen.
5 * This code may be copied for personal, non-profit use only.
12 #if !defined(_eic_ptr) && !defined(_EiC)
14 typedef struct {void *p, *sp, *ep;} ptr_t;
17 #include <sys/types.h>
21 void *EiC_add_builtinfunc(char *name, val_t(*vfunc)(void));
22 void EiC_startEiC(int argc, char ** argv);
24 int EiC_run(int argc, char **argv);
25 void EiC_parseString(char *, ...);
26 void EiC_callBack(void *code);
28 void EiC_setMessageDisplay(void (*)(char *));
30 extern void (*EiC_messageDisplay)(char *);
33 #define setArg(x,C,type,v) do { code_t *c = C; \
34 *(type*)(&c->inst[c->nextinst - 5 - 2 * x].val) = v;} while(0)
36 extern val_t EiC_STaCK_VaLuE;
38 #define EiC_ReturnValue(type) (*(type*)&EiC_STaCK_VaLuE)
44 #define arg_list AR_t *
45 #define getargc() ARGC
46 #define getargs() AR[2]
47 #define nextarg(x,type) (*((type*)&(--x)->v))
48 #define arg(i,x,type) (*((type*)&x[-(i+1)].v))
50 #define malloc(x) xmalloc(x)
51 #define calloc(x,y) xcalloc(x,y)
52 #define free(x) xfree(x)
53 #define realloc(x,y) xrealloc(x,y)