Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment:

Raymond, is this kind of recipes worth adding to the 'collections' module?

Maybe with the following form:

def enum(*valuenames):
     return namedtuple('Enum', valuenames)(*range(len(valuenames)))

----------
nosy: +amaury.forgeotdarc, rhettinger

__________________________________
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue2502>
__________________________________
_______________________________________________
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to