diff options
author | Ludovic Courtes <ludovic.courtes@laas.fr> | 2006-05-14 18:44:09 +0000 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2008-09-05 00:48:31 +0200 |
commit | ce6660664198cc05a30ab5f342f8f95d491dbb41 (patch) | |
tree | 5648c4b8596d44db8980820eb13ee4b3d46bb65d /libguile/weaks.c | |
parent | 59cac9e3d8fb0097aba43dd3351274593ec552d7 (diff) | |
download | guile-ce6660664198cc05a30ab5f342f8f95d491dbb41.tar.gz |
procs/weaks/hashtab: Removed a bit of useless mark/free code.
* libguile/hashtab.c (UNMARKED_CELL_P): Removed.
(scm_i_scan_weak_hashtables): Removed.
* libguile/hashtab.h (scm_i_scan_weak_hashtables): Removed.
* libguile/procs.c (scm_mark_subr_table): Removed.
* libguile/procs.h (scm_mark_subr_table): Removed.
* libguile/weaks.c (UNMARKED_CELL_P): Removed.
(scm_i_remove_weaks): Removed.
(scm_i_remove_weaks_from_weak_vectors): Removed.
git-archimport-id: lcourtes@laas.fr--2005-libre/guile-core--boehm-gc--1.9--patch-18
Diffstat (limited to 'libguile/weaks.c')
-rw-r--r-- | libguile/weaks.c | 65 |
1 files changed, 0 insertions, 65 deletions
diff --git a/libguile/weaks.c b/libguile/weaks.c index b27839e48..7950d891b 100644 --- a/libguile/weaks.c +++ b/libguile/weaks.c @@ -191,74 +191,9 @@ SCM_DEFINE (scm_doubly_weak_alist_vector_p, "doubly-weak-alist-vector?", 1, 0, 0 } #undef FUNC_NAME -#define UNMARKED_CELL_P(x) 1 /* (SCM_NIMP(x) && !SCM_GC_MARK_P (x)) *//* - FIXME */ -static void -scm_i_remove_weaks (SCM w) -{ - return; /* FIXME */ -#if 0 - SCM *ptr = SCM_I_WVECT_GC_WVELTS (w); - size_t n = SCM_I_WVECT_LENGTH (w); - size_t i; - - if (!SCM_IS_WHVEC_ANY (w)) - { - for (i = 0; i < n; ++i) - if (UNMARKED_CELL_P (ptr[i])) - ptr[i] = SCM_BOOL_F; - } - else - { - size_t delta = 0; - - for (i = 0; i < n; ++i) - { - SCM alist, *fixup; - - fixup = ptr + i; - alist = *fixup; - while (scm_is_pair (alist) && !SCM_GC_MARK_P (alist)) - { - if (UNMARKED_CELL_P (SCM_CAR (alist))) - { - *fixup = SCM_CDR (alist); - delta++; - } - else - { - SCM_SET_GC_MARK (alist); - fixup = SCM_CDRLOC (alist); - } - alist = *fixup; - } - } -#if 0 - if (delta) - fprintf (stderr, "vector %p, delta %d\n", w, delta); -#endif - SCM_I_SET_WVECT_DELTA (w, delta); - } -#endif -} - -#if 0 -void -scm_i_remove_weaks_from_weak_vectors () -{ - SCM w = weak_vectors; - while (!scm_is_null (w)) - { - scm_i_remove_weaks (w); - w = SCM_I_WVECT_GC_CHAIN (w); - } -} -#endif - - SCM scm_init_weaks_builtins () { |