Barry A. Warsaw added the comment: On May 12, 2013, at 10:57 AM, Nick Coghlan wrote:
>I encountered an interesting suggestion [1] regarding the enum.Enum >convenience API: use the member names as their values, rather than the >current integers starting from one. > >Since we're now using definition order rather than value order for iteration, >this suggestion makes a lot of sense to me. Cute, but I want the functional API to be equivalent to the class syntax. Besides: X = Enum('X', ((name, name) for name in 'ant bee cat dog elk'.split())) is not so much typing. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue17961> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com