diff -ruN klic-3.003-2002-02-19d/include/klic/alloc.h klic-3.003-2002-02-19e/include/klic/alloc.h
--- klic-3.003-2002-02-19d/include/klic/alloc.h	Tue Feb 19 15:15:23 2002
+++ klic-3.003-2002-02-19e/include/klic/alloc.h	Tue Feb 19 17:00:31 2002
@@ -30,6 +30,8 @@
 }while(0)
 
 
+typedef void (*gc_t)(void);
+
 /* runtime/intrpt.c */
 extern void klic_interrupt(struct goalrec* qp);
 
@@ -37,7 +39,11 @@
 extern void* malloc_check(unsigned long size);
 extern void* realloc_check(void* original, unsigned long newsize);
 extern void initalloc(void);
-extern void register_gc_hook(void (*routine)(void));
-extern void register_after_gc_hook(void (*routine)(void));
+extern void register_gc_hook(gc_t routine);
+extern void register_after_gc_hook(gc_t routine);
+extern gc_t gc_hook_table(int k);
+extern gc_t after_gc_hook_table(int k);
+extern int num_gc_hooks(void);
+extern int num_after_gc_hooks(void);
 
 #endif /* _KLIC_ALLOC_H_ */
diff -ruN klic-3.003-2002-02-19d/include/klic/struct.h klic-3.003-2002-02-19e/include/klic/struct.h
--- klic-3.003-2002-02-19d/include/klic/struct.h	Tue Feb 19 13:48:35 2002
+++ klic-3.003-2002-02-19e/include/klic/struct.h	Tue Feb 19 16:59:36 2002
@@ -248,12 +248,6 @@
 #define program_name	(glbl->program_name0)
 #define command_argc	(glbl->command_argc0)
 #define command_argv	(glbl->command_argv0)
-#define gc_hook_table	(glbl->gc_hook_table0)
-#define gc_hooktab_size (glbl->gc_hooktab_size0)
-#define num_gc_hooks	(glbl->num_gc_hooks0)
-#define after_gc_hook_table (glbl->after_gc_hook_table0)
-#define after_gc_hooktab_size (glbl->after_gc_hooktab_size0)
-#define num_after_gc_hooks (glbl->num_after_gc_hooks0)
 #define suspensions	(glbl->suspensions0)
 #define	resumes		(glbl->resumes0)
 #define copied_susp	(glbl->copied_susp0)
@@ -317,12 +311,6 @@
   char* program_name0;
   int command_argc0;
   char** command_argv0;
-  q*(** gc_hook_table0)();
-  int gc_hooktab_size0;
-  int num_gc_hooks0;
-  q*(** after_gc_hook_table0)();
-  int after_gc_hooktab_size0;
-  int num_after_gc_hooks0;
   unsigned long suspensions0, resumes0, copied_susp0, cum_susps0, cum_resumps0;
   struct suspended_goal_rec* suspended_goal_list0;
   const struct predicate* postmortem_pred0;
diff -ruN klic-3.003-2002-02-19d/runtime/alloc.c klic-3.003-2002-02-19e/runtime/alloc.c
--- klic-3.003-2002-02-19d/runtime/alloc.c	Tue Feb 19 15:16:41 2002
+++ klic-3.003-2002-02-19e/runtime/alloc.c	Tue Feb 19 17:01:01 2002
@@ -15,6 +15,13 @@
 static q* old_space_top0;
 static unsigned long new_space_size0, old_space_size0;
 
+static gc_t* gc_hook_table0;
+static int gc_hooktab_size0;
+static int num_gc_hooks0;
+static gc_t* after_gc_hook_table0;
+static int after_gc_hooktab_size0;
+static int num_after_gc_hooks0;
+
 extern q*
 heapp(void)
 {
@@ -36,6 +43,11 @@
 extern void set_new_space_size(unsigned long size){ new_space_size0 = size; }
 extern void set_old_space_size(unsigned long size){ old_space_size0 = size; }
 
+extern gc_t gc_hook_table(int k){ return gc_hook_table0[k]; }
+extern gc_t after_gc_hook_table(int k){ return after_gc_hook_table0[k]; }
+extern int num_gc_hooks(void){ return num_gc_hooks0; }
+extern int num_after_gc_hooks(void){ return num_after_gc_hooks0; }
+
 extern void*
 malloc_check(size)
      unsigned long size;
@@ -70,13 +82,12 @@
   set_heapp( heaptop = new_space_top() );
   real_heapbytesize = (unsigned long) heapbottom - (unsigned long) heaptop;
   this_more_space = 0;
-  gc_hooktab_size = 32;
-  num_gc_hooks = 0;
-  gc_hook_table = (q*(**)()) malloc_check(gc_hooktab_size*sizeof(q*(**)()));
-  after_gc_hooktab_size = 32;
-  num_after_gc_hooks = 0;
-  after_gc_hook_table =
-    (q*(**)()) malloc_check(gc_hooktab_size*sizeof(q*(**)()));
+  gc_hooktab_size0 = 32;
+  num_gc_hooks0 = 0;
+  gc_hook_table0 = (gc_t*) malloc_check(gc_hooktab_size0*sizeof(gc_t*));
+  after_gc_hooktab_size0 = 32;
+  num_after_gc_hooks0 = 0;
+  after_gc_hook_table0 = (gc_t*) malloc_check(gc_hooktab_size0*sizeof(gc_t*));
 }
 
 extern void
@@ -99,28 +110,26 @@
 }
 
 extern void
-register_gc_hook(routine)
-  void (*routine)(void);
+register_gc_hook(gc_t routine)
 {
   declare_globals;
-  if (num_gc_hooks >= gc_hooktab_size) {
-    gc_hooktab_size *= 2;
-    gc_hook_table = (q*(**)())
-      realloc_check((char*) gc_hook_table, gc_hooktab_size*sizeof(q*(**)()));
+  if (num_gc_hooks0 >= gc_hooktab_size0) {
+    gc_hooktab_size0 *= 2;
+    gc_hook_table0 = (gc_t*)
+      realloc_check((void*) gc_hook_table0, gc_hooktab_size0*sizeof(gc_t*));
   }
-  gc_hook_table[num_gc_hooks++] = routine;
+  gc_hook_table0[num_gc_hooks0++] = routine;
 }
 
 extern void
-register_after_gc_hook(routine)
-  void (*routine)(void);
+register_after_gc_hook(gc_t routine)
 {
   declare_globals;
-  if (num_after_gc_hooks >= after_gc_hooktab_size) {
-    after_gc_hooktab_size *= 2;
-    after_gc_hook_table = (q*(**)())
-      realloc_check((char*) after_gc_hook_table,
-		    after_gc_hooktab_size*sizeof(q*(**)()));
+  if (num_after_gc_hooks0 >= after_gc_hooktab_size0) {
+    after_gc_hooktab_size0 *= 2;
+    after_gc_hook_table0 = (gc_t*)
+      realloc_check((void*) after_gc_hook_table0,
+		    after_gc_hooktab_size0*sizeof(gc_t*));
   }
-  after_gc_hook_table[num_after_gc_hooks++] = routine;
+  after_gc_hook_table0[num_after_gc_hooks0++] = routine;
 }
diff -ruN klic-3.003-2002-02-19d/runtime/gc.c klic-3.003-2002-02-19e/runtime/gc.c
--- klic-3.003-2002-02-19d/runtime/gc.c	Tue Feb 19 15:27:42 2002
+++ klic-3.003-2002-02-19e/runtime/gc.c	Tue Feb 19 17:01:33 2002
@@ -574,8 +574,8 @@
   heapbottom = real_heaplimit + incrementsize;
 
   set_heapp(allocp);
-  for( k=0; k<num_gc_hooks; k++ ){
-    gc_hook_table[k]();
+  for( k=0; k<num_gc_hooks(); k++ ){
+    ((gc_t) gc_hook_table(k))();
   }
 
   for( ; pq->prio >= 0; pq = pq->next ){
@@ -739,8 +739,8 @@
     fatal("Perpetually suspending goal(s) found during GC");
   }
 
-  for( k=0; k<num_after_gc_hooks; k++ ){
-    after_gc_hook_table[k]();
+  for( k=0; k<num_after_gc_hooks(); k++ ){
+    ((gc_t) after_gc_hook_table(k))();
   }
 
   return qp;
