[Python-ideas] Enums

Ben Finney ben+python at benfinney.id.au
Wed Jul 27 23:42:07 CEST 2011


Barry Warsaw <barry at python.org> writes:

> Most enums (at least IME) are discrete objects that don't have a
> natural ordering.

+1. This is an important property of an enumerated type, IMO.

The fact that ‘bool’ disagrees (‘False < True’) is an artifact of its
history, and is not relevant for an argument for orderable EnumValues.

-- 
 \          “A thing moderately good is not so good as it ought to be. |
  `\        Moderation in temper is always a virtue; but moderation in |
_o__)                       principle is always a vice.” —Thomas Paine |
Ben Finney
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20110728/4d03a1d4/attachment.pgp>


More information about the Python-ideas mailing list