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

Defstruct and CLOS

> From: "Daniel L. Weinreb" <DLW@alderaan.scrc.symbolics.com> 
> One idea that's been discussed that would do what you want, in fact do
> something more general, is to redefine structures in terms of
> object-oriented programming, if and after CLOS is accepted as part of
> Common Lisp.  The basic idea is that CLOS would have a defined mechanism
> for talking about slots and their properties.  I don't know whether
> this idea is still current; I suspect it's mainly on the back burner
> while the CLOS proposal itself is being finished.

One reason people use structures rather than ``objects'' is that there
is a significant overhead incurred by using objects.  If defstruct were
subsumed into an object oriented standard there should be a way of
turning off all the power (and overhead) of the OOS.  In particular, you
don't want the defstruct accessor functions to become generic functions.

Kevin Gallagher