Re: $model->iter_next fix



muppet,

Could you please put on your teacher's hat and explain something to use mere mortals?

Let me explain how I though this was woriking, and then you can point at the place where I lost track and dumped core.

GBoxed is DERIVABLE, but it's not DEEP_DERIVABLE, right? In "perl language" this should be equivalent to

 @Any::Boxed::Type::ISA = ('Glib::Boxed');

By definition almost, or at least as long as you are playing by Glib's rules.

In GBoxed.xs, a boxed type is wrapped up in a BoxedInfo struct, so that a boxed type (from perl's point of view) can know it's own gtype/package_name. There are also hashes being maintained in GBoxed.xs to facilitate lookup by gtype or by package name.

I could have understood the need for a recursive lookup routine if GBoxed was DEEP_DERIVABLE, especially in the presense of multiple inheritance, but Glib doesn't allow multiple inheritance, and any boxed type inherits directly from GBoxed. So why not just look it up in the hash and leave it at that?

I guess the part I don't understand has something to do with the interplay of @ISA and the Glib inheritance...

Bjarne





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