[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: PRINT-OBJECT, May-day classes & methods in same file

   X-Ns-Transport-Id: 08002008D0FD0002A873
   Date: 	Sat, 29 Sep 1990 11:38:43 PDT
   From: tim@cstr.edinburgh.ac.uk

   I often use fairly complex after methods for INITIALIZE-INSTANCE,
   typically for filling slots from a file.  It *seems* to be the case
   that trying to print an object before INITIALIZE-INSTANCE has done
   its work is dangerous; is this true?  It would make good sense if it

Well, this depends on the print-object method you have defined,
applicable to objects of that class.  If that method generates an error,
perhaps by attempting to access an unbound slot, then the printer will
run into troubles (exactly what kind depends on what Lisp you are using,
and whether you were in the debugger to start with.)  PCL's default
methods on print-object are written so that they won't cause such
errors, you may want to re-write your methods to also do this checking.

   Is it the case that the resulting compiled file *will* work OK?  It
   seems to on both the implementations I use (Xerox Medley & Franz
   Allegro CL).

Yes, it will.