On Sun, Nov 20, 2011 at 10:44 AM, Michael Foord
wrote:
>
> On 20 Nov 2011, at 16:35, Guido van Rossum wrote:
>
>> Um, what?! __class__ *already* has a special meaning. Those examples
>> violate that meaning. No wonder they get garbage results.
>>
>> The correct way to override isinstance is explai
On 20 Nov 2011, at 16:35, Guido van Rossum wrote:
> Um, what?! __class__ *already* has a special meaning. Those examples
> violate that meaning. No wonder they get garbage results.
>
> The correct way to override isinstance is explained here:
> http://www.python.org/dev/peps/pep-3119/#overloadin
Um, what?! __class__ *already* has a special meaning. Those examples
violate that meaning. No wonder they get garbage results.
The correct way to override isinstance is explained here:
http://www.python.org/dev/peps/pep-3119/#overloading-isinstance-and-issubclass
.
--Guido
On Sat, Nov 19, 2011 a
Michael Foord voidspace.org.uk> writes:
> The Python compiler can do strange things with assignment to __class__ in the
> presence of super. This issue has now been fixed, but it may be what is
> biting you:
>
> http://bugs.python.org/issue12370
>
> If this *is* the problem, then see the workarou