This is the mail archive of the guile@cygnus.com mailing list for the guile project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Any examples of modules using GOOPS?


Mikael Djurfeldt <mdj@nada.kth.se> writes:

> I don't think not having :initform is a big loss, since the cases
> where you need to use :initform rather than #:init are few, and since
> it's no big deal to write out the lambda explicitly in those few
> cases.

Sigh...

Wrong again!

What I didn't realize was that every time you initialize a slot with
an object, you need #:init-form, since you need to call the
constructor at each instantiation of the parent object.

I'll re-introduce #:init-form.

BTW, what about renaming #:init-thunk to #:init-procedure and let it
take one argument: "this", i.e. the object itself?

When you have called `nect-method' in order to run the initializers
for the supers, this would allow you to refer to those initialized
slots of the supers when initializing additional slots.

/mdj