Author serhiy.storchaka
Recipients gvanrossum, serhiy.storchaka
Date 2020-10-08.06:55:25
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
The complex class has special methods which always raise a TypeError:


After removing them the corresponding operations (converting to int and float, operators // and %, function divmod()) will still a TypeError.

Advantages of removing:

* Less code to maintain.
* More uniform error messages.
* Clearer output of help().
* Possibility to implement a type with __rfloordiv__, __rmod__ and __rdivmod__ which support complex numbers.
Date User Action Args
2020-10-08 06:55:25serhiy.storchakasetrecipients: + serhiy.storchaka, gvanrossum
2020-10-08 06:55:25serhiy.storchakasetmessageid: <>
2020-10-08 06:55:25serhiy.storchakalinkissue41974 messages
2020-10-08 06:55:25serhiy.storchakacreate