> On 21 Jul 2024, at 10:22, Paul Howarth <p...@city-fan.org> wrote:
> 
> since enums are singletons in Python.

I am not near a computer to check this. The enum is a singleton.
But I am not sure that the values of an enum are singletons.
Often they are int and int’s are not singletons.

Int’s being usable with “is” is a side effect of cpython’s implementation
which make small int’s seem to be singletons.

If this is correct then the test is wrong and must use ==.

I will test tomorrow.

Barry



-- 
_______________________________________________
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue

Reply via email to