On 5/13/2021 10:02 AM, Tal Einat wrote:
On Thu, May 13, 2021 at 4:31 PM Eric V. Smith <e...@trueblade.com> wrote:
I do think a python-wide standard for this would be helpful, but I don't
see how to change existing code given backward compatibility constraints.
While we're on the subject, these sentinels also don't compare
properly using `is` after pickling and unpickling.
I think it's worth considering making the sentinels in the stdlib all
have good reprs and support pickling+unpickling.
What would be the potential backwards-compatibility issues with
changing the implementation of these existing sentinel values?
I don't think there would be a problem changing the implementation. I
was commenting on changing the name of the sentinel objects so that we
could document the functions with the sentinel's real name. We couldn't
change them to all be some appropriate module-level value named
"MISSING", for example.
Eric
_______________________________________________
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at
https://mail.python.org/archives/list/python-dev@python.org/message/SWGCTZFNGLFEQ5SL5GBVQFQAD2YAAZNI/
Code of Conduct: http://python.org/psf/codeofconduct/