super() doesn't get superclass
Scott David Daniels
Scott.Daniels at Acm.Org
Wed Sep 19 21:30:53 EDT 2007
Ben Finney wrote:
> aleax at mac.com (Alex Martelli) writes:
>
>> In general, "a superclass of foo" means "a class X such that foo is a
>> sublass of X"
>
> Sure. However, this doesn't equate to the assertion that "next class
> in the MRO is the superclass", which is what I was responding to.
>
One thing not pointed out in this thread is that the chain of classes
on the MRO starting with super(A, obj) _will_ include all superclasses
of A. That is the guarantee of the MRO, and that is why super is an
appropriate name.
-Scott David Daniels
Scott.Daniels at Acm.Org
More information about the Python-list
mailing list