[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Class redefinition and class-changed.
- To: DUSSUD%Jenner%ti-csl.CSNet@relay.cs.net
- Subject: Re: Class redefinition and class-changed.
- From: Danny Bobrow <Bobrow.pa@Xerox.COM>
- Date: 9 Jul 87 11:51 PDT
- Cc: common-lisp-object-system@SAIL.STANFORD.EDU
- In-reply-to: Patrick H Dussud <DUSSUD%Jenner@ti-csl.CSNET>'s message of Wed, 8 Jul 87 16:02:06 CDT
- Sender: Bobrow.pa@Xerox.COM
Goals:
- There should be a way to define a method for class-changed
on the obsolete class and the class.
- This method needs to be defined before any the instances is
changed, otherwise it wouldn't get invoked on all the instances of
the class.
Agreed.
The necessary and sufficient condition for this is to be able to get
hold of an obsolete version of a class.
Proposal:
Changing a class updates a database to allow the following generic
functions to work.
GET-OBSOLETE-VERSION class
returns the preceding obsolete version of this class, or NIL if none.
This allows users to define methods at any time on the obsolete class.
Obsolete classes themselves may also have an obsolete-version. Obsolete
classes also respond to
GET-UPDATED-VERSION obsolete-class
with the next class or NIL
This allows following the chain in the opposite direction
Providing this chain allows defining pair-wise updaters from an obsolete
to its updated version, a general updating protocal that will follow the
chain from any old version to the current version, and accelerators
between any old-version and any later version on the chain.