Hi Eugene,
On Sun, 13 Jul 2008 22:23:20 -0400, Eugene Ossintsev <eugoss(a)gmail.com> wrote:
> I was trying to compile flexi-streams 1.0.3 with CMUCL 19e and it
> stopped with the following message in ascii.lisp :
>
> --------------------------------------------------------
> Type-error in KERNEL::OBJECT-NOT-TYPE-ERROR-HANDLER:
> 65533 is not of type (UNSIGNED-BYTE 8)
> [Condition of type TYPE-ERROR]
> --------------------------------------------------------
>
> I don't know if it's my fault or not, I'm not experienced enough
> yet. But as I see, in MAKE-DECODING-TABLE the function MAKE-ARRAY
> has :element-type 'char-code-integer.
>
> CHAR-CODE-INTEGER is defined as
>
> (deftype char-code-integer ()
> "The subtype of integers which can be returned by the function CHAR-CODE."
> '(integer 0 #.(1- char-code-limit)))
>
> But at least in CMUCL 19e CHAR-CODE-LIMIT is 256, that is not enough
> to hold 65533. I'm afraid it's about Unicode-non-Unicode characters,
> right?
Please send but reports to the mailing list (see Cc).
I'm not sure what the best thing to do is w.r.t. CMUCL. Should we
declare CHAR-CODE-INTEGER to be the same as FIXNUM on CMUCL? Or
(integer 0 65535)? Or should at least MAKE-DECODING-TABLE be
modified? Opinions?
Cheers,
Edi.
PS: Eugene, as a workaround please try the following in mapping.lisp
and report to the list if you still have problems:
(defun make-decoding-table (list)
"Creates and returns an array which contains the elements in the
list LIST and has an element type that's suitable for character
codes."
(make-array (length list)
:element-type 'fixnum
:initial-contents list))