On Apr 25, 2013, at 02:54 PM, Guido van Rossum wrote: >I don't know what's going on,
Mostly that this is my first opportunity to chime in on the subject. >but it feels like we had this same discussion a week ago, and I still >disagree. Disregarding, the C[i] notation, I feel quite strongly that in the >following example: > >class Color(Enum): > red = 1 > white = 2 > blue = 3 > orange = 4 > >the values Color.red etc. should be instances of Color. This is how >things work in all other languages that I am aware of that let you >define enums. Is it enough that isinstance(Color.red, Color) returns True, or do you really-and-truly want them to be instances of Color? I still think it's weird, but I could accept the former if you're flexible on the latter, which in some sense is just an implementation detail anyway. -Barry
signature.asc
Description: PGP signature
_______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com