Re: TclOO: questions (Method Chaining, next, my variable)



eiji wrote:
In the TIP #257 [http://www.tcl.tk/cgi-bin/tct/tip/257.html] you find
information about the so called "Method-Chaining", and I played a
little bit with that feature and determine, that there is no statement
to when the forward-declaration is called.
In the following example I see that the filters and mixings intercept
before the forward proc. I that well defined behavior?

Yes. The documentation for the extension should be definitive for this.
The TIP might be a bit inaccurate or out-of-date (I've not been actively
keeping it in synch).

Is there any reason why the mixings intercept before forward?
I was just wondering and some dicussion on TclOO would be interesting
too.

Yes. Forwards are just a different type of method, whereas mixins are a
different type of inheritance. :-)

Shouldn't ''next'' on derived throw an error?
[...]
TIP #257 says:
"It is an error to invoke the next
command when there is no superclass
definition of the current method."

That has been changed. Turns out to be a bad idea when the inheritance
graph gets non-trivial (deciding if you have a superclass implementation
at the class level is not as easy as it sounds!) and is one of the
reasons why I now accept that pushing for TclOO in 8.5 was a not-so-good
idea. By finding these things out, life will be better in the future. :-)

What's the difference between ''variable'' and ''my variable''?
[...]
What is the benefit using ''my variable''?
In the first place, everything looks similar to ''variable''.

Apart from the fact that [variable] sucks for more than one variable,
nothing really. Need to re-evaluate that part. :-)

Donal.
.