This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author Sergey.Kirpichev
Recipients Sergey.Kirpichev, abcdef, adityasriram.b, docs@python, miguendes, rhettinger
Date 2021-05-15.08:22:40
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
Maybe some methods from the Complex class could be moved to the Number class?

I think, that something like the ring structure (probably even a commutative ring) is expected from the number classes in the Python.  I.e. there should be __add__/__sub__/__mul__/__pos__/__neg__/__pow__/etc.  But not __truediv__/__floordiv__.

Even simpler idea: move the __eq__ method to the Number class.

Then it would be impossible to instantiate a Number.
Date User Action Args
2021-05-15 08:22:40Sergey.Kirpichevsetrecipients: + Sergey.Kirpichev, rhettinger, docs@python, abcdef, miguendes, adityasriram.b
2021-05-15 08:22:40Sergey.Kirpichevsetmessageid: <>
2021-05-15 08:22:40Sergey.Kirpichevlinkissue32133 messages
2021-05-15 08:22:40Sergey.Kirpichevcreate