From: Joseph Verzulli
Subject: Dispatching character macros
Date: 
Message-ID: <7dvlnf+@rpi.edu>
  I'm trying to create a CLOS instance from a dispatching character
read macro, but it doesn't seem to work when the #n= and #n# syntax is
used.  Here's a simple example:

    (defclass foo ()
       ((s1 :accessor s1 :initarg :s1)))

    (setq z (make-instance 'foo :s1 0))

    (defun read-thing (stm char num)
      (read stm t nil t)
      z)

    (set-dispatch-macro-character #\# #\D #'read-thing)

    (setq x "(#1=#D() #D())")

    (with-input-from-string (stm x)
      (read stm))


   Should this work in Common Lisp?  I've tried it in AKCL and it gets
an "Illegal instruction" when doing the "read."
From: Barry Margolin
Subject: Re: Dispatching character macros
Date: 
Message-ID: <1991Jul9.165011.24924@Think.COM>
In article <·······@rpi.edu> ········@cs.rpi.edu (Joseph Verzulli) writes:
>  I'm trying to create a CLOS instance from a dispatching character
>read macro, but it doesn't seem to work when the #n= and #n# syntax is
>used.  Here's a simple example:

[Example deleted]

>   Should this work in Common Lisp?  I've tried it in AKCL and it gets
>an "Illegal instruction" when doing the "read."

It works fine for me in Symbolics Genera 8.1 and Sun CL 4.0.  I suspect a
bug in AKCL.
-- 
Barry Margolin, Thinking Machines Corp.

······@think.com
{uunet,harvard}!think!barmar