[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: truth of %nil
From: |
Neil Jerram |
Subject: |
Re: truth of %nil |
Date: |
Thu, 17 Sep 2009 22:21:23 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) |
Mark H Weaver <address@hidden> writes:
> Certainly writing (a b c . #nil) as (a b c) would be most natural and
> convenient, and maybe it's the best compromise, but I'm not entirely
> sure it's safe.
>
> What if we have an association list mapping symbols to booleans that
> came from elisp? Such a alist might look something like
> ((a . #t) (b . #nil)), and can reasonably be assumed to be written
> and then read back in, but doing so would then result in
> ((a . #t) (b . ())), magically changing the false to a true.
Hmmm... From the elisp point of view it's still false, of course. From
the scheme point of view your point stands.
> This also violates the idea the CARs and CDRs should be treated the
> same way.
Also a good point.
> I'm tempted to suggest that "write" should write (a . #nil) as
> "(a . #nil)", and "display" should write it as "(a)".
For now I'm happy with any reasonable position (such as this), because I
don't think we've got any data to help decide between the options.
Hopefully it won't be too long before we have some real non-trival
Guile/Scheme/Elisp interactions.
Neil