Author jdemeyer
Recipients AVINASH MISHRA, jdemeyer, ncoghlan, remi.lapeyre, ronaldoussoren, serhiy.storchaka, vstinner
Date 2019-01-21.10:48:34
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
The motivation for PEP 357 was certainly using an object as the index for a sequence, but that's not the only use case.

In fact PEP 357 states "For example, the slot can be used any time Python requires an integer internally"

So despite the name __index__, I think that this is now the de facto standard for "convert the object (which is some kind of integer) to a Python int without loss of precision".
Date User Action Args
2019-01-21 10:48:35jdemeyersetrecipients: + jdemeyer, ronaldoussoren, ncoghlan, vstinner, serhiy.storchaka, remi.lapeyre, AVINASH MISHRA
2019-01-21 10:48:34jdemeyersetmessageid: <>
2019-01-21 10:48:34jdemeyerlinkissue35707 messages
2019-01-21 10:48:34jdemeyercreate