This is the mail archive of the
kawa@sourceware.org
mailing list for the Kawa project.
Re: CL not is not not?
- From: Per Bothner <per at bothner dot com>
- To: Jamison Hope <jrh at theptrgroup dot com>
- Cc: Kawa mailing list <kawa at sourceware dot org>
- Date: Tue, 24 Apr 2012 01:25:36 -0700
- Subject: Re: CL not is not not?
- References: <0A252721-4F4C-452F-8435-93213F5CF94A@theptrgroup.com>
On 04/24/2012 01:03 AM, Jamison Hope wrote:
Speaking of Common Lisp, I find this interaction to be very curious...
$ kawa --lisp
#|kawa:1|# (not t)
t
Trying with --debug-print-final-expr I see:
#|kawa:1|# (not t)
[Compiling final atInteractiveLevel$1 to atInteractiveLevel$1:
(Module/atInteractiveLevel$1/1/ () (Quote () ::boolean))]
t
So constant-folding works, correctly yielding ().
Then that gets cast to boolean. My guess is the problem is
that cast is to the *Scheme* version of the boolean type,
so () is treated as true.
Using --debug-dump-zip shows the result is passed to writeBoolean
in the actual run method.
--
--Per Bothner
per@bothner.com http://per.bothner.com/