[Python-Dev] enum discussion: can someone please summarize open issues?

Greg Ewing greg.ewing at canterbury.ac.nz
Mon Apr 29 09:42:02 CEST 2013

Guido van Rossum wrote:
> (2a. We could also allow Color('red') is Color.red, but that could be
> confusing, and we can already do that with getattr(Color, 'red'),

That doesn't quite give you the same thing. Presumably
Color('__str__') would be expected to raise a ValueError,
for example.


More information about the Python-Dev mailing list