Class slots in CLOS
- From: Blake McBride <blake@xxxxxxxxxxxx>
- Date: Mon, 31 Dec 2007 10:49:51 -0600
Greetings,
It seems to me that there are two ways to define class slots (slots common to all instances of the class) in CLOS as follows:
1. via the use of :allocation :class slot option
2. By the creation and use of a meta-class that is to house the shared slots for a given class or set of classes.
I suppose my main question is what is the difference. I'm pretty sure method #1 is easier to declare and access to the class slots is easier (just like instance slots). Is one faster than the other.
I understand that using method #2 is more flexible and theoretically pure. Or, is method #1 just a shorthand for method #2?
Thanks.
Blake McBride
.
- Follow-Ups:
- Re: Class slots in CLOS
- From: Pascal Costanza
- Re: Class slots in CLOS
- From: Michael Weber
- Re: Class slots in CLOS
- Prev by Date: Re: Curses alternative for Lisp?
- Next by Date: Re: self-managed freelist for class instances
- Previous by thread: [ANN] ECL 0.9j-p1
- Next by thread: Re: Class slots in CLOS
- Index(es):
Relevant Pages
|