What is the semantics meaning of 'object'?

Antoon Pardon antoon.pardon at rece.vub.ac.be
Sun Jun 23 15:33:02 EDT 2013


Op 23-06-13 18:35, Steven D'Aprano schreef:
> On Sun, 23 Jun 2013 10:15:38 -0600, Ian Kelly wrote:
>
>> If you're worried about efficiency, you can also explicitly name the
>> superclass in order to call the method directly, like:
>>
>>          A.__init__(self, arg)
>
> Please don't. This is false economy. The time you save will be trivial,
> the overhead of inheritance is not going to be the bottleneck in your
> code, and by ignoring super, you only accomplish one thing:
>
> - if you use your class in multiple inheritance, it will be buggy.

Which is why I don't understand that the python standard library still
contains that kind of code. At least it did in 3.2 and I saw nothing
in the 3.3 release notes that would make me suspect this has changed.

-- 
Antoon Pardon




More information about the Python-list mailing list