[armedbear-devel] Patch: call reinitialize-instance on metaclass on class redefinition

Alessio Stalla alessiostalla at gmail.com
Fri Apr 22 22:53:48 UTC 2011


I found out that ABCL, when redefining a class, modifies the old class
metaobject in-place, slot by slot. This has the implication that the
redefinition of an instance of a custom metaclass does not update
custom slots. Now, I didn't check on the AMOP, but I'm pretty sure the
proper class redefinition protocol is more articulate than the one
implemented in ABCL; still, applying the patch that you find attached
fixes the problem of custom slots not being updated by calling
reinitialize-instance where the old code manually updated the class
metaobject, so it is, I think, a valid temporary solution until we
have a full MOP. However, before committing the patch, I'd like to
hear your opinion about it.

The patch also includes some tabs converted to spaces, sorry for the noise.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: reinitialize-instance-for-metaclasses.patch
Type: text/x-patch
Size: 4690 bytes
Desc: not available
URL: <https://mailman.common-lisp.net/pipermail/armedbear-devel/attachments/20110423/f8f9943f/attachment.bin>

More information about the armedbear-devel mailing list