--- stack/stack.h 2002/03/07 03:28:29 1.4 +++ stack/stack.h 2002/03/10 09:13:36 1.8 @@ -28,17 +28,20 @@ typedef struct { enum { integer, + tfloat, string, func, /* Function pointer */ symb, list - } type:3; /* Type of stack element */ + } type:4; /* Type of stack element */ int gc_garb:1; + int gc_protect:1; union { void *ptr; /* Pointer to the content */ - int val; /* ...or an integer */ + int i; /* ...or an integer */ + float f; } content; /* Stores a pointer or an integer */ } value; @@ -67,7 +70,6 @@ defined symbols */ typedef struct { stackitem *gc_ref; - stackitem *gc_protect; int gc_limit, gc_count; stackitem *head; /* Head of the stack */ @@ -90,9 +92,11 @@ symbol **hash(hashtbl, const char*); value* new_val(environment*); void gc_mark(value*); +void gc_maybe(environment *env); extern void gc_init(environment*); void push_val(environment*, value*); void push_int(environment*, int); +void push_float(environment*, float); void push_cstring(environment*, const char*); char *mangle_str(const char*); extern void mangle(environment*); @@ -136,7 +140,14 @@ extern void readline(environment*); extern void sx_72656164(environment*); extern void foreach(environment*); -void protect(environment*, value*); -void unprotect(environment*); -extern void copying(environment *env); -extern void warranty(environment *env); +void protect(value*); +void unprotect(value*); +extern void copying(environment*); +extern void warranty(environment*); +extern void sx_2a(environment*); +extern void sx_2f(environment*); +extern void mod(environment*); +extern void sx_3c(environment*); +extern void sx_3c3d(environment*); +extern void sx_3e3d(environment*); +extern void sx_646976(environment*);