Newsgroups: comp.lang.lisp
Path: cantaloupe.srv.cs.cmu.edu!rochester!cornellcs!newsfeed.cit.cornell.edu!newsstand.cit.cornell.edu!travelers.mail.cornell.edu!news.kei.com!news.mathworks.com!tank.news.pipex.net!pipex!lade.news.pipex.net!pipex!harlqn.co.uk!harlequin.co.uk!pekka
From: pekka@harlequin.co.uk (Pekka P. Pirinen)
Subject: Re: (UNSIGNED-BYTE 0) vs. (SIGNED-BYTE 0)
In-Reply-To: lmayka@aol.com's message of 23 Oct 1995 19:50:07 -0400
Message-ID: <PEKKA.95Oct27191820@gaspode.harlqn.co.uk>
Lines: 22
Sender: usenet@harlequin.co.uk (Usenet Maintainer)
Organization: Harlequin Ltd, Barrington Hall, Cambridge UK
References: <46h9nf$8ra@newsbf02.news.aol.com>
Date: Fri, 27 Oct 1995 19:18:20 GMT

In article <46h9nf$8ra@newsbf02.news.aol.com> lmayka@aol.com (LMayka) writes:
   I would think that both (UNSIGNED-BYTE 0) and (SIGNED-BYTE 0), if legal at
   all, would be equivalent to (EQL 0).  But on all of LispWorks, Allegro CL,
   and CLISP, the type (UNSIGNED-BYTE 0) does include the single integer 0
   but the type (SIGNED-BYTE 0) does not include any integer at all, as
   indicated by TYPEP.

The other Harlequin Lisp, LCL, signals error for (UNSIGNED-BYTE 0) and
(SIGNED-BYTE 0); we'll change LW to do that as well.  CLtL could be
read to allow (UNSIGNED-BYTE 0), but ANSI restricts that bit count to
a positive integer, so 0 is illegal.

   from the information-theoretical
   point of view, 0 bits can indicate exactly one value, which for
   SIGNED-BYTE would clearly be the integer 0.

One could make a case for -1/2 as well, but I won't bother.
-- 
Pekka P. Pirinen
Harlequin Limited, Cambridge, UK
"If you don't want to be replaced by a machine, don't act like one."
   from _Ideas and Information_  by Arno Penzias
