py.user added the comment:
>>> import itertools
>>>
>>> class A(itertools.chain):
... def from_iter(arg):
... return A(iter(arg))
...
>>> class B(A):
... pass
...
>>> B('a', 'b')
<__main__.B object at 0x7f40116d7730>
>>> B.from_iter(['a', 'b'])
<__main__.A object at 0x7f40116d7780>
>>>
it should be B
----------
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue18301>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com