guile-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: SCM_BOOL_F == 0 and BDW-GC


From: Ludovic Courtès
Subject: Re: SCM_BOOL_F == 0 and BDW-GC
Date: Fri, 18 Sep 2009 00:28:43 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux)

Hello,

Neil Jerram <address@hidden> writes:

> address@hidden (Ludovic Courtès) writes:

[...]

>> Instead what's really needed is a special pointer-to-reclaimed-object
>> value that can be distinguished from valid Scheme values since that
>> value ends up in the car or cdr of weak pairs in hash table buckets.  As
>> such, SCM_PACK (NULL) was a good choice until now.
>
> Here I'm confused again.  I thought we now had no choice about the
> pointer-to-reclaimed-object value, because BDW-GC always uses NULL.

True.  So, what I meant is that ((SCM) NULL) must be distinguishable
from valid Scheme values.

>> SCM_UNDEFINED == 0 would work fine because SCM_UNDEFINED is not a valid
>> Scheme value, but it wouldn't change the implementation.
>
> I'm afraid I don't understand "but it wouldn't change the
> implementation".

Ugly stuff like ‘scm_fixup_weak_alist ()’ would still be needed.

> SCM_UNDEFINED == 0 is sounding promising...

Yeah.  Sorry for the false hope about SCM_BOOL_F == 0.

Thanks,
Ludo’.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]