🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by john Tue, 13 Oct 1992 09:51
Re: Fate of obsolete accessors
#327
Author: john
Date: Tue, 13 Oct 1992 09:51
28 lines
1488 bytes
Jeff Dalton (jeff@aiai.edinburgh.ac.uk) writes:

  Suppose I

    1. Define a class with a slot A, :acessor GET-A.
    2. Redefine the class w/o the alot A.

  What happens to the access method on the generic function GET-A?

  In PCL the method goes away.  But is this behavior guaranteed?  What
  if the method was redefined to no longer be a slot access between
  (1) and (2)?

Page 4-15 of the ANSI Draft says

  Redefining a class ...  Any method object created by a :READER,
  :WRITER, or :ACCESSOR option specified by the old DEFCLASS form is
  removed from the corresponding generic function.

So it seems that in either situation, the Right Thing (tm) is
guaranteed to happen.  If you redefine the method between (1) and (2),
then the original method object defined in (1) doesn't get removed by
(2), because it's already been removed, by your redefinition.
Presumably, neither does the new method get removed, since it isn't
the same method object added by (1).

John Burger
john@mitre.org
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads