[Python-Dev] Best practices for Enum

Antoine Pitrou solipsis at pitrou.net
Mon May 13 10:38:00 CEST 2013

Le Mon, 13 May 2013 00:06:52 -0700,
Raymond Hettinger <raymond.hettinger at gmail.com> a écrit :
> On May 12, 2013, at 8:26 PM, Eli Bendersky <eliben at gmail.com> wrote:
> > Thanks for the insights, Raymond. I don't think anyone is planning
> > on rushing anything. We still have to get the enum module itself
> > committed and a serious review process has just started for that,
> > so it will take time.
> > 
> > There's no general "let's replace all constants with enums" TODO
> > item that I know of. It's my hope that such changes will happen
> > very gradually and only when deemed important and useful by core
> > developers.
> Ethan's email suggests that against my advice he is in-fact going to
> go through the standard library, applying enums quite broadly.

It probably won't go in without reviews, so there's no need to be too
concerned IMHO.

The fact that one of the enum classes is an int subclass should make
the behaviour changes minimal, if any.



More information about the Python-Dev mailing list