diff options
author | dkf <donal.k.fellows@manchester.ac.uk> | 2013-09-19 14:21:21 (GMT) |
---|---|---|
committer | dkf <donal.k.fellows@manchester.ac.uk> | 2013-09-19 14:21:21 (GMT) |
commit | 5aee161167696db6b88db2b42a0d8963bb1cda6a (patch) | |
tree | 970f17d7a63aefbd337cf0c9314f2d241cb6eff1 /doc/next.n | |
parent | bbf4d17089f64ca705e9a5205d3039e2a8fa4029 (diff) | |
download | tcl-5aee161167696db6b88db2b42a0d8963bb1cda6a.zip tcl-5aee161167696db6b88db2b42a0d8963bb1cda6a.tar.gz tcl-5aee161167696db6b88db2b42a0d8963bb1cda6a.tar.bz2 |
[3606943]: Corrected description of method search order.
Diffstat (limited to 'doc/next.n')
-rw-r--r-- | doc/next.n | 11 |
1 files changed, 7 insertions, 4 deletions
@@ -62,14 +62,14 @@ The method chain is cached for future use. When constructing the method chain, method implementations are searched for in the following order: .IP [1] -In the object. -.IP [2] In the classes mixed into the object, in class traversal order. The list of mixins is checked in natural order. -.IP [3] +.IP [2] In the classes mixed into the classes of the object, with sources of mixing in being searched in class traversal order. Within each class, the list of mixins is processed in natural order. +.IP [3] +In the object itself. .IP [4] In the object's class. .IP [5] @@ -77,7 +77,10 @@ In the superclasses of the class, following each superclass in a depth-first fashion in the natural order of the superclass list. .PP Any particular method implementation always comes as \fIlate\fR in the -resulting list of implementations as possible. +resulting list of implementations as possible; this means that if some class, +A, is both mixed into a class, B, and is also a superclass of B, the instances +of B will always treat A as a superclass from the perspective of inheritance. +This is true even when the multiple inheritance is processed indirectly. .SS FILTERS .PP When an object has a list of filter names set upon it, or is an instance of a |