Tony Nelson <[EMAIL PROTECTED]> wrote: > In article <[EMAIL PROTECTED]>, > Jan Niklas Fingerle <[EMAIL PROTECTED]> wrote: > > > ...Super is a good tool to use, when dealing with > > diamond shape inheritance. In any other case I would use the direct > > calls to the base classes. In fact, i've yet to find a non-textbook-case > > where I really need diamond shape inheritance. ... > > As long as you don't use multiple inheritance with new-style classes, > you'll be fine.
OK, I should have written: "... diamond shape inheritance where the base class's methods have to be called cooperatively ..." In other words: In almost every real world example of diamond shape inheritance where the base class is "only" object we don't have a problem, because you don't have to call object's __init__, yet it causes no harm if you call it twice - and __init__ is the *the* method you most commonly would use "super()" for. So, yes, "no multiple inheritance" is sufficient, but not nessecary to live happily without ever using "super()". Nothing against super where it's appropiate. But don't optimize for ("real") diamond shape inheritance, before you really need it... Cheers, --Jan Niklas -- http://mail.python.org/mailman/listinfo/python-list