Okay, I'll bite. On Sat, Dec 12, 2020 at 6:00 PM Ethan Furman <et...@stoneleaf.us> wrote:
> unlike Enum, duplicates are allowed > What does this even mean? ``` class K( NamedValues): A = 1 A = 2 ``` Why would I want that? > unlike Enum, new values can be added after class definition > Sure, that points to maybe a subclass of Enum? > unlike Enum, a NamedValue can always be used as-is, even if no data type > has been mixed in -- in other words, there is > no functional difference between MyIntConstants(int, NamedValue) and > MyConstants(NamedValue). > I'm not following this either. Can you give an example of something that doesn't work with Enum (and shouldn't work) but should work with NamedValues? Finally, why the plural in the name, where Enum and friends all have singular names? -- --Guido van Rossum (python.org/~guido) *Pronouns: he/him **(why is my pronoun here?)* <http://feministing.com/2015/02/03/how-using-they-as-a-singular-pronoun-can-change-the-world/>
_______________________________________________ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to python-ideas-le...@python.org https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/python-ideas@python.org/message/QCVOO6UVBSNWFCY2FNP5DAFVT5RDETAR/ Code of Conduct: http://python.org/psf/codeofconduct/