[Python-ideas] Should bool continue to inherit from int?

Ethan Furman ethan at stoneleaf.us
Wed Jan 21 19:20:48 CET 2015


On 01/21/2015 03:32 AM, Michael Mitchell wrote:

> 1) Would it still be very inconvenient to implement bools separately from ints?

Extremely.  Lots of code relies on the int properties of bool.

> 2) Do most Python users still agree that arithmetic operations should be supported on booleans?

I certainly do.  It might be nice from an ivory-tower perspective to keep bools separate from ints, but in a
Practicality Beats Purity world it is quite handy.

--
~Ethan~

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: OpenPGP digital signature
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20150121/d932090a/attachment.sig>


More information about the Python-ideas mailing list