Stefan Krah added the comment:

Ethan Furman <rep...@bugs.python.org> wrote:
> The current meaning is unfortunate in that it is possible to want a type that
> can be used as an index or slice but that is still not a number, and in fact
> won't be used as a number in any scenario _except_ bin(), hex(), and oct().

memoryview, struct and probably also array.array accept __index__.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue19995>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to