From 038c39b1ad834660a91ed7661a072f02ea23b08c Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Sun, 31 Jan 2010 23:12:02 -0800 Subject: [PATCH] Fix bug: weak-method:clean! removing entries whose key is #f. --- src/runtime/hashtb.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/runtime/hashtb.scm b/src/runtime/hashtb.scm index e5fe7f896..6390433a9 100644 --- a/src/runtime/hashtb.scm +++ b/src/runtime/hashtb.scm @@ -317,7 +317,7 @@ USA. ((scan-head (lambda (p) (if (pair? p) - (if (%weak-entry-key (car p)) + (if (%weak-entry-valid? (car p)) (begin (vector-set! buckets i p) (scan-tail (cdr p) p)) @@ -328,13 +328,13 @@ USA. (scan-tail (lambda (p q) (if (pair? p) - (if (%weak-entry-key (car p)) + (if (%weak-entry-valid? (car p)) (scan-tail (cdr p) p) (begin (decrement-table-count! table) (let loop ((p (cdr p))) (if (pair? p) - (if (%weak-entry-key (car p)) + (if (%weak-entry-valid? (car p)) (begin (set-cdr! q p) (scan-tail (cdr p) p)) -- 2.25.1