[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: "is a" relationships
- To: email@example.com (Brad Might)
- Subject: Re: "is a" relationships
- From: firstname.lastname@example.org (Michael Richardson)
- Date: Thu, 24 Sep 1992 11:07:41 -0400
- Cc: email@example.com
- In-reply-to: firstname.lastname@example.org (Brad Might) ""is a" relationships" (Sep 23, 7:43pm)
- Resent-date: Thu, 24 Sep 92 10:58:04 PDT
- Resent-from: Urs Hoelzle <urs@otis>
- Resent-message-id: <9209241758.AA12237@otis.Stanford.Edu>
- Resent-to: real-self-interest
On Sep 23, 7:43pm, Brad Might wrote:
} This is what I have tried, is it the way to go ?
} prototypes _AddSlots: (|
} animal = (|
} parent* = traits animal.
} "object specific stuff here".
} mammal = (|
} parent* = traits mammal.
} inherit**. "at initialization (copy), this slot will be
} filled in with a copy of prototypes animal"
You are not the only one to ponder exactly how to do this.
Particularily nasty is that changing the animal prototype doesn't
affect the inherited slots of mammal at all. Of course, it doesn't
affect any existing animals either. I was hacking on `copy-on-write'
slots at one point, but this as was with 1.1, and one couldn't
use _AddSlots: from within a method...
I think that something like that is the solution.
:!mcr!: | The postmaster never | So much mail,
Michael Richardson | resolves twice. | so little time.
HOME: email@example.com Bell: (613) 237-5629