[DGD] Re: Some basics

Erwin Harte harte at is-here.com
Mon Oct 20 21:26:41 CEST 2003


On Mon, Oct 20, 2003 at 12:17:33PM -0700, Noah Gibbs wrote:
> --- nihilxaos at nihilxaos.com wrote:
> > 1) When an object is compiled it's create is
> > called.
> 
>   Nope, but close.  The first time a function is
> called on the object, create() is called first.  So if
> you've just made an object called "bob" and want to
> initialize it, you can say "bob->NoSuchFunction()",
> which will return nil, and will do nothing but call
> create(), at least if the function doesn't exist.

I'd go for this instead:

    call_other(bob, "")

Less chance of NoSuchFunction() accidentally (or intentionally, if
someone is trying to break things) existing.

[...]
> > Basically this is going on the assumption
> > that inheriting brings the 
> > inherited data types into the object, but keeps any
> > non-overridden code in a 
> > separate object so it can be called from any of its
> > children.

If with 'data types' you mean 'non-private variables', then yes.

Erwin.
-- 
Erwin Harte <harte at is-here.com>
_________________________________________________________________
List config page:  http://list.imaginary.com/mailman/listinfo/dgd



More information about the DGD mailing list