1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-10 14:00:21 +02:00

* goops.texi (Class Redefinition): Clarifications; Removed

mentioning of change-object-class.
This commit is contained in:
Mikael Djurfeldt 2003-01-10 12:40:21 +00:00
parent 9cf5d9b7d2
commit da9015263e
2 changed files with 19 additions and 12 deletions

View file

@ -1,3 +1,8 @@
2003-01-10 Mikael Djurfeldt <djurfeldt@nada.kth.se>
* goops.texi (Class Redefinition): Clarifications; Removed
mentioning of change-object-class.
2002-11-07 Neil Jerram <neil@ossau.uklinux.net>
* goops.texi (Top): Say "Indices" before index nodes in main menu.

View file

@ -26,7 +26,7 @@ Guile
@ifinfo
This file documents GOOPS, an object oriented extension for Guile.
Copyright (C) 1999, 2000, 2001 Free Software Foundation
Copyright (C) 1999, 2000, 2001, 2003 Free Software Foundation
Permission is granted to make and distribute verbatim copies of
this manual provided the copyright notice and this permission notice
@ -2651,12 +2651,6 @@ The default @code{class-redefinition} method, specialized for classes
with the default metaclass @code{<class>}, has the following internal
protocol.
[ *fixme* I'm not sure that I understand this sufficiently to explain
it. Also, the internals of the default class redefinition method are
extremely implementation-specific, and I'm not sure that there is that
much point trying to describe the internal protocol such that it could
be customized without going to look at the source code. ]
@code{class-redefinition @var{(old <class>)} @var{(new <class>)}}
(method)
@ -2671,16 +2665,24 @@ be customized without going to look at the source code. ]
@code{update-direct-subclass! @var{subclass} @var{old} @var{new}} (generic)
@end itemize
This protocol cleans up things that the definition of the old class
once changed and modifies things to work with the new class.
The default @code{remove-class-accessors!} method removes the
accessor methods of the old class from all classes which they
specialize.
The default @code{update-direct-method!} method substitutes the new
class for the old in all methods specialized to the old class.
The default @code{update-direct-subclass!} method invokes
@code{class-redefinition} recursively to handle the redefinition of the
subclass.
@code{class-redefinition} recursively to handle the redefinition of
subclasses.
When a class is redefined, any existing instance of the redefined class
will be modified for the new class definition before the next time that
any of the instance's slot is referenced or set. GOOPS modifies each
instance by calling the generic function @code{change-class}. [ *fixme*
Actually it sometimes calls @code{change-class} and sometimes
@code{change-object-class}, and I don't understand why. ]
instance by calling the generic function @code{change-class}.
The default @code{change-class} method copies slot values from the old
to the modified instance, and initializes new slots, as described in