On Dec 3, 2019, at 15:45, Greg Ewing <greg.ew...@canterbury.ac.nz> wrote:
> 
> On 4/12/19 7:26 am, Andrew Barnert via Python-ideas wrote:
>> If you’re using interning for functionality, to distinguish two equal 
>> strings that came from different inputs or processes, your code is probably 
>> broken.
> 
> That's not what interning is normally used for. Usually it's
> to allow test for equality to be replaced by tests for identity.

But why do you want to replace those tests? If it’s not for performance or for 
functionality, why do you care?

(In C it could be about convenience/readability—strcmp is ugly and easy to get 
wrong—but that doesn’t apply to Python.)
_______________________________________________
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/55GIID2S6PZVICAIJYYX5QYW7FAJNGRD/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to