Mark Dickinson <dicki...@gmail.com> added the comment:
> This decouples int from __trunc__ and leaves __trunc__ as simply the support > for the math.trunc function. Argh; copy and paste fail - I left out the crucial line. I propose deprecating the delegation of int to __trunc__: calls to int(a) where type(a) implements __trunc__ but not __int__ or __index__ would raise a DeprecationWarning, and at some point in the future int(a) would become a TypeError. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue44977> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com