Message93524
This is defined behaviour and no bug at all. Special methods are looked
up in the type for new-style classes and not in the instance. Try
changing ``self.__iter__=self.__str__`` to ``test1.__iter__ =
self.__str__`` in your example (which will then raise a TypeError on
the second iteration). |
|
Date |
User |
Action |
Args |
2009-10-04 08:57:02 | Trundle | set | recipients:
+ Trundle, omatt |
2009-10-04 08:57:02 | Trundle | set | messageid: <1254646622.82.0.899960860781.issue7053@psf.upfronthosting.co.za> |
2009-10-04 08:57:01 | Trundle | link | issue7053 messages |
2009-10-04 08:57:01 | Trundle | create | |
|